fixup! Try to build with AVX2.
[openjpeg.git] / tests / j2k_random_tile_access.c
index b76bf35994a184cc7572c5a09f571b6e399e91bf..b53c6005c7fd5ef1230548ad5b6972ce84d5fbb4 100644 (file)
@@ -209,7 +209,7 @@ int main(int argc, char **argv)
        opj_set_warning_handler(l_codec, warning_callback,00);
        opj_set_error_handler(l_codec, error_callback,00);
 
-    l_stream = opj_stream_create_default_file_stream_v3(parameters.infile,1);
+    l_stream = opj_stream_create_default_file_stream(parameters.infile,1);
        if (!l_stream){
         fprintf(stderr, "ERROR -> failed to create the stream from the file %s\n", parameters.infile);
                return EXIT_FAILURE;
@@ -218,7 +218,7 @@ int main(int argc, char **argv)
        /* Setup the decoder decoding parameters using user parameters */
        if ( !opj_setup_decoder(l_codec, &parameters) ){
                fprintf(stderr, "ERROR -> j2k_dump: failed to setup the decoder\n");
-               opj_stream_destroy_v3(l_stream);
+               opj_stream_destroy(l_stream);
                opj_destroy_codec(l_codec);
                return EXIT_FAILURE;
        }
@@ -226,7 +226,7 @@ int main(int argc, char **argv)
        /* Read the main header of the codestream and if necessary the JP2 boxes*/
        if(! opj_read_header(l_stream, l_codec, &image)){
                fprintf(stderr, "ERROR -> j2k_to_image: failed to read the header\n");
-               opj_stream_destroy_v3(l_stream);
+               opj_stream_destroy(l_stream);
                opj_destroy_codec(l_codec);
                opj_image_destroy(image);
                return EXIT_FAILURE;
@@ -246,7 +246,7 @@ int main(int argc, char **argv)
        fprintf(stdout, "Decoding tile %d ...\n", tile_index); \
        if(!opj_get_decoded_tile(l_codec, l_stream, image, tile_index )){ \
                fprintf(stderr, "ERROR -> j2k_to_image: failed to decode tile %d\n", tile_index); \
-               opj_stream_destroy_v3(l_stream); \
+               opj_stream_destroy(l_stream); \
                opj_destroy_cstr_info(&cstr_info); \
                opj_destroy_codec(l_codec); \
                opj_image_destroy(image); \
@@ -255,7 +255,7 @@ int main(int argc, char **argv)
   for(index = 0; index < image->numcomps; ++index) { \
     if( image->comps[index].data == NULL ){ \
        fprintf(stderr, "ERROR -> j2k_to_image: failed to decode tile %d\n", tile_index); \
-               opj_stream_destroy_v3(l_stream); \
+               opj_stream_destroy(l_stream); \
                opj_destroy_cstr_info(&cstr_info); \
                opj_destroy_codec(l_codec); \
                opj_image_destroy(image); \
@@ -272,7 +272,7 @@ int main(int argc, char **argv)
        TEST_TILE(tile_lr)
 
        /* Close the byte stream */
-       opj_stream_destroy_v3(l_stream);
+       opj_stream_destroy(l_stream);
 
        /* Destroy code stream info */
        opj_destroy_cstr_info(&cstr_info);