[FFmpeg-devel] JPEG2000 decoder
Michael Niedermayer
michaelni at gmx.at
Fri May 27 16:10:12 CEST 2011
On Fri, May 27, 2011 at 04:28:29AM -0700, rukhsana afroz wrote:
> Hi Michael,
>
> On Tue, May 24, 2011 at 1:10 AM, rukhsana afroz <rukhsana.afroz at gmail.com>wrote:
>
> > Hi Michael,
> >
> > On Fri, May 20, 2011 at 10:49 PM, rukhsana afroz <rukhsana.afroz at gmail.com
> > > wrote:
> >
> >> Hi Michael,
> >>
> >>
> >> On Thu, May 19, 2011 at 3:38 PM, rukhsana afroz <rukhsana.afroz at gmail.com
> >> > wrote:
> >>
> >>>
> >>>
> >>> On Thu, May 19, 2011 at 3:32 PM, rukhsana afroz <
> >>> rukhsana.afroz at gmail.com> wrote:
> >>>
> >>>> Hi Michael,
> >>>>
> >>>>
> >>>> On Sun, May 15, 2011 at 5:00 PM, Michael Niedermayer <michaelni at gmx.at>wrote:
> >>>>
> >>>>>
> >>>>> We will have to implement multiple codeword segments.
> >>>>>
> >>>>> Also sofar, good work!
> >>>>>
> >>>>>
> >>>> Sorry for the late reply. If I implement codeblock segment, its going to
> >>>> affect from packet decoding process to the subsequent deoding process till
> >>>> the last. Therefore, I have to be properly planned in order to accomplish
> >>>> these changes. Here, I have put patch for incorporating multiple codeblock
> >>>> segment. I had to create two more structures and modify J2KCblk sturucture
> >>>> as well. This patch is just for the modification/creation on the structures.
> >>>> I am also writing some miscellaneous function and I will post those in my
> >>>> subsequent emails.
> >>>>
> >>>
> >> I have modified the decode_packet function incorporating multiple codeword
> >> segment. Here, I have attached the patch for the required changes. I have
> >> taken the help from jasper code while writing this code, because only the
> >> document is not sufficient to incorporate these changes. I have not tested
> >> this code yet. Once, I test it, I also let you know. If you have any
> >> suggestion on this patch, please let me know.
> >>
> >>
> >>
> >
> > While doing arithmetic coding operation in decode_cblk function one
> > term/variable is "bpno". Coding operation (decode_sigpass, decode_refpass,
> > decode_clpass) uses this variable to determine the data of each codeblock in
> > different contexts. This variable has been set in our decoder:
> >
> >
> > bpno = cblk->nonzerobits - 1
> >
> > And, jasper has set this variable as follows:
> >
> > bpno = band->roishift + band->numbps - 1 - (cblk->numimsbs + (seg->passno +
> > i - cblk->firstpassno + 2) / 3);
> >
> > band->roishift is the value got from processing the RGN marker and
> > band->numbps is also the value got from some other marker. Our decoder has
> > not processed this marker. cblk->numimsbs is similar to our decoder's
> > cblk->nonzerobits. Other part of this variable is segment specific and that
> > makes sense. I need you suggestion on how to set this variable. I will
> > explain more tomorrow on IRC chat.
> >
> >
> >
> Here, I have attached two patches which cove all changes due to multiple
> codeblock segment. I have tested decode_packet function, but not decode_cblk
> yet.
thx, some comments below
[...]
> -/* Tier-1 coding pass types. */
> -#define J2K_SIGPASS 0 /* significance */
> -#define J2K_REFPASS 1 /* refinement */
> -#define J2K_CLNPASS 2 /* cleanup */
that contains tabs, tabs cannot be commited to our git
i suggest you configure your editor not to insert tabs or trailing
whitespace (many editors can be configured that way)
also the patch is reversed (like diff a b instead of diff b a )
the second patch doesnt apply:
patching file libavcodec/j2kdec.c
Hunk #1 succeeded at 463 (offset -5 lines).
Hunk #2 succeeded at 570 (offset -21 lines).
Hunk #3 FAILED at 604.
Hunk #4 succeeded at 608 (offset -27 lines).
Hunk #5 succeeded at 758 (offset -27 lines).
Hunk #6 succeeded at 764 (offset -35 lines).
[...]
if you use git you can turn commits into patches trivially with
git format-patch -2
(that would turn the last 2 commits into patches together with author&
commit message)
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
DNS cache poisoning attacks, popular search engine, Google internet authority
dont be evil, please
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110527/efc1f4a9/attachment.asc>
More information about the ffmpeg-devel
mailing list