How to capture an image from my usb camera and display on my front panel

How to capture an image from my usb camera and display on my front panel

Install NI Vision Acquisition Software and NI IMAQ for USB and open an example.
Christian

Similar Messages

  • How do I acquire images from my usb webcam ?

    Hi all ,
    How do I acquire images from my usb webcam (logitech quickcam express ) ?
    I use Labview 7 .

    Pedrus wrote:
    > Hi all ,
    > How do I acquire images from my usb webcam (logitech quickcam express)?
    > I use Labview 7 .
    This seems a very popular question coming up about once every week at
    least. And there are many good answers in the developer Zone on www.ni.com
    Check out:
    Irene He's IVision Toolkit:
    http://www.hytekautomation.com/Products/IVision.html
    or
    Pete Parentes WebCam library:
    http://www.cs.unc.edu/~parente/labview/index.shtml
    The first is a rather impressive Video Manipulation library with a
    nice video capture interface to VfW too, and the second is a simple
    video capture library to access any VfW compliant device.
    Rolf K"
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Raspberry Pi B+ capture a image from a video cam

    Hello,
    is there any way to capture a image from the video camera. I didn't find any media class for video. Nor did I find any Runtime.exec to use a native linux command.
    Did I overseen something?

    Hi Klaus,
    There a few ideas in design stage, but nothing solid enough to talk about. And actually it should not have been possible with older ME as it's specifically prohibited by the spec. I mean native methods in Java applications. Of course there may be other means to communicate with native applications, like files, sockets etc. But no direct calls
    The date for ME 8.1 GA (General Availability) release is not confirmed yet. But it should happen quite soon, stay tuned
    Regards.
    Andrey

  • How to capture an image from a clip

    Hi,
    Is there a way to capture an image from a movie clip using iMovie 06?
    I would like to save some frames from the vedio footage as photos.
    Any help will be greatly appreciated. Thank you.
    New Mac User
      Mac OS X (10.4.5)  

    Hi iMac User:
    Yes-you can save a single frame from iMovie by selecting the File-->Save Frame As option. From there it will ask you where and in what format you want to save it.
    Just be aware that the quality won't be perfect because it is taken from a video clip.
    Sue

  • Can load image from file using LabVIEW and display on IMAQ graph?

    I dont have IMAQ Vision for LabVIEW on my computer. Is it possible to load image file and display on an IMAQ graph?
    Thanks!

    Hey werwr,
    In response to: "I dont have IMAQ Vision for LabVIEW on my computer. Is it possible to load image file and display on an IMAQ graph?"
    As of right now, in order to read an image from file, you actually do need the IMAQ Vision software. The IMAQ driver without the Vision VI's will allow you to collect images from a framegrabber, and it will allow you to save those images to file. But the function that allows you to read an image from file does require the Vision VI's. Once you have the VI to read images from a file, you will be able to display the image on an IMAQ "Graph" or otherwise known as an Image Display.
    I hope this helps. Please let me know if you have any further questions.
    Thanks,
    DJ
    Applications Engineer
    National Instruments

  • How to store character in file and display result on front panel

    hi
    currently i m working on FPGA project.i want to aquired data from FPGA board.i want to know about how to store character to file and contineous display each character on front panel in string format.
    i have complete up to character display on front panel but only single character display when i want all character in string format.
    Solved!
    Go to Solution.

    I don't see how this question is at all related to Digital I/O but it sounds like you just need a shift register with the concantanate string function.

  • Simply capture raster image from webcam or camera

    Hello everybody!
    First, thanks to all for all the good ideas I've read on this forum!
    I would like to capture images (raster type) from an external device (webcam, camera...) to apply particular processing on them. I would not like to lose time extracting these rasters... in a way to focus on my postprocessing stage. Does anybody know the simplest way to do this? JMStudio? but how?
    Thanks a lot!!!

    Hi...
    Could you not just use the Java Media Framework API to do an image capture from the webcam?
    http://java.sun.com/dev/evangcentral/totallytech/jmf.html

  • Re: how to capture a frame from a video file and save it as a jpeg

    package com.snn.multimedia;
    * @(#)FrameAccess.java     1.5 01/03/13
    * Copyright (c) 1999-2001 Sun Microsystems, Inc. All Rights Reserved.
    * Sun grants you ("Licensee") a non-exclusive, royalty free, license to use,
    * modify and redistribute this software in source and binary code form,
    * provided that i) this copyright notice and license appear on all copies of
    * the software; and ii) Licensee does not utilize the software in a manner
    * which is disparaging to Sun.
    * This software is provided "AS IS," without a warranty of any kind. ALL
    * EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING ANY
    * IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR
    * NON-INFRINGEMENT, ARE HEREBY EXCLUDED. SUN AND ITS LICENSORS SHALL NOT BE
    * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING
    * OR DISTRIBUTING THE SOFTWARE OR ITS DERIVATIVES. IN NO EVENT WILL SUN OR ITS
    * LICENSORS BE LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA, OR FOR DIRECT,
    * INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER
    * CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF THE USE OF
    * OR INABILITY TO USE SOFTWARE, EVEN IF SUN HAS BEEN ADVISED OF THE
    * POSSIBILITY OF SUCH DAMAGES.
    * This software is not designed or intended for use in on-line control of
    * aircraft, air traffic, aircraft navigation or aircraft communications; or in
    * the design, construction, operation or maintenance of any nuclear
    * facility. Licensee represents and warrants that it will not use or
    * redistribute the Software for such purposes.
    import java.util.Date;
    import java.util.Arrays;
    import java.util.Iterator;
    import javax.imageio.ImageIO;
    import javax.imageio.stream.ImageOutputStream;
    import javax.imageio.ImageWriter;
    import java.awt.*;
    import java.awt.image.BufferedImage;
    import java.awt.image.DataBufferByte;
    import javax.media.*;
    import javax.media.control.FramePositioningControl;
    import javax.media.control.TrackControl;
    import javax.media.Format;
    import javax.media.format.*;
    import javax.media.util.BufferToImage;
    import javax.media.util.ImageToBuffer;
    import java.io.FileOutputStream;
    import java.io.OutputStream;
    import com.sun.image.codec.jpeg.*;
    * Sample program to access individual video frames by using a
    * "pass-thru" codec. The codec is inserted into the data flow
    * path. As data pass through this codec, a callback is invoked
    * for each frame of video data.
    public class FrameAccess extends java.awt.Frame implements ControllerListener
    Processor p;
    Object waitSync = new Object();
    boolean stateTransitionOK = true;
    * Given a media locator, create a processor and use that processor
    * as a player to playback the media.
    * During the processor's Configured state, two "pass-thru" codecs,
    * PreAccessCodec and PostAccessCodec, are set on the video track.
    * These codecs are used to get access to individual video frames
    * of the media.
    * Much of the code is just standard code to present media in JMF.
    public boolean open(MediaLocator ml)
    try
    p = Manager.createProcessor(ml);
    catch (Exception e)
    System.err.println("Failed to create a processor from the given url: "
    + e);
    return false;
    p.addControllerListener(this);
    // Put the Processor into configured state.
    p.configure();
    if (!waitForState(p.Configured))
    System.err.println("Failed to configure the processor.");
    return false;
    // So I can use it as a player.
    p.setContentDescriptor(null);
    // Obtain the track controls.
    TrackControl tc[] = p.getTrackControls();
    if (tc == null)
    System.err.println("Failed to obtain track controls from the processor.");
    return false;
    // Search for the track control for the video track.
    TrackControl videoTrack = null;
    for (int i = 0; i < tc.length; i++)
    if (tc.getFormat() instanceof VideoFormat)
    videoTrack = tc[i];
    break;
    if (videoTrack == null)
    System.err.println("The input media does not contain a video track.");
    return false;
    VideoFormat currentFormat = (VideoFormat)videoTrack.getFormat();
    System.err.println("Video format: " + videoTrack.getFormat() );
    videoTrack.setFormat(new VideoFormat("RGB", currentFormat.getSize(), currentFormat.getMaxDataLength(), currentFormat.getDataType(), currentFormat.getFrameRate()));
    // Instantiate and set the frame access codec to the data flow path.
    try
    // Try to retrieve a FramePositioningControl from the player.
    FramePositioningControl fpc = (FramePositioningControl) p.getControl("javax.media.control.FramePositioningControl");
    if (fpc == null)
    System.err.println("The player does not support FramePositioningControl.");
    System.err.println("There's no reason to go on for the purpose of this demo.");
    return false;
    Time duration = p.getStopTime();
    long totalFrames = 0;
    if (duration != Duration.DURATION_UNKNOWN)
    System.err.println("Movie duration: " + duration.getSeconds());
    totalFrames = fpc.mapTimeToFrame(duration);
    if (totalFrames != FramePositioningControl.FRAME_UNKNOWN)
    System.err.println("Total # of video frames in the movies: "
    + totalFrames);
    } else
    System.err.println("The FramePositiongControl does not support mapTimeToFrame.");
    } else
    System.err.println("Movie duration: unknown");
    long[] frames;
    if (totalFrames > 0L)
    double intervalDouble = Math.floor(totalFrames / 5.0);
    long interval = new Double(intervalDouble).longValue();
    frames = new long[5];
    frames[0] = 1;
    frames[1] = frames[0] + interval;
    frames[2] = frames[1] + interval;
    frames[3] = frames[2] + interval;
    frames[4] = frames[3] + interval;
    } else
    frames = new long[1];
    frames[0] = 1;
    // Codec codec[] = { new PreAccessCodec(), new PostAccessCodec()};
    Codec codec[] = { new OverlayCodec(frames)};
    videoTrack.setCodecChain(codec);
    catch (UnsupportedPlugInException e)
    System.err.println("The process does not support effects.");
    // Realize the processor.
    p.prefetch();
    if (!waitForState(p.Prefetched))
    System.err.println("Failed to realize the processor.");
    return false;
    // Display the visual & control component if there's one.
    setLayout(new BorderLayout());
    Component cc;
    Component vc;
    if ((vc = p.getVisualComponent()) != null)
    add("Center", vc);
    if ((cc = p.getControlPanelComponent()) != null)
    add("South", cc);
    // Start the processor.
    p.start();
    setVisible(true);
    return true;
    public void addNotify()
    super.addNotify();
    pack();
    * Block until the processor has transitioned to the given state.
    * Return false if the transition failed.
    boolean waitForState(int state)
    synchronized (waitSync)
    try
    while (p.getState() != state && stateTransitionOK)
    waitSync.wait();
    catch (Exception e)
    return stateTransitionOK;
    * Controller Listener.
    public void controllerUpdate(ControllerEvent evt)
    if (evt instanceof ConfigureCompleteEvent
    || evt instanceof RealizeCompleteEvent
    || evt instanceof PrefetchCompleteEvent)
    synchronized (waitSync)
    stateTransitionOK = true;
    waitSync.notifyAll();
    } else
    if (evt instanceof ResourceUnavailableEvent)
    synchronized (waitSync)
    stateTransitionOK = false;
    waitSync.notifyAll();
    } else
    if (evt instanceof EndOfMediaEvent)
    p.close();
    System.exit(0);
    * Main program
    public static void main(String[] args)
    if (args.length == 0)
    prUsage();
    System.exit(0);
    String url = args[0];
    if (url.indexOf(":") < 0)
    prUsage();
    System.exit(0);
    MediaLocator ml;
    if ((ml = new MediaLocator(url)) == null)
    System.err.println("Cannot build media locator from: " + url);
    System.exit(0);
    FrameAccess fa = new FrameAccess();
    if (!fa.open(ml))
    System.exit(0);
    static void prUsage()
    System.err.println("Usage: java FrameAccess <url>");
    * Inner class.
    * A pass-through codec to access to individual frames.
    public class PreAccessCodec implements Codec
    * Callback to access individual video frames.
    void accessFrame(Buffer frame)
    // For demo, we'll just print out the frame #, time &
    // data length.
    long t = (long) (frame.getTimeStamp() / 10000000f);
    System.err.println("Pre: frame #: " + frame.getSequenceNumber()
    + ", time: " + ((float) t) / 100f + ", len: "
    + frame.getLength());
    * The code for a pass through codec.
    // We'll advertize as supporting all video formats.
    protected Format supportedIns[] = new Format[] {
    new VideoFormat(null)
    // We'll advertize as supporting all video formats.
    protected Format supportedOuts[] = new Format[] {
    new VideoFormat(null)
    Format input = null, output = null;
    public String getName()
    return "Pre-Access Codec";
    // No op.
    public void open()
    // No op.
    public void close()
    // No op.
    public void reset()
    public Format[] getSupportedInputFormats()
    return supportedIns;
    public Format[] getSupportedOutputFormats(Format in)
    if (in == null)
    return supportedOuts;
    } else
    // If an input format is given, we use that input format
    // as the output since we are not modifying the bit stream
    // at all.
    Format outs[] = new Format[1];
    outs[0] = in;
    return outs;
    public Format setInputFormat(Format format)
    input = format;
    return input;
    public Format setOutputFormat(Format format)
    output = format;
    return output;
    public int process(Buffer in, Buffer out)
    // This is the "Callback" to access individual frames.
    accessFrame(in);
    // Swap the data between the input & output.
    Object data = in.getData();
    in.setData(out.getData());
    out.setData(data);
    // Copy the input attributes to the output
    out.setFormat(in.getFormat());
    out.setLength(in.getLength());
    out.setOffset(in.getOffset());
    return BUFFER_PROCESSED_OK;
    public Object[] getControls()
    return new Object[0];
    public Object getControl(String type)
    return null;
    public class OverlayCodec extends PreAccessCodec
    long[] myFrames;
    BufferedImage work;
    byte[] workData;
    int width;
    int height;
    int dataLen;
    RGBFormat supportedRGB = new RGBFormat(null, // size
    Format.NOT_SPECIFIED, // maxDataLength
    Format.byteArray, // dataType
    Format.NOT_SPECIFIED, // frameRate
    24, // bitsPerPixel
    3, 2, 1, // red/green/blue masks
    3, // pixelStride
    Format.NOT_SPECIFIED, // lineStride
    Format.FALSE, // flipped
    Format.NOT_SPECIFIED); // endian
    public OverlayCodec(long[] frames)
    // force specific input format
    supportedIns = new Format[] {
    supportedRGB};
    myFrames = new long[frames.length];
    System.arraycopy(frames, 0, myFrames, 0, frames.length);
    public String getName()
    return "Capture Codec";
    public Format setInputFormat(Format format)
    if ((format != null) && (format instanceof RGBFormat)
    && format.matches(supportedRGB))
    // set up working image if valid type
    // (it should be since we insisted!)
    Dimension size = ((RGBFormat) format).getSize();
    width = size.width;
    height = size.height;
    dataLen = width * height * 3;
    if ((dataLen > 0)
    && ((work == null) || (work.getWidth() != width)
    || (work.getHeight() != height)))
    // working image - same 3-byte format as buffer
    work = new BufferedImage(width, height,
    BufferedImage.TYPE_3BYTE_BGR);
    // reference to pixel data
    workData = ((DataBufferByte) work.getRaster().getDataBuffer()).getData();
    return format;
    * Callback to access individual video frames.
    void accessFrame(Buffer in)
    try
    if (Arrays.binarySearch(myFrames, in.getSequenceNumber()) >= 0)
    BufferToImage stopBuffer = new BufferToImage((VideoFormat) in.getFormat());
    Image stopImage = stopBuffer.createImage(in);
    BufferedImage outImage = new BufferedImage(140, 96,
    BufferedImage.TYPE_INT_RGB);
    Graphics og = outImage.getGraphics();
    og.drawImage(stopImage, 0, 0, 140, 96, null);
    FileOutputStream fout = new FileOutputStream("image"
    + in.getSequenceNumber() + ".jpg");
    writeImage(outImage, fout);
    catch (Exception e)
    e.printStackTrace();
    public int process(Buffer in, Buffer out)
    try
    accessFrame(in);
    BufferToImage stopBuffer = new BufferToImage((VideoFormat) in.getFormat());
    Image stopImage = stopBuffer.createImage(in);
    ImageToBuffer outImagebuffer = new ImageToBuffer();
    out = outImagebuffer.createBuffer(stopImage, p.getRate());
    // Swap the data between the input & output.
    in.copy(out, true);
    catch (Exception e)
    e.printStackTrace();
    return BUFFER_PROCESSED_OK;
    void writeImage(BufferedImage outImage, OutputStream os) throws Exception
    Iterator writers = ImageIO.getImageWritersByFormatName("jpg");
    ImageWriter writer = (ImageWriter) writers.next();
    ImageOutputStream ios = ImageIO.createImageOutputStream(os);
    writer.setOutput(ios);
    writer.write(outImage);
    ios.close();

    Hi,
    I have a jpeg movie file 60 mins long and a text file tell me five time-lines for breaking the movie. For example, break the movie at 10:21, 16:05�
    The final output should be five small jpeg movie files. Each file contains a 90 sec (30 sec before the break time and 60 sec after the break time).
    Do you know any java library (jar) contain the library that can help me on programming this? Any existing source code? Any SDK for a movie editor can do that?
    Please help.
    Thanks
    Kenny

  • How to read images from local hard disk and display in tile layout

    Dear Folks,
    I have 100 images in a folder @ local hard disk (E drive).
    I would like to display them in Tile view of 3X3.
    I have options (Radio buttons) to chnage the layout at runtime to 4X4 , 5#5 and 6X6.
    Also when the change in layout happens, I wanted to make use of backgroudLoading of image view so that user do not want to wait till the entire tile loads.
    How do I achive this requiremet?
    Sample code if any of great help. Thanks in advance.
    Edited by: JavaFX_Duo on Jul 9, 2009 12:02 PM

    1. So I would like to know which is the {color:#3366ff}best way to load local images in ImageView{color}.I'm no expert, but is there a reason that you are using Swing to do the loading?
    2. secondly, currently the system displays all images only after the completion of creating all images. {color:#3366ff}How to display images as and when they are created.{color} So that the user has a feeling that the images are loading.JavaFX Image class let you display a lightweight placeholder, and you can bind the progress to some kind of visual indicator. I don't think you can display an image that is partially loaded.
    def PATHS: String[] = [
        "C://Ariel Atom//ariel-atom-1.jpg",
        "C://Ariel Atom//ariel-atom-2.jpg",
        "C://Ariel Atom//ariel-atom-3.jpg",
        "C://Ariel Atom//ariel-atom-5.jpg"
    function getImage(path: String): Image {
        Image {
            url: "file:///{path}"
            backgroundLoading: true
    Stage {
        title: "Image Tiles"
        width: 1024
        height: 800
        scene: Scene {
            content: [
                Tile {
                    columns: 2
                    tileWidth: 400
                    tileHeight: 400
                    content: for (i in [0..3]) {
                        ImageView {
                            image: getImage(PATHS)

  • How can I get text from a text field and display it in an alert?

    Hello!  I am BRAND NEW to Objective-C and Xcode and iOS, so PLEASE be forgiving of what is going to be a stupid question.  I have a text field.  I want to enter some text, click "return", and see my text in an alert.  It doesn't serve any useful purpose, but this is how I learn.  So far, I am unsuccessful.  Here's my function from my HelloEarthViewController.m file:
    -(IBAction)showInputMessageUITextField *)textField
    if ([textField.text isEqualToString:@""])
        return;
    UIAlertView *helloEarthInputAlert = [[UIAlertView alloc]
                                         initWithTitle:@"Name!" message:[NSString stringWithFormat:@"Message: %@", textField.text]
                                         delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
    // Display this message.
    [helloEarthInputAlert show];
    Then I go option+click the text field and drag it to File's Owner and connect it to "showInputMessage:"  Then I run it and the build succeeds, but nothing happens when I click my "return" button on the iPhone simulator.
    What have I missed?  Where have I gone wrong? 

    Okay, here's where I am.  I have this in my view controller .h file:
    @interface HelloEarthViewController : UIViewController <UITextFieldDelegate>
        IBOutlet UITextField *textFieldTest;
    @end
    And this in my view controller .m file:
    -(IBAction)showInputMessage
        if ([textFieldTest.text isEqualToString:@""])
            return;
        UIAlertView *helloEarthInputAlert = [[UIAlertView alloc]
                                             initWithTitle:@"Name!" message:[NSString stringWithFormat:@"Message: %@", textFieldTest.text]
                                             delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
        // Display this message.
        [helloEarthInputAlert show];
    And I have connected the text field to showInputMessage.  When I hit "return", however, I still get nothing.
    Is an "action button" a real button?  From my limited understanding, the alert should launch when I click "return" since showInputMessage is attached to Editing Did End on the text field.
    Thanks for the help.  The transition from writing C# for web applications to writing Objective-C for iOS applications is not going as smoothly as I'd anticipated.

  • How to send object arraylist from servlet to jsp and display using jstl

    Hi All....
    I have a simple application and problem with it.
    Once user logged in to system the user will redirect to LoginServlet.java controller.
    Then in LoginServlet I want to redirect user to another page called book_details.jsp.
    this is my login servlet.
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
              // TODO Auto-generated method stub
              PrintWriter out = response.getWriter();
              ArrayList<BankAccountDTO> account_list = new ArrayList();
              ResultSet resultSet = null;
              LowFairAirDB airDB = null;
              try{
                   airDB = new LowFairAirDB();
                   String query = "SELECT account_id, type, description, balance, credit_line, begin_balance, begin_balance_time_stamp FROM bank_account";
                   airDB.sqlSelect(query);
                   resultSet = airDB.getResultSet();
                   while(resultSet.next()){
                        account_list.add(new BankAccountDTO(resultSet.getInt(1),
                                                                     resultSet.getInt(4),
                                                                     resultSet.getInt(5),
                                                                     resultSet.getInt(6),
                                                                     resultSet.getString(2),
                                                                     resultSet.getString(3),
                                                                     resultSet.getString(7)));
              }catch(Exception ex){
              }finally{
                   try{resultSet.close();}catch(Exception ex){}
                   airDB.sqlClose();
         }I set bank account values to BankAccountDTO.java objects and add them to the arrayList.
    Next I want to send this objects arrayList to books_details.jsp and wanna display each objects values using JSTL.
    I still finding a way to go through this.
    1. Can anyone say how can I do it?
    2. Is there any other method to do the same thing without using JSTL?
    thanks in advance,
    Dil.

    Naishe wrote:
    In your servlet,
    request.setAttribute("account_list", account_list);
    requestDispatcher.findForward("/your/display/jsp");
    Good. I would only follow the Java naming conventions. E.g. accountList or accounts instead of the ugly PHP/C conventions.
    In the JSP,
    lst = (List< BankAccountDTO >)request.setAttribute("account_list");
    for(BankAccountDTO b: lst){
    populate your HTML tags or whatever
    Wrong. 1) You need getAttribute() and 2) you should not use scriptlets. Use JSTL c:forEach, e.g.<table>
        <c:forEach items="${accounts}" var="account">
            <tr>
                <td>${account.id}</td>
                <td>${account.type}</td>
                <td>${account.description}</td>
            </tr>
        </c:forEach>
    </table>To the topicstarter: for future JSP/JSTL related questions please use JSP/JSTL forum.
    Here it is: [http://forums.sun.com/forum.jspa?forumID=45].

  • How can I stop firefox from checking add-ons and displaying the What's new page each time I launch it

    Since upgrading to the latest version, I have viewed read and interacted with everything on the What's new page. I have done this a number of times but the page is still opened each time I launch Firefox. In addition it shows my homepage in a second tab.
    Prior to opening Firefox it checks for add-ons.

    hello Michells, this will likely be caused by the user.js file in your profile folder.
    go to the firefox ''menu ≡ > help ? > troubleshooting information'', click on ''profile folder/show folder'' and close all firefox windows afterwards. a windows explorer window should open up - in there delete the file named '''user.js''' and restart the browser afterwards.
    [[How to fix preferences that won't save]]

  • How to change the path of sysprep files that were copied to reference computer when i capture the image from reference.

    Dears ,,
    how to change the path that sysprep were copied to reference computer when i capture the image from reference.
    Should i modify some codes in LTIAPPLY.wsf? how to modify it?
    Thanks.

    Sysprep and capture has *Three* steps.
    1. Run sysprep on the local machine (easy).
    2. Copy WinPE down to the local machine so we can reboot into winpe for capture.
    3. Capture the drive in an *offline* state from within WinPE.
    What is most likely happening is that you are having problems with step #2. 100MB is *WAY* too small to copy down WinPE. By default MDT will make this System partition much bigger, 499MB. IF you install Windows 7 from the default media. IT will only create
    a 100MB partition.
    By default MDT 2012 Update 1 and greater *should* recover to a fallback drive with the OS on it, however if you are running older versions that might not happen correctly.
    If you are still having problems, copy your BDD.log file to a public share like OneDrive and copy the link here.
    Keith Garner - keithga.wordpress.com

  • Capturing an image from webcam

    hi, i'm trying to capture a image from a webcam, but i don't have a clue of how to do this, could anyone help me with samples or books.
    thanks.

    hi
    so as i understood u want to access the USB and make whats called camera interaction i worked with my webcam and i generate a video stream and i'm working now to sample this video
    i found these class on the internet u have to make a littel changes like camera defention
    * File: DeviceInfo.java.java
    * created 24.07.2001 21:44:12 by David Fischer, [email protected]
    import java.awt.Dimension;
    import javax.media.*;
    import javax.media.control.*;
    import javax.media.format.*;
    import javax.media.protocol.*;
    public class DeviceInfo
         public static Format formatMatches (Format format, Format supported[] )
              if (supported == null)
                   return null;
              for (int i = 0;  i < supported.length;  i++)
                   if (supported.matches(format))
                        return supported[i];
              return null;
         public static boolean setFormat(DataSource dataSource, Format format)
              boolean formatApplied = false;
              FormatControl formatControls[] = null;
              formatControls = ((CaptureDevice) dataSource).getFormatControls();
              for (int x = 0; x < formatControls.length; x++)
                   if (formatControls[x] == null)
                        continue;
                   Format supportedFormats[] = formatControls[x].getSupportedFormats();
                   if (supportedFormats == null)
                        continue;
                   if (DeviceInfo.formatMatches(format, supportedFormats) != null)
                        formatControls[x].setFormat(format);
                        formatApplied = true;
              return formatApplied;
         public static boolean isVideo(Format format)
              return (format instanceof VideoFormat);
         public static boolean isAudio(Format format)
              return (format instanceof AudioFormat);
         public static String formatToString(Format format)
              if (isVideo(format))
                   return videoFormatToString((VideoFormat) format);
              if (isAudio(format))
                   return audioFormatToString((AudioFormat) format);
              return ("--- unknown media device format ---");
         public static String videoFormatToString(VideoFormat videoFormat)
              StringBuffer result = new StringBuffer();
              // add width x height (size)
              Dimension d = videoFormat.getSize();
              result.append("size=" + (int) d.getWidth() + "x" + (int) d.getHeight() + ", ");
              // try to add color depth
              if (videoFormat instanceof IndexedColorFormat)
                   IndexedColorFormat f = (IndexedColorFormat) videoFormat;
                   result.append("color depth=" + f.getMapSize() + ", ");
              // add encoding
              result.append("encoding=" + videoFormat.getEncoding() + ", ");
              // add max data length
              result.append("maxdatalength=" + videoFormat.getMaxDataLength() + "");
              return result.toString();
         public static String audioFormatToString(AudioFormat audioFormat)
              StringBuffer result = new StringBuffer();
              // short workaround
              result.append(audioFormat.toString().toLowerCase());
              return result.toString();
    the second class:
    * File: MyDataSinkListener.java
    * created 24.07.2001 21:41:47 by David Fischer, [email protected]
    * Decription: simple data sink listener, used to check for end of stream
    import javax.media.datasink.*;
    public class MyDataSinkListener implements DataSinkListener
         boolean endOfStream = false;
         public void dataSinkUpdate(DataSinkEvent event)
              if (event instanceof javax.media.datasink.EndOfStreamEvent)
                   endOfStream = true;
         public void waitEndOfStream(long checkTimeMs)
              while (! endOfStream)
                   Stdout.log("datasink: waiting for end of stream ...");
                   try { Thread.currentThread().sleep(checkTimeMs); } catch (InterruptedException ie) {}
              Stdout.log("datasink: ... end of stream reached.");
    * File: MyDataSinkListener.java
    * created 24.07.2001 21:41:47 by David Fischer, [email protected]
    * Decription: simple data sink listener, used to check for end of stream
    import javax.media.datasink.*;
    public class MyDataSinkListener implements DataSinkListener
         boolean endOfStream = false;
         public void dataSinkUpdate(DataSinkEvent event)
              if (event instanceof javax.media.datasink.EndOfStreamEvent)
                   endOfStream = true;
         public void waitEndOfStream(long checkTimeMs)
              while (! endOfStream)
                   Stdout.log("datasink: waiting for end of stream ...");
                   try { Thread.currentThread().sleep(checkTimeMs); } catch (InterruptedException ie) {}
              Stdout.log("datasink: ... end of stream reached.");
    }[i]the 3rd class:/******************************************************
    * File: Stdout.java.java
    * created 24.07.2001 21:44:46 by David Fischer, [email protected]
    * Description: utility class for standard output
    public class Stdout
         public static void log(String msg)
              System.out.println(msg);
         public static void logAndAbortException(Exception e)
              log("" + e);
              flush();
              System.exit(0);
         public static void logAndAbortError(Error e)
              log("" + e);
              flush();
              System.exit(0);
         public static void flush()
              System.out.flush();
    the 4rt is :
    * File: TestQuickCamPro.java
    * created 24.07.2001 21:40:13 by David Fischer, [email protected]
    * Description: this test program will capture the video and audio stream
    * from a Logitech QuickCam� Pro 3000 USB camera for 10 seconds and stores
    * it on a file, named "testcam.avi". You can use the microsoft windows
    * media player to display this file.
    * operating system: Windows 2000
    * required hardware:  Logitech QuickCam� Pro 3000
    * required software: jdk 1.3 or jdk1.4 plus jmf2.1.1 (www.javasoft.com)
    * source files: DeviceInfo.java, MyDataSinkListener.java,
    *               Stdout.java, TestQuickCamPro.java
    * You can just start this program with "java TestQuickCamPro"
    * hint: please make shure that you setup first the logitech camerea drives
    * and jmf2.1.1 correctly. "jmf.jar" must be part of your CLASSPATH.
    * useful links:
    * - http://java.sun.com/products/java-media/jmf/2.1.1/index.html
    * - http://java.sun.com/products/java-media/jmf/2.1.1/solutions/index.html
    * with some small modifications, this program will work with any USB camera.
    import java.io.*;
    import javax.media.*;
    import javax.media.control.*;
    import javax.media.datasink.*;
    import javax.media.format.*;
    import javax.media.protocol.*;
    public class TestQuickCamPro
         private static boolean                    debugDeviceList = false;
         private static String                    defaultVideoDeviceName = "vfw:Microsoft WDM Image Capture (Win32):0";
         private static String                    defaultAudioDeviceName = "DirectSoundCapture";
         private static String                    defaultVideoFormatString = "size=176x144, encoding=yuv, maxdatalength=38016";
         private static String                    defaultAudioFormatString = "linear, 16000.0 hz, 8-bit, mono, unsigned";
         private static CaptureDeviceInfo     captureVideoDevice = null;
         private static CaptureDeviceInfo     captureAudioDevice = null;
         private static VideoFormat               captureVideoFormat = null;
         private static AudioFormat               captureAudioFormat = null;
         public static void main(String args[])
              // get command line arguments
              for (int x = 0; x < args.length; x++)
                   // -dd = debug devices list -> display list of all media devices - and exit
                   if (args[x].toLowerCase().compareTo("-dd") == 0)
                        debugDeviceList = true;
              // get a list of all media devices, search default devices and formats, and print it out if args[x] = "-dd"
              Stdout.log("get list of all media devices ...");
              java.util.Vector deviceListVector = CaptureDeviceManager.getDeviceList(null);
              if (deviceListVector == null)
                   Stdout.log("... error: media device list vector is null, program aborted");
                   System.exit(0);
              if (deviceListVector.size() == 0)
                   Stdout.log("... error: media device list vector size is 0, program aborted");
                   System.exit(0);
              for (int x = 0; x < deviceListVector.size(); x++)
                   // display device name
                   CaptureDeviceInfo deviceInfo = (CaptureDeviceInfo) deviceListVector.elementAt(x);
                   String deviceInfoText = deviceInfo.getName();
                   if (debugDeviceList)
                        Stdout.log("device " + x + ": " + deviceInfoText);
                   // display device formats
                   Format deviceFormat[] = deviceInfo.getFormats();
                   for (int y = 0; y < deviceFormat.length; y++)
                        // serach for default video device
                        if (captureVideoDevice == null)
                             if (deviceFormat[y] instanceof VideoFormat)
                             if (deviceInfo.getName().indexOf(defaultVideoDeviceName) >= 0)
                             captureVideoDevice = deviceInfo;
                             Stdout.log(">>> capture video device = " + deviceInfo.getName());
                        // search for default video format
                        if (captureVideoDevice == deviceInfo)
                             if (captureVideoFormat == null)
                             if (DeviceInfo.formatToString(deviceFormat[y]).indexOf(defaultVideoFormatString) >= 0)
                             captureVideoFormat = (VideoFormat) deviceFormat[y];
                             Stdout.log(">>> capture video format = " + DeviceInfo.formatToString(deviceFormat[y]));
                        // serach for default audio device
                        if (captureAudioDevice == null)
                             if (deviceFormat[y] instanceof AudioFormat)
                             if (deviceInfo.getName().indexOf(defaultAudioDeviceName) >= 0)
                             captureAudioDevice = deviceInfo;
                             Stdout.log(">>> capture audio device = " + deviceInfo.getName());
                        // search for default audio format
                        if (captureAudioDevice == deviceInfo)
                             if (captureAudioFormat == null)
                             if (DeviceInfo.formatToString(deviceFormat[y]).indexOf(defaultAudioFormatString) >= 0)
                             captureAudioFormat = (AudioFormat) deviceFormat[y];
                             Stdout.log(">>> capture audio format = " + DeviceInfo.formatToString(deviceFormat[y]));
                        if (debugDeviceList)
                             Stdout.log(" - format: " +  DeviceInfo.formatToString(deviceFormat[y]));
              Stdout.log("... list completed.");
              // if args[x] = "-dd" terminate now
              if (debugDeviceList)
                   System.exit(0);
              // setup video data source
              MediaLocator videoMediaLocator = captureVideoDevice.getLocator();
              DataSource videoDataSource = null;
              try
                   videoDataSource = javax.media.Manager.createDataSource(videoMediaLocator);
              catch (IOException ie) { Stdout.logAndAbortException(ie); }
              catch (NoDataSourceException nse) { Stdout.logAndAbortException(nse); }
              if (! DeviceInfo.setFormat(videoDataSource, captureVideoFormat))
                   Stdout.log("Error: unable to set video format - program aborted");
                   System.exit(0);
              // setup audio data source
              MediaLocator audioMediaLocator = captureAudioDevice.getLocator();
              DataSource audioDataSource = null;
              try
                   audioDataSource = javax.media.Manager.createDataSource(audioMediaLocator);
              catch (IOException ie) { Stdout.logAndAbortException(ie); }
              catch (NoDataSourceException nse) { Stdout.logAndAbortException(nse); }
              if (! DeviceInfo.setFormat(audioDataSource, captureAudioFormat))
                   Stdout.log("Error: unable to set audio format - program aborted");
                   System.exit(0);
              // merge the two data sources
              DataSource mixedDataSource = null;
              try
                   DataSource dArray[] = new DataSource[2];
                   dArray[0] = videoDataSource;
                   dArray[1] = audioDataSource;
                   mixedDataSource = javax.media.Manager.createMergingDataSource(dArray);
              catch (IncompatibleSourceException ise) { Stdout.logAndAbortException(ise); }
              // create a new processor
              // setup output file format  ->> msvideo
              FileTypeDescriptor outputType = new FileTypeDescriptor(FileTypeDescriptor.MSVIDEO);
              // setup output video and audio data format
              Format outputFormat[] = new Format[2];
              outputFormat[0] = new VideoFormat(VideoFormat.INDEO50);
              outputFormat[1] = new AudioFormat(AudioFormat.GSM_MS /* LINEAR */);
              // create processor
              ProcessorModel processorModel = new ProcessorModel(mixedDataSource, outputFormat, outputType);
              Processor processor = null;
              try
                   processor = Manager.createRealizedProcessor(processorModel);
              catch (IOException e) { Stdout.logAndAbortException(e); }
              catch (NoProcessorException e) { Stdout.logAndAbortException(e); }
              catch (CannotRealizeException e) { Stdout.logAndAbortException(e); }
              // get the output of the processor
              DataSource source = processor.getDataOutput();
              // create a File protocol MediaLocator with the location
              // of the file to which bits are to be written
              MediaLocator dest = new MediaLocator("file:testcam.avi");
              // create a datasink to do the file
              DataSink dataSink = null;
              MyDataSinkListener dataSinkListener = null;
              try
                   dataSink = Manager.createDataSink(source, dest);
                   dataSinkListener = new MyDataSinkListener();
                   dataSink.addDataSinkListener(dataSinkListener);
                   dataSink.open();
              catch (IOException e) { Stdout.logAndAbortException(e); }
              catch (NoDataSinkException e) { Stdout.logAndAbortException(e); }
              catch (SecurityException e) { Stdout.logAndAbortException(e); }
              // now start the datasink and processor
              try
                   dataSink.start();
              catch (IOException e) { Stdout.logAndAbortException(e); }
              processor.start();
              Stdout.log("starting capturing ...");
              try { Thread.currentThread().sleep(10000); } catch (InterruptedException ie) {}     // capture for 10 seconds
              Stdout.log("... capturing done");
              // stop and close the processor when done capturing...
              // close the datasink when EndOfStream event is received...
              processor.stop();
              processor.close();
              dataSinkListener.waitEndOfStream(10);
              dataSink.close();
              Stdout.log("[all done]");
    }finally search with the athour name there is an additional program u must download to detect ur cam .
    i hope that is work with u

  • Capture an image using the web camera from a web application

    Hi All,
    Could anyone please share the steps what have to be followed for capture an image using the web camera from a web application.
    I have a similar requirement like this,
    1) Detect the Webcam on the users machine from the web application.(To be more clear when the user clicks on 'Add Photo' tool from the web application)
    2) When the user confirms to save, save the Image in users machine at some temporary location with some unique file name.
    3) Upload the Image to the server from the temporary location.
    Please share the details like, what can be used and how it can be used etc...
    Thanks,
    Suman

    1) Detect the Webcam on the users machine from the web application.(To be more clear when the user clicks on 'Add Photo' tool from the web application)There's not really any good way to do this with JMF. You'd have to somehow create a JMF web-start application that will install the native JMF binaries, and then kick off the capture device scanning code from the application, and then scan through the list of devices found to get the MediaLocator of the web cam.
    2) When the user confirms to save, save the Image in users machine at some temporary location with some unique file name.You'd probably be displaying a "preview" window and then you'd just want to capture the image. There are a handful of ways you could capture the image, but it really depends on your situation.
    3) Upload the Image to the server from the temporary location.You can find out how to do this on google.
    All things told, this application is probably more suited to be a FMJ (Freedom for Media in Java) application than a JMF application. JMF relies on native code to capture from the web cams, whereas FMJ does not.
    Alternately, you might want to look into Adobe Flex for this particular application.

Maybe you are looking for

  • ICloud with personal email - Calendar Event Sharing

    Calendar event sharing seems to be a pain for a lot of people especially because of the new iCloud and even more so if you are a legacy .Me or .Mac user. First of all if you are a first time iCloud user and you entered your own personal e-mail addres

  • RFC adapter...How it handles multiple calls...

    Hi folks Basic doc'tation on RFC adapter states...qRFC is not supported..Agreed.. I have a scenario where I need to dump lot of transactions from a flat file to an RFC. I have split the single structure by 1:n mapping(multi) and pushed each message u

  • May be getting hacked by someone...

    I'm getting Dos attacked off xbox live and I know exactly who it is and his IP address.. I would just like to know if anyone has an email address where I can shoot these pictures over to show them who it is and what he's doing.. He is just a stupid k

  • CS4 Design Premium installation failure on Win-7

    I have tried this installation a number of times now and continually get a problem with kb403891r2 error regarding the UninstallColorProfilesRollback preventing the installation. I have tried both solutions I was taken to by the Adobe Support advisor

  • Life cycle of Cirrus server peer id

    After netConnection.connect to Cirrus server and get a nearID, is there life cycle (or session timeout) for this peer id? My scenario is, when one member on my web site has a Cirrus peer id at the begining, he can video chat with others. Then, next t