Not able to able capture video through AmCap!!!! Please help me...

Discussion in 'Windows Vista Drivers' started by darshan.tapdia, Nov 9, 2006.

  1. Hi all,
    I have written AvStream Class Minidriver for USB camera. I tested
    it with Amcap.exe . IT works fine for previewing.
    - > But when i tried to capture through AmCap it doesnt show any
    frames captured. I mean i doesnt capture. Please give some pointers on
    Waiting for reply.
    darshan.tapdia, Nov 9, 2006
    1. Advertisements

  2. sorry for mistake i posted it twice..
    darshan.tapdia, Nov 9, 2006
    1. Advertisements

  3. You must have correct timestamps and dropped/captured frames for each frame.
    See avssamp or testcap examples for reference.
    Anatoly Greenblatt, Nov 9, 2006
  4. Thanks a for helping Anatoly,
    Actually , as this driven r i havent implemeted Master clock,
    but for timestamping i am using.. Mechanism as....
    PresentationTime = PresentSystemTime - StreamStarTime ;
    Where... StreamStartTime , i have stored at RUN State of the pin ,
    which is inturn systemtime at that point of time.For Every sample i
    calculate and do the same.

    Will this approach work.? if not Please,give some more suggestions.

    Please guide me. Waiting for reply.
    darshan.tapdia, Nov 9, 2006
  5. You dont have to implement master clock. Stream clock and system clock is
    not the same thing, so you better find the master clock and query it instead
    of system time. There is also a bunch of parameters to be filled, see
    CVideoCapturePin::CaptureFrame in avssamp for reference.

    Anatoly Greenblatt, Nov 12, 2006
  6. Hi Anatoly,
    I have filled all stream header members properly. Do we need to
    fill-up KS_FRAME_INFO structure too????.
    One more behaviour i found out when i tried my driver in
    KsStudio with Sink Capture Test Filter(Avaiable in KsKstudio Test
    filters) is that, after connection, when i start streaming "Log
    Windiow" doesnt show any thing about captured samples, rather it shows
    IOCTL_READ_STREAM....and no pictures come in the preview window.

    When i try to stop the previewing from Sink Capture filter ,
    the streaming never stops unless and untill i manually stop from my
    Well, in other sample avsshw(PinCentric Processing as my
    implementation is also pincentric) it works fine.

    Please help , because problems lies as it is. Some more pointer
    would really help./
    Thanks a lot,
    darshan.tapdia, Nov 13, 2006
  7. Hi,
    Addtion to previous mail ,
    I am using KsPinGetReferenceClockInterface to get the
    reference to the available clock. and during intializing the stream
    If i dont have clock.
    pStreamHeader->PresentationTime.Time = 0
    pStreamHeader->PresentationTime.Numerator = 1;
    pStreamHeader->PresentationTime.Denominator = 1;
    pStreamHeader->Duration =AvgTimePerFrame;

    pStreamHeader->OptionsFlags |=

    pStreamHeader->DataUsed = FRAME_SIZE

    Please review and let me know,
    Thanks ,
    darshan.tapdia, Nov 13, 2006
  8. darshan.tapdia

    Max Paklin Guest

    Does the file you capture grow at size over time while you capture?
    Do you see a single frame from the file you captured?

    You might want to check if you generate correct stream for the format of the
    data that you negotiate during connection for the _capture_ case.
    Also see what format gets negotiated for the playback case and then disable
    all formats other than that one and see if you can capture anything.

    I am fairly certain that wrong time stamps is not the source of your
    problem. If timestamps were off you'd still be able to see some video.

    -- Max.
    Max Paklin, Nov 16, 2006
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.