GSVideo library video implementation
in
Contributed Library Questions
•
10 months ago
Hello together,
I would like to control a video sequence by mouse position. I use the GSVideo library. Every time when I'm going to compile the code the following error is occured:
"Could not find movie file called probesequenz01.mov"
The pde-file and the video-file are at the same folder. What's the problem? Thanks in advance.
That's the code:
- import codeanticode.gsvideo.*;
- GSMovie AdultManVideo;
- int BeamerWidth = 1024;
- int BeamerHeight = 768;
- void setup() {
- size(BeamerWidth, BeamerHeight);
- background(0);
- AdultManVideo = new GSMovie(this, "probesequenz01.mov");
- // Pausing the video at the first frame.
- AdultManVideo.play();
- AdultManVideo.goToBeginning();
- AdultManVideo.pause();
- }
- void movieEvent(GSMovie AdultManVideo) {
- AdultManVideo.read();
- }
- void draw() {
- // A new time position is calculated using the current mouse location:
- float f = constrain((float)mouseX / width, 0, 1);
- float t = AdultManVideo.duration() * f;
- if (AdultManVideo.ready()) {
- AdultManVideo.play();
- AdultManVideo.jump(t);
- AdultManVideo.pause();
- }
- image(AdultManVideo, 0, 0, width, height);
- }
1