LIP SYNC PROBLEM

Mark X

New Member
I have one PTZ camera that is connected to a Win 10 lap top via two different signal paths.

The primary signal is via coax SDI to an AVMatrix UC1118 SDI to USB 3.0 converter into a USB capture source. The USB plugs directly into the lap top.

The secondary signal path is video over IP, the PTZ camera and lap top are on the same switch. Input via a media source.

The key feature of this system is that the audio is fed to the camera and encoded by the camera so the audio and video travel TOGETHER via SDI/USB or via IP to the lap top. This was done to avoid lip sync issues.

This system worked well for many years using mostly the SDI path/ USB capture source path.

A few months ago I updated OBS to 30.2.3 in order to add the advanced scene switcher feature. I also added ANYDESK remote desktop access to the laptop at this time.

Ever since this upgrade, I have had a lip sync problem. When I start OBS, the lip is OK but gradually over time, the audio and video drift apart to as much as over 30 seconds apart. I can get it back by stopping and starting a source. The lap top shows very low CPU usage, under 20%. I have tested with both software and hardware encoding. The present log capture is with software encoder, but the same thing happens with hardware encoding. The USB path drifts out of lip sync in a few minutes.

I have a fundamental question about OBS buffering architecture. Since the audio and video arrive together into the PC, via the same USB capture card input, if the buffer were increasing due to whatever reason, would not the video and audio delay increase equally and therefore not create a lip sync problem. Does the lip sync drift problem indicate that there are DIFFERENT buffering paths within OBS for the audio and video. Why would it be designed this way? In order for lip sync to be stable, to two buffer paths have to remain consistent with each other?

The IP path also has the lip sync problem but not as bad. My work around for the last several months is to use the IP signal path and reset the input every 15 minutes or so. But I would prefer to fix this correctly.

I have a low frame rate = 20FPS, thats all I need, for talking heads
My streaming resolution is 720



Any ideas how to solve this problem?

Recent log file https://obsproject.com/logs/CuLOjvBso4Jo9i1d

Thank you.
 

Mark X

New Member
I have one PTZ camera that is connected to a Win 10 lap top via two different signal paths.

The primary signal is via coax SDI to an AVMatrix UC1118 SDI to USB 3.0 converter into a USB capture source. The USB plugs directly into the lap top.

The secondary signal path is video over IP, the PTZ camera and lap top are on the same switch. Input via a media source.

The key feature of this system is that the audio is fed to the camera and encoded by the camera so the audio and video travel TOGETHER via SDI/USB or via IP to the lap top. This was done to avoid lip sync issues.

This system worked well for many years using mostly the SDI path/ USB capture source path.

A few months ago I updated OBS to 30.2.3 in order to add the advanced scene switcher feature. I also added ANYDESK remote desktop access to the laptop at this time.

Ever since this upgrade, I have had a lip sync problem. When I start OBS, the lip is OK but gradually over time, the audio and video drift apart to as much as over 30 seconds apart. I can get it back by stopping and starting a source. The lap top shows very low CPU usage, under 20%. I have tested with both software and hardware encoding. The present log capture is with software encoder, but the same thing happens with hardware encoding. The USB path drifts out of lip sync in a few minutes.

I have a fundamental question about OBS buffering architecture. Since the audio and video arrive together into the PC, via the same USB capture card input, if the buffer were increasing due to whatever reason, would not the video and audio delay increase equally and therefore not create a lip sync problem. Does the lip sync drift problem indicate that there are DIFFERENT buffering paths within OBS for the audio and video. Why would it be designed this way? In order for lip sync to be stable, to two buffer paths have to remain consistent with each other?

The IP path also has the lip sync problem but not as bad. My work around for the last several months is to use the IP signal path and reset the input every 15 minutes or so. But I would prefer to fix this correctly.

I have a low frame rate = 20FPS, thats all I need, for talking heads
My streaming resolution is 720



Any ideas how to solve this problem?

Recent log file https://obsproject.com/logs/CuLOjvBso4Jo9i1d

Thank you.
Can anyone explain how the OBS dynamic buffer system works? How can you maintain lip sync with different dynamic buffers for the sound and video?
 

Suslik V

Active Member
In the media (stream of the 0 and 1 from the device) all data interleaved. By block of video data follows block of audio data. These blocks named "frames" (no matter if this is audio or video data). There is timestamp linked with given data. Synchronization possible by retrieving timestamps.
Some additional info can be found in this post (devices may not take into account timestamps or may produce inaccurate timestamps):
 

Mark X

New Member
In the media (stream of the 0 and 1 from the device) all data interleaved. By block of video data follows block of audio data. These blocks named "frames" (no matter if this is audio or video data). There is timestamp linked with given data. Synchronization possible by retrieving timestamps.
Some additional info can be found in this post (devices may not take into account timestamps or may produce inaccurate timestamps):
Thank you, I will try the low latency mode and report back.
 
Top