[PD] Capturing images from a DVcam / webcam

chris clepper cgc at humboldtblvd.com
Wed Jul 9 08:33:23 CEST 2003


>Hello
>
>I would like to capture the pixel values of a DVcam image in order 
>to use these
>values in a patch. I'm not interested in displaying the image, so the frame
>rate is not very important.
>These values will be used for filling a matrix regularly (in the patch). As
>this matrix is quite small, the capture X-Y-resolution should be low (possibly
>the same as the size of the matrix) in order to save computation time. 
>
>I think it's possible with GEM, but it may slow the patch. What is the best
>method for doing this ?
>
>Maybe I should use a webcam instead of the DVcam, too.

Again - what platform are you trying this under?  Video capture is 
platform dependent.

Also, things like scaling will most likely not be done in hardware so 
decreasing the size of the incoming image will almost always also 
decrease performance!  Take DV for example, it should always be 
720x480/576 in every situation since the various capture APIs will do 
software resizing of the DV stream, and I can assure you that most of 
them don't do this in the most efficient way.  If you want a smaller 
matrix from a DV image you should capture at DV resolution and use 
your own sampling algo code.  You might want to just use a few 
pix_info objects ins series to sample various intervals of pixel 
values.  I also seem to recall writing some sort of pixel averaging 
object for testing purposes - perhaps this might be useful for 
analysis like you want to do?

Another thing to remember is that nearly every video input/capture 
device natively uses YUV and _NOT_ RGB color-space.  The only version 
of GEM that doesn't do slow, painful, frame-rate killing conversion 
is the one for OSX.

cgc

>
>Thank you all,
>
>Julien




More information about the Pd-list mailing list