RaceControl icon indicating copy to clipboard operation
RaceControl copied to clipboard

[BUG] audio stutters/crackling

Open mechoriet opened this issue 4 years ago • 4 comments

Describe the bug So far I only notices it every few seconds the audio starts crackling for a very short period on live sessions via the watch button with all default settings from install however the picture is very clear compared to the #158 when going to the official f1tv player it isn't on there feed cause then its clean and crisp in VOD viewings it seems to not happen so far I tested

To Reproduce Steps to reproduce the behavior: watch a live broadcast

Expected behavior no Crackling audio

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • Windows 10 pro version:10.0.19041 Build 19041
  • System type 64bit
  • Version 2.3.3

F1TV account

  • Pro(via ziggo)
  • Netherlands
  • Using VPN or proxy? none

Additional context I feel it something with buffering of the new audio stream

mechoriet avatar Jun 27 '21 10:06 mechoriet

Hi @mechoriet, as it is not possible to reproduce the issue would you be able to test the internal player application itself (can be found here https://github.com/SuRGeoNix/Flyleaf/releases/download/v3.1.9/Flyleaf_v3.1.9.7z)

Try to play around with the Settings (Video/Buffering), turn on V.Sync, turn off Video Acceleration, use less decoder threads or more and try larger buffers for video (eg. Min 20, Max 40). Do the same for audio by changing the buffers (eg. Min 50, Max 100)

SuRGeoNix avatar Jul 17 '21 08:07 SuRGeoNix

@robvdpol I have found another two possible reason why this one could happened.

  1. You have more than one audio streams enabled in the demuxer by mistake at the same time

  2. When you have multiple audio streams within the same video ffmpeg organize them by programs eg....

[Programs] 5
	Program #0
		Streams [2]: 0,1
	Program #1
		Streams [2]: 2,3
	Program #2
		Streams [2]: 4,5
	Program #3
		Streams [2]: 6,7
	Program #4
		Streams [1]: 8

You should chose an audio stream which is in the same program with the video stream. I will add the available programs in the next version (Player.decoder.VideoDemuxer.Programs).

SuRGeoNix avatar Jul 26 '21 06:07 SuRGeoNix

@SuRGeoNix I don't think those scenario's apply to Race Control.

For point 1, I simply call Player.Open() when switching audio streams. I don't have to first close the existing audio stream, right?

For point 2, I don't think the F1TV streams have different 'programs'.

robvdpol avatar Jul 27 '21 06:07 robvdpol

I will change the Player.Open to allow a 'naked' open without the embedded functionality to select default streams. If you have more than one video/audio stream then probably you have programs as well. And if you choose streams from different programs you will get the bandwidth that both programs require. FFmpeg allows you even to discard a program completely, which would be the best to ensure that you don't receive useless packets.

SuRGeoNix avatar Jul 27 '21 13:07 SuRGeoNix