LabVIEW

cancel
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:

Server:

Client:

 

Thanks in advance!



Message Edited by claudio.klein on 07-02-2008 04:03 PM
0 Kudos
Message 1 of 11
(9,903 Views)

Hello Claudio,

Try to move the constant with value 250 to inside the loop (Server.vi). 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
(9,871 Views)
Hi Bruno,
please think about your comment. Smiley Wink
Mike
Message 3 of 11
(9,855 Views)
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...
 
 
 
Klein
 
 
0 Kudos
Message 4 of 11
(9,844 Views)
Hi claudio,
another solution is to use the function from the avicap32.dll. How often do you need an image?
Mike
0 Kudos
Message 5 of 11
(9,833 Views)

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?

Regards.

Message 6 of 11
(9,830 Views)
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
(9,802 Views)

Claudio,

Check if this forum solve your problem.

http://forums.ni.com/ni/board/message?board.id=170&message.id=257625&requireLogin=False

Best regards.

Bruno M.

0 Kudos
Message 8 of 11
(9,766 Views)
Bruno,
 
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: www.hytekautomation.com/Products/IVision.html
 
 
Thanks again, Bruno!
0 Kudos
Message 9 of 11
(9,763 Views)

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.

http://joule.ni.com/nidu/cds/view/p/id/758/lang/en

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:

http://sine.ni.com/nips/cds/view/p/lang/en/nid/2881

Best Regards.

Bruno M.

0 Kudos
Message 10 of 11
(9,754 Views)