On Wed, Jun 22, 2011 at 3:03 AM, Kostya <[email protected]> wrote:
> On Wed, Jun 22, 2011 at 02:51:30AM -0700, Jason Garrett-Glaser wrote:
>> On Wed, Jun 22, 2011 at 2:47 AM, Kostya <[email protected]> wrote:
>> > On Wed, Jun 22, 2011 at 02:34:27AM -0700, Jason Garrett-Glaser wrote:
>> >> ---
>> >>  libavcodec/h264_ps.c |    3 ++-
>> >>  1 files changed, 2 insertions(+), 1 deletions(-)
>> >>
>> >> diff --git a/libavcodec/h264_ps.c b/libavcodec/h264_ps.c
>> >> index 5ca2361..7491807 100644
>> >> --- a/libavcodec/h264_ps.c
>> >> +++ b/libavcodec/h264_ps.c
>> >> @@ -396,6 +396,7 @@ int ff_h264_decode_seq_parameter_set(H264Context *h){
>> >>  #endif
>> >>      sps->crop= get_bits1(&s->gb);
>> >>      if(sps->crop){
>> >> +        int crop_limit = sps->chroma_format_idc == 3 ? 16 : 8;
>> >>          sps->crop_left  = get_ue_golomb(&s->gb);
>> >>          sps->crop_right = get_ue_golomb(&s->gb);
>> >>          sps->crop_top   = get_ue_golomb(&s->gb);
>> >> @@ -403,7 +404,7 @@ int ff_h264_decode_seq_parameter_set(H264Context *h){
>> >>          if(sps->crop_left || sps->crop_top){
>> >>              av_log(h->s.avctx, AV_LOG_ERROR, "insane cropping not 
>> >> completely supported, this could look slightly wrong ...\n");
>> >>          }
>> >> -        if(sps->crop_right >= (8<<CHROMA444) || sps->crop_bottom >= 
>> >> (8<<CHROMA444)){
>> >> +        if(sps->crop_right >= crop_limit || sps->crop_bottom >= 
>> >> crop_limit){
>> >>              av_log(h->s.avctx, AV_LOG_ERROR, "brainfart cropping not 
>> >> supported, this could look slightly wrong ...\n");
>> >>          }
>> >>      }else{
>> >> --
>> >
>> > Not very good log message and why do you increase cropping value for that
>> > case (i.e. dimensions there are guaranteed to be always multiple of 
>> > sixteen)?
>>
>> I'm not changing the existing code or its limitations.  If you want to
>> do that, it should be a separate patch.
>
> It was not obvious to me. Patch looks OK then

Applied.

Jason
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to