We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › accessing Movie pixels
Page Index Toggle Pages: 1
accessing Movie pixels (Read 970 times)
accessing Movie pixels
May 2nd, 2005, 9:06pm
 
I've been trying to access pixel data from the Movie object, so I can apply effects before its drawn to the screen but i can't find a way. The only solution i can think of is to display the Movie with image(), then use copyPixel() into a PImage object and apply manipulations there,(so I can use it as a texture in OPENGL). This seems very inefficient though.
I'd try using PGraphics2, but from what I've read in these forums and what I've tried, it's broken in the current version.
Does anyone have any ideas of how to acces pixel data from a Movie object.

thank you
Re: accessing Movie pixels
Reply #1 - May 2nd, 2005, 9:26pm
 
well .. movie extends PImage so it should be usable just the same ..

have you read this in the faq(?):
Quote:
When using the pixels[] array of the main window, or on an image, you should first call loadPixels(), and once you're done editing, call updatePixels(). This is because the new JAVA2D and OPENGL renderers both need to post-process the image data before displaying it, which is a time-consuming operation.


F
Page Index Toggle Pages: 1