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 › Capture to PImage
Page Index Toggle Pages: 1
Capture to PImage (Read 952 times)
Capture to PImage
Jan 3rd, 2010, 6:20pm
 
I was wondering if there was a way to get each frame of a video input one at a time and convert them to a PImage. I have not been able to find any way to do that.
Re: Capture to PImage
Reply #1 - Jan 4th, 2010, 2:28am
 
Have you looked at the Video Library page
Re: Capture to PImage
Reply #2 - Jan 4th, 2010, 8:36am
 
Yes, actually, I have. Obviously I've missed the important part of that library, and it would have been very helpful if you could have given me some kind of hint as to actually where in that library it was. I may not be the only person to have this problem in the future and this forum is indexed by the search feature on the website, making it almost a wiki of data relevant to the processing language.
Re: Capture to PImage
Reply #3 - Jan 5th, 2010, 2:46am
 
In a private message, you mention the Capture part of the library.
Personally, I only used the MovieMaker class, but saw some uses of the Movie class (in the forum, this huge information pool, as you point out), so I thought that by "video input" you mean reading a movie file.
I was terse because 1) some newcomers just overlook some information, or fail to mention their previous searches, 2) I have no direct experience in the field, but was willing to give a quick answer.

Movie extends PImage, ie. can be treated as such, which is obvious in the available() example, where we have myMovie.read() followed by image(myMovie, 0, 0).

Well, it looks like Capture behaves identically, so I think you have your answer. Which might not been so obvious, on second thought: indeed, stating the above explicitly (instead of letting people guess from code samples) might be good. Smiley
Page Index Toggle Pages: 1