Showing results for 
Search instead for 
Did you mean: 

Grab images from USB Webcam (Peter Paret's driver) too slow..

Hi everybody!

I'm developing a code to grab images from a USB webcam. So, I have been using the Peter Parent's driver for a long time and I don't need to use IMAQ drivers at all.

It's because I just want to grab images and transfer them using datasocket protocol. I don't have to make any kind of manipulation.
But, I realized that this code is quite slow. Even if I use it in a separate loop running in parallel.

I'd like to program a server to acquire data from several sensors e transmit these information using datasocket, including the webcam images.

That's my problem. If I use the Peter's code to grab images, my acquisition time slow down too much....

Could anybody help me? Is there another solution just to grab images from USB webcams without have to buy the IMAQ driver for this task?

My code:




Thanks in advance!

Message Edited by claudio.klein on 07-02-2008 04:03 PM
0 Kudos
Message 1 of 11

Hello Claudio,

Try to move the constant with value 250 to inside the loop ( Your loop is not been timed with this constant outside the loop.

Check it solves your problem.

Best regards.

Bruno M.

0 Kudos
Message 2 of 11
Hi Bruno,
please think about your comment. Smiley Wink
Message 3 of 11
Thanks Bruno for your post.
But it's not the problem because when the while loop begins it first copy the constant value to inside the loop and don't check it anymore...
0 Kudos
Message 4 of 11
Hi claudio,
another solution is to use the function from the avicap32.dll. How often do you need an image?
0 Kudos
Message 5 of 11

You are sure, Mike.

Claudio, can you give us more information about your computer, including the processor speed, RAM memory, etc? Which is your windows version? Which is your Labview version?


Message 6 of 11
I have to monitor a laboratory room where there is a mechanical test under execution. So, I'm planning to grab the images every 200ms or until 500ms.
I don't know nothing about the avicap32.dll. I'm going to search about it.
Here are the specifications of the lab computer:
Processor: Pentium D 2.8 GHz (dual core)
RAM memory: 2 GHz
O. System: Windows XP Pro SP2
LabVIEW version: 8.2.1 (without IMAQ or Vision)
0 Kudos
Message 7 of 11


Check if this forum solve your problem.

Best regards.

Bruno M.

0 Kudos
Message 8 of 11
I had already read this topic about avicap32.dll.
I have a feeling that this solution is not so simple... I think it depends on specific webcam information (parameters) and I don't have them....
I'm still searching for a solution... Maybe, I can consider this toolkit:
Thanks again, Bruno!
0 Kudos
Message 9 of 11

Sorry Claudio.

We can´t offer support to 3rd party VIs.

Maybe if you install the NI-IMAQ 3.1.3 drivers it can solve your problem.

The better suggestion is to buy NI Vision Development Module that allows you to use much more functions.

More informations you will find in NI Vision Development Module:

Best Regards.

Bruno M.

0 Kudos
Message 10 of 11