[MPlayer-dev-eng] Re: [PATCH] Allow aspect change in TS and DVB
Nico Sabbi
nsabbi at email.it
Tue May 9 09:54:23 CEST 2006
Carl Eugen Hoyos wrote:
> Hi Nico!
>
> Nico Sabbi <nicola_sabbi <at> fastwebnet.it> writes:
>
>
>> Carl Eugen Hoyos wrote:
>>
>
> [...]
>
>
>>> So I would suggest once again to test the demuxer type: Does it make sense to
>>> check for aspect ration change in another medium than TS/DVB?
>>>
>>>
>>>
>> yes, ever heard of dvd?
>>
>
> There are really DVDs with aspect change? I didn't know...
>
> [...]
>
>
>> As for the A/R function Ivan and I think that video.c is not really the
>> best place for it;
>> maybe mpeg_hdr.c.
>> Opinions?
>>
>
> AFAICT, the information has to get from a frame, decoded in mpeg_hdr.c, into the
> sh_video data structure, which is not present in mpeg_hdr.c, so I don't see how
> this could be done without changing video.c a bit.
> One line patch attached.
>
>
no, it's in the sequence header, not in the picture header
> I hope it's clean enough now, Carl Eugen Hoyos
>
> Index: libmpdemux/video.c
> ===================================================================
> RCS file: /cvsroot/mplayer/main/libmpdemux/video.c,v
> retrieving revision 1.64
> diff -u -r1.64 video.c
> --- libmpdemux/video.c 7 May 2006 16:05:38 -0000 1.64
> +++ libmpdemux/video.c 9 May 2006 00:17:07 -0000
> @@ -440,7 +440,9 @@
> //printf("read packet 0x%X, len=%d\n",i,videobuf_len);
> // process headers:
> switch(i){
> - case 0x1B3: mp_header_process_sequence_header (&picture,
> &videobuffer[start]);break;
> + case 0x1B3: mp_header_process_sequence_header (&picture,
> &videobuffer[start]);
> + sh_video->aspect = mpeg12_aspect_info(&picture);
> + break;
> case 0x1B5: mp_header_process_extension (&picture,
> &videobuffer[start]);break;
> case 0x1B2: process_userdata (&videobuffer[start],
> videobuf_len-start);break;
> case 0x100: picture_coding_type=(videobuffer[start+1] >> 3) & 7;break;
>
>
>
wrong: you can't determine the correct A/R before first knowing if you
are dealing with
mpeg1 or mpeg2 (part of the patch I posted previously).
In practice you have to move or copy
sh_video->aspect = mpeg12_aspect_info(&picture);
to the bottom of video_read_frame()
--
Email.it, the professional e-mail, gratis per te: http://www.email.it/f
Sponsor:
DA NON PERDERE: Prova gratis per 15 giorni DVDNet Rent e ricevi a casa tua i migliori film!
*
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=4634&d=9-5
More information about the MPlayer-dev-eng
mailing list