Page 39 of 102 FirstFirst ... 29303132333435363738394041424344454647484989 ... LastLast
Results 381 to 390 of 1016
Like Tree1Likes

Thread: One-Click WebCam Recording!

  1. #381
    Newbie Cameleon's Avatar
    Join Date
    May 2007
    Location
    UK
    Posts
    33
    Right more digging -

    AV sync issue seems to be down to the varying framerate of the video and the audio clock being different. There is a code snippet posted on the original CaptureTest page which supposidly fixes it. Will try that out soon.

    Also found this while digging - http://www.limegreensocks.com/DShow/ - it has a CaptureTest updated to use the SourceForge DirectShowNet v2.0 (updated CaptureTest in Dec 2008). I think thats about as recent as we will get.

    To solve the AV sync issues properly, you apparently have to use the audio clock as a master and pad the audio out (copy sample or drop samples) to match the video, and it will then stay in sync. This has been done in VirtualVCR which seems to work much better for me. This is the deal breaker for me, as recording decent quality footage from track days, I want to have decent audio. Not sure this will be achieved easily

  2. #382
    What can I say? I like serial. Curiosity's Avatar
    Join Date
    Mar 2004
    Location
    Florence Yall, BFKY
    Posts
    2,684
    Just grab the IConfigAviMux interface and call SetMasterStream(1) to use the clock off the audio board if you're not. It would look kinda bad without a clock source.

  3. #383
    FLAC
    Join Date
    May 2006
    Location
    Calgary, Alberta
    Posts
    1,718
    Quote Originally Posted by tj!2k4 View Post
    hmm, seem to be having a problem running this in the car..

    It won't start, and displays the dialog below.

    I do have .Net 1.1 installed... any ideas?

    Thanks..

    Dave
    Don't know if anyone answered it but this is from the incorrect security permissions for the application. Try running these commands from the command line or create a batch file:

    Code:
    rem Changing your .net 2.0 security policy for Intranet
    "%windir%\microsoft.net\framework\v2.0.50727\caspol" -polchgprompt off
    "%windir%\microsoft.net\framework\v2.0.50727\caspol" -m -cg LocalIntranet_Zone FullTrust
    "%windir%\microsoft.net\framework\v2.0.50727\caspol" -polchgprompt off
    Ampie Case
    2.5" Hard Drive 80GB Samsung 5400RPM
    256 MB DDR2 PC5400
    Xenarc 700TSV - VGA Monitor
    Intel D945GCLF Motherboard
    M2-ATX-HV

    2005 Honda Civic

  4. #384
    Constant Bitrate Prefect's Avatar
    Join Date
    May 2005
    Location
    Switzerland
    Posts
    178
    Hi all

    Your discussion seems promising :-)

    @Chameleon: You managed to implement the latest CaptureTest-Classes into Capture! ? Could you send me a copy of the updated project-files?

    @Curiosity: is "SetMasterStream(1)" the solution for the audio-sync-problem? Can this be done with the current version of Capture! ?

    Regards!
    Chris

  5. #385
    Newbie Cameleon's Avatar
    Join Date
    May 2007
    Location
    UK
    Posts
    33
    Prefect - I'm currently working on it. I found this bit of code to insert into your version of Capture!

    AV sync issues
    Hi,

    I solved the audio/video synchronization problem. It is because capturing is done with two different devices, like a TV Tuner and a sound card. Sometime later capture environment looses the synchronization, if one of the devices is not master. The correct solution is to set Audio stream as master. Video stream may result some conflicts. Anyway here is the solution for Audio/Video synchronization problem.

    Firstly, write this code at the end of the DShowNET namespace in "DsExtend.cs":
    Code:
    [ComVisible(true), ComImport,
    Guid("5acd6aa0-f482-11ce-8b67-00aa00a3f1a6"),
    InterfaceType( ComInterfaceType.InterfaceIsIUnknown)]
    public interface IConfigAviMux
    {
    [PreserveSig]
    int SetMasterStream( 
    [In] int iStream);
    
    [PreserveSig]
    int GetMasterStream( 
    [Out] out int pStream);
    
    [PreserveSig]
    int SetOutputCompatibilityIndex( 
    [In] bool fOldIndex);
    
    [PreserveSig]
    int GetOutputCompatibilityIndex( 
    [Out] out bool pfOldIndex);
    }
    Secondly, copy the code into "Capture.cs" in the function "renderGraph()"
    in the "if ( wantCaptureRendered && !isCaptureRendered )" condition and
    just before the line "isCaptureRendered = true;"

    The code is:
    Code:
    // This setting will synchronize audio with video.
    if(muxFilter!=null)
    {
    IConfigAviMux configMux = muxFilter as IConfigAviMux;
    if(configMux!=null)
    {
    // FALSE means AVI will support more than 2 GB (AVI 2.0 format)
    configMux.SetOutputCompatibilityIndex(false);
    // Stream no 0 is video and 1 is audio
    hr = configMux.SetMasterStream(1);
    }
    }
    Now - I have also found that newer version of Catpure Refresh that is using the most up to date SourceForge DirectShowNet v2.0. This already has the same public interface IConfigAviMux. So I am looking to get your CaptureTest (with the nice touchscreen buttons) working with that. Will be playing with it this evening. I have so many copies of different tweaked projects atm its a bit mad lol. But if you want to test out the code above, just copy and paste as it says, I didnt need to do any modifications.

    Hopefully this solves my AV sync issues and we can push on with the more fun stuff (CF plugin and overlays!)

    Happy coding,
    Chris (another one!)

  6. #386
    What can I say? I like serial. Curiosity's Avatar
    Join Date
    Mar 2004
    Location
    Florence Yall, BFKY
    Posts
    2,684
    Regardless of what MS or anyone else says, SetOutputCompatibilityIndex true or false supposedly fixes the 2GB limit by writing an AVI2.0 index chunk. 10 years ago, I'd say TRUE most definitely goes past 2GB the limit. Not calling it at all doesn't. I've never used false though. So you might want to test it by recording a few hours of video at low compression.

  7. #387
    Newbie Cameleon's Avatar
    Join Date
    May 2007
    Location
    UK
    Posts
    33
    Fair enough, I will be the first to admitt I dont know what it does really. I just regurgetate the post that someone else made on the original CaptureTest site. I think the main thing, as you had already said, was to get SetMasterStream(1) in there to set it to the audio clock.

    Interestingly, the current version I am working with (http://www.limegreensocks.com/DShow/) seems to have quite a lot of updates and already included the setting of MasterStream to 1. Also seems to do some spotting of dropped frames, but not sure it does anything with it yet!

  8. #388
    What can I say? I like serial. Curiosity's Avatar
    Join Date
    Mar 2004
    Location
    Florence Yall, BFKY
    Posts
    2,684
    It should be pretty much dead on using one reference clock. Unless the CPU can't handle it, there shouldn't be any dropframe, or it should be handled internally. It works a lot like professional post productions suites. If you've ever played with GraphEdit to build a preview graph or a capture graph with encoding of video and audio, you'll see why a clock is important. The video and audio sources associate a time to each frame (of video and audio or multiple sources) and then it goes through all the transforms over differing times to the final output (file renderer in this case), which then has the original times of all sources and synchronizes the frames before writing. Every filter in the graph passes the clocks with the frames and uses that time to some degree. So just let it do its thing.

  9. #389
    What can I say? I like serial. Curiosity's Avatar
    Join Date
    Mar 2004
    Location
    Florence Yall, BFKY
    Posts
    2,684
    I noticed you guys also wanted a GPS overlay. You can grab the directshow filter on the bottom of my XPort page and play around with it.

  10. #390
    Newbie Cameleon's Avatar
    Join Date
    May 2007
    Location
    UK
    Posts
    33
    Quote Originally Posted by Curiosity View Post
    I noticed you guys also wanted a GPS overlay. You can grab the directshow filter on the bottom of my XPort page and play around with it.
    Excellent. Also nice work with XPort, been using it for ages and its very very good

Similar Threads

  1. Recording (web)camera to carpc
    By DaKyy in forum General Hardware Discussion
    Replies: 12
    Last Post: 09-05-2005, 08:59 AM
  2. iGuidance Recording
    By Cheekz185 in forum GPS
    Replies: 35
    Last Post: 07-22-2005, 06:56 PM
  3. Routis click ok
    By johnnyutah36 in forum MediaCar
    Replies: 3
    Last Post: 08-25-2004, 10:22 PM
  4. T-Mobile Internet
    By cavramair in forum Wireless Communications
    Replies: 9
    Last Post: 07-24-2004, 03:53 AM
  5. Video camera for recording driving
    By MBL MIKE in forum Input Devices
    Replies: 4
    Last Post: 04-26-2004, 12:27 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •