[vlc-devel] [PATCH] sout:AES3Audio: fix buffer end calculation

Steve Lhomme robux4 at ycbcr.xyz
Thu Sep 20 16:16:56 CEST 2018


The value returned by FramesToDuration is already in vlc_tick_t so no need to
multiply it by CLOCK_FREQ.
---
 modules/stream_out/sdi/AES3Audio.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/stream_out/sdi/AES3Audio.cpp b/modules/stream_out/sdi/AES3Audio.cpp
index 5352880aa93..014fe3d4a49 100644
--- a/modules/stream_out/sdi/AES3Audio.cpp
+++ b/modules/stream_out/sdi/AES3Audio.cpp
@@ -134,7 +134,7 @@ vlc_tick_t AES3AudioBuffer::bufferEnd() const
 {
     vlc_tick_t start = bufferStart();
     if(start != VLC_TICK_INVALID)
-        start += CLOCK_FREQ * FramesToDuration(BytesToFrames(block_BytestreamRemaining(&bytestream)));
+        start += FramesToDuration(BytesToFrames(block_BytestreamRemaining(&bytestream)));
      return start;
 }
 
-- 
2.17.0



More information about the vlc-devel mailing list