summaryrefslogtreecommitdiff
path: root/command/audio.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'command/audio.cpp')
-rw-r--r--command/audio.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/command/audio.cpp b/command/audio.cpp
index 448d1e9..dba0f59 100644
--- a/command/audio.cpp
+++ b/command/audio.cpp
@@ -149,13 +149,25 @@ MarkAdMark *cMarkAdAudio::Process(int FrameNumber, int FrameNumberNext)
if (ChannelChange(macontext->Audio.Info.Channels,channels))
{
+ bool start=false;
+ if (macontext->Audio.Info.DolbyDigital51)
+ {
+ if (macontext->Audio.Info.Channels>2) start=true;
+ else start=false;
+ }
+ else
+ {
+ if (macontext->Audio.Info.Channels>2) start=false;
+ else start=true;
+ }
+
char *buf=NULL;
if (asprintf(&buf,"audio channel change from %i to %i (%i)", channels,
macontext->Audio.Info.Channels,
- (macontext->Audio.Info.Channels>2) ? FrameNumberNext :
+ start ? FrameNumberNext :
framelast)!=-1)
{
- if (macontext->Audio.Info.Channels>2)
+ if (start)
{
AddMark(MT_CHANNELSTART,FrameNumberNext,buf);
}