summaryrefslogtreecommitdiff
path: root/tests/test_tile_encoder.c
diff options
context:
space:
mode:
authorMickael Savinaud <savmickael@users.noreply.github.com>2012-05-13 22:13:58 +0000
committerMickael Savinaud <savmickael@users.noreply.github.com>2012-05-13 22:13:58 +0000
commit80c23d451930e76cecab7a36bb73c460d59b9871 (patch)
treef9bea60b178d6e1a5eceaefbd5df8f6bde1d9cd2 /tests/test_tile_encoder.c
parent821d7a894123a8909e30a33a35b41969e4767b8a (diff)
solve problem with input of image_to_j2k; using the right return type comparison for opj_stream_flush; add j2k_write_com_v2, j2k_write_poc_v2, j2k_write_eoc_v2 and j2k_write_tlm_v2
Diffstat (limited to 'tests/test_tile_encoder.c')
-rw-r--r--tests/test_tile_encoder.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_tile_encoder.c b/tests/test_tile_encoder.c
index 85f51c70..ee125b10 100644
--- a/tests/test_tile_encoder.c
+++ b/tests/test_tile_encoder.c
@@ -242,6 +242,7 @@ int main ()
l_image->color_space = CLRSPC_SRGB;
if (! opj_setup_encoder_v2(l_codec,&l_param,l_image)) {
+ fprintf(stderr, "ERROR -> test_tile_encoder: failed to setup the codec!\n");
opj_destroy_codec(l_codec);
opj_image_destroy(l_image);
return 1;
@@ -249,6 +250,7 @@ int main ()
l_file = fopen(OUTPUT_FILE,"wb");
if (! l_file) {
+ fprintf(stderr, "ERROR -> test_tile_encoder: failed to create the output file!\n");
opj_destroy_codec(l_codec);
opj_image_destroy(l_image);
return 1;
@@ -257,6 +259,7 @@ int main ()
l_stream = opj_stream_create_default_file_stream(l_file, OPJ_FALSE);
if (! opj_start_compress(l_codec,l_image,l_stream)) {
+ fprintf(stderr, "ERROR -> test_tile_encoder: failed to start compress!\n");
opj_stream_destroy(l_stream);
fclose(l_file);
opj_destroy_codec(l_codec);
@@ -266,6 +269,7 @@ int main ()
for (i=0;i<l_nb_tiles;++i) {
if (! opj_write_tile(l_codec,i,l_data,l_data_size,l_stream)) {
+ fprintf(stderr, "ERROR -> test_tile_encoder: failed to write the tile %d!\n",i);
opj_stream_destroy(l_stream);
fclose(l_file);
opj_destroy_codec(l_codec);
@@ -275,6 +279,7 @@ int main ()
}
if (! opj_end_compress(l_codec,l_stream)) {
+ fprintf(stderr, "ERROR -> test_tile_encoder: failed to end compress!\n");
opj_stream_destroy(l_stream);
fclose(l_file);
opj_destroy_codec(l_codec);