Forums
in > Search
Welcome to Pinnacle Systems - Forums Sign in | Join | Help

Laptop Webcam Import terrile sync

Last post 11-09-2020, 15:22 by kiteflyer. 17 replies.
Sort Posts: Previous Next
  •  10-09-2020, 11:38 806491

    Laptop Webcam Import terrile sync

    Just playing around with the new laptop PS24U and decided to import from the web cam via the import tab, only to disver the sync is terrible, just check out this clip i've put on you tube, all i've done is drop it on the timeline:

     

    https://youtu.be/PwCFYN-aWss

  •  10-10-2020, 3:43 806503 in reply to 806491

    Re: Laptop Webcam Import terrile sync

    Martin - if you record a bit with a hand clap and then sync it up, does the sync then drift?

     

  •  10-10-2020, 4:35 806504 in reply to 806503

    Re: Laptop Webcam Import terrile sync

    jjn:

    Martin - if you record a bit with a hand clap and then sync it up, does the sync then drift?

     

    Jeff, I'll take look later
  •  10-10-2020, 6:43 806505 in reply to 806504

    Re: Laptop Webcam Import terrile sync

    kiteflyer:
    jjn:

    Martin - if you record a bit with a hand clap and then sync it up, does the sync then drift?

     

    Jeff, I'll take look later

     

    Well would you believe it.....

    Check this out

  •  10-10-2020, 7:36 806507 in reply to 806505

    Re: Laptop Webcam Import terrile sync

    Humm..., always the way :-)

    I wonder if there happened to be a background process running the first time you tried?

  •  10-10-2020, 8:51 806509 in reply to 806507

    Re: Laptop Webcam Import terrile sync

    jjn:

    Humm..., always the way :-)

    I wonder if there happened to be a background process running the first time you tried?

     

    Yeah, you never know, oh well it send to be ok now, my only other gripe about that importer is the square resolution that it uses even when is capturing from a webcam that's capable of 1080P, but that's probably the subject for another thread...

  •  10-10-2020, 15:05 806519 in reply to 806507

    Re: Laptop Webcam Import terrile sync

    jjn:

    Humm..., always the way :-)

    I wonder if there happened to be a background process running the first time you tried?

     This is what i had to do to get the original back in sync and as you can see it was well screwed.......


  •  10-11-2020, 11:52 806549 in reply to 806519

    Re: Laptop Webcam Import terrile sync

    Webcams are notorious for having a variable frame rate all over the place depending on the lighting conditions.

     

  •  10-11-2020, 13:59 806559 in reply to 806549

    Re: Laptop Webcam Import terrile sync

    Tony P:

    Webcams are notorious for having a variable frame rate all over the place depending on the lighting conditions.

     

    This is what mediainfo has to say about the one that was out of sync:

     

    General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Videos\Capture test.mpg
    Format                                   : MPEG-PS
    File size                                : 20.7 MiB
    Duration                                 : 40 s 488 ms
    Overall bit rate mode                    : Variable
    Overall bit rate                         : 4 294 kb/s

    Video
    ID                                       : 224 (0xE0)
    Format                                   : MPEG Video
    Format version                           : Version 2
    Format profile                           : Main@Main
    Format settings                          : CustomMatrix / BVOP
    Format settings, BVOP                    : Yes
    Format settings, Matrix                  : Custom
    Format settings, GOP                     : M=3, N=15
    Duration                                 : 26 s 433 ms
    Bit rate mode                            : Variable
    Bit rate                                 : 3 985 kb/s
    Maximum bit rate                         : 8 000 kb/s
    Width                                    : 640 pixels
    Height                                   : 480 pixels
    Display aspect ratio                     : 4:3
    Frame rate                               : 30.000 FPS
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.432
    Time code of first frame                 : 00:00:00:00
    Time code source                         : Group of pictures header
    GOP, Open/Closed                         : Open
    GOP, Open/Closed of first frame          : Closed
    Stream size                              : 12.6 MiB (61%)
    Color primaries                          : BT.601 NTSC
    Transfer characteristics                 : BT.601
    Matrix coefficients                      : BT.601

    Audio
    ID                                       : 192 (0xC0)
    Format                                   : MPEG Audio
    Format version                           : Version 1
    Format profile                           : Layer 2
    Format settings                          : Joint stereo
    Duration                                 : 40 s 488 ms
    Bit rate mode                            : Constant
    Bit rate                                 : 224 kb/s
    Channel(s)                               : 2 channels
    Sampling rate                            : 48.0 kHz& audio
    Frame rate                               : 41.667 FPS (1152 SPF)
    Compression mode                         : Lossy
    Stream size                              : 1.08 MiB (5%)

    Look at duration of video 

  •  10-12-2020, 10:34 806577 in reply to 806559

    Re: Laptop Webcam Import terrile sync

    kiteflyer:
    Tony P:
    Webcams are notorious for having a variable frame rate all over the place depending on the lighting conditions.

    This is what mediainfo has to say about the one that was out of sync:
    <snip>

    There doesn't appear to be anything wrong with the video properties apart from the length...

    I wonder if that laptop camera is outputting a variable frame rate - you could try capturing with MultiCam Capture (or some third-party app such as OBS - or even the Windows Camera app) instead of Studio's Importer in case it's better able to handle it? Other apps might still fail, but they could throw up additional information to help with troubleshooting...

    Regards,
    Richard

  •  10-12-2020, 11:15 806579 in reply to 806577

    Re: Laptop Webcam Import terrile sync

    culpanr:
    kiteflyer:
    Tony P:
    Webcams are notorious for having a variable frame rate all over the place depending on the lighting conditions.

    This is what mediainfo has to say about the one that was out of sync:
    <snip>

    There doesn't appear to be anything wrong with the video properties apart from the length...

    I wonder if that laptop camera is outputting a variable frame rate - you could try capturing with MultiCam Capture (or some third-party app such as OBS - or even the Windows Camera app) instead of Studio's Importer in case it's better able to handle it? Other apps might still fail, but they could throw up additional information to help with troubleshooting...

    Regards,
    Richard

    Yeah its certainly a weird one Richard, I did try with multicam as i had the same thought, and it captured with no problem, and the second time i tried it directly to check for drift as Jeff suggested It captured fine.

    I will have another go at trying to get it to fail, cheers for your input

  •  10-13-2020, 13:12 806630 in reply to 806579

    Re: Laptop Webcam Import terrile sync

    Thanks Richard for chiming in..... I've been out of town and busy as of late and am finally getting around to answer emails, etc...
  •  11-09-2020, 5:32 807353 in reply to 806577

    Re: Laptop Webcam Import terrile sync

    Attachment: 2020-11-08 (1).jpg
    culpanr:
    kiteflyer:
    Tony P:
    Webcams are notorious for having a variable frame rate all over the place depending on the lighting conditions.

    This is what mediainfo has to say about the one that was out of sync:
    <snip>

    There doesn't appear to be anything wrong with the video properties apart from the length...

    I wonder if that laptop camera is outputting a variable frame rate - you could try capturing with MultiCam Capture (or some third-party app such as OBS - or even the Windows Camera app) instead of Studio's Importer in case it's better able to handle it? Other apps might still fail, but they could throw up additional information to help with troubleshooting...

    Regards,
    Richard

     

    Had another play with this last night, tried both Studio & multicam, here are the mediainfo files for each

     

    Studio

     

    General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Videos\Laptop chicony\Studio capture\Capture test countdown off.mpg
    Format                                   : MPEG-PS
    File size                                : 55.2 MiB
    Duration                                 : 2 min 6 s
    Overall bit rate mode                    : Variable
    Overall bit rate                         : 3 675 kb/s

    Video
    ID                                       : 224 (0xE0)
    Format                                   : MPEG Video
    Format version                           : Version 2
    Format profile                           : Main@Main
    Format settings                          : CustomMatrix / BVOP
    Format settings, BVOP                    : Yes
    Format settings, Matrix                  : Custom
    Format settings, GOP                     : M=3, N=15
    Duration                                 : 1 min 9 s
    Bit rate mode                            : Variable
    Bit rate                                 : 3 378 kb/s
    Maximum bit rate                         : 8 000 kb/s
    Width                                    : 640 pixels
    Height                                   : 480 pixels
    Display aspect ratio                     : 4:3
    Frame rate                               : 30.000 FPS
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.367
    Time code of first frame                 : 00:00:00:00
    Time code source                         : Group of pictures header
    GOP, Open/Closed                         : Open
    GOP, Open/Closed of first frame          : Closed
    Stream size                              : 28.0 MiB (51%)
    Color primaries                          : BT.601 NTSC
    Transfer characteristics                 : BT.601
    Matrix coefficients                      : BT.601

    Audio
    ID                                       : 192 (0xC0)
    Format                                   : MPEG Audio
    Format version                           : Version 1
    Format profile                           : Layer 2
    Format settings                          : Joint stereo
    Duration                                 : 2 min 6 s
    Bit rate mode                            : Constant
    Bit rate                                 : 224 kb/s
    Channel(s)                               : 2 channels
    Sampling rate                            : 48.0 kHz
    Frame rate                               : 41.667 FPS (1152 SPF)
    Compression mode                         : Lossy
    Stream size                              : 3.36 MiB (6%)

    Almost half the video missing..............

     

    Multicam

     General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Videos\Laptop chicony\Multicam capture\sync issues\Web cam1.mov
    Format                                   : MPEG-4
    Format profile                           : QuickTime
    Codec ID                                 : qt   0000.02 (qt  )
    File size                                : 565 MiB
    Duration                                 : 2 min 3 s
    Overall bit rate mode                    : Variable
    Overall bit rate                         : 38.4 Mb/s
    Encoded date                             : UTC 2020-11-08 21:04:55
    Tagged date                              : UTC 2020-11-08 21:04:55

    Video
    ID                                       : 1
    Format                                   : JPEG
    Codec ID                                 : jpeg
    Duration                                 : 2 min 3 s
    Bit rate mode                            : Variable
    Bit rate                                 : 38.2 Mb/s
    Width                                    : 1 280 pixels
    Height                                   : 720 pixels
    Display aspect ratio                     : 16:9
    Frame rate mode                          : Constant
    Frame rate                               : 30.000 FPS
    Color space                              : YUV
    Chroma subsampling                       : 4:2:2
    Bit depth                                : 8 bits
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 1.383
    Stream size                              : 563 MiB (100%)
    Language                                 : English
    Encoded date                             : UTC 2020-11-08 21:04:55
    Tagged date                              : UTC 2020-11-08 21:04:55

    Audio
    ID                                       : 2
    Format                                   : AAC LC
    Format/Info                              : Advanced Audio Codec Low Complexity
    Codec ID                                 : mp4a-40-2
    Duration                                 : 2 min 3 s
    Bit rate mode                            : Variable
    Bit rate                                 : 128 kb/s
    Maximum bit rate                         : 131 kb/s
    Channel(s)                               : 2 channels
    Channel layout                           : L R
    Sampling rate                            : 44.1 kHz
    Frame rate                               : 43.066 FPS (1024 SPF)
    Compression mode                         : Lossy
    Stream size                              : 1.89 MiB (0%)
    Language                                 : English
    Encoded date                             : UTC 2020-11-08 21:04:55
    Tagged date                              : UTC 2020-11-08 21:04:55

    No problem at all with multicam capture

     

    Both captures performed with laptop in built webcam

    An aside with this, why does studio insist on capturing in 4:3 instead of the cameras native 16:9

    See attached screenshot for dropped frames

     


  •  11-09-2020, 7:50 807358 in reply to 807353

    Re: Laptop Webcam Import terrile sync

    I would guess, from the shortened video content and large "dropped frame count" when using the Studio importer:

    • The webcam is very likely delivering a variable frame rate with an average around 15fps. If it's anything like my phone it will be dependent on light level (lowering the frame rate to improve low-light performance).
    • Studio's importer may still be using old code (possibly ported over from legacy Studio 14/15?) - and such old code does not understand variable frame rate video; each time it goes to capture another frame, if the webcam hasn't yet delivered one, it is just dropped.
    • However, MultiCam Capture does understand variable frame rate sources; although its output is a constant frame rate 30fps, I'm guessing that each time it goes to save a new frame, if the webcam hasn't yet delivered a new one, it just re-uses the previous one. A clue to whether this is actually what is happening would be to step through the captured video frame-by-frame; you may see that most frames are repeated.

    I think my HP laptop's built-in camera may produce a variable frame rate; if so I ought to be able to reproduce the same issue here (Studio's importer dropping frames, multicam capture I will be using lite) capturing just fine). If I can reproduce, I'll certainly try getting it "onto the radar" as a possible bug...

    Regards,
    Richard

  •  11-09-2020, 8:56 807363 in reply to 807358

    Re: Laptop Webcam Import terrile sync

    Cheers Rich,

    I've also got a coupl of USB webcams, I'll give those a try as well and see what happens

  •  11-09-2020, 11:51 807368 in reply to 807363

    Re: Laptop Webcam Import terrile sync

    Ok so I've had a play with one of my other webcams and also did another capture with the laptops inbuilt webcam using the windows camera app, here are the resulting files from mediainfo:

     

    Studio

     General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Videos\USB Live Camera\Studio capture\Studio Capture Sync test.mpg
    Format                                   : MPEG-PS
    File size                                : 63.9 MiB
    Duration                                 : 2 min 3 s
    Overall bit rate mode                    : Variable
    Overall bit rate                         : 4 342 kb/s

    Video
    ID                                       : 224 (0xE0)
    Format                                   : MPEG Video
    Format version                           : Version 2
    Format profile                           : Main@Main
    Format settings                          : CustomMatrix / BVOP
    Format settings, BVOP                    : Yes
    Format settings, Matrix                  : Custom
    Format settings, GOP                     : M=3, N=15
    Duration                                 : 1 min 21 s
    Bit rate mode                            : Variable
    Bit rate                                 : 4 031 kb/s
    Maximum bit rate                         : 8 000 kb/s
    Width                                    : 640 pixels
    Height                                   : 480 pixels
    Display aspect ratio                     : 4:3
    Frame rate                               : 30.000 FPS
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.437
    Time code of first frame                 : 00:00:00:00
    Time code source                         : Group of pictures header
    GOP, Open/Closed                         : Open
    GOP, Open/Closed of first frame          : Closed
    Stream size                              : 39.4 MiB (62%)
    Color primaries                          : BT.601 NTSC
    Transfer characteristics                 : BT.601
    Matrix coefficients                      : BT.601

    Audio
    ID                                       : 192 (0xC0)
    Format                                   : MPEG Audio
    Format version                           : Version 1
    Format profile                           : Layer 2
    Format settings                          : Joint stereo
    Duration                                 : 2 min 3 s
    Bit rate mode                            : Constant
    Bit rate                                 : 224 kb/s
    Channel(s)                               : 2 channels
    Sampling rate                            : 48.0 kHz
    Frame rate                               : 41.667 FPS (1152 SPF)
    Compression mode                         : Lossy
    Stream size                              : 3.30 MiB (5%)

    Multicam

      General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Videos\USB Live Camera\Multicam Capture\sync issues (2)\Source 1.mov
    Format                                   : MPEG-4
    Format profile                           : QuickTime
    Codec ID                                 : qt   0000.02 (qt  )
    File size                                : 966 MiB
    Duration                                 : 2 min 3 s
    Overall bit rate mode                    : Variable
    Overall bit rate                         : 65.8 Mb/s
    Encoded date                             : UTC 2020-11-09 15:39:49
    Tagged date                              : UTC 2020-11-09 15:39:49

    Video
    ID                                       : 1
    Format                                   : JPEG
    Codec ID                                 : jpeg
    Duration                                 : 2 min 3 s
    Bit rate mode                            : Variable
    Bit rate                                 : 65.6 Mb/s
    Width                                    : 1 920 pixels
    Height                                   : 1 080 pixels
    Display aspect ratio                     : 16:9
    Frame rate mode                          : Constant
    Frame rate                               : 30.000 FPS
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 1.055
    Stream size                              : 964 MiB (100%)
    Language                                 : English
    Encoded date                             : UTC 2020-11-09 15:39:49
    Tagged date                              : UTC 2020-11-09 15:39:49

    Audio
    ID                                       : 2
    Format                                   : AAC LC
    Format/Info                              : Advanced Audio Codec Low Complexity
    Codec ID                                 : mp4a-40-2
    Duration                                 : 2 min 3 s
    Bit rate mode                            : Variable
    Bit rate                                 : 128 kb/s
    Maximum bit rate                         : 132 kb/s
    Channel(s)                               : 2 channels
    Channel layout                           : L R
    Sampling rate                            : 44.1 kHz
    Frame rate                               : 43.066 FPS (1024 SPF)
    Compression mode                         : Lossy
    Stream size                              : 1.88 MiB (0%)
    Language                                 : English
    Encoded date                             : UTC 2020-11-09 15:39:49
    Tagged date                              : UTC 2020-11-09 15:39:49

    Laptop inbuilt windows camera app

     General
    Complete name                            : C:\Users\mread\Dropbox\My PC (DESKTOP-RNGHNNU)\Pictures\Camera Roll\WIN_20201109_15_56_10_Pro.mp4
    Format                                   : MPEG-4
    Format profile                           : Base Media / Version 2
    Codec ID                                 : mp42 (mp41/isom)
    File size                                : 41.2 MiB
    Duration                                 : 2 min 2 s
    Overall bit rate mode                    : Constant
    Overall bit rate                         : 2 817 kb/s
    Encoded date                             : UTC 2020-11-09 15:56:10
    Tagged date                              : UTC 2020-11-09 15:56:10

    Video
    ID                                       : 1
    Format                                   : AVC
    Format/Info                              : Advanced Video Codec
    Format profile                           : Main@L3.1
    Format settings                          : CABAC / 2 Ref Frames
    Format settings, CABAC                   : Yes
    Format settings, Reference frames        : 2 frames
    Format settings, GOP                     : M=3, N=30
    Codec ID                                 : avc1
    Codec ID/Info                            : Advanced Video Coding
    Duration                                 : 2 min 2 s
    Bit rate mode                            : Constant
    Bit rate                                 : 2 620 kb/s
    Nominal bit rate                         : 7 899 kb/s
    Width                                    : 1 280 pixels
    Height                                   : 720 pixels
    Display aspect ratio                     : 16:9
    Frame rate mode                          : Variable
    Frame rate                               : 10.000 FPS
    Minimum frame rate                       : 8.905 FPS
    Maximum frame rate                       : 30.000 FPS
    Original frame rate                      : 30.000 FPS
    Standard                                 : Component
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Bits/(Pixel*Frame)                       : 0.284
    Stream size                              : 38.3 MiB (93%)
    Encoded date                             : UTC 2020-11-09 15:56:10
    Tagged date                              : UTC 2020-11-09 15:56:10
    Color range                              : Full
    mdhd_Duration                            : 122801
    Codec configuration box                  : avcC

    Audio
    ID                                       : 2
    Format                                   : AAC LC
    Format/Info                              : Advanced Audio Codec Low Complexity
    Codec ID                                 : mp4a-40-2
    Duration                                 : 2 min 2 s
    Bit rate mode                            : Constant
    Bit rate                                 : 192 kb/s
    Channel(s)                               : 2 channels
    Channel layout                           : L R
    Sampling rate                            : 48.0 kHz
    Frame rate                               : 46.875 FPS (1024 SPF)
    Compression mode                         : Lossy
    Stream size                              : 2.86 MiB (7%)
    Encoded date                             : UTC 2020-11-09 15:56:10
    Tagged date                              : UTC 2020-11-09 15:56:10

    So as before when capturing from Studio the video stream is a lot shorter.

    Now if  you look at the General section in all 3 files at the  format field you'll see that both the multicam and windows camera app list it as MPEG-4, however for the Studio file it is listed as MPEG-PS, this led me to do some digging as I hadn't heard of this format This is what wikipedia has to say https://en.wikipedia.org/wiki/MPEG_program_stream

  •  11-09-2020, 13:00 807373 in reply to 807368

    Re: Laptop Webcam Import terrile sync

    From the description on that Amazon page - the webcam having "automatic low-light correction" may well imply that it uses a variable frame rate?

    I tried with my HP laptop's webcam and can reproduce the issue under low-light conditions (Studio's importer drops a ton of frames, multicam capture OK). So I do believe that the issue is due to legacy code in Studio's importer (not handling variable frame rate video, when the average frame rate drops below what the importer thinks it is trying to record.

    So, continue with the known workaround (use multicam capture or some other app) until such time as the importer gets fixed...

    Regards,
    Richard

  •  11-09-2020, 15:22 807380 in reply to 807373

    Re: Laptop Webcam Import terrile sync

    culpanr:

    From the description on that Amazon page - the webcam having "automatic low-light correction" may well imply that it uses a variable frame rate?

    I tried with my HP laptop's webcam and can reproduce the issue under low-light conditions (Studio's importer drops a ton of frames, multicam capture OK). So I do believe that the issue is due to legacy code in Studio's importer (not handling variable frame rate video, when the average frame rate drops below what the importer thinks it is trying to record.

    So, continue with the known workaround (use multicam capture or some other app) until such time as the importer gets fixed...

    Regards,
    Richard

    Cheers for confirming it RichYes


View as RSS news feed in XML
Copyright © 2012 Corel, Inc.. Terms of Use | Privacy Policy