Quantcast
Channel: Processing Forum
Viewing all articles
Browse latest Browse all 1768

Re : Videos with alpha mask() sync problem

$
0
0
Thanks for the quick response Amnon.owed!

Had a look at this thread before, but I don't seem to get Akiersky's code working.

Nevertheless, I managed to get the layers synced up with a different method. This works fine with one RGB move and one ALPHA movie, but applying it to further ones will cause the sketch slow down and the masks will appear out of sync again.

Thought I post it for anybody, who only wants to use this method:

  1. float elair_timespot;
    float moviespeed = 0.05;
  1.      elair_mask.read();
         elair.read();
     
         elair.loop();
         elair_mask.loop();
        
         if (elair_timespot < elair.duration()) {
           elair_timespot += moviespeed;
         } else {
           elair_timespot = 0;
         }
         elair.jump(elair_timespot);
         elair_mask.jump(elair_timespot);

         elair.mask(elair_mask);
         image(elair, width/2, height/2);

Viewing all articles
Browse latest Browse all 1768

Trending Articles