comparison mpcommon.c @ 36682:68794f2fbf1e

Add support for default of multiple video tracks. Some container formats like matroska support multiple video tracks, one of which may be flagged the 'default' one which thus should be played by default. Works with the lavf demuxer.
author ib
date Sun, 02 Feb 2014 19:18:31 +0000
parents 8587ae275646
children
comparison
equal deleted inserted replaced
36681:c3962450b00b 36682:68794f2fbf1e
414 demuxer->audio->sh = NULL; 414 demuxer->audio->sh = NULL;
415 } 415 }
416 return demuxer->audio->id; 416 return demuxer->audio->id;
417 } 417 }
418 418
419 int select_video(demuxer_t* demuxer, int video_id)
420 {
421 if (video_id == -1)
422 video_id = demuxer_default_video_track(demuxer);
423 if (video_id != -1) // -1 (automatic) is the default behaviour of demuxers
424 demuxer_switch_video(demuxer, video_id);
425
426 return demuxer->video->id;
427 }
428
419 /* Parse -noconfig common to both programs */ 429 /* Parse -noconfig common to both programs */
420 int disable_system_conf=0; 430 int disable_system_conf=0;
421 int disable_user_conf=0; 431 int disable_user_conf=0;
422 #ifdef CONFIG_GUI 432 #ifdef CONFIG_GUI
423 int disable_gui_conf=0; 433 int disable_gui_conf=0;