From 3f9fb13df66064ce9ba707e48a8c3ead9556aa49 Mon Sep 17 00:00:00 2001 From: Mickael Savinaud Date: Thu, 9 Aug 2012 12:16:59 +0000 Subject: [PATCH] remove deprecated v1 style function opj_decode and opj_decode_with_info --- libopenjpeg/openjpeg.c | 23 ----------------------- libopenjpeg/openjpeg.h | 17 ----------------- 2 files changed, 40 deletions(-) diff --git a/libopenjpeg/openjpeg.c b/libopenjpeg/openjpeg.c index 91dcfbbb..d0d49ad2 100644 --- a/libopenjpeg/openjpeg.c +++ b/libopenjpeg/openjpeg.c @@ -476,29 +476,6 @@ opj_bool OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec, return OPJ_FALSE; } -/* DEPRECATED */ -opj_image_t* OPJ_CALLCONV opj_decode(opj_dinfo_t *dinfo, opj_cio_t *cio) { - return opj_decode_with_info(dinfo, cio, NULL); -} - -/* DEPRECATED */ -opj_image_t* OPJ_CALLCONV opj_decode_with_info(opj_dinfo_t *dinfo, opj_cio_t *cio, opj_codestream_info_t *cstr_info) { - if(dinfo && cio) { - switch(dinfo->codec_format) { - case CODEC_J2K: - return j2k_decode((opj_j2k_t*)dinfo->j2k_handle, cio, cstr_info); - case CODEC_JPT: - return j2k_decode_jpt_stream((opj_j2k_t*)dinfo->j2k_handle, cio, cstr_info); - case CODEC_JP2: - return opj_jp2_decode((opj_jp2_t*)dinfo->jp2_handle, cio, cstr_info); - case CODEC_UNKNOWN: - default: - break; - } - } - return NULL; -} - /* DEPRECATED */ opj_cinfo_t* OPJ_CALLCONV opj_create_compress(OPJ_CODEC_FORMAT format) { opj_cinfo_t *cinfo = (opj_cinfo_t*)opj_calloc(1, sizeof(opj_cinfo_t)); diff --git a/libopenjpeg/openjpeg.h b/libopenjpeg/openjpeg.h index 108c5071..80bffaca 100644 --- a/libopenjpeg/openjpeg.h +++ b/libopenjpeg/openjpeg.h @@ -1262,14 +1262,6 @@ OPJ_API opj_bool OPJ_CALLCONV opj_set_decode_area( opj_codec_t *p_codec, OPJ_INT32 p_start_x, OPJ_INT32 p_start_y, OPJ_INT32 p_end_x, OPJ_INT32 p_end_y ); -/** -Decode an image from a JPEG-2000 codestream -@param dinfo decompressor handle -@param cio Input buffer stream -@return Returns a decoded image if successful, returns NULL otherwise -*/ -DEPRECATED( OPJ_API opj_image_t* OPJ_CALLCONV opj_decode(opj_dinfo_t *dinfo, opj_cio_t *cio) ); - /** * Decode an image from a JPEG-2000 codestream * @param p_decompressor decompressor handle @@ -1370,15 +1362,6 @@ OPJ_API opj_bool OPJ_CALLCONV opj_decode_tile_data( opj_codec_t *p_codec, OPJ_UINT32 p_data_size, opj_stream_t *p_stream ); -/** -Decode an image from a JPEG-2000 codestream and extract the codestream information -@param dinfo decompressor handle -@param cio Input buffer stream -@param cstr_info Codestream information structure if needed afterwards, NULL otherwise -@return Returns a decoded image if successful, returns NULL otherwise -*/ -DEPRECATED( OPJ_API opj_image_t* OPJ_CALLCONV opj_decode_with_info(opj_dinfo_t *dinfo, opj_cio_t *cio, opj_codestream_info_t *cstr_info) ); - /* COMPRESSION FUNCTIONS*/ /** -- 2.40.0