]> granicus.if.org Git - openjpeg/commitdiff
[trunk] JP3D codec was trying to pull information from the registration parameter...
authorMathieu Malaterre <mathieu.malaterre@gmail.com>
Wed, 28 Nov 2012 13:37:50 +0000 (13:37 +0000)
committerMathieu Malaterre <mathieu.malaterre@gmail.com>
Wed, 28 Nov 2012 13:37:50 +0000 (13:37 +0000)
src/lib/openjp3d/jp3d.c

index de4b226685db49826fc8116c29a25b417037bc3e..bbdf0dc558a15322aa3e0ebe5799411b3226010f 100755 (executable)
@@ -799,9 +799,8 @@ static void j3d_read_com(opj_j3d_t *j3d) {
        opj_cio_t *cio = j3d->cio;\r
 \r
        len = cio_read(cio, 2);\r
+       cio_read(cio, 2); // read registration\r
        \r
-       j3d->cp->transform_format = (OPJ_TRANSFORM) cio_read(cio, 1);\r
-       j3d->cp->encoding_format = (OPJ_ENTROPY_CODING) cio_read(cio, 1);\r
        /*opj_event_msg(j3d->cinfo, EVT_INFO, "TRF %D ENCOD %d\n",j3d->cp->transform_format,j3d->cp->encoding_format);*/\r
 \r
        cio_skip(cio, len - 4);  /*posible comments*/\r
@@ -1685,11 +1684,12 @@ void j3d_setup_decoder(opj_j3d_t *j3d, opj_dparameters_t *parameters) {
                cp->reduce[2] = parameters->cp_reduce[2];\r
                cp->layer = parameters->cp_layer;\r
                cp->bigendian = parameters->bigendian;\r
-               \r
-               \r
-               cp->encoding_format = ENCOD_2EB;\r
+\r
+    /* MM: Settings of the following two member variables would take\r
+      place during j3d_read_com. FIXME */\r
+               cp->encoding_format = ENCOD_3EB;\r
                cp->transform_format = TRF_2D_DWT;\r
-               \r
+\r
                /* keep a link to cp so that we can destroy it later in j3d_destroy_decompress */\r
                j3d->cp = cp;\r
        }\r