OSDN Git Service

LinGui: fix auto audio track selection problem
authorjstebbins <jstebbins@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 5 Nov 2010 18:49:36 +0000 (18:49 +0000)
committerjstebbins <jstebbins@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 5 Nov 2010 18:49:36 +0000 (18:49 +0000)
When passthru is requested, and the first audio track of the source isn't
passthru compatible, it picked the first track instead of moving on
to a compatible track.

git-svn-id: svn://localhost/HandBrake/trunk@3647 b64f7644-9d1e-0410-96f1-a4d463321fa5

gtk/src/hb-backend.c

index d930865..fc35adf 100644 (file)
@@ -2245,7 +2245,7 @@ ghb_find_audio_track(
                {
                        audio = (hb_audio_config_t*)hb_list_audio_config_item( 
                                                                                                        title->list_audio, ii );
-                       passthru_acodec = acodec & audio->in.codec;
+                       passthru_acodec = HB_ACODEC_PASS_MASK & acodec & audio->in.codec;
                        // Is the source track use a passthru capable codec?
                        if (passthru_acodec == 0)
                                continue;
@@ -2326,7 +2326,7 @@ ghb_find_audio_track(
                {
                        audio = (hb_audio_config_t*)hb_list_audio_config_item( 
                                                                                                        title->list_audio, ii );
-                       passthru_acodec = HB_ACODEC_PASS_MASK & audio->in.codec;
+                       passthru_acodec = HB_ACODEC_PASS_MASK & acodec & audio->in.codec;
                        // Is the source track use a passthru capable codec?
                        if (passthru_acodec == 0)
                                continue;