[vlc-devel] [PATCH] Fix snapshot chroma/size mismach bug

basos g noxelia at gmail.com
Sat Dec 13 00:25:30 CET 2008

2008/12/12 Laurent Aimar <fenrir at via.ecp.fr>:
> On Fri, Dec 12, 2008, Laurent Aimar wrote:
>> Hi,
>> On Fri, Dec 12, 2008, basos g wrote:
>> > Also there is size mismatch. Vout->fmt_out has the final video size
>> > that may be resized. This is not the initial picture size. This
>> > affects the snapshot size when snapshot-width and snapshot-height vars
>> > are zero (meaning snap the *original* size )
>>  For me it does not mean the original size, but the original *display* size, ie
>> after the aspect ratio has been applied.
That's ok. But i have observed that p_cout->fmt_out size is the
current display size. I.e. if i resize the video window this size
changes. I don't think that snapshot size should depend on current
video size.

Now i have recent data. This patch does not work on windows.
p_pic->format size is 0x0 !!

Also i have noticed other x-platform incosinstencies..

 p_vout->fmt_out and p_pic->format have the same size (maybe different
chroma ) and is the CURRENT video size (e.g. if u resize the video
window these sizes CHANGE) . I don't think that this should be the

 p_vout->fmt_out is invariant of the window size but
 p_pic->format size is 0x0 ! I don't think this should be ok !

ALso could you explain the sar_num ans sar_den values ?

>>  Using your patch, the snapshot has sometimes the wrong aspect ratio which is
>> not acceptable. (I have not investigated the reason).
>  Replying to myself, the picture format does not have the sar set but
> i_aspect is.
>  The attached patch fix the aspect ratio issue.
> Anyway, when vout call vout_Snapshot both format (picture and vout) contain
> the same video size (including any video output resize).
> --
> fenrir
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> http://mailman.videolan.org/listinfo/vlc-devel

More information about the vlc-devel mailing list