Hi guys, i’m trying to use postFX to render a video but i only got a black screen and only the audio is playing
import processing.video.*;
import processing.sound.*;
import ch.bildspur.postfx.builder.*;
import ch.bildspur.postfx.pass.*;
import ch.bildspur.postfx.*;
PostFX fx;
SoundFile file;
Movie myMovie;
Amplitude amp;
int numPixels;
int blockSize = 1;
color myMovieColors[];
void setup(){
size(500, 500, P3D);
fx = new PostFX(this);
//file = new SoundFile(this, "FKAtwigs.mp3");
//file.play();
//amp = new Amplitude(this);
//amp.input(file);
myMovie = new Movie(this, "teo2.mp4");
numPixels = width/blockSize;
myMovieColors = new color[numPixels * numPixels];
myMovie.loop();
}
void movieEvent(Movie m) {
m.read();
m.loadPixels();
m.play();
for(int j = 0; j < numPixels; j = j + 8){
for(int i = 0; i < numPixels; i = i + 8){
myMovieColors[j * numPixels + i] = m.get(i, j);
}
}
}
void draw(){
background(0);
//float vol = amp.analyze()*600;
for(int j = 0; j < numPixels; j = j + 8){
for(int i = 0; i < numPixels; i = i + 8){
int loc = myMovieColors[j * numPixels + i];
float r = red(loc);
float g = green(loc);
float b = blue(loc);
float br = brightness(loc);
strokeWeight(9);
stroke(r, g, b);
point(i * blockSize, j * blockSize, (br * 1.2));
}
}
//image(myMovie, 100, 100);
fx.render()
.bloom(0.5, 20, 40)
.compose();
}