diff options
| author | Mickael Savinaud <savmickael@users.noreply.github.com> | 2011-10-21 16:36:04 +0000 |
|---|---|---|
| committer | Mickael Savinaud <savmickael@users.noreply.github.com> | 2011-10-21 16:36:04 +0000 |
| commit | 028088f5f077b6cc666f8152736398df68ec239b (patch) | |
| tree | bed941de09c01aab261776d105b554aedd9d155a /applications/codec | |
| parent | 21178c3571a74bb84c39055347210970c1c76666 (diff) | |
[trunk] WIP: enhance codestream index generation
Diffstat (limited to 'applications/codec')
| -rw-r--r-- | applications/codec/j2k_to_image.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/applications/codec/j2k_to_image.c b/applications/codec/j2k_to_image.c index 3296ec7f..1013ef60 100644 --- a/applications/codec/j2k_to_image.c +++ b/applications/codec/j2k_to_image.c @@ -579,6 +579,7 @@ int main(int argc, char **argv) opj_image_t* image = NULL; opj_stream_t *cio = NULL; /* Stream */ opj_codec_t* dinfo = NULL; /* Handle to a decompressor */ + opj_codestream_index_t* cstr_index = NULL; char indexfilename[OPJ_PATH_LEN]; /* index file name */ @@ -720,6 +721,10 @@ int main(int argc, char **argv) return EXIT_FAILURE; } + opj_dump_codec(dinfo, OPJ_J2K_MH_IND, stdout ); + + cstr_index = opj_get_cstr_index(dinfo); + /* Close the byte stream */ opj_stream_destroy(cio); fclose(fsrc); @@ -819,6 +824,9 @@ int main(int argc, char **argv) /* free image data structure */ opj_image_destroy(image); + /* destroy the codestream index */ + opj_destroy_cstr_index(&cstr_index); + } return EXIT_SUCCESS; } |
