On Tue, Aug 25, 2020 at 1:18 PM Michael Niedermayer
<mich...@niedermayer.cc> wrote:
>
> On Tue, Aug 25, 2020 at 09:50:04AM +0530, gautamr...@gmail.com wrote:
> > From: Gautam Ramakrishnan <gautamr...@gmail.com>
> >
> > The implementation of tag tree encoding was incorrect.
> > However, this error was not visible as the current j2k
> > encoder encodes only 1 layer.
> > This patch fixes tag tree coding for JPEG2000 such tag
> > tree coding would work for multi layer encoding.
> > ---
> >  libavcodec/j2kenc.c   | 41 +++++++++++++++++++++++++----------------
> >  libavcodec/jpeg2000.c |  1 +
> >  libavcodec/jpeg2000.h |  1 +
> >  3 files changed, 27 insertions(+), 16 deletions(-)
>
> iam not sure the tag tree is working correctly before or after this
>
> For example if i make this chnage:
>
> --- a/libavcodec/j2kenc.c
> +++ b/libavcodec/j2kenc.c
> @@ -282,6 +282,7 @@ static void tag_tree_update(Jpeg2000TgtNode *node)
>      while (node->parent){
>          if (node->parent->val <= node->val)
>              break;
> +        abort();
>          node->parent->val = node->val;
>          node = node->parent;
>          lev++;
>
> all tests still pass, so iam not sure what sets the parent values or if
> they are not if the code working with them is fully tested
Looks like the tag tree initializer is incorrect. This would not cause an
undecodable file, but however, leads to an extremely inefficient encoding
of the tag tree. I shall send a patch for this also.
>
> thx
>
> [...]
> --
> Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> Observe your enemies, for they first find out your faults. -- Antisthenes
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".



-- 
-------------
Gautam |
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to