Skip to content

Commit

Permalink
fix(toDash): Fix default audio stream for dubbed movie trailers (#858)
Browse files Browse the repository at this point in the history
  • Loading branch information
absidue authored Dec 31, 2024
1 parent 5f899fc commit 0054690
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/utils/StreamingInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,8 @@ function getTrackRoles(format: Format, has_drc_streams: boolean) {
}

const roles: ('main' | 'dub' | 'description' | 'enhanced-audio-intelligibility' | 'alternate')[] = [
format.is_original ? 'main' : 'alternate'
// movie trailers can have a dubbed track as the only audio track so is_original is false but format.audio_track.audio_is_default is true
format.is_original || format.audio_track?.audio_is_default ? 'main' : 'alternate'
];

if (format.is_dubbed || format.is_auto_dubbed)
Expand Down

0 comments on commit 0054690

Please sign in to comment.