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.
Page Index Toggle Pages: 1
Image squishing with Capture? (Read 748 times)
Image squishing with Capture?
Aug 15th, 2007, 5:25am
 
Trying out Capture as I ran into the problem with JMyron that you can't know what framerate it's actually reading the video device at.

Capture works perfect native NTSC resolution, but obviously chews all the CPU.  Setting a smaller size with the same aspect ratio only scales the Y axis, the X (horz) appears to still be stretched at the full 640ish.

Anyone experience this?  Know cause?  Seems if it can scale one axis it should scale the other without issue.  I thought maybe I could scale a PImage before drawing it to the canvas, but doubt that would save any cpu cycles, especially if capture still has to run at the full res.

Capture device: Pinnacle HD Stick Pro (USB)

My Capture init bits look like:
Code:

Capture camera;
int[] _size = {320, 240};
void setup()
{
size(_size[0], _size[1]);
String[] devices = Capture.list();
camera = new Capture(this, _size[0], _size[1], devices[1], 30);
camera.source(Capture.COMPOSITE);
}


Admit 30fps is fast, but I need the high framerate for my application, hence the need to scale the video down instead.

Side Question: Capture shows an interlaced image, my source is uncompressed, Myron didn't have this issue (not sure why).  Would using a MPEG1/2/4 capture device get rid of this perhaps?
Page Index Toggle Pages: 1