OpenJPEG
2.4.0
|
Go to the source code of this file.
Data Structures | |
struct | opj_poc |
Progression order changes. More... | |
struct | opj_cparameters |
Compression parameters. More... | |
struct | opj_dparameters |
Decompression parameters. More... | |
struct | opj_image_comp |
Defines a single image component. More... | |
struct | opj_image |
Defines image data and characteristics. More... | |
struct | opj_image_comptparm |
Component parameters structure used by the opj_image_create function. More... | |
struct | opj_packet_info |
Index structure : Information concerning a packet inside tile. More... | |
struct | opj_marker_info |
Marker structure. More... | |
struct | opj_tp_info |
Index structure : Information concerning tile-parts. More... | |
struct | opj_tile_info |
Index structure : information regarding tiles. More... | |
struct | opj_codestream_info |
Index structure of the codestream. More... | |
struct | opj_tccp_info |
Tile-component coding parameters information. More... | |
struct | opj_tile_v2_info |
Tile coding parameters information. More... | |
struct | opj_codestream_info_v2 |
Information structure about the codestream (FIXME should be expand and enhance) More... | |
struct | opj_tp_index |
Index structure about a tile part. More... | |
struct | opj_tile_index |
Index structure about a tile. More... | |
struct | opj_codestream_index |
Index structure of the codestream (FIXME should be expand and enhance) More... | |
struct | opj_jp2_metadata |
Info structure of the JP2 file EXPERIMENTAL FOR THE MOMENT. More... | |
struct | opj_jp2_index |
Index structure of the JP2 file EXPERIMENTAL FOR THE MOMENT. More... | |
Macros | |
#define | INLINE |
#define | OPJ_DEPRECATED(func) func |
#define | OPJ_API |
#define | OPJ_LOCAL |
#define | OPJ_CALLCONV |
#define | OPJ_TRUE 1 |
#define | OPJ_FALSE 0 |
#define | OPJ_ARG_NOT_USED(x) (void)(x) |
#define | OPJ_PATH_LEN 4096 |
Maximum allowed size for filenames. More... | |
#define | OPJ_J2K_MAXRLVLS 33 |
Number of maximum resolution level authorized. More... | |
#define | OPJ_J2K_MAXBANDS (3*OPJ_J2K_MAXRLVLS-2) |
Number of maximum sub-band linked to number of resolution level. More... | |
#define | OPJ_J2K_DEFAULT_NB_SEGS 10 |
#define | OPJ_J2K_STREAM_CHUNK_SIZE 0x100000 /** 1 mega by default */ |
#define | OPJ_J2K_DEFAULT_HEADER_SIZE 1000 |
#define | OPJ_J2K_MCC_DEFAULT_NB_RECORDS 10 |
#define | OPJ_J2K_MCT_DEFAULT_NB_RECORDS 10 |
#define | JPWL_MAX_NO_TILESPECS 16 |
Maximum number of tile parts expected by JPWL: increase at your will. More... | |
#define | JPWL_MAX_NO_PACKSPECS 16 |
Maximum number of packet parts expected by JPWL: increase at your will. More... | |
#define | JPWL_MAX_NO_MARKERS 512 |
Maximum number of JPWL markers: increase at your will. More... | |
#define | JPWL_PRIVATEINDEX_NAME "jpwl_index_privatefilename" |
index file name used when JPWL is on More... | |
#define | JPWL_EXPECTED_COMPONENTS 3 |
Expect this number of components, so you'll find better the first EPB. More... | |
#define | JPWL_MAXIMUM_TILES 8192 |
Expect this maximum number of tiles, to avoid some crashes. More... | |
#define | JPWL_MAXIMUM_HAMMING 2 |
Expect this maximum number of bit errors in marker id's. More... | |
#define | JPWL_MAXIMUM_EPB_ROOM 65450 |
Expect this maximum number of bytes for composition of EPBs. More... | |
#define | OPJ_IMG_INFO 1 |
EXPERIMENTAL FOR THE MOMENT Supported options about file information used only in j2k_dump. More... | |
#define | OPJ_J2K_MH_INFO 2 |
Codestream information based only on the main header. More... | |
#define | OPJ_J2K_TH_INFO 4 |
Tile information based on the current tile header. More... | |
#define | OPJ_J2K_TCH_INFO 8 |
Tile/Component information of all tiles. More... | |
#define | OPJ_J2K_MH_IND 16 |
Codestream index based only on the main header. More... | |
#define | OPJ_J2K_TH_IND 32 |
Tile index based on the current tile. More... | |
#define | OPJ_JP2_INFO 128 |
< More... | |
#define | OPJ_JP2_IND 256 |
JP2 file index. More... | |
#define | OPJ_PROFILE_NONE 0x0000 /** no profile, conform to 15444-1 */ |
JPEG 2000 Profiles, see Table A.10 from 15444-1 (updated in various AMD) These values help choosing the RSIZ value for the J2K codestream. More... | |
#define | OPJ_PROFILE_0 0x0001 /** Profile 0 as described in 15444-1,Table A.45 */ |
#define | OPJ_PROFILE_1 0x0002 /** Profile 1 as described in 15444-1,Table A.45 */ |
#define | OPJ_PROFILE_PART2 0x8000 /** At least 1 extension defined in 15444-2 (Part-2) */ |
#define | OPJ_PROFILE_CINEMA_2K 0x0003 /** 2K cinema profile defined in 15444-1 AMD1 */ |
#define | OPJ_PROFILE_CINEMA_4K 0x0004 /** 4K cinema profile defined in 15444-1 AMD1 */ |
#define | OPJ_PROFILE_CINEMA_S2K 0x0005 /** Scalable 2K cinema profile defined in 15444-1 AMD2 */ |
#define | OPJ_PROFILE_CINEMA_S4K 0x0006 /** Scalable 4K cinema profile defined in 15444-1 AMD2 */ |
#define | OPJ_PROFILE_CINEMA_LTS 0x0007 /** Long term storage cinema profile defined in 15444-1 AMD2 */ |
#define | OPJ_PROFILE_BC_SINGLE 0x0100 /** Single Tile Broadcast profile defined in 15444-1 AMD3 */ |
#define | OPJ_PROFILE_BC_MULTI 0x0200 /** Multi Tile Broadcast profile defined in 15444-1 AMD3 */ |
#define | OPJ_PROFILE_BC_MULTI_R 0x0300 /** Multi Tile Reversible Broadcast profile defined in 15444-1 AMD3 */ |
#define | OPJ_PROFILE_IMF_2K 0x0400 /** 2K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_PROFILE_IMF_4K 0x0500 /** 4K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_PROFILE_IMF_8K 0x0600 /** 8K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_PROFILE_IMF_2K_R 0x0700 /** 2K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_PROFILE_IMF_4K_R 0x0800 /** 4K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_PROFILE_IMF_8K_R 0x0900 /** 8K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
#define | OPJ_EXTENSION_NONE 0x0000 /** No Part-2 extension */ |
JPEG 2000 Part-2 extensions. More... | |
#define | OPJ_EXTENSION_MCT 0x0100 /** Custom MCT support */ |
#define | OPJ_IS_CINEMA(v) (((v) >= OPJ_PROFILE_CINEMA_2K)&&((v) <= OPJ_PROFILE_CINEMA_S4K)) |
JPEG 2000 profile macros. More... | |
#define | OPJ_IS_STORAGE(v) ((v) == OPJ_PROFILE_CINEMA_LTS) |
#define | OPJ_IS_BROADCAST(v) (((v) >= OPJ_PROFILE_BC_SINGLE)&&((v) <= ((OPJ_PROFILE_BC_MULTI_R) | (0x000b)))) |
#define | OPJ_IS_IMF(v) (((v) >= OPJ_PROFILE_IMF_2K)&&((v) <= ((OPJ_PROFILE_IMF_8K_R) | (0x009b)))) |
#define | OPJ_IS_PART2(v) ((v) & OPJ_PROFILE_PART2) |
#define | OPJ_GET_IMF_PROFILE(v) ((v) & 0xff00) /** Extract IMF profile without mainlevel/sublevel */ |
#define | OPJ_GET_IMF_MAINLEVEL(v) ((v) & 0xf) /** Extract IMF main level */ |
#define | OPJ_GET_IMF_SUBLEVEL(v) (((v) >> 4) & 0xf) /** Extract IMF sub level */ |
#define | OPJ_IMF_MAINLEVEL_MAX 11 /** Maximum main level */ |
#define | OPJ_IMF_MAINLEVEL_1_MSAMPLESEC 65 /** MSamples/sec for IMF main level 1 */ |
Max. More... | |
#define | OPJ_IMF_MAINLEVEL_2_MSAMPLESEC 130 /** MSamples/sec for IMF main level 2 */ |
#define | OPJ_IMF_MAINLEVEL_3_MSAMPLESEC 195 /** MSamples/sec for IMF main level 3 */ |
#define | OPJ_IMF_MAINLEVEL_4_MSAMPLESEC 260 /** MSamples/sec for IMF main level 4 */ |
#define | OPJ_IMF_MAINLEVEL_5_MSAMPLESEC 520 /** MSamples/sec for IMF main level 5 */ |
#define | OPJ_IMF_MAINLEVEL_6_MSAMPLESEC 1200 /** MSamples/sec for IMF main level 6 */ |
#define | OPJ_IMF_MAINLEVEL_7_MSAMPLESEC 2400 /** MSamples/sec for IMF main level 7 */ |
#define | OPJ_IMF_MAINLEVEL_8_MSAMPLESEC 4800 /** MSamples/sec for IMF main level 8 */ |
#define | OPJ_IMF_MAINLEVEL_9_MSAMPLESEC 9600 /** MSamples/sec for IMF main level 9 */ |
#define | OPJ_IMF_MAINLEVEL_10_MSAMPLESEC 19200 /** MSamples/sec for IMF main level 10 */ |
#define | OPJ_IMF_MAINLEVEL_11_MSAMPLESEC 38400 /** MSamples/sec for IMF main level 11 */ |
#define | OPJ_IMF_SUBLEVEL_1_MBITSSEC 200 /** Mbits/s for IMF sub level 1 */ |
Max. More... | |
#define | OPJ_IMF_SUBLEVEL_2_MBITSSEC 400 /** Mbits/s for IMF sub level 2 */ |
#define | OPJ_IMF_SUBLEVEL_3_MBITSSEC 800 /** Mbits/s for IMF sub level 3 */ |
#define | OPJ_IMF_SUBLEVEL_4_MBITSSEC 1600 /** Mbits/s for IMF sub level 4 */ |
#define | OPJ_IMF_SUBLEVEL_5_MBITSSEC 3200 /** Mbits/s for IMF sub level 5 */ |
#define | OPJ_IMF_SUBLEVEL_6_MBITSSEC 6400 /** Mbits/s for IMF sub level 6 */ |
#define | OPJ_IMF_SUBLEVEL_7_MBITSSEC 12800 /** Mbits/s for IMF sub level 7 */ |
#define | OPJ_IMF_SUBLEVEL_8_MBITSSEC 25600 /** Mbits/s for IMF sub level 8 */ |
#define | OPJ_IMF_SUBLEVEL_9_MBITSSEC 51200 /** Mbits/s for IMF sub level 9 */ |
#define | OPJ_CINEMA_24_CS 1302083 /** Maximum codestream length for 24fps */ |
JPEG 2000 codestream and component size limits in cinema profiles. More... | |
#define | OPJ_CINEMA_48_CS 651041 /** Maximum codestream length for 48fps */ |
#define | OPJ_CINEMA_24_COMP 1041666 /** Maximum size per color component for 2K & 4K @ 24fps */ |
#define | OPJ_CINEMA_48_COMP 520833 /** Maximum size per color component for 2K @ 48fps */ |
#define | OPJ_UINT32_SEMANTICALLY_BUT_INT32 OPJ_INT32 |
#define | OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG 0x0001 |
#define | OPJ_DPARAMETERS_DUMP_FLAG 0x0002 |
#define | OPJ_STREAM_READ OPJ_TRUE |
Stream open flags. More... | |
#define | OPJ_STREAM_WRITE OPJ_FALSE |
The stream was opened for writing. More... | |
Typedefs | |
typedef int | OPJ_BOOL |
typedef char | OPJ_CHAR |
typedef float | OPJ_FLOAT32 |
typedef double | OPJ_FLOAT64 |
typedef unsigned char | OPJ_BYTE |
typedef int8_t | OPJ_INT8 |
typedef uint8_t | OPJ_UINT8 |
typedef int16_t | OPJ_INT16 |
typedef uint16_t | OPJ_UINT16 |
typedef int32_t | OPJ_INT32 |
typedef uint32_t | OPJ_UINT32 |
typedef int64_t | OPJ_INT64 |
typedef uint64_t | OPJ_UINT64 |
typedef int64_t | OPJ_OFF_T |
typedef size_t | OPJ_SIZE_T |
typedef enum RSIZ_CAPABILITIES | OPJ_RSIZ_CAPABILITIES |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Rsiz Capabilities. More... | |
typedef enum CINEMA_MODE | OPJ_CINEMA_MODE |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Digital cinema operation mode. More... | |
typedef enum PROG_ORDER | OPJ_PROG_ORDER |
Progression order. More... | |
typedef enum COLOR_SPACE | OPJ_COLOR_SPACE |
Supported image color spaces. More... | |
typedef enum CODEC_FORMAT | OPJ_CODEC_FORMAT |
Supported codec. More... | |
typedef void(* | opj_msg_callback) (const char *msg, void *client_data) |
Callback function prototype for events. More... | |
typedef struct opj_poc | opj_poc_t |
Progression order changes. More... | |
typedef struct opj_cparameters | opj_cparameters_t |
Compression parameters. More... | |
typedef struct opj_dparameters | opj_dparameters_t |
Decompression parameters. More... | |
typedef void * | opj_codec_t |
JPEG2000 codec V2. More... | |
typedef OPJ_SIZE_T(* | opj_stream_read_fn) (void *p_buffer, OPJ_SIZE_T p_nb_bytes, void *p_user_data) |
typedef OPJ_SIZE_T(* | opj_stream_write_fn) (void *p_buffer, OPJ_SIZE_T p_nb_bytes, void *p_user_data) |
typedef OPJ_OFF_T(* | opj_stream_skip_fn) (OPJ_OFF_T p_nb_bytes, void *p_user_data) |
typedef OPJ_BOOL(* | opj_stream_seek_fn) (OPJ_OFF_T p_nb_bytes, void *p_user_data) |
typedef void(* | opj_stream_free_user_data_fn) (void *p_user_data) |
typedef void * | opj_stream_t |
typedef struct opj_image_comp | opj_image_comp_t |
Defines a single image component. More... | |
typedef struct opj_image | opj_image_t |
Defines image data and characteristics. More... | |
typedef struct opj_image_comptparm | opj_image_cmptparm_t |
Component parameters structure used by the opj_image_create function. More... | |
typedef struct opj_packet_info | opj_packet_info_t |
Index structure : Information concerning a packet inside tile. More... | |
typedef struct opj_marker_info | opj_marker_info_t |
Marker structure. More... | |
typedef struct opj_tp_info | opj_tp_info_t |
Index structure : Information concerning tile-parts. More... | |
typedef struct opj_tile_info | opj_tile_info_t |
Index structure : information regarding tiles. More... | |
typedef struct opj_codestream_info | opj_codestream_info_t |
Index structure of the codestream. More... | |
typedef struct opj_tccp_info | opj_tccp_info_t |
Tile-component coding parameters information. More... | |
typedef struct opj_tile_v2_info | opj_tile_info_v2_t |
Tile coding parameters information. More... | |
typedef struct opj_codestream_info_v2 | opj_codestream_info_v2_t |
Information structure about the codestream (FIXME should be expand and enhance) More... | |
typedef struct opj_tp_index | opj_tp_index_t |
Index structure about a tile part. More... | |
typedef struct opj_tile_index | opj_tile_index_t |
Index structure about a tile. More... | |
typedef struct opj_codestream_index | opj_codestream_index_t |
Index structure of the codestream (FIXME should be expand and enhance) More... | |
typedef struct opj_jp2_metadata | opj_jp2_metadata_t |
Info structure of the JP2 file EXPERIMENTAL FOR THE MOMENT. More... | |
typedef struct opj_jp2_index | opj_jp2_index_t |
Index structure of the JP2 file EXPERIMENTAL FOR THE MOMENT. More... | |
Enumerations | |
enum | RSIZ_CAPABILITIES { OPJ_STD_RSIZ = 0, OPJ_CINEMA2K = 3, OPJ_CINEMA4K = 4, OPJ_MCT = 0x8100 } |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Rsiz Capabilities. More... | |
enum | CINEMA_MODE { OPJ_OFF = 0, OPJ_CINEMA2K_24 = 1, OPJ_CINEMA2K_48 = 2, OPJ_CINEMA4K_24 = 3 } |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Digital cinema operation mode. More... | |
enum | PROG_ORDER { OPJ_PROG_UNKNOWN = -1, OPJ_LRCP = 0, OPJ_RLCP = 1, OPJ_RPCL = 2, OPJ_PCRL = 3, OPJ_CPRL = 4 } |
Progression order. More... | |
enum | COLOR_SPACE { OPJ_CLRSPC_UNKNOWN = -1, OPJ_CLRSPC_UNSPECIFIED = 0, OPJ_CLRSPC_SRGB = 1, OPJ_CLRSPC_GRAY = 2, OPJ_CLRSPC_SYCC = 3, OPJ_CLRSPC_EYCC = 4, OPJ_CLRSPC_CMYK = 5 } |
Supported image color spaces. More... | |
enum | CODEC_FORMAT { OPJ_CODEC_UNKNOWN = -1, OPJ_CODEC_J2K = 0, OPJ_CODEC_JPT = 1, OPJ_CODEC_JP2 = 2, OPJ_CODEC_JPP = 3, OPJ_CODEC_JPX = 4 } |
Supported codec. More... | |
Functions | |
OPJ_API const char *OPJ_CALLCONV | opj_version (void) |
OPJ_API opj_image_t *OPJ_CALLCONV | opj_image_create (OPJ_UINT32 numcmpts, opj_image_cmptparm_t *cmptparms, OPJ_COLOR_SPACE clrspc) |
Create an image. More... | |
OPJ_API void OPJ_CALLCONV | opj_image_destroy (opj_image_t *image) |
Deallocate any resources associated with an image. More... | |
OPJ_API opj_image_t *OPJ_CALLCONV | opj_image_tile_create (OPJ_UINT32 numcmpts, opj_image_cmptparm_t *cmptparms, OPJ_COLOR_SPACE clrspc) |
Creates an image without allocating memory for the image (used in the new version of the library). More... | |
OPJ_API void *OPJ_CALLCONV | opj_image_data_alloc (OPJ_SIZE_T size) |
Allocator for opj_image_t->comps[].data To be paired with opj_image_data_free. More... | |
OPJ_API void OPJ_CALLCONV | opj_image_data_free (void *ptr) |
Destructor for opj_image_t->comps[].data To be paired with opj_image_data_alloc. More... | |
OPJ_API opj_stream_t *OPJ_CALLCONV | opj_stream_default_create (OPJ_BOOL p_is_input) |
Creates an abstract stream. More... | |
OPJ_API opj_stream_t *OPJ_CALLCONV | opj_stream_create (OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_input) |
Creates an abstract stream. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_destroy (opj_stream_t *p_stream) |
Destroys a stream created by opj_create_stream. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_read_function (opj_stream_t *p_stream, opj_stream_read_fn p_function) |
Sets the given function to be used as a read function. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_write_function (opj_stream_t *p_stream, opj_stream_write_fn p_function) |
Sets the given function to be used as a write function. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_skip_function (opj_stream_t *p_stream, opj_stream_skip_fn p_function) |
Sets the given function to be used as a skip function. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_seek_function (opj_stream_t *p_stream, opj_stream_seek_fn p_function) |
Sets the given function to be used as a seek function, the stream is then seekable, using SEEK_SET behavior. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_user_data (opj_stream_t *p_stream, void *p_data, opj_stream_free_user_data_fn p_function) |
Sets the given data to be used as a user data for the stream. More... | |
OPJ_API void OPJ_CALLCONV | opj_stream_set_user_data_length (opj_stream_t *p_stream, OPJ_UINT64 data_length) |
Sets the length of the user data for the stream. More... | |
OPJ_API opj_stream_t *OPJ_CALLCONV | opj_stream_create_default_file_stream (const char *fname, OPJ_BOOL p_is_read_stream) |
Create a stream from a file identified with its filename with default parameters (helper function) More... | |
OPJ_API opj_stream_t *OPJ_CALLCONV | opj_stream_create_file_stream (const char *fname, OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_read_stream) |
Create a stream from a file identified with its filename with a specific buffer size. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_info_handler (opj_codec_t *p_codec, opj_msg_callback p_callback, void *p_user_data) |
Set the info handler use by openjpeg. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_warning_handler (opj_codec_t *p_codec, opj_msg_callback p_callback, void *p_user_data) |
Set the warning handler use by openjpeg. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_error_handler (opj_codec_t *p_codec, opj_msg_callback p_callback, void *p_user_data) |
Set the error handler use by openjpeg. More... | |
OPJ_API opj_codec_t *OPJ_CALLCONV | opj_create_decompress (OPJ_CODEC_FORMAT format) |
Creates a J2K/JP2 decompression structure. More... | |
OPJ_API void OPJ_CALLCONV | opj_destroy_codec (opj_codec_t *p_codec) |
Destroy a decompressor handle. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_end_decompress (opj_codec_t *p_codec, opj_stream_t *p_stream) |
Read after the codestream if necessary. More... | |
OPJ_API void OPJ_CALLCONV | opj_set_default_decoder_parameters (opj_dparameters_t *parameters) |
Set decoding parameters to default values. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_setup_decoder (opj_codec_t *p_codec, opj_dparameters_t *parameters) |
Setup the decoder with decompression parameters provided by the user and with the message handler provided by the user. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_codec_set_threads (opj_codec_t *p_codec, int num_threads) |
Allocates worker threads for the compressor/decompressor. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_read_header (opj_stream_t *p_stream, opj_codec_t *p_codec, opj_image_t **p_image) |
Decodes an image header. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_decoded_components (opj_codec_t *p_codec, OPJ_UINT32 numcomps, const OPJ_UINT32 *comps_indices, OPJ_BOOL apply_color_transforms) |
Restrict the number of components to decode. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_decode_area (opj_codec_t *p_codec, opj_image_t *p_image, OPJ_INT32 p_start_x, OPJ_INT32 p_start_y, OPJ_INT32 p_end_x, OPJ_INT32 p_end_y) |
Sets the given area to be decoded. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_decode (opj_codec_t *p_decompressor, opj_stream_t *p_stream, opj_image_t *p_image) |
Decode an image from a JPEG-2000 codestream. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_get_decoded_tile (opj_codec_t *p_codec, opj_stream_t *p_stream, opj_image_t *p_image, OPJ_UINT32 tile_index) |
Get the decoded tile from the codec. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_decoded_resolution_factor (opj_codec_t *p_codec, OPJ_UINT32 res_factor) |
Set the resolution factor of the decoded image. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_write_tile (opj_codec_t *p_codec, OPJ_UINT32 p_tile_index, OPJ_BYTE *p_data, OPJ_UINT32 p_data_size, opj_stream_t *p_stream) |
Writes a tile with the given data. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_read_tile_header (opj_codec_t *p_codec, opj_stream_t *p_stream, OPJ_UINT32 *p_tile_index, OPJ_UINT32 *p_data_size, OPJ_INT32 *p_tile_x0, OPJ_INT32 *p_tile_y0, OPJ_INT32 *p_tile_x1, OPJ_INT32 *p_tile_y1, OPJ_UINT32 *p_nb_comps, OPJ_BOOL *p_should_go_on) |
Reads a tile header. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_decode_tile_data (opj_codec_t *p_codec, OPJ_UINT32 p_tile_index, OPJ_BYTE *p_data, OPJ_UINT32 p_data_size, opj_stream_t *p_stream) |
Reads a tile data. More... | |
OPJ_API opj_codec_t *OPJ_CALLCONV | opj_create_compress (OPJ_CODEC_FORMAT format) |
Creates a J2K/JP2 compression structure. More... | |
OPJ_API void OPJ_CALLCONV | opj_set_default_encoder_parameters (opj_cparameters_t *parameters) |
Set encoding parameters to default values, that means : More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_setup_encoder (opj_codec_t *p_codec, opj_cparameters_t *parameters, opj_image_t *image) |
Setup the encoder parameters using the current image and using user parameters. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_encoder_set_extra_options (opj_codec_t *p_codec, const char *const *p_options) |
Specify extra options for the encoder. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_start_compress (opj_codec_t *p_codec, opj_image_t *p_image, opj_stream_t *p_stream) |
Start to compress the current image. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_end_compress (opj_codec_t *p_codec, opj_stream_t *p_stream) |
End to compress the current image. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_encode (opj_codec_t *p_codec, opj_stream_t *p_stream) |
Encode an image into a JPEG-2000 codestream. More... | |
OPJ_API void OPJ_CALLCONV | opj_destroy_cstr_info (opj_codestream_info_v2_t **cstr_info) |
Destroy Codestream information after compression or decompression. More... | |
OPJ_API void OPJ_CALLCONV | opj_dump_codec (opj_codec_t *p_codec, OPJ_INT32 info_flag, FILE *output_stream) |
Dump the codec information into the output stream. More... | |
OPJ_API opj_codestream_info_v2_t *OPJ_CALLCONV | opj_get_cstr_info (opj_codec_t *p_codec) |
Get the codestream information from the codec. More... | |
OPJ_API opj_codestream_index_t *OPJ_CALLCONV | opj_get_cstr_index (opj_codec_t *p_codec) |
Get the codestream index from the codec. More... | |
OPJ_API void OPJ_CALLCONV | opj_destroy_cstr_index (opj_codestream_index_t **p_cstr_index) |
OPJ_API opj_jp2_metadata_t *OPJ_CALLCONV | opj_get_jp2_metadata (opj_codec_t *p_codec) |
Get the JP2 file information from the codec FIXME. More... | |
OPJ_API opj_jp2_index_t *OPJ_CALLCONV | opj_get_jp2_index (opj_codec_t *p_codec) |
Get the JP2 file index from the codec FIXME. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_set_MCT (opj_cparameters_t *parameters, OPJ_FLOAT32 *pEncodingMatrix, OPJ_INT32 *p_dc_shift, OPJ_UINT32 pNbComp) |
Sets the MCT matrix to use. More... | |
OPJ_API OPJ_BOOL OPJ_CALLCONV | opj_has_thread_support (void) |
Returns if the library is built with thread support. More... | |
OPJ_API int OPJ_CALLCONV | opj_get_num_cpus (void) |
Return the number of virtual CPUs. More... | |
#define INLINE |
#define JPWL_EXPECTED_COMPONENTS 3 |
Expect this number of components, so you'll find better the first EPB.
Referenced by opj_set_default_decoder_parameters().
#define JPWL_MAX_NO_MARKERS 512 |
Maximum number of JPWL markers: increase at your will.
#define JPWL_MAX_NO_PACKSPECS 16 |
Maximum number of packet parts expected by JPWL: increase at your will.
Referenced by opj_j2k_setup_encoder(), and opj_set_default_encoder_parameters().
#define JPWL_MAX_NO_TILESPECS 16 |
Maximum number of tile parts expected by JPWL: increase at your will.
Referenced by opj_j2k_setup_encoder(), and opj_set_default_encoder_parameters().
#define JPWL_MAXIMUM_EPB_ROOM 65450 |
Expect this maximum number of bytes for composition of EPBs.
#define JPWL_MAXIMUM_HAMMING 2 |
Expect this maximum number of bit errors in marker id's.
#define JPWL_MAXIMUM_TILES 8192 |
Expect this maximum number of tiles, to avoid some crashes.
Referenced by opj_set_default_decoder_parameters().
#define JPWL_PRIVATEINDEX_NAME "jpwl_index_privatefilename" |
index file name used when JPWL is on
#define OPJ_API |
#define OPJ_ARG_NOT_USED | ( | x | ) | (void)(x) |
Referenced by opj_default_callback(), opj_mct_decode_custom(), opj_mct_encode_custom(), opj_pi_update_decode_poc(), opj_pi_update_encode_poc_and_final(), opj_seek_from_file(), opj_stream_default_read(), opj_stream_default_seek(), opj_stream_default_skip(), opj_stream_default_write(), opj_stream_read_seek(), opj_t1_getwmsedec(), opj_t2_decode_packets(), opj_t2_read_packet_data(), and opj_t2_skip_packet_data().
#define OPJ_CALLCONV |
#define OPJ_CINEMA_24_COMP 1041666 /** Maximum size per color component for 2K & 4K @ 24fps */ |
Referenced by opj_j2k_set_cinema_parameters(), and opj_j2k_setup_encoder().
#define OPJ_CINEMA_24_CS 1302083 /** Maximum codestream length for 24fps */ |
JPEG 2000 codestream and component size limits in cinema profiles.
Referenced by opj_j2k_set_cinema_parameters(), and opj_j2k_setup_encoder().
#define OPJ_CINEMA_48_COMP 520833 /** Maximum size per color component for 2K @ 48fps */ |
Referenced by opj_j2k_setup_encoder().
#define OPJ_CINEMA_48_CS 651041 /** Maximum codestream length for 48fps */ |
Referenced by opj_j2k_setup_encoder().
#define OPJ_DEPRECATED | ( | func | ) | func |
#define OPJ_DPARAMETERS_DUMP_FLAG 0x0002 |
Referenced by opj_j2k_setup_decoder().
#define OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG 0x0001 |
Referenced by opj_jp2_setup_decoder().
#define OPJ_EXTENSION_MCT 0x0100 /** Custom MCT support */ |
Referenced by opj_j2k_setup_encoder(), opj_j2k_setup_header_writing(), and opj_set_MCT().
#define OPJ_EXTENSION_NONE 0x0000 /** No Part-2 extension */ |
JPEG 2000 Part-2 extensions.
Referenced by opj_j2k_setup_encoder().
#define OPJ_FALSE 0 |
Referenced by associate_channel(), check_JP2boxidx(), close_channel(), delete_session(), enqueue_metabins(), fread_jpip(), fwrite_jp2k(), gene_cachemodel(), gene_JPIPstream(), gene_metamsg(), get_initquery(), get_mainheader_from_j2kstream(), handle_clientreq(), identify_cid(), identify_target(), is_allsent(), isJPPstream(), isJPTfeasible(), main(), modify_COCmkrstream(), modify_mainheader(), modify_SIZmkrstream(), modify_tileheader(), open_channel(), opj_alloc_tile_component_data(), opj_bio_bytein(), opj_bio_byteout(), opj_bio_flush(), opj_bio_inalign(), opj_check_EPHuse(), opj_codec_set_threads(), opj_create_compress(), opj_decode(), opj_decode_tile_data(), opj_dwt_decode_partial_97(), opj_dwt_decode_partial_tile(), opj_dwt_decode_tile(), opj_dwt_decode_tile_97(), opj_dwt_encode_h_func(), opj_dwt_encode_procedure(), opj_encode(), opj_encoder_set_extra_options(), opj_end_compress(), opj_end_decompress(), opj_event_msg(), opj_get_decoded_tile(), opj_has_thread_support(), opj_j2k_add_mct(), opj_j2k_add_mhmarker(), opj_j2k_add_tlmarker(), opj_j2k_allocate_tile_element_cstr_index(), opj_j2k_are_all_used_components_decoded(), opj_j2k_check_poc_val(), opj_j2k_compare_coc(), opj_j2k_compare_SPCod_SPCoc(), opj_j2k_compare_SQcd_SQcc(), opj_j2k_copy_default_tcp_and_create_tcd(), opj_j2k_create_tcd(), opj_j2k_decode(), opj_j2k_decode_one_tile(), opj_j2k_decode_tile(), opj_j2k_decode_tiles(), opj_j2k_encode(), opj_j2k_encoder_set_extra_options(), opj_j2k_encoding_validation(), opj_j2k_end_compress(), opj_j2k_get_sot_values(), opj_j2k_get_tile(), opj_j2k_is_cinema_compliant(), opj_j2k_is_imf_compliant(), opj_j2k_merge_ppm(), opj_j2k_merge_ppt(), opj_j2k_move_data_from_codec_to_output_image(), opj_j2k_need_nb_tile_parts_correction(), opj_j2k_post_write_tile(), opj_j2k_pre_write_tile(), opj_j2k_read_cbd(), opj_j2k_read_coc(), opj_j2k_read_cod(), opj_j2k_read_crg(), opj_j2k_read_header(), opj_j2k_read_header_procedure(), opj_j2k_read_mcc(), opj_j2k_read_mco(), opj_j2k_read_mct(), opj_j2k_read_plm(), opj_j2k_read_plt(), opj_j2k_read_poc(), opj_j2k_read_ppm(), opj_j2k_read_ppt(), opj_j2k_read_qcc(), opj_j2k_read_qcd(), opj_j2k_read_rgn(), opj_j2k_read_siz(), opj_j2k_read_soc(), opj_j2k_read_sod(), opj_j2k_read_sot(), opj_j2k_read_SPCod_SPCoc(), opj_j2k_read_SQcd_SQcc(), opj_j2k_read_tile_header(), opj_j2k_read_tlm(), opj_j2k_read_unk(), opj_j2k_set_cinema_parameters(), opj_j2k_set_decode_area(), opj_j2k_set_decoded_components(), opj_j2k_set_decoded_resolution_factor(), opj_j2k_set_threads(), opj_j2k_setup_decoding(), opj_j2k_setup_decoding_tile(), opj_j2k_setup_decoding_validation(), opj_j2k_setup_encoder(), opj_j2k_setup_encoding_validation(), opj_j2k_setup_end_compress(), opj_j2k_setup_header_reading(), opj_j2k_setup_header_writing(), opj_j2k_setup_mct_encoding(), opj_j2k_start_compress(), opj_j2k_update_image_data(), opj_j2k_update_image_dimensions(), opj_j2k_update_rates(), opj_j2k_write_all_coc(), opj_j2k_write_all_qcc(), opj_j2k_write_all_tile_parts(), opj_j2k_write_cbd(), opj_j2k_write_coc(), opj_j2k_write_cod(), opj_j2k_write_com(), opj_j2k_write_eoc(), opj_j2k_write_first_tile_part(), opj_j2k_write_mcc_record(), opj_j2k_write_mco(), opj_j2k_write_mct_data_group(), opj_j2k_write_mct_record(), opj_j2k_write_plt_in_memory(), opj_j2k_write_poc(), opj_j2k_write_qcc(), opj_j2k_write_qcd(), opj_j2k_write_regions(), opj_j2k_write_rgn(), opj_j2k_write_siz(), opj_j2k_write_soc(), opj_j2k_write_sod(), opj_j2k_write_sot(), opj_j2k_write_SPCod_SPCoc(), opj_j2k_write_SQcd_SQcc(), opj_j2k_write_tile(), opj_j2k_write_tlm(), opj_j2k_write_updated_tlm(), opj_jp2_apply_pclr(), opj_jp2_check_color(), opj_jp2_decode(), opj_jp2_encoder_set_extra_options(), opj_jp2_end_compress(), opj_jp2_end_decompress(), opj_jp2_get_tile(), opj_jp2_read_boxhdr(), opj_jp2_read_boxhdr_char(), opj_jp2_read_bpcc(), opj_jp2_read_cdef(), opj_jp2_read_cmap(), opj_jp2_read_colr(), opj_jp2_read_ftyp(), opj_jp2_read_header(), opj_jp2_read_header_procedure(), opj_jp2_read_ihdr(), opj_jp2_read_jp(), opj_jp2_read_jp2h(), opj_jp2_read_pclr(), opj_jp2_setup_encoder(), opj_jp2_setup_encoding_validation(), opj_jp2_setup_end_header_reading(), opj_jp2_setup_end_header_writing(), opj_jp2_setup_header_reading(), opj_jp2_setup_header_writing(), opj_jp2_skip_jp2c(), opj_jp2_start_compress(), opj_jp2_write_ftyp(), opj_jp2_write_jp(), opj_jp2_write_jp2c(), opj_jp2_write_jp2h(), opj_jpip_skip_iptr(), opj_lupDecompose(), opj_matrix_inversion_f(), opj_mct_decode_custom(), opj_mct_encode_custom(), opj_pi_check_next_level(), opj_pi_next(), opj_pi_next_cprl(), opj_pi_next_lrcp(), opj_pi_next_pcrl(), opj_pi_next_rlcp(), opj_pi_next_rpcl(), opj_procedure_list_add_procedure(), opj_read_header(), opj_read_tile_header(), opj_seek_from_file(), opj_set_decode_area(), opj_set_decoded_components(), opj_set_decoded_resolution_factor(), opj_set_default_decoder_parameters(), opj_set_default_encoder_parameters(), opj_set_error_handler(), opj_set_info_handler(), opj_set_MCT(), opj_set_warning_handler(), opj_setup_decoder(), opj_setup_encoder(), opj_sparse_array_int32_read_or_write(), opj_sparse_array_int32_write(), opj_start_compress(), opj_stream_default_seek(), opj_stream_flush(), opj_stream_read_seek(), opj_stream_write_seek(), opj_t1_allocate_buffers(), opj_t1_cblk_encode_processor(), opj_t1_clbl_decode_processor(), opj_t1_dec_clnpass_64x64_novsc(), opj_t1_dec_clnpass_generic_novsc(), opj_t1_dec_clnpass_step(), opj_t1_dec_sigpass_mqc_64x64_novsc(), opj_t1_dec_sigpass_mqc_generic_novsc(), opj_t1_dec_sigpass_raw(), opj_t1_decode_cblk(), opj_t1_decode_cblks(), opj_t1_enc_is_term_pass(), opj_t1_encode_cblks(), opj_t2_decode_packet(), opj_t2_decode_packets(), opj_t2_encode_packet(), opj_t2_encode_packets(), opj_t2_init_seg(), opj_t2_read_packet_data(), opj_t2_read_packet_header(), opj_t2_skip_packet(), opj_t2_skip_packet_data(), opj_tcd_code_block_dec_allocate(), opj_tcd_code_block_enc_allocate(), opj_tcd_code_block_enc_allocate_data(), opj_tcd_copy_tile_data(), opj_tcd_decode_tile(), opj_tcd_dwt_decode(), opj_tcd_dwt_encode(), opj_tcd_encode_tile(), opj_tcd_init(), opj_tcd_init_decode_tile(), opj_tcd_init_tile(), opj_tcd_mct_decode(), opj_tcd_mct_encode(), opj_tcd_rate_allocate_encode(), opj_tcd_rateallocate(), opj_tcd_t1_decode(), opj_tcd_t2_decode(), opj_tcd_t2_encode(), opj_tcd_update_tile_data(), opj_thread_pool_get_next_job(), opj_thread_pool_setup(), opj_thread_pool_submit_job(), opj_tls_set(), opj_worker_thread_function(), opj_write_tile(), parse_JPIPstream(), recons_codestream_from_JPPstream(), recons_codestream_from_JPTstream(), recons_packet(), recons_precinct(), recv_ack(), search_session_and_channel(), set_cidxdata(), set_CODmkrdata(), set_cptrdata(), set_mainmhixdata(), set_ppixdata(), set_SIZmkrdata(), set_thixdata(), and set_tpixdata().
#define OPJ_GET_IMF_MAINLEVEL | ( | v | ) | ((v) & 0xf) /** Extract IMF main level */ |
Referenced by opj_j2k_is_imf_compliant().
#define OPJ_GET_IMF_PROFILE | ( | v | ) | ((v) & 0xff00) /** Extract IMF profile without mainlevel/sublevel */ |
Referenced by opj_j2k_get_imf_max_NL(), opj_j2k_is_imf_compliant(), and opj_j2k_set_imf_parameters().
#define OPJ_GET_IMF_SUBLEVEL | ( | v | ) | (((v) >> 4) & 0xf) /** Extract IMF sub level */ |
Referenced by opj_j2k_is_imf_compliant().
#define OPJ_IMF_MAINLEVEL_10_MSAMPLESEC 19200 /** MSamples/sec for IMF main level 10 */ |
#define OPJ_IMF_MAINLEVEL_11_MSAMPLESEC 38400 /** MSamples/sec for IMF main level 11 */ |
#define OPJ_IMF_MAINLEVEL_1_MSAMPLESEC 65 /** MSamples/sec for IMF main level 1 */ |
Max.
Components Sampling Rate (MSamples/sec) per IMF main level
#define OPJ_IMF_MAINLEVEL_2_MSAMPLESEC 130 /** MSamples/sec for IMF main level 2 */ |
#define OPJ_IMF_MAINLEVEL_3_MSAMPLESEC 195 /** MSamples/sec for IMF main level 3 */ |
#define OPJ_IMF_MAINLEVEL_4_MSAMPLESEC 260 /** MSamples/sec for IMF main level 4 */ |
#define OPJ_IMF_MAINLEVEL_5_MSAMPLESEC 520 /** MSamples/sec for IMF main level 5 */ |
#define OPJ_IMF_MAINLEVEL_6_MSAMPLESEC 1200 /** MSamples/sec for IMF main level 6 */ |
#define OPJ_IMF_MAINLEVEL_7_MSAMPLESEC 2400 /** MSamples/sec for IMF main level 7 */ |
#define OPJ_IMF_MAINLEVEL_8_MSAMPLESEC 4800 /** MSamples/sec for IMF main level 8 */ |
#define OPJ_IMF_MAINLEVEL_9_MSAMPLESEC 9600 /** MSamples/sec for IMF main level 9 */ |
#define OPJ_IMF_MAINLEVEL_MAX 11 /** Maximum main level */ |
Referenced by opj_j2k_is_imf_compliant().
#define OPJ_IMF_SUBLEVEL_1_MBITSSEC 200 /** Mbits/s for IMF sub level 1 */ |
Max.
compressed Bit Rate (Mbits/s) per IMF sub level
#define OPJ_IMF_SUBLEVEL_2_MBITSSEC 400 /** Mbits/s for IMF sub level 2 */ |
#define OPJ_IMF_SUBLEVEL_3_MBITSSEC 800 /** Mbits/s for IMF sub level 3 */ |
#define OPJ_IMF_SUBLEVEL_4_MBITSSEC 1600 /** Mbits/s for IMF sub level 4 */ |
#define OPJ_IMF_SUBLEVEL_5_MBITSSEC 3200 /** Mbits/s for IMF sub level 5 */ |
#define OPJ_IMF_SUBLEVEL_6_MBITSSEC 6400 /** Mbits/s for IMF sub level 6 */ |
#define OPJ_IMF_SUBLEVEL_7_MBITSSEC 12800 /** Mbits/s for IMF sub level 7 */ |
#define OPJ_IMF_SUBLEVEL_8_MBITSSEC 25600 /** Mbits/s for IMF sub level 8 */ |
#define OPJ_IMF_SUBLEVEL_9_MBITSSEC 51200 /** Mbits/s for IMF sub level 9 */ |
#define OPJ_IMG_INFO 1 |
EXPERIMENTAL FOR THE MOMENT Supported options about file information used only in j2k_dump.
Basic image information provided to the user
Referenced by j2k_dump().
#define OPJ_IS_BROADCAST | ( | v | ) | (((v) >= OPJ_PROFILE_BC_SINGLE)&&((v) <= ((OPJ_PROFILE_BC_MULTI_R) | (0x000b)))) |
Referenced by opj_j2k_setup_encoder().
#define OPJ_IS_CINEMA | ( | v | ) | (((v) >= OPJ_PROFILE_CINEMA_2K)&&((v) <= OPJ_PROFILE_CINEMA_S4K)) |
JPEG 2000 profile macros.
Referenced by opj_j2k_get_specific_header_sizes(), opj_j2k_setup_encoder(), opj_j2k_setup_end_compress(), opj_j2k_setup_header_writing(), opj_j2k_update_rates(), opj_j2k_write_all_tile_parts(), opj_j2k_write_first_tile_part(), opj_pi_create_encode(), opj_pi_initialise_encode(), and opj_tcd_rateallocate().
#define OPJ_IS_IMF | ( | v | ) | (((v) >= OPJ_PROFILE_IMF_2K)&&((v) <= ((OPJ_PROFILE_IMF_8K_R) | (0x009b)))) |
#define OPJ_IS_PART2 | ( | v | ) | ((v) & OPJ_PROFILE_PART2) |
Referenced by opj_j2k_setup_encoder(), and opj_set_MCT().
#define OPJ_IS_STORAGE | ( | v | ) | ((v) == OPJ_PROFILE_CINEMA_LTS) |
Referenced by opj_j2k_setup_encoder().
#define OPJ_J2K_DEFAULT_HEADER_SIZE 1000 |
Referenced by opj_j2k_create_compress(), and opj_j2k_create_decompress().
#define OPJ_J2K_DEFAULT_NB_SEGS 10 |
Referenced by opj_t2_init_seg(), and opj_tcd_code_block_dec_allocate().
#define OPJ_J2K_MAXBANDS (3*OPJ_J2K_MAXRLVLS-2) |
Number of maximum sub-band linked to number of resolution level.
Referenced by j2k_get_cstr_info(), opj_j2k_copy_tile_quantization_parameters(), and opj_j2k_read_SQcd_SQcc().
#define OPJ_J2K_MAXRLVLS 33 |
Number of maximum resolution level authorized.
Referenced by j2k_get_cstr_info(), opj_j2k_read_SPCod_SPCoc(), opj_j2k_setup_encoder(), opj_pi_create_decode(), and opj_pi_initialise_encode().
#define OPJ_J2K_MCC_DEFAULT_NB_RECORDS 10 |
Referenced by opj_j2k_read_mcc(), and opj_j2k_read_siz().
#define OPJ_J2K_MCT_DEFAULT_NB_RECORDS 10 |
Referenced by opj_j2k_read_mct(), opj_j2k_read_siz(), and opj_j2k_setup_mct_encoding().
#define OPJ_J2K_MH_IND 16 |
Codestream index based only on the main header.
Referenced by j2k_dump().
#define OPJ_J2K_MH_INFO 2 |
Codestream information based only on the main header.
Referenced by j2k_dump().
#define OPJ_J2K_STREAM_CHUNK_SIZE 0x100000 /** 1 mega by default */ |
Referenced by opj_stream_create_default_file_stream(), and opj_stream_default_create().
#define OPJ_J2K_TCH_INFO 8 |
Tile/Component information of all tiles.
Referenced by j2k_dump().
#define OPJ_J2K_TH_IND 32 |
Tile index based on the current tile.
Referenced by j2k_dump().
#define OPJ_J2K_TH_INFO 4 |
Tile information based on the current tile header.
Referenced by j2k_dump().
#define OPJ_JP2_IND 256 |
JP2 file index.
Referenced by j2k_dump().
#define OPJ_JP2_INFO 128 |
#define OPJ_LOCAL |
#define OPJ_PATH_LEN 4096 |
Maximum allowed size for filenames.
#define OPJ_PROFILE_0 0x0001 /** Profile 0 as described in 15444-1,Table A.45 */ |
#define OPJ_PROFILE_1 0x0002 /** Profile 1 as described in 15444-1,Table A.45 */ |
#define OPJ_PROFILE_BC_MULTI 0x0200 /** Multi Tile Broadcast profile defined in 15444-1 AMD3 */ |
#define OPJ_PROFILE_BC_MULTI_R 0x0300 /** Multi Tile Reversible Broadcast profile defined in 15444-1 AMD3 */ |
#define OPJ_PROFILE_BC_SINGLE 0x0100 /** Single Tile Broadcast profile defined in 15444-1 AMD3 */ |
#define OPJ_PROFILE_CINEMA_2K 0x0003 /** 2K cinema profile defined in 15444-1 AMD1 */ |
Referenced by opj_j2k_is_cinema_compliant(), opj_j2k_set_cinema_parameters(), and opj_j2k_setup_encoder().
#define OPJ_PROFILE_CINEMA_4K 0x0004 /** 4K cinema profile defined in 15444-1 AMD1 */ |
#define OPJ_PROFILE_CINEMA_LTS 0x0007 /** Long term storage cinema profile defined in 15444-1 AMD2 */ |
#define OPJ_PROFILE_CINEMA_S2K 0x0005 /** Scalable 2K cinema profile defined in 15444-1 AMD2 */ |
Referenced by opj_j2k_setup_encoder().
#define OPJ_PROFILE_CINEMA_S4K 0x0006 /** Scalable 4K cinema profile defined in 15444-1 AMD2 */ |
Referenced by opj_j2k_setup_encoder().
#define OPJ_PROFILE_IMF_2K 0x0400 /** 2K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), opj_j2k_is_imf_compliant(), and opj_j2k_set_imf_parameters().
#define OPJ_PROFILE_IMF_2K_R 0x0700 /** 2K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), and opj_j2k_is_imf_compliant().
#define OPJ_PROFILE_IMF_4K 0x0500 /** 4K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), opj_j2k_is_imf_compliant(), and opj_j2k_set_imf_parameters().
#define OPJ_PROFILE_IMF_4K_R 0x0800 /** 4K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), and opj_j2k_is_imf_compliant().
#define OPJ_PROFILE_IMF_8K 0x0600 /** 8K Single Tile Lossy IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), opj_j2k_is_imf_compliant(), and opj_j2k_set_imf_parameters().
#define OPJ_PROFILE_IMF_8K_R 0x0900 /** 8K Single/Multi Tile Reversible IMF profile defined in 15444-1 AMD 8 */ |
Referenced by opj_j2k_get_imf_max_NL(), and opj_j2k_is_imf_compliant().
#define OPJ_PROFILE_NONE 0x0000 /** no profile, conform to 15444-1 */ |
JPEG 2000 Profiles, see Table A.10 from 15444-1 (updated in various AMD) These values help choosing the RSIZ value for the J2K codestream.
The RSIZ value triggers various encoding options, as detailed in Table A.10. If OPJ_PROFILE_PART2 is chosen, it has to be combined with one or more extensions described hereunder. Example: rsiz = OPJ_PROFILE_PART2 | OPJ_EXTENSION_MCT; For broadcast profiles, the OPJ_PROFILE value has to be combined with the targeted mainlevel (3-0 LSB, value between 0 and 11): Example: rsiz = OPJ_PROFILE_BC_MULTI | 0x0005; (here mainlevel 5) For IMF profiles, the OPJ_PROFILE value has to be combined with the targeted mainlevel (3-0 LSB, value between 0 and 11) and sublevel (7-4 LSB, value between 0 and 9): Example: rsiz = OPJ_PROFILE_IMF_2K | 0x0040 | 0x0005; (here main 5 and sublevel 4)
Referenced by opj_j2k_setup_encoder(), and opj_set_default_encoder_parameters().
#define OPJ_PROFILE_PART2 0x8000 /** At least 1 extension defined in 15444-2 (Part-2) */ |
Referenced by opj_j2k_setup_encoder(), opj_j2k_setup_header_writing(), and opj_set_MCT().
#define OPJ_STREAM_READ OPJ_TRUE |
Stream open flags.
The stream was opened for reading.
#define OPJ_STREAM_WRITE OPJ_FALSE |
The stream was opened for writing.
#define OPJ_TRUE 1 |
Referenced by associate_channel(), check_JP2boxidx(), close_channel(), delete_session(), enqueue_mainheader(), enqueue_metabins(), enqueue_metadata(), enqueue_precinct(), enqueue_tile(), enqueue_tileheader(), fread_jpip(), fwrite_jp2k(), gene_cachemodel(), gene_JPIPstream(), gene_target(), get_mainheader_from_j2kstream(), handle_clientreq(), handle_dstCIDreqMSG(), handle_JPIPstreamMSG(), identify_cid(), identify_target(), init_dec_server(), init_jpipdecoder(), is_allsent(), isJPPstream(), isJPTfeasible(), j2k_to_pnm(), main(), modify_COCmkrstream(), modify_mainheader(), modify_SIZmkrstream(), modify_tileheader(), open_channel(), opj_alloc_tile_component_data(), opj_bio_bytein(), opj_bio_byteout(), opj_bio_flush(), opj_bio_inalign(), opj_check_EPHuse(), opj_create_decompress(), opj_dwt_decode_partial_97(), opj_dwt_decode_partial_tile(), opj_dwt_decode_tile(), opj_dwt_decode_tile_97(), opj_dwt_encode_h_func(), opj_dwt_encode_procedure(), opj_dwt_init_sparse_array(), opj_dwt_interleave_partial_h(), opj_dwt_interleave_partial_v(), opj_event_msg(), opj_j2k_add_mct(), opj_j2k_add_mhmarker(), opj_j2k_add_tlmarker(), opj_j2k_allocate_tile_element_cstr_index(), opj_j2k_are_all_used_components_decoded(), opj_j2k_build_decoder(), opj_j2k_build_encoder(), opj_j2k_calculate_tp(), opj_j2k_compare_SPCod_SPCoc(), opj_j2k_compare_SQcd_SQcc(), opj_j2k_copy_default_tcp_and_create_tcd(), opj_j2k_create_tcd(), opj_j2k_decode_one_tile(), opj_j2k_decode_tile(), opj_j2k_decode_tiles(), opj_j2k_decoding_validation(), opj_j2k_destroy_header_memory(), opj_j2k_encode(), opj_j2k_encoder_set_extra_options(), opj_j2k_encoding_validation(), opj_j2k_end_compress(), opj_j2k_end_decompress(), opj_j2k_end_encoding(), opj_j2k_exec(), opj_j2k_get_end_header(), opj_j2k_get_sot_values(), opj_j2k_is_cinema_compliant(), opj_j2k_is_imf_compliant(), opj_j2k_mct_validation(), opj_j2k_merge_ppm(), opj_j2k_merge_ppt(), opj_j2k_move_data_from_codec_to_output_image(), opj_j2k_need_nb_tile_parts_correction(), opj_j2k_post_write_tile(), opj_j2k_pre_write_tile(), opj_j2k_read_cbd(), opj_j2k_read_coc(), opj_j2k_read_cod(), opj_j2k_read_com(), opj_j2k_read_crg(), opj_j2k_read_header(), opj_j2k_read_header_procedure(), opj_j2k_read_mcc(), opj_j2k_read_mco(), opj_j2k_read_mct(), opj_j2k_read_plm(), opj_j2k_read_plt(), opj_j2k_read_poc(), opj_j2k_read_ppm(), opj_j2k_read_ppt(), opj_j2k_read_qcc(), opj_j2k_read_qcd(), opj_j2k_read_rgn(), opj_j2k_read_siz(), opj_j2k_read_soc(), opj_j2k_read_sod(), opj_j2k_read_sot(), opj_j2k_read_SPCod_SPCoc(), opj_j2k_read_SQcd_SQcc(), opj_j2k_read_tile_header(), opj_j2k_read_tlm(), opj_j2k_read_unk(), opj_j2k_set_decoded_components(), opj_j2k_set_decoded_resolution_factor(), opj_j2k_set_threads(), opj_j2k_setup_decoding(), opj_j2k_setup_decoding_tile(), opj_j2k_setup_decoding_validation(), opj_j2k_setup_encoder(), opj_j2k_setup_encoding_validation(), opj_j2k_setup_end_compress(), opj_j2k_setup_header_reading(), opj_j2k_setup_header_writing(), opj_j2k_setup_mct_encoding(), opj_j2k_start_compress(), opj_j2k_update_image_data(), opj_j2k_update_image_dimensions(), opj_j2k_update_rates(), opj_j2k_write_all_coc(), opj_j2k_write_all_qcc(), opj_j2k_write_all_tile_parts(), opj_j2k_write_cbd(), opj_j2k_write_coc(), opj_j2k_write_cod(), opj_j2k_write_com(), opj_j2k_write_eoc(), opj_j2k_write_epc(), opj_j2k_write_first_tile_part(), opj_j2k_write_mcc_record(), opj_j2k_write_mco(), opj_j2k_write_mct_data_group(), opj_j2k_write_mct_record(), opj_j2k_write_plt_in_memory(), opj_j2k_write_poc(), opj_j2k_write_qcc(), opj_j2k_write_qcd(), opj_j2k_write_regions(), opj_j2k_write_rgn(), opj_j2k_write_siz(), opj_j2k_write_soc(), opj_j2k_write_sod(), opj_j2k_write_sot(), opj_j2k_write_SPCod_SPCoc(), opj_j2k_write_SQcd_SQcc(), opj_j2k_write_tile(), opj_j2k_write_tlm(), opj_j2k_write_updated_tlm(), opj_jp2_apply_pclr(), opj_jp2_check_color(), opj_jp2_decode(), opj_jp2_default_validation(), opj_jp2_encoder_set_extra_options(), opj_jp2_exec(), opj_jp2_get_tile(), opj_jp2_read_boxhdr(), opj_jp2_read_boxhdr_char(), opj_jp2_read_bpcc(), opj_jp2_read_cdef(), opj_jp2_read_cmap(), opj_jp2_read_colr(), opj_jp2_read_ftyp(), opj_jp2_read_header_procedure(), opj_jp2_read_ihdr(), opj_jp2_read_jp(), opj_jp2_read_jp2h(), opj_jp2_read_pclr(), opj_jp2_setup_decoding_validation(), opj_jp2_setup_encoder(), opj_jp2_setup_encoding_validation(), opj_jp2_setup_end_header_reading(), opj_jp2_setup_end_header_writing(), opj_jp2_setup_header_reading(), opj_jp2_setup_header_writing(), opj_jp2_skip_jp2c(), opj_jp2_write_jp(), opj_jp2_write_jp2c(), opj_jp2_write_jp2h(), opj_jpip_skip_iptr(), opj_lupDecompose(), opj_matrix_inversion_f(), opj_mct_decode_custom(), opj_mct_encode_custom(), opj_pi_check_next_level(), opj_pi_next_cprl(), opj_pi_next_lrcp(), opj_pi_next_pcrl(), opj_pi_next_rlcp(), opj_pi_next_rpcl(), opj_procedure_list_add_procedure(), opj_seek_from_file(), opj_set_error_handler(), opj_set_info_handler(), opj_set_MCT(), opj_set_warning_handler(), opj_setup_decoder(), opj_sparse_array_int32_read(), opj_sparse_array_int32_read_or_write(), opj_stream_flush(), opj_stream_read_seek(), opj_stream_write_seek(), opj_t1_allocate_buffers(), opj_t1_cblk_encode_processor(), opj_t1_dec_clnpass_64x64_vsc(), opj_t1_dec_clnpass_generic_vsc(), opj_t1_dec_clnpass_step(), opj_t1_dec_sigpass_mqc_64x64_vsc(), opj_t1_dec_sigpass_mqc_generic_vsc(), opj_t1_decode_cblk(), opj_t1_enc_is_term_pass(), opj_t1_encode_cblks(), opj_t2_decode_packet(), opj_t2_decode_packets(), opj_t2_encode_packet(), opj_t2_encode_packets(), opj_t2_init_seg(), opj_t2_read_packet_data(), opj_t2_read_packet_header(), opj_t2_skip_packet(), opj_t2_skip_packet_data(), opj_tcd_code_block_dec_allocate(), opj_tcd_code_block_enc_allocate(), opj_tcd_code_block_enc_allocate_data(), opj_tcd_copy_tile_data(), opj_tcd_dc_level_shift_decode(), opj_tcd_dc_level_shift_encode(), opj_tcd_decode_tile(), opj_tcd_dwt_decode(), opj_tcd_dwt_encode(), opj_tcd_encode_tile(), opj_tcd_init(), opj_tcd_init_encode_tile(), opj_tcd_init_tile(), opj_tcd_mct_decode(), opj_tcd_mct_encode(), opj_tcd_rate_allocate_encode(), opj_tcd_rateallocate(), opj_tcd_t1_decode(), opj_tcd_t1_encode(), opj_tcd_t2_decode(), opj_tcd_t2_encode(), opj_tcd_update_tile_data(), opj_thread_pool_get_next_job(), opj_thread_pool_setup(), opj_thread_pool_submit_job(), opj_tls_set(), opj_v8dwt_interleave_partial_h(), opj_v8dwt_interleave_partial_v(), opj_worker_thread_function(), parse_comps(), parse_JPIPstream(), parse_metareq(), parse_req_box_prop(), recons_codestream_from_JPPstream(), recons_codestream_from_JPTstream(), recons_packet(), recons_precinct(), recv_ack(), search_session_and_channel(), set_cidxdata(), set_CODmkrdata(), set_cptrdata(), set_mainmhixdata(), set_ppixdata(), set_SIZmkrdata(), set_thixdata(), and set_tpixdata().
#define OPJ_UINT32_SEMANTICALLY_BUT_INT32 OPJ_INT32 |
typedef int OPJ_BOOL |
typedef unsigned char OPJ_BYTE |
typedef char OPJ_CHAR |
typedef enum CINEMA_MODE OPJ_CINEMA_MODE |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Digital cinema operation mode.
typedef enum CODEC_FORMAT OPJ_CODEC_FORMAT |
Supported codec.
typedef void* opj_codec_t |
JPEG2000 codec V2.
typedef struct opj_codestream_index opj_codestream_index_t |
Index structure of the codestream (FIXME should be expand and enhance)
typedef struct opj_codestream_info opj_codestream_info_t |
Index structure of the codestream.
typedef struct opj_codestream_info_v2 opj_codestream_info_v2_t |
Information structure about the codestream (FIXME should be expand and enhance)
typedef enum COLOR_SPACE OPJ_COLOR_SPACE |
Supported image color spaces.
typedef struct opj_cparameters opj_cparameters_t |
Compression parameters.
typedef struct opj_dparameters opj_dparameters_t |
Decompression parameters.
typedef float OPJ_FLOAT32 |
typedef double OPJ_FLOAT64 |
typedef struct opj_image_comptparm opj_image_cmptparm_t |
Component parameters structure used by the opj_image_create function.
typedef struct opj_image_comp opj_image_comp_t |
Defines a single image component.
typedef struct opj_image opj_image_t |
Defines image data and characteristics.
typedef int16_t OPJ_INT16 |
typedef int32_t OPJ_INT32 |
typedef int64_t OPJ_INT64 |
typedef int8_t OPJ_INT8 |
typedef struct opj_jp2_index opj_jp2_index_t |
Index structure of the JP2 file EXPERIMENTAL FOR THE MOMENT.
typedef struct opj_jp2_metadata opj_jp2_metadata_t |
Info structure of the JP2 file EXPERIMENTAL FOR THE MOMENT.
typedef struct opj_marker_info opj_marker_info_t |
Marker structure.
typedef void(* opj_msg_callback) (const char *msg, void *client_data) |
Callback function prototype for events.
msg | Event message |
client_data | Client object where will be return the event message |
typedef int64_t OPJ_OFF_T |
typedef struct opj_packet_info opj_packet_info_t |
Index structure : Information concerning a packet inside tile.
typedef enum PROG_ORDER OPJ_PROG_ORDER |
Progression order.
typedef enum RSIZ_CAPABILITIES OPJ_RSIZ_CAPABILITIES |
DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead Rsiz Capabilities.
typedef size_t OPJ_SIZE_T |
typedef void(* opj_stream_free_user_data_fn) (void *p_user_data) |
typedef OPJ_SIZE_T(* opj_stream_read_fn) (void *p_buffer, OPJ_SIZE_T p_nb_bytes, void *p_user_data) |
typedef void* opj_stream_t |
typedef OPJ_SIZE_T(* opj_stream_write_fn) (void *p_buffer, OPJ_SIZE_T p_nb_bytes, void *p_user_data) |
typedef struct opj_tccp_info opj_tccp_info_t |
Tile-component coding parameters information.
typedef struct opj_tile_index opj_tile_index_t |
Index structure about a tile.
typedef struct opj_tile_info opj_tile_info_t |
Index structure : information regarding tiles.
typedef struct opj_tile_v2_info opj_tile_info_v2_t |
Tile coding parameters information.
typedef struct opj_tp_index opj_tp_index_t |
Index structure about a tile part.
typedef struct opj_tp_info opj_tp_info_t |
Index structure : Information concerning tile-parts.
typedef uint16_t OPJ_UINT16 |
typedef uint32_t OPJ_UINT32 |
typedef uint64_t OPJ_UINT64 |
typedef uint8_t OPJ_UINT8 |
enum CINEMA_MODE |
enum CODEC_FORMAT |
Supported codec.
enum COLOR_SPACE |
enum PROG_ORDER |
Progression order.
enum RSIZ_CAPABILITIES |
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_codec_set_threads | ( | opj_codec_t * | p_codec, |
int | num_threads | ||
) |
Allocates worker threads for the compressor/decompressor.
By default, only the main thread is used. If this function is not used, but the OPJ_NUM_THREADS environment variable is set, its value will be used to initialize the number of threads. The value can be either an integer number, or "ALL_CPUS". If OPJ_NUM_THREADS is set and this function is called, this function will override the behaviour of the environment variable.
This function must be called after opj_setup_decoder() and before opj_read_header() for the decoding side, or after opj_setup_encoder() and before opj_start_compress() for the encoding side.
p_codec | decompressor or compressor handler |
num_threads | number of threads. |
References opj_codec_private::m_codec, OPJ_FALSE, and opj_codec_private::opj_set_threads.
OPJ_API opj_codec_t* OPJ_CALLCONV opj_create_compress | ( | OPJ_CODEC_FORMAT | format | ) |
Creates a J2K/JP2 compression structure.
format | Coder to select |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, opj_calloc(), OPJ_CODEC_J2K, OPJ_CODEC_JP2, OPJ_CODEC_JPT, OPJ_CODEC_UNKNOWN, OPJ_FALSE, opj_free(), opj_j2k_create_compress(), opj_j2k_destroy(), opj_j2k_encode(), opj_j2k_encoder_set_extra_options(), opj_j2k_end_compress(), opj_j2k_set_threads(), opj_j2k_setup_encoder(), opj_j2k_start_compress(), opj_j2k_write_tile(), opj_jp2_create(), opj_jp2_destroy(), opj_jp2_encode(), opj_jp2_encoder_set_extra_options(), opj_jp2_end_compress(), opj_jp2_set_threads(), opj_jp2_setup_encoder(), opj_jp2_start_compress(), opj_jp2_write_tile(), opj_set_default_event_handler(), and opj_codec_private::opj_set_threads.
OPJ_API opj_codec_t* OPJ_CALLCONV opj_create_decompress | ( | OPJ_CODEC_FORMAT | format | ) |
Creates a J2K/JP2 decompression structure.
format | Decoder to select |
References opj_codec_private::is_decompressor, j2k_dump(), j2k_get_cstr_index(), j2k_get_cstr_info(), jp2_dump(), jp2_get_cstr_index(), jp2_get_cstr_info(), opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, opj_calloc(), OPJ_CODEC_J2K, OPJ_CODEC_JP2, OPJ_CODEC_JPT, OPJ_CODEC_UNKNOWN, opj_codec_private::opj_dump_codec, opj_free(), opj_codec_private::opj_get_codec_index, opj_codec_private::opj_get_codec_info, opj_j2k_create_decompress(), opj_j2k_decode(), opj_j2k_decode_tile(), opj_j2k_destroy(), opj_j2k_end_decompress(), opj_j2k_get_tile(), opj_j2k_read_header(), opj_j2k_read_tile_header(), opj_j2k_set_decode_area(), opj_j2k_set_decoded_components(), opj_j2k_set_decoded_resolution_factor(), opj_j2k_set_threads(), opj_j2k_setup_decoder(), opj_jp2_create(), opj_jp2_decode(), opj_jp2_decode_tile(), opj_jp2_destroy(), opj_jp2_end_decompress(), opj_jp2_get_tile(), opj_jp2_read_header(), opj_jp2_read_tile_header(), opj_jp2_set_decode_area(), opj_jp2_set_decoded_components(), opj_jp2_set_decoded_resolution_factor(), opj_jp2_set_threads(), opj_jp2_setup_decoder(), opj_set_default_event_handler(), opj_codec_private::opj_set_threads, and OPJ_TRUE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_decode | ( | opj_codec_t * | p_decompressor, |
opj_stream_t * | p_stream, | ||
opj_image_t * | p_image | ||
) |
Decode an image from a JPEG-2000 codestream.
p_decompressor | decompressor handle |
p_stream | Input buffer stream |
p_image | the decoded image |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_decode_tile_data | ( | opj_codec_t * | p_codec, |
OPJ_UINT32 | p_tile_index, | ||
OPJ_BYTE * | p_data, | ||
OPJ_UINT32 | p_data_size, | ||
opj_stream_t * | p_stream | ||
) |
Reads a tile data.
This function is compulsory and allows one to decode tile data. opj_read_tile_header should be called before. The user may need to refer to the image got by opj_read_header to understand the size being taken by the tile.
Note: opj_decode_tile_data() should not be used together with opj_set_decoded_components().
p_codec | the jpeg2000 codec. |
p_tile_index | the index of the tile being decoded, this should be the value set by opj_read_tile_header. |
p_data | pointer to a memory block that will hold the decoded data. |
p_data_size | size of p_data. p_data_size should be bigger or equal to the value set by opj_read_tile_header. |
p_stream | the stream to decode. |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API void OPJ_CALLCONV opj_destroy_codec | ( | opj_codec_t * | p_codec | ) |
Destroy a decompressor handle.
p_codec | decompressor handle to destroy |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_decompression, and opj_free().
Referenced by j2k_to_pnm().
OPJ_API void OPJ_CALLCONV opj_destroy_cstr_index | ( | opj_codestream_index_t ** | p_cstr_index | ) |
References j2k_destroy_cstr_index().
OPJ_API void OPJ_CALLCONV opj_destroy_cstr_info | ( | opj_codestream_info_v2_t ** | cstr_info | ) |
Destroy Codestream information after compression or decompression.
cstr_info | Codestream information structure |
References opj_free().
Referenced by j2k_get_cstr_info().
OPJ_API void OPJ_CALLCONV opj_dump_codec | ( | opj_codec_t * | p_codec, |
OPJ_INT32 | info_flag, | ||
FILE * | output_stream | ||
) |
Dump the codec information into the output stream.
p_codec | the jpeg2000 codec. |
info_flag | type of information dump. |
output_stream | output stream where dump the information gotten from the codec. |
References opj_codec_private::m_codec, and opj_codec_private::opj_dump_codec.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_encode | ( | opj_codec_t * | p_codec, |
opj_stream_t * | p_stream | ||
) |
Encode an image into a JPEG-2000 codestream.
p_codec | compressor handle |
p_stream | Output buffer stream |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_encoder_set_extra_options | ( | opj_codec_t * | p_codec, |
const char *const * | p_options | ||
) |
Specify extra options for the encoder.
This may be called after opj_setup_encoder() and before opj_start_compress()
This is the way to add new options in a fully ABI compatible way, without extending the opj_cparameters_t structure.
Currently supported options are:
p_codec | Compressor handle |
p_options | Compression options. This should be a NULL terminated array of strings. Each string is of the form KEY=VALUE. |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_compress | ( | opj_codec_t * | p_codec, |
opj_stream_t * | p_stream | ||
) |
End to compress the current image.
p_codec | Compressor handle |
p_stream | Input stgream |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_decompress | ( | opj_codec_t * | p_codec, |
opj_stream_t * | p_stream | ||
) |
Read after the codestream if necessary.
p_codec | the JPEG2000 codec to read. |
p_stream | the JPEG2000 stream. |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
Referenced by j2k_to_pnm().
OPJ_API opj_codestream_index_t* OPJ_CALLCONV opj_get_cstr_index | ( | opj_codec_t * | p_codec | ) |
Get the codestream index from the codec.
p_codec | the jpeg2000 codec. |
References opj_codec_private::m_codec, and opj_codec_private::opj_get_codec_index.
OPJ_API opj_codestream_info_v2_t* OPJ_CALLCONV opj_get_cstr_info | ( | opj_codec_t * | p_codec | ) |
Get the codestream information from the codec.
p_codec | the jpeg2000 codec. |
References opj_codec_private::m_codec, and opj_codec_private::opj_get_codec_info.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_get_decoded_tile | ( | opj_codec_t * | p_codec, |
opj_stream_t * | p_stream, | ||
opj_image_t * | p_image, | ||
OPJ_UINT32 | tile_index | ||
) |
Get the decoded tile from the codec.
p_codec | the jpeg2000 codec. |
p_stream | input streamm |
p_image | output image |
tile_index | index of the tile which will be decode |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API opj_jp2_index_t* OPJ_CALLCONV opj_get_jp2_index | ( | opj_codec_t * | p_codec | ) |
Get the JP2 file index from the codec FIXME.
p_codec | the jpeg2000 codec. |
OPJ_API opj_jp2_metadata_t* OPJ_CALLCONV opj_get_jp2_metadata | ( | opj_codec_t * | p_codec | ) |
Get the JP2 file information from the codec FIXME.
p_codec | the jpeg2000 codec. |
OPJ_API int OPJ_CALLCONV opj_get_num_cpus | ( | void | ) |
Return the number of virtual CPUs.
Referenced by opj_j2k_get_default_thread_count().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_has_thread_support | ( | void | ) |
Returns if the library is built with thread support.
OPJ_TRUE if mutex, condition, thread, thread pool are available.
References OPJ_FALSE.
Referenced by opj_j2k_get_default_thread_count(), and opj_j2k_set_threads().
OPJ_API opj_image_t* OPJ_CALLCONV opj_image_create | ( | OPJ_UINT32 | numcmpts, |
opj_image_cmptparm_t * | cmptparms, | ||
OPJ_COLOR_SPACE | clrspc | ||
) |
Create an image.
numcmpts | number of components |
cmptparms | components parameters |
clrspc | image color space |
References opj_image_comp::bpp, opj_image_comptparm::bpp, opj_image::color_space, opj_image::comps, opj_image_comp::data, opj_image_comp::dx, opj_image_comptparm::dx, opj_image_comp::dy, opj_image_comptparm::dy, opj_image_comp::h, opj_image_comptparm::h, opj_image::numcomps, opj_calloc(), opj_image_data_alloc(), opj_image_destroy(), opj_image_comp::prec, opj_image_comptparm::prec, opj_image_comp::sgnd, opj_image_comptparm::sgnd, SIZE_MAX, opj_image_comp::w, opj_image_comptparm::w, opj_image_comp::x0, opj_image_comptparm::x0, opj_image_comp::y0, and opj_image_comptparm::y0.
OPJ_API void* OPJ_CALLCONV opj_image_data_alloc | ( | OPJ_SIZE_T | size | ) |
Allocator for opj_image_t->comps[].data To be paired with opj_image_data_free.
size | number of bytes to allocate |
References opj_aligned_malloc().
Referenced by opj_alloc_tile_component_data(), opj_image_create(), opj_j2k_update_image_data(), opj_jp2_apply_pclr(), and opj_tcd_decode_tile().
OPJ_API void OPJ_CALLCONV opj_image_data_free | ( | void * | ptr | ) |
Destructor for opj_image_t->comps[].data To be paired with opj_image_data_alloc.
ptr | Pointer to free |
References opj_aligned_free().
Referenced by opj_alloc_tile_component_data(), opj_copy_image_header(), opj_image_destroy(), opj_j2k_decode_tiles(), opj_j2k_get_tile(), opj_j2k_move_data_from_codec_to_output_image(), opj_jp2_apply_pclr(), opj_tcd_decode_tile(), opj_tcd_free_tile(), and opj_tcd_init_tile().
OPJ_API void OPJ_CALLCONV opj_image_destroy | ( | opj_image_t * | image | ) |
Deallocate any resources associated with an image.
image | image to be destroyed |
References opj_image::comps, opj_image_comp::data, opj_image::icc_profile_buf, opj_image::numcomps, opj_free(), and opj_image_data_free().
Referenced by j2k_to_pnm(), opj_image_create(), opj_image_tile_create(), opj_j2k_decode(), opj_j2k_destroy(), opj_j2k_get_tile(), opj_j2k_move_data_from_codec_to_output_image(), and opj_j2k_read_header().
OPJ_API opj_image_t* OPJ_CALLCONV opj_image_tile_create | ( | OPJ_UINT32 | numcmpts, |
opj_image_cmptparm_t * | cmptparms, | ||
OPJ_COLOR_SPACE | clrspc | ||
) |
Creates an image without allocating memory for the image (used in the new version of the library).
numcmpts | the number of components |
cmptparms | the components parameters |
clrspc | the image color space |
References opj_image::color_space, opj_image::comps, opj_image_comp::data, opj_image_comp::dx, opj_image_comptparm::dx, opj_image_comp::dy, opj_image_comptparm::dy, opj_image_comp::h, opj_image_comptparm::h, opj_image::numcomps, opj_calloc(), opj_image_destroy(), opj_image_comp::prec, opj_image_comptparm::prec, opj_image_comp::sgnd, opj_image_comptparm::sgnd, opj_image_comp::w, opj_image_comptparm::w, opj_image_comp::x0, opj_image_comptparm::x0, opj_image_comp::y0, and opj_image_comptparm::y0.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_read_header | ( | opj_stream_t * | p_stream, |
opj_codec_t * | p_codec, | ||
opj_image_t ** | p_image | ||
) |
Decodes an image header.
p_stream | the jpeg2000 stream. |
p_codec | the jpeg2000 codec to read. |
p_image | the image structure initialized with the characteristics of encoded image. |
References EVT_ERROR, opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, opj_event_msg(), and OPJ_FALSE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_read_tile_header | ( | opj_codec_t * | p_codec, |
opj_stream_t * | p_stream, | ||
OPJ_UINT32 * | p_tile_index, | ||
OPJ_UINT32 * | p_data_size, | ||
OPJ_INT32 * | p_tile_x0, | ||
OPJ_INT32 * | p_tile_y0, | ||
OPJ_INT32 * | p_tile_x1, | ||
OPJ_INT32 * | p_tile_y1, | ||
OPJ_UINT32 * | p_nb_comps, | ||
OPJ_BOOL * | p_should_go_on | ||
) |
Reads a tile header.
This function is compulsory and allows one to know the size of the tile that will be decoded. The user may need to refer to the image got by opj_read_header to understand the size being taken by the tile.
p_codec | the jpeg2000 codec. |
p_tile_index | pointer to a value that will hold the index of the tile being decoded, in case of success. |
p_data_size | pointer to a value that will hold the maximum size of the decoded data, in case of success. In case of truncated codestreams, the actual number of bytes decoded may be lower. The computation of the size is the same as depicted in opj_write_tile. |
p_tile_x0 | pointer to a value that will hold the x0 pos of the tile (in the image). |
p_tile_y0 | pointer to a value that will hold the y0 pos of the tile (in the image). |
p_tile_x1 | pointer to a value that will hold the x1 pos of the tile (in the image). |
p_tile_y1 | pointer to a value that will hold the y1 pos of the tile (in the image). |
p_nb_comps | pointer to a value that will hold the number of components in the tile. |
p_should_go_on | pointer to a boolean that will hold the fact that the decoding should go on. In case the codestream is over at the time of the call, the value will be set to false. The user should then stop the decoding. |
p_stream | the stream to decode. |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decode_area | ( | opj_codec_t * | p_codec, |
opj_image_t * | p_image, | ||
OPJ_INT32 | p_start_x, | ||
OPJ_INT32 | p_start_y, | ||
OPJ_INT32 | p_end_x, | ||
OPJ_INT32 | p_end_y | ||
) |
Sets the given area to be decoded.
This function should be called right after opj_read_header and before any tile header reading.
The coordinates passed to this function should be expressed in the reference grid, that is to say at the highest resolution level, even if requesting the image at lower resolution levels.
Generally opj_set_decode_area() should be followed by opj_decode(), and the codec cannot be re-used. In the particular case of an image made of a single tile, several sequences of calls to opoj_set_decode_area() and opj_decode() are allowed, and will bring performance improvements when reading an image by chunks.
p_codec | the jpeg2000 codec. |
p_image | the decoded image previously set by opj_read_header |
p_start_x | the left position of the rectangle to decode (in image coordinates). |
p_end_x | the right position of the rectangle to decode (in image coordinates). |
p_start_y | the up position of the rectangle to decode (in image coordinates). |
p_end_y | the bottom position of the rectangle to decode (in image coordinates). |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decoded_components | ( | opj_codec_t * | p_codec, |
OPJ_UINT32 | numcomps, | ||
const OPJ_UINT32 * | comps_indices, | ||
OPJ_BOOL | apply_color_transforms | ||
) |
Restrict the number of components to decode.
This function should be called after opj_read_header().
This function enables to restrict the set of decoded components to the specified indices. Note that the current implementation (apply_color_transforms == OPJ_FALSE) is such that neither the multi-component transform at codestream level, nor JP2 channel transformations will be applied. Consequently the indices are relative to the codestream.
Note: opj_decode_tile_data() should not be used together with opj_set_decoded_components().
p_codec | the jpeg2000 codec to read. |
numcomps | Size of the comps_indices array. |
comps_indices | Array of numcomps values representing the indices of the components to decode (relative to the codestream, starting at 0) |
apply_color_transforms | Whether multi-component transform at codestream level or JP2 channel transformations should be applied. Currently this parameter should be set to OPJ_FALSE. Setting it to OPJ_TRUE will result in an error. |
References EVT_ERROR, opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, opj_event_msg(), and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decoded_resolution_factor | ( | opj_codec_t * | p_codec, |
OPJ_UINT32 | res_factor | ||
) |
Set the resolution factor of the decoded image.
p_codec | the jpeg2000 codec. |
res_factor | resolution factor to set |
References opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API void OPJ_CALLCONV opj_set_default_decoder_parameters | ( | opj_dparameters_t * | parameters | ) |
Set decoding parameters to default values.
parameters | Decompression parameters |
References opj_dparameters::cod_format, opj_dparameters::cp_layer, opj_dparameters::cp_reduce, opj_dparameters::decod_format, opj_dparameters::flags, opj_dparameters::jpwl_correct, opj_dparameters::jpwl_exp_comps, JPWL_EXPECTED_COMPONENTS, opj_dparameters::jpwl_max_tiles, JPWL_MAXIMUM_TILES, and OPJ_FALSE.
Referenced by j2k_to_pnm().
OPJ_API void OPJ_CALLCONV opj_set_default_encoder_parameters | ( | opj_cparameters_t * | parameters | ) |
Set encoding parameters to default values, that means :
parameters | Compression parameters |
References opj_cparameters::cblockh_init, opj_cparameters::cblockw_init, opj_cparameters::cod_format, opj_cparameters::cp_cinema, opj_cparameters::cp_disto_alloc, opj_cparameters::cp_fixed_alloc, opj_cparameters::cp_fixed_quality, opj_cparameters::cp_rsiz, opj_cparameters::decod_format, opj_cparameters::jpip_on, opj_cparameters::jpwl_epc_on, opj_cparameters::jpwl_hprot_MH, opj_cparameters::jpwl_hprot_TPH, opj_cparameters::jpwl_hprot_TPH_tileno, JPWL_MAX_NO_PACKSPECS, JPWL_MAX_NO_TILESPECS, opj_cparameters::jpwl_pprot, opj_cparameters::jpwl_pprot_packno, opj_cparameters::jpwl_pprot_tileno, opj_cparameters::jpwl_sens_addr, opj_cparameters::jpwl_sens_MH, opj_cparameters::jpwl_sens_range, opj_cparameters::jpwl_sens_size, opj_cparameters::jpwl_sens_TPH, opj_cparameters::jpwl_sens_TPH_tileno, opj_cparameters::max_comp_size, opj_cparameters::numresolution, OPJ_COMP_PARAM_DEFAULT_CBLOCKH, OPJ_COMP_PARAM_DEFAULT_CBLOCKW, OPJ_COMP_PARAM_DEFAULT_NUMRESOLUTION, OPJ_COMP_PARAM_DEFAULT_PROG_ORDER, OPJ_FALSE, OPJ_OFF, OPJ_PROFILE_NONE, OPJ_STD_RSIZ, opj_cparameters::prog_order, opj_cparameters::roi_compno, opj_cparameters::rsiz, opj_cparameters::subsampling_dx, opj_cparameters::subsampling_dy, opj_cparameters::tcp_numlayers, opj_cparameters::tcp_rates, and opj_cparameters::tp_on.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_error_handler | ( | opj_codec_t * | p_codec, |
opj_msg_callback | p_callback, | ||
void * | p_user_data | ||
) |
Set the error handler use by openjpeg.
p_codec | the codec previously initialise |
p_callback | the callback function which will be used |
p_user_data | client object where will be returned the message |
References opj_event_mgr::error_handler, opj_event_mgr::m_error_data, opj_codec_private::m_event_mgr, OPJ_FALSE, and OPJ_TRUE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_info_handler | ( | opj_codec_t * | p_codec, |
opj_msg_callback | p_callback, | ||
void * | p_user_data | ||
) |
Set the info handler use by openjpeg.
p_codec | the codec previously initialise |
p_callback | the callback function which will be used |
p_user_data | client object where will be returned the message |
References opj_event_mgr::info_handler, opj_codec_private::m_event_mgr, opj_event_mgr::m_info_data, OPJ_FALSE, and OPJ_TRUE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_MCT | ( | opj_cparameters_t * | parameters, |
OPJ_FLOAT32 * | pEncodingMatrix, | ||
OPJ_INT32 * | p_dc_shift, | ||
OPJ_UINT32 | pNbComp | ||
) |
Sets the MCT matrix to use.
parameters | the parameters to change. |
pEncodingMatrix | the encoding matrix. |
p_dc_shift | the dc shift coefficients to use. |
pNbComp | the number of components of the image. |
References opj_cparameters::irreversible, opj_cparameters::mct_data, OPJ_EXTENSION_MCT, OPJ_FALSE, OPJ_IS_PART2, opj_malloc(), OPJ_PROFILE_PART2, OPJ_TRUE, opj_cparameters::rsiz, and opj_cparameters::tcp_mct.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_warning_handler | ( | opj_codec_t * | p_codec, |
opj_msg_callback | p_callback, | ||
void * | p_user_data | ||
) |
Set the warning handler use by openjpeg.
p_codec | the codec previously initialise |
p_callback | the callback function which will be used |
p_user_data | client object where will be returned the message |
References opj_codec_private::m_event_mgr, opj_event_mgr::m_warning_data, OPJ_FALSE, OPJ_TRUE, and opj_event_mgr::warning_handler.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_decoder | ( | opj_codec_t * | p_codec, |
opj_dparameters_t * | parameters | ||
) |
Setup the decoder with decompression parameters provided by the user and with the message handler provided by the user.
p_codec | decompressor handler |
parameters | decompression parameters |
References EVT_ERROR, opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_decompression, opj_codec_private::m_event_mgr, opj_event_msg(), OPJ_FALSE, and OPJ_TRUE.
Referenced by j2k_to_pnm().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_encoder | ( | opj_codec_t * | p_codec, |
opj_cparameters_t * | parameters, | ||
opj_image_t * | image | ||
) |
Setup the encoder parameters using the current image and using user parameters.
p_codec | Compressor handle |
parameters | Compression parameters |
image | Input filled image |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_start_compress | ( | opj_codec_t * | p_codec, |
opj_image_t * | p_image, | ||
opj_stream_t * | p_stream | ||
) |
Start to compress the current image.
p_codec | Compressor handle |
p_image | Input filled image |
p_stream | Input stgream |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.
OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create | ( | OPJ_SIZE_T | p_buffer_size, |
OPJ_BOOL | p_is_input | ||
) |
Creates an abstract stream.
This function does nothing except allocating memory and initializing the abstract stream.
p_buffer_size | FIXME DOC |
p_is_input | if set to true then the stream will be an input stream, an output stream else. |
References opj_stream_private::m_buffer_size, opj_stream_private::m_current_data, opj_stream_private::m_opj_seek, opj_stream_private::m_opj_skip, opj_stream_private::m_read_fn, opj_stream_private::m_seek_fn, opj_stream_private::m_skip_fn, opj_stream_private::m_status, opj_stream_private::m_stored_data, opj_stream_private::m_write_fn, opj_calloc(), opj_free(), opj_malloc(), opj_stream_default_read(), opj_stream_default_seek(), opj_stream_default_skip(), opj_stream_default_write(), opj_stream_read_seek(), opj_stream_read_skip(), OPJ_STREAM_STATUS_INPUT, OPJ_STREAM_STATUS_OUTPUT, opj_stream_write_seek(), and opj_stream_write_skip().
Referenced by opj_stream_create_file_stream(), and opj_stream_default_create().
OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream | ( | const char * | fname, |
OPJ_BOOL | p_is_read_stream | ||
) |
Create a stream from a file identified with its filename with default parameters (helper function)
fname | the filename of the file to stream |
p_is_read_stream | whether the stream is a read stream (true) or not (false) |
References OPJ_J2K_STREAM_CHUNK_SIZE, and opj_stream_create_file_stream().
Referenced by j2k_to_pnm().
OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream | ( | const char * | fname, |
OPJ_SIZE_T | p_buffer_size, | ||
OPJ_BOOL | p_is_read_stream | ||
) |
Create a stream from a file identified with its filename with a specific buffer size.
fname | the filename of the file to stream |
p_buffer_size | size of the chunk used to stream |
p_is_read_stream | whether the stream is a read stream (true) or not (false) |
References opj_get_data_length_from_file(), opj_read_from_file(), opj_seek_from_file(), opj_skip_from_file(), opj_stream_create(), opj_stream_set_read_function(), opj_stream_set_seek_function(), opj_stream_set_skip_function(), opj_stream_set_user_data(), opj_stream_set_user_data_length(), opj_stream_set_write_function(), and opj_write_from_file().
Referenced by opj_stream_create_default_file_stream().
OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_default_create | ( | OPJ_BOOL | p_is_input | ) |
Creates an abstract stream.
This function does nothing except allocating memory and initializing the abstract stream.
p_is_input | if set to true then the stream will be an input stream, an output stream else. |
References OPJ_J2K_STREAM_CHUNK_SIZE, and opj_stream_create().
OPJ_API void OPJ_CALLCONV opj_stream_destroy | ( | opj_stream_t * | p_stream | ) |
Destroys a stream created by opj_create_stream.
This function does NOT close the abstract stream. If needed the user must close its own implementation of the stream.
p_stream | the stream to destroy. |
References opj_stream_private::m_free_user_data_fn, opj_stream_private::m_stored_data, opj_stream_private::m_user_data, and opj_free().
Referenced by j2k_to_pnm().
OPJ_API void OPJ_CALLCONV opj_stream_set_read_function | ( | opj_stream_t * | p_stream, |
opj_stream_read_fn | p_function | ||
) |
Sets the given function to be used as a read function.
p_stream | the stream to modify |
p_function | the function to use a read function. |
References opj_stream_private::m_read_fn, opj_stream_private::m_status, and OPJ_STREAM_STATUS_INPUT.
Referenced by opj_stream_create_file_stream().
OPJ_API void OPJ_CALLCONV opj_stream_set_seek_function | ( | opj_stream_t * | p_stream, |
opj_stream_seek_fn | p_function | ||
) |
Sets the given function to be used as a seek function, the stream is then seekable, using SEEK_SET behavior.
p_stream | the stream to modify |
p_function | the function to use a skip function. |
References opj_stream_private::m_seek_fn.
Referenced by opj_stream_create_file_stream().
OPJ_API void OPJ_CALLCONV opj_stream_set_skip_function | ( | opj_stream_t * | p_stream, |
opj_stream_skip_fn | p_function | ||
) |
Sets the given function to be used as a skip function.
p_stream | the stream to modify |
p_function | the function to use a skip function. |
References opj_stream_private::m_skip_fn.
Referenced by opj_stream_create_file_stream().
OPJ_API void OPJ_CALLCONV opj_stream_set_user_data | ( | opj_stream_t * | p_stream, |
void * | p_data, | ||
opj_stream_free_user_data_fn | p_function | ||
) |
Sets the given data to be used as a user data for the stream.
p_stream | the stream to modify |
p_data | the data to set. |
p_function | the function to free p_data when opj_stream_destroy() is called. |
References opj_stream_private::m_free_user_data_fn, and opj_stream_private::m_user_data.
Referenced by opj_stream_create_file_stream().
OPJ_API void OPJ_CALLCONV opj_stream_set_user_data_length | ( | opj_stream_t * | p_stream, |
OPJ_UINT64 | data_length | ||
) |
Sets the length of the user data for the stream.
p_stream | the stream to modify |
data_length | length of the user_data. |
References opj_stream_private::m_user_data_length.
Referenced by opj_stream_create_file_stream().
OPJ_API void OPJ_CALLCONV opj_stream_set_write_function | ( | opj_stream_t * | p_stream, |
opj_stream_write_fn | p_function | ||
) |
Sets the given function to be used as a write function.
p_stream | the stream to modify |
p_function | the function to use a write function. |
References opj_stream_private::m_status, opj_stream_private::m_write_fn, and OPJ_STREAM_STATUS_OUTPUT.
Referenced by opj_stream_create_file_stream().
OPJ_API const char* OPJ_CALLCONV opj_version | ( | void | ) |
Referenced by opj_j2k_setup_encoder().
OPJ_API OPJ_BOOL OPJ_CALLCONV opj_write_tile | ( | opj_codec_t * | p_codec, |
OPJ_UINT32 | p_tile_index, | ||
OPJ_BYTE * | p_data, | ||
OPJ_UINT32 | p_data_size, | ||
opj_stream_t * | p_stream | ||
) |
Writes a tile with the given data.
p_codec | the jpeg2000 codec. |
p_tile_index | the index of the tile to write. At the moment, the tiles must be written from 0 to n-1 in sequence. |
p_data | pointer to the data to write. Data is arranged in sequence, data_comp0, then data_comp1, then ... NO INTERLEAVING should be set. |
p_data_size | this value os used to make sure the data being written is correct. The size must be equal to the sum for each component of tile_width * tile_height * component_size. component_size can be 1,2 or 4 bytes, depending on the precision of the given component. |
p_stream | the stream to write data to. |
References opj_codec_private::is_decompressor, opj_codec_private::m_codec, opj_codec_private::m_codec_data, opj_codec_private::m_compression, opj_codec_private::m_event_mgr, and OPJ_FALSE.