Hello Akiersky
thank you very much for your code !
I'm trying to use it but I don't get it. I think I do it in a very wrong way >
- import processing.opengl.*;
- import codeanticode.gsvideo.*;
- import codeanticode.glgraphics.*;
- BGvideo bgv = new BGvideo ("marsRVBA.mov",app);
- void setup(){
- size(640,480);
- }
- void draw(){
- bgv;
- background(34,231,90);
- }
- public class BGvideo {
- GSMovie myMovie;
- GLTexture tex;
- public BGvideo (String videoFile, PApplet app) {
- app.registerDraw(this);
- myMovie = new GSMovie(app, videofile );
- tex = new GLTexture(app);
- myMovie.setPixelDest(tex);
- myMovie.loop();
- }
- public void draw () {
- myMovie.read();
- if (tex.putPixelsIntoTexture()) {
- background(255, 0, 0);
- image(tex, 0, 0, 1920, 487);
- }
- }
- }