Home | History | Annotate | Download | only in libopenjpeg20

Lines Matching full:cblk

142 @param cblk
147 static OPJ_BOOL opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
578 opj_tcd_cblk_enc_t* cblk = 00;
615 cblk = &prc->cblks.enc[cblkno];
617 cblk->numpasses = 0;
618 opj_tgt_setvalue(prc->imsbtree, cblkno, band->numbps - (OPJ_INT32)cblk->numbps);
638 cblk = prc->cblks.enc;
641 opj_tcd_layer_t *layer = &cblk->layers[layno];
643 if (!cblk->numpasses && layer->numpasses) {
647 ++cblk;
650 cblk = prc->cblks.enc;
652 opj_tcd_layer_t *layer = &cblk->layers[layno];
658 /* cblk inclusion bits */
659 if (!cblk->numpasses) {
665 /* if cblk not included, go to the next cblk */
667 ++cblk;
671 /* if first instance of cblk --> zero bit-planes information */
672 if (!cblk->numpasses) {
673 cblk->numlenbits = 3;
679 l_nb_passes = cblk->numpasses + layer->numpasses;
680 pass = cblk->passes + cblk->numpasses;
683 for (passno = cblk->numpasses; passno < l_nb_passes; ++passno) {
687 if (pass->term || passno == (cblk->numpasses + layer->numpasses) - 1) {
689 - ((OPJ_INT32)cblk->numlenbits + opj_int_floorlog2((OPJ_INT32)nump)));
699 cblk->numlenbits += increment;
701 pass = cblk->passes + cblk->numpasses;
703 for (passno = cblk->numpasses; passno < l_nb_passes; ++passno) {
707 if (pass->term || passno == (cblk->numpasses + layer->numpasses) - 1) {
708 opj_bio_write(bio, (OPJ_UINT32)len, cblk->numlenbits + (OPJ_UINT32)opj_int_floorlog2((OPJ_INT32)nump));
715 ++cblk;
756 cblk = prc->cblks.enc;
759 opj_tcd_layer_t *layer = &cblk->layers[layno];
762 ++cblk;
771 cblk->numpasses += layer->numpasses;
784 ++cblk;
987 /* if cblk not yet included before --> inclusion tagtree */
996 /* if cblk not included */
1004 /* if cblk not yet included --> zero-bitplane tagtree */
1190 /* Check if the cblk->data have allocated enough memory */
1341 OPJ_BOOL opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
1349 if (l_nb_segs > cblk->m_current_max_segs) {
1351 cblk->m_current_max_segs += OPJ_J2K_DEFAULT_NB_SEGS;
1353 new_segs = (opj_tcd_seg_t*) opj_realloc(cblk->segs, cblk->m_current_max_segs * sizeof(opj_tcd_seg_t));
1355 opj_free(cblk->segs);
1356 cblk->segs = NULL;
1357 cblk->m_current_max_segs = 0;
1361 cblk->segs = new_segs;
1364 seg = &cblk->segs[index];