Webcam capture/save without $3600 NI-Vision

I would like to use the NI-IMAQ drivers to capture a picture for a test system but my company won't purchase the vision module.  I can't blame them at $3600 per license!  There are some VIs that use system DLLs but they require .net programming, which I am not familiar with.
Is there any way to use IMAQ without parting with all that cash?

Hey Brock,
Andrey is right. The NI Vision Acquisition Software 8.6.1 and the IMAQdx driver that it contains now supports USB cameras (as long as they are Direct Show compliant). With this software, you would be able to acquire images and save them to file. The IMAQdx driver still requires a license. However, because the Vision Acquisition Software does not include any of the machine vision and image processing algorithms, it has a lower price tag. Check out the Release Notes to be sure that this software will work with what you have now.
Hope this helps.
-Ben
WaterlooLabs

Similar Messages

  • Webcam capture & save as JPEG image

    Hi,
    I'm creating an application to capture image via webcam using directshow. I've managed to capture the stream using samplegrabber.
    the problem is when I save the grabbed image to a JPEG, the colors are incorrect.
    provided the link of the captured image from the webcam http://www.filefreak.com/pfiles/44160/test2.jpg
    the right hand side of the image should be brown colored, not blue as in the picture.
    I've also test to save as a bmp image, the color are ok.
    this is how i save the grabbed webcam frame into a jpeg file
    sampleGrabber->GetCurrentBuffer(&bufferSize, (long*)frameBuffer); 
    //save into jpeg 
    struct jpeg_compress_struct cinfo; 
    struct jpeg_error_mgr jerr; 
    JSAMPLE * image_buffer=NULL; 
    FILE * outfile;      
    JSAMPROW row_pointer[1];     
    int row_stride;  
    cinfo.err = jpeg_std_error(&jerr); 
    jpeg_create_compress(&cinfo); 
    if ((outfile = fopen("test2.jpg", "wb")) == NULL) { 
            fprintf(stderr, "can't open %s\n", "test2.jpg"); 
        return; 
    image_buffer = (unsigned char*)frameBuffer; 
    jpeg_stdio_dest(&cinfo, outfile); 
    cinfo.image_width = videoWidth;      
    cinfo.image_height = videoHeight; 
    cinfo.input_components = 3;      
    cinfo.in_color_space = JCS_RGB;      
    jpeg_set_defaults(&cinfo); 
    jpeg_set_quality(&cinfo, 255, TRUE ); 
    jpeg_start_compress(&cinfo, TRUE); 
    row_stride = videoWidth * 3;     
    while (cinfo.next_scanline < cinfo.image_height) { 
        row_pointer[0] = & image_buffer[cinfo.next_scanline * row_stride]; 
        (void) jpeg_write_scanlines(&cinfo, row_pointer, 1); 
    jpeg_finish_compress(&cinfo); 
    fclose(outfile); 
    jpeg_destroy_compress(&cinfo); 
    //end save jpeg 
    Thanks.
    Regards

    Hi,
    Thanks
    for participating on the MSDN Forum! I think your question is mainly related
    with DirectX, but not Visual C++ Language. Thus, I suggest you post your
    question on the microsoft.public.win32.programmer.directx.video newsgroup, there you find DirectX experts and your
    question should be answered in no time.
    The people there will have enough experience with DirectX to give you the best
    advice or answer!
    http://www.microsoft.com/communities/newsgroups/en-us/default.aspx?dg=microsoft.public.win32.programmer.directx.video&lang=en&cr=US
    Thanks! Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Detecting Video Capture Devices without Installing JMF

    Hi All,
    I want to detect the video capture devices, without installing the JMF.
    I had included the jmf (windows version) in lib path in netbeans ide. I am able to detect the audio capture device. But unable to detect the video capture devices. But if I install the JMF, I am able to detect the Video Capture devices in My system. Can anyone help me?
    Thanks,
    Vinoth Kumar.

    YES! Please take a look at SIP Communicator project. They have all what u want.
    The main idea is copy all .dll files to System or System32 (Please check files which JMF will copy to ur computer and where).
    U need to have jmf.jar and sound.jar too ( maybe more) in your computer.
    Your program should have DirectSoundAuto.java, JavaSoundAuto.java, JavaSoundDetector.java, JMFInit.java. Those files are in JMStudio source code. They are used to detect all capture devices and register it to JMF, but wait !!! where they will be saved? In order to save information about capture devices which are detected, you should create "jmf.properties" file in the same location with jmf.jar.Therefore, u should modify the JMFInit.java so it can check if the "jmf.properties" exists. If it's not, you have to create it.
    Check SIP Communicator at Folder "media" then "device". They have modified those files I mentioned above and created some new files to SC can detect more devices.
    Edited by: tamngminh on Sep 16, 2008 9:50 AM

  • Simple Webcam Capture to JPG

    I cannot figure this out.
    All I want to do is write a simple program that will take a still capture from my webcam and save it as a JPG. I don't need any kind of GUI or drawing to the screen. I will be using it in a batch script to take a picture and upload to my website at a fixed interval.
    I have been messing around with it for a long time and have had no success. Here is some code I wrote just now that won't work. I have imported things while trying different pieces of code, but I never took any of them out. That's why I import so many things.
    As you can see, I throw the NoPlayerException and CannotRealizeException. I do not understand why I get these. Also, when I run the program the light on my webcam turns on so I know it's connecting at some level. The file saved test.jpg is not a capture but rather a black square. Is my error in getting the image from the webcam or in writing it onto the BufferedImage so I can the write it to the file?
    Any help would be appreciated.
    import javax.swing.*;
    import javax.swing.event.*;
    import java.io.*;
    import javax.media.*;
    import javax.media.format.*;
    import javax.media.util.*;
    import javax.media.control.*;
    import javax.media.protocol.*;
    import java.util.*;
    import java.awt.*;
    import java.awt.image.*;
    import java.awt.event.*;
    import com.sun.image.codec.jpeg.*;
    import javax.imageio.ImageIO;
    public class wc
         public static Player player = null;
         public static CaptureDeviceInfo di = null;
         public static MediaLocator ml = null;
         public static Buffer buf = null;
         public static Image img = null;
         public static BufferToImage btoi = null;
         public static void main(String[] args) throws IOException, NoPlayerException, CannotRealizeException
              String str = "vfw:Microsoft WDM Image Capture (Win32):0";
              di = CaptureDeviceManager.getDevice(str);
              ml = di.getLocator();
              player = Manager.createRealizedPlayer(ml);
              player.start();
              FrameGrabbingControl fgc = (FrameGrabbingControl)
              player.getControl("javax.media.control.FrameGrabbingControl");
              buf = fgc.grabFrame();
              btoi = new BufferToImage((VideoFormat)buf.getFormat());
              img = btoi.createImage(buf);
              BufferedImage bi = new BufferedImage(160, 120, BufferedImage.TYPE_INT_RGB);
              Graphics2D g2 = bi.createGraphics();
              g2.drawImage(img, null, null);
              File f = new File("test.jpg");
              ImageIO.write(bi, "jpg", f);
    }

    I have a question posted about this code, slightly modified in this thread:
    http://forum.java.sun.com/thread.jspa?threadID=5310154&tstart=0
    Would you check it out, I made a new thread because its not strictly related to this post.

  • Problem with webcam capture

    Dear all,
    Using the Peter Parente's "webcam capture" library (Webcam Continuous Capture.vi), I faced some problems. In fact instead of showing for example one 320*240 picture it displayed some smaller pictures with some other parts of the picture indicator left blank(black).
    What's the problem. Any help would be appreciated.
    Regards

    Hello Smal,
    I did a search for this library and it looks like it was developed some time ago.  The FAQ on the download page seems to indicate that you need to make sure that your acquisition parameters in Windows and LabVIEW need to match in order for this to work properly.  There was also a data type change between Vision 6.1 and 7.0 so that could be related, but it sounds more likely it is something else.
    If your camera is DirectShow compatible and you have Vision, you can try IMAQ for USB.  This, like Peter Parente's Library, is not actively being developed or supported by National Instruments Applications Engineers, but you may have some more luck, assuming you are using more recent versions of LabVIEW and Vision.
    If there is a problem with a specific VI, please try to narrow down where the problem is occurring.  You may be able to post an image that might indicate how the library is failing.
    I hope this helps!  Good luck with your application.
    Regards,
    Angela
    Applications Engineer

  • Manipulating Webcam capture??????

    Hi
    I have successfully managed to capture, transmit, receive and display (using an applet) a webcam capture using jmf.
    However I want to let the user to put their mouse on the applet and be able to scroll around, zoom in and out etc..
    Any suggestions?

    dear Fergus
    My main objective is to capture / preview video using an applet and then capture a still image. save this still image to a file in users machine and then upload the file to the server at a specified folder.
    this applet is a part of Student Registration system and to generate ID cards for students.
    can you help me in this regards ? I have catagorized the requirements and other details. I am pasting the same here.
    Video Capture Module
    Objective: To capture a still image from a web page and Upload the image to specified folder on the server.
    Technologies to be used: JAVA Applets, HTML & Servelets.
    Synopsis: This application basically involves use of Java Media Framework. The primary objectives of this module are categorized according to the functionality.
    1)     Detect the video capture device on the users machine.
    2)     Preview the Live Video from the Detected Compatible Video Capture device.
    3)     Ask for user to click to take a snap and save the file in users machine at some temporary location with some unique file name.
    4)     Upload the file to the server at the specified path.
    There are a few constraints to this application. These are identified in following according to severity of the constraint
    1)     Minimal download time for the applet and supporting files.
    2)     Browser compatibility with Internet Explorer 4.0 upward as well as Netscape Navigator 4.0 upward.
    3)     User interface flexibility and easy to plug-in to the main module.
    4)     Reusability of this module for other purposes.
    There are few technological hurdles involved in doing this. These are stated below in order of severity.
    1)     Detecting the Capture Device on users machine.
    2)     User should not be asked to install Java Media Studio on his / her machine. Whatever the files are required should be loaded at the runtime.
    3)     Making the applet compatible with both the browser technologies.
    Following assumptions are being made
    1)     The browsers are capable to handle applets i.e. the JVM & Java Plug-in are already installed.
    2)     Video capture device Drivers are installed in the machine and the Camera is plugged in to the system.
    The assumptions are prerequisite and must be met.
    Details of the Sub Modules:
    SM-1: Detect Video capture Device in users machine.
    This involves following steps
    1)     Initialize the applet and get permissions to access the system resources such as capture devices and other input devices. Having the signed applet with the required premissions can do this.
    2)     Once we have the permission to access the devices we can scan various input devices and store the information in some temporary place such as cookie.
    3)     If Compatible Video Capture device is found then query the Video capture device.
    4)     If the Video capture device is not found then prompt user to install the Video capture device and revert back to starting the applet again.
    5)     Check for the Device Capabilities. Compare that with our requirements.
    6)     If things are ok then we can proceed to next step else go back to step 4.
    7)     Save the device info for the future use possibly in a cookie.
    SM-2: Preview the Live Video from the Detected Compatible Video Capture device.
    This involves following steps
    1)     Read the information from the cookie.
    2)     Initialize the viewer for the Live Video.
    3)     Present the live video.
    4)     As a tool tip, we should suggest the user to focus the camera and adjust the camera lens to get a sharp image.
    SM-3: Ask for user to click to take a snap and save the file in users machine at some temporary location with some unique file name.
    This involves following steps
    1)     Ask user to look in to camera straight. Not to blink eyes while picture is being taken.
    2)     User should then click the snap button. As a useful tip we may also provide a keyboard short cut to capture the still image.
    3)     Once the image is captured show the still image instead of the live video.
    4)     Give an option to user to recapture the still image.
    5)     If user feels his / her image has been satisfactorily captured.
    6)     Ask for confirmation to save and upload the image to server.
    SM-4: Upload the file to the server at the specified path.
    This involves following steps
    1)     Check for user authentication.
    2)     Check for file name.
    3)     Check for file size.
    4)     If all above is ok then upload the image to server at the specified path.
    regards
    Virendra

  • Webcam capture

    I am using Logitech Quickcam Pro 9000 on my computer and I am
    trying to capture an image size of 533x280. I know it is a non
    standard size. The camera does seem to capture the image at that
    size, but it seems to truncate a lot of the image compared to
    another size that I capture for a different application, the size
    of which is 352x288, which is a standard CIF.
    I have two question based on this observation
    1. if I am streaming the bigger image (with details
    truncated) to FMS, does it transmit more pixels than the truncated
    image that appears on my screen. In short does it transmit more
    than 533x280x30 fps.
    2. Can webcams capture any size (within its outer bounds of
    course) or do they capture only standard sizes that are closest to
    the requested size. Does it make a difference in performance of the
    webcam?
    Thanks

    I would suggest you look at USTREAM. http://www.ustream.tv/
    You can use this free web service to record and broadcast webcam streams from your own computer (or someone else's).
    You can save the streams as an FLV file and then download the FLV to your own computer for editing.  If your bandwidth is reasonable (e.g. 300 kbps) and you use a good quality web cam such as the Logitech C910, which is full HD, you should be able to get excellent video.
    I'm currently using all of this to stream my daughter's wedding tomorrow.

  • Webcam Capture Picture Tool

    I want to write a program in VB 2010 that can capture photo using a webcam, and directly saves it to the database. Someone please help me. Thanks! 

    Hi,
     Here is a small code a made a while back that uses the capCreateCaptureWindowA API to capture a webcam and save pictures when the Save Picture button is clicked. You can test it out by creating a new form project and adding 2 buttons and 1 picturebox.
    Name one of the buttons (Button_SavePicture) and the other (Button_SetSizeColor). The picturebox i left as the default name (PictureBox1). In the Button_SavePicture click event you will want to change the path to where the images are saved or you will get
    an error there. As far as saving it to a database i will have to leave that up to someone that knows about using them. There is also this LINK
    where there is a few links to other ways using DirectShow and maybe more.
    Imports System.Runtime.InteropServices
    Public Class Form1
    Dim cWnd As IntPtr = IntPtr.Zero
    Dim devId As Integer = 0 '0 will be the first capture device found
    Dim picnumber As Integer = 0
    Dim tmppic As String = System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "Temp.dib")
    Private Const WS_CHILD As Integer = &H40000000
    Private Const WS_VISIBLE As Integer = &H10000000
    Private Const WM_USER As Integer = &H400
    Private Const WM_CAP_DRIVER_CONNECT As Integer = WM_USER + 10
    Private Const WM_CAP_DRIVER_DISCONNECT As Integer = WM_USER + 11
    Private Const WM_CAP_SET_PREVIEW As Integer = WM_USER + 50
    Private Const WM_CAP_SET_PREVIEWRATE As Integer = WM_USER + 52
    Private Const WM_CAP_SET_SCALE As Integer = WM_USER + 53
    Private Const WM_CAP_SAVEDIB As Integer = WM_USER + 25
    Private Const WM_CAP_DLG_VIDEOFORMAT As Integer = WM_USER + 41
    <DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Ansi)> Private Shared Function SendMessage(ByVal hWnd As IntPtr, ByVal Msg As Integer, ByVal wParam As Integer, ByVal lParam As String) As IntPtr
    End Function
    <DllImport("avicap32.dll", SetLastError:=True, CharSet:=CharSet.Auto)> Private Shared Function capCreateCaptureWindowA(ByVal lpszWindowName As String, ByVal dwStyle As Integer, ByVal x As Integer, ByVal y As Integer, ByVal nWidth As Integer, ByVal nHeight As Integer, ByVal hWndParent As IntPtr, ByVal nID As Integer) As IntPtr
    End Function
    <DllImport("user32.dll", SetLastError:=True, CharSet:=CharSet.Unicode)> Private Shared Function DestroyWindow(ByVal hwnd As IntPtr) As <MarshalAs(UnmanagedType.Bool)> Boolean
    End Function
    Private Sub Form1_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
    If Not cWnd.Equals(IntPtr.Zero) Then
    SendMessage(cWnd, WM_CAP_DRIVER_DISCONNECT, devId, Nothing)
    DestroyWindow(cWnd)
    End If
    If System.IO.File.Exists(tmppic) Then System.IO.File.Delete(tmppic)
    End Sub
    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    cWnd = capCreateCaptureWindowA(devId.ToString, WS_VISIBLE Or WS_CHILD, 0, 0, PictureBox1.Width, PictureBox1.Height, PictureBox1.Handle, 0)
    If Not SendMessage(cWnd, WM_CAP_DRIVER_CONNECT, devId, Nothing) = IntPtr.Zero Then
    SendMessage(cWnd, WM_CAP_SET_SCALE, 1, Nothing)
    SendMessage(cWnd, WM_CAP_SET_PREVIEWRATE, 66, Nothing)
    SendMessage(cWnd, WM_CAP_SET_PREVIEW, 1, Nothing)
    Else
    MessageBox.Show("Error connecting to capture device. Make sure your WebCam is connected and try again.")
    cWnd = IntPtr.Zero
    Me.Close()
    End If
    End Sub
    Private Sub Button_SavePicture_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button_SavePicture.Click
    SendMessage(cWnd, WM_CAP_SAVEDIB, 0, tmppic)
    Dim bmp As New Bitmap(tmppic)
    Dim saveas As String = "C:\TestFolder\MyPic_" & picnumber.ToString & ".jpg"
    picnumber += 1
    bmp.Save(saveas, Imaging.ImageFormat.Jpeg)
    bmp.Dispose()
    End Sub
    Private Sub Button_SetSizeColor_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button_SetSizeColor.Click
    'Shows a dialog window to choose the size and color depth of the image that the webcam is capable of using.
    SendMessage(cWnd, WM_CAP_DLG_VIDEOFORMAT, 0, Nothing)
    End Sub
    End Class

  • Error message: "Attempt to capture video without a video device selected."

    When trying to log and capture, I'm receiving the following error message: "Attempt to capture video without a video device selected. Please select a video device in your capture presents and try again."
    In Capture Presents under DV NTSC 48 kHz it says "WARNING: Video Device DV Video is missing."
    An attempt to edit the Capture Preset gives me QuickTime Video Setting Digitzer options of only "[missing] DV Video."
    This happened only after I upgraded to Tiger. I know Log and Capture is recognizing the camera because it's showing the timecodes, but not the image. Any help would be most appreciated.

    This reminds me of a problem with the QuickTime install. Try this - remove all the QuickTime associated .pkg files from /Library/Receipts, then go to http://www.quicktime.com and download the full installer and do a complete install.
    Post back,
    Patrick

  • Billing Document taking save without performing PGI

    Dear Experts,
    In our company all of our Billing is delivery related and we can not perform VF01 without performing post goods issue. But problem is we have configured a new company and after that Billing Documents taking save without performing PGI. Can you please advice us how can I restrict this again because we don't want any Billing document without PGI.
    Thanks in advance for your kind support and co-operation.
    Best Regards.
    Ripon Kumar Paul

    Hi Ripon.paul 
    --Go to copy controls T.Code VTFL & select your billing document & delivery document
    In Header
    Copying Req- 003
    Assignment no- C
    Reference No- E
    check mark copy item number
    In Item
    copying Requirments should be 004 (deliver -related item). (You have to do PGI before doing the billing)
    Data VBRK/VBRP - 001
    Billing qty - B
    pos/neg qty- +
    Pricing type- G
    Price source- E
    Let me know if your problem is solved
    Regards
    Pradeep

  • The shipment should not allow to save without partner forwarrding agent.

    The CR (forwarding agent) partner is set as Mandatory in the configuration for partner procedure TR, but you can save a shipment without this partner function.  We are only using Shipment type Z003 and the TR procedure is assigned, and the CR partner is set as mandatory but the system is not requiring it.  Why isn't the Mandatory flag working in create mode?  If there is a CR on a shipment already, it will not let you delete it, but it will let you create a shipment and save without the CR partner.  See Shipmentxxx in DX1, it was created and saved without any partners on the partner tab.
    The shipment should not allow to save without partner forwarrding agent.

    Hi,
    Check config for 'Set Up Partner Determination for Shipments'.
    I believe the Partner function for Forwarding agent is FA and here you are talking about CR.
    Also make sure you Partner determination procedure is reflecting in your Shipment type.
    Regards,
    Amit

  • How do I go back a step in numbers when making a mistake - it seems to save without asking

    Imac user

    Hi Ger,
    it seems to save without asking
    Adding to the advice from T2YUKI, try this setting in System Preferences > General > Ask to keep changes when closing documents > tick that box.
    Save, Save, Save as you work (if you are happy with your changes).
    If you make too many mistakes, close the document and Numbers (or any app) will ask you if you want to Save the changes (since your last Save).
    Click on 'Don't Save'.
    Reopen from Menu > Open Recent to get back to your last satisfactory version.
    Regards,
    Ian.
    Edit: Reopen from Menu > File > Open Recent to get back to your last satisfactory version.

  • CS4 Photoshop - saving on NAS storage - open file won't save without renaming it.

    open file won't save without renaming it.  If you try to save a file that you have adjusted in CS4 Photoshop on a networked drive, it won't save it.  If you rename it, sure.  If you are working on the local drive it is not a problem. 
    By the way, we have 2 users in house.  Both on Mac systems and both are using CS4 Creative Suite.  One Mac is OSX 10.6.8 - the other is Mac OSX 10.8.3.  The older Mac system does not have a problem. 
    Is this a Mac operating system problem?  would upgrading to CS6 solve the issue for our Mac OSX 10.8 ?

    Try the forum for Adobe Acrobat.

  • Exporting chronologically by capture time without having to rename files

    Is there any way to export files by capture time without having to rename all the files? Right now they are always rearranged numerically by the file name and get all mixed up chronologically.
    Thanks, Kinsey

    Although it may not be of help to you, it happens that Jeffrey Friedl's "Export to Zenfolio" (Lightroom plugin) provides the option to keep the destination folder (Gallery) sorted according to various criteria, such as creation date, etc. This would do what you want, but unfortunately this doesn't work for general export (e.g., to disk). I'm not aware if anyone's written a plugin that does export file-sorting for "general" export.
    Friedl also has written "Export to..." plugins for Smugmug, Picassa, Flickr, and Facebook, although I don't know if all (or any) of these have the same gallery sorting options as in his excellent Zenfolio export plugin.
    Phil

  • Do CS5 or CS6 include a save option save without artboard?

    Hi All,
    I am currently using CS4. Is there an eps save option in CS5 or CS6 that such as save with artboard (boolean).  The CS4 interface allows you to save without the artboard.  Now I as a final step before my save code I have to resize the artboard for my visual bounds of my file.
    Thanks,
    Carolyn

    Hi Carlos,
    At this point could we agree at this point that apple script is save is not working properly (in regards to artboards) when you are dealing with 1 art board and that ulitimately Adobe needs to fix this? I hope to test this soon on AI CS6.
    And, at this point we are discussing which is the best work around.
    That being said, I did some more testing reproducing your results with multiple images.  And yes I would agree that the code works well with 2 images on 2 separate artboards (Only only tested 1 & 2). Somehow using one artboard fell through the cracks.
    I was unsuccessful using the code in your most recent post.  However if I created a document with 2 art boards and with art only on the first artboard then saved via apple script with save multiple artboards set to false and omitted anything for range.  I got the best result. (Oddly I get the same result with one art board and setting save multiple art boards to true.)  The image imported into ID closely cropped.  However, this approach was still flawed.
    -- First the image imported slightly off by about 1 or 2 points too low.  Cut of the very top of the image and added about 1 or 2 points of white space before the bounding box at the end of the image.  My work has to be precise.  I am sure that this holds true for others as well.  This has to be addressed by Adobe before this solution could be considered a viable option.
    -- Second for this solution to work a second unnecessary art board needs to be added. I haven't tried adding one via script before saving.  If that is a case an the first item was fixed this could be a viable work around.  But adding a second art board to 50 to hundred of templates for a work around is not practical.
    Until I see that Adobe has fixed this issue,  I am going to stick with my current workaround.  It provides the accuracy I need.
    Thank you so much for your help and input. It has broadened my view of these save options.
    Carolyn

Maybe you are looking for