mirror of
https://github.com/mpv-player/mpv
synced 2024-12-18 12:55:16 +00:00
arpi's display_time + interlace hack
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2563 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
1be26c73ce
commit
704ca0fcef
@ -203,7 +203,6 @@ static int header_process_picture_coding_extension (picture_t * picture, uint8_t
|
||||
picture->repeat_first_field = (buffer[3] >> 1) & 1;
|
||||
picture->progressive_frame = buffer[4] >> 7;
|
||||
|
||||
#if 1
|
||||
// repeat_first implementation by A'rpi/ESP-team, based on libmpeg3:
|
||||
picture->display_time=100;
|
||||
if(picture->repeat_first_field){
|
||||
@ -217,32 +216,9 @@ static int header_process_picture_coding_extension (picture_t * picture, uint8_t
|
||||
picture->display_time+=50;
|
||||
}
|
||||
}
|
||||
//repeat_count=display_time-100%
|
||||
#else
|
||||
|
||||
|
||||
// repeat_first implemantation by iive, based on A'rpi/ESP-team and libmpeg3
|
||||
if( picture->progressive_sequence == 1 )
|
||||
{
|
||||
if( picture->repeat_first_field == 0 ) picture->display_time=100;//normal
|
||||
else
|
||||
{
|
||||
if( picture->top_field_first == 0 ) picture->display_time=200;//2 frames
|
||||
else picture->display_time=300;//3 frames
|
||||
}
|
||||
}else
|
||||
{
|
||||
if( picture->progressive_frame == 0 )
|
||||
picture->display_time=100;//2fields, interlaced in time
|
||||
else
|
||||
{
|
||||
if( picture->top_field_first == 0 ) picture->display_time=150;//reconstruct 2 fields
|
||||
else picture->display_time = 150;//reconstruct 3 fields
|
||||
}
|
||||
|
||||
if( picture->picture_structure!=3 ) picture->display_time/=2;//we calc on every field
|
||||
}
|
||||
#endif
|
||||
//temopral hack. We calc time on every field, so if we have 2 fields
|
||||
// interlaced we'll end with double time for 1 frame
|
||||
if( picture->picture_structure!=3 ) picture->display_time/=2;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user