Issues
Below are some common issues people have when using FIP and how to resolve them. If your issue is not listed below, please report it here and I'll try to help you or fix it.
Out of date graphics drivers
As FIP runs GLSL shaders on the GPU, make sure you update to the latest graphics drivers for your GPU (how?), otherwise you may see some visual glitches.
Not passing textures
Some shaders have required parameters and will not work if these parameters are not passed into them. Below we use the blend shader but fail to pass it the textures we want to blend, so it does nothing.
import fip.*;
PShader blend;
PImage ireland;
PImage bird;
void setup() {
size(1000, 1000, P3D);
blend = loadShader(FIP.blend);
ireland = loadImage("ireland.jpg");
bird = loadImage("bird.jpg");
// blend.set("texture1", ireland); - Blend requires these 2 textures to be passed into it.
// blend.set("texture2", bird);
blend.set("mixFactor", 0.5);
blend.set("blendingMode", 0);
}
void draw() {
background(255);
filter(blend);
}