| openjpeg.h (2.0.1) | | openjpeg.h (2.1) | |
| | | | |
| skipping to change at line 175 | | skipping to change at line 175 | |
| #define OPJ_IMG_INFO 1 /**< Basic image information provide
d to the user */ | | #define OPJ_IMG_INFO 1 /**< Basic image information provide
d to the user */ | |
| #define OPJ_J2K_MH_INFO 2 /**< Codestream information
based only on the main header */ | | #define OPJ_J2K_MH_INFO 2 /**< Codestream information
based only on the main header */ | |
| #define OPJ_J2K_TH_INFO 4 /**< Tile information based
on the current tile header */ | | #define OPJ_J2K_TH_INFO 4 /**< Tile information based
on the current tile header */ | |
| #define OPJ_J2K_TCH_INFO 8 /**< Tile/Component information of a
ll tiles */ | | #define OPJ_J2K_TCH_INFO 8 /**< Tile/Component information of a
ll tiles */ | |
| #define OPJ_J2K_MH_IND 16 /**< Codestream index based only on
the main header */ | | #define OPJ_J2K_MH_IND 16 /**< Codestream index based only on
the main header */ | |
| #define OPJ_J2K_TH_IND 32 /**< Tile index based on the current
tile */ | | #define OPJ_J2K_TH_IND 32 /**< Tile index based on the current
tile */ | |
| /*FIXME #define OPJ_J2K_CSTR_IND 48*/ /**< */ | | /*FIXME #define OPJ_J2K_CSTR_IND 48*/ /**< */ | |
| #define OPJ_JP2_INFO 128 /**< JP2 file information */ | | #define OPJ_JP2_INFO 128 /**< JP2 file information */ | |
| #define OPJ_JP2_IND 256 /**< JP2 file index */ | | #define OPJ_JP2_IND 256 /**< JP2 file index */ | |
| | | | |
|
| | | /** | |
| | | * JPEG 2000 Profiles, see Table A.10 from 15444-1 (updated in various AMD) | |
| | | * These values help chosing 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 e | |
| | | xtensions | |
| | | * described hereunder. | |
| | | * Example: rsiz = OPJ_PROFILE_PART2 | OPJ_EXTENSION_MCT; | |
| | | * For broadcast profiles, the OPJ_PROFILE value has to be combined with th | |
| | | e 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 targ | |
| | | eted 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) | |
| | | * */ | |
| | | #define OPJ_PROFILE_NONE 0x0000 /** no profile, conform to 15444-1 * | |
| | | / | |
| | | #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 154 | |
| | | 44-1 AMD1 */ | |
| | | #define OPJ_PROFILE_CINEMA_4K 0x0004 /** 4K cinema profile defined in 154 | |
| | | 44-1 AMD1 */ | |
| | | #define OPJ_PROFILE_CINEMA_S2K 0x0005 /** Scalable 2K cinema profile defin | |
| | | ed in 15444-1 AMD2 */ | |
| | | #define OPJ_PROFILE_CINEMA_S4K 0x0006 /** Scalable 4K cinema profile defin | |
| | | ed 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 de | |
| | | fined in 15444-1 AMD3 */ | |
| | | #define OPJ_PROFILE_BC_MULTI 0x0200 /** Multi Tile Broadcast profile def | |
| | | ined 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 0x0401 /** 4K Single Tile Lossy IMF profile | |
| | | defined in 15444-1 AMD 8 */ | |
| | | #define OPJ_PROFILE_IMF_8K 0x0402 /** 8K Single Tile Lossy IMF profile | |
| | | defined in 15444-1 AMD 8 */ | |
| | | #define OPJ_PROFILE_IMF_2K_R 0x0403 /** 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 0x0801 /** 8K Single/Multi Tile Reversible | |
| | | IMF profile defined in 15444-1 AMD 8 */ | |
| | | | |
| | | /** | |
| | | * JPEG 2000 Part-2 extensions | |
| | | * */ | |
| | | #define OPJ_EXTENSION_NONE 0x0000 /** No Part-2 extension */ | |
| | | #define OPJ_EXTENSION_MCT 0x0100 /** Custom MCT support */ | |
| | | | |
| | | /** | |
| | | * JPEG 2000 profile macros | |
| | | * */ | |
| | | #define OPJ_IS_CINEMA(v) (((v) >= OPJ_PROFILE_CINEMA_2K)&&((v) <= OPJ_P | |
| | | ROFILE_CINEMA_S4K)) | |
| | | #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_PR | |
| | | OFILE_IMF_8K_R) | (0x009b)))) | |
| | | #define OPJ_IS_PART2(v) ((v) & OPJ_PROFILE_PART2) | |
| | | | |
| | | /** | |
| | | * JPEG 2000 codestream and component size limits in cinema profiles | |
| | | * */ | |
| | | #define OPJ_CINEMA_24_CS 1302083 /** Maximum codestream lengt | |
| | | h for 24fps */ | |
| | | #define OPJ_CINEMA_48_CS 651041 /** Maximum codestream length for 4 | |
| | | 8fps */ | |
| | | #define OPJ_CINEMA_24_COMP 1041666 /** Maximum size per color componen | |
| | | t for 2K & 4K @ 24fps */ | |
| | | #define OPJ_CINEMA_48_COMP 520833 /** Maximum size per color c | |
| | | omponent for 2K @ 48fps */ | |
| | | | |
| /* | | /* | |
| ========================================================== | | ========================================================== | |
| enum definitions | | enum definitions | |
| ========================================================== | | ========================================================== | |
| */ | | */ | |
|
| | | | |
| /** | | /** | |
|
| | | * DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead | |
| * Rsiz Capabilities | | * Rsiz Capabilities | |
| * */ | | * */ | |
| typedef enum RSIZ_CAPABILITIES { | | typedef enum RSIZ_CAPABILITIES { | |
|
| OPJ_STD_RSIZ = 0, /** Standard JPEG2000 profile*/ | | OPJ_STD_RSIZ = 0, /** Standard JPEG2000 profile*/ | |
| OPJ_CINEMA2K = 3, /** Profile name for a 2K image*/ | | OPJ_CINEMA2K = 3, /** Profile name for a 2K image*/ | |
| OPJ_CINEMA4K = 4, /** Profile name for a 4K image*/ | | OPJ_CINEMA4K = 4, /** Profile name for a 4K image*/ | |
| OPJ_MCT = 0x8100 | | OPJ_MCT = 0x8100 | |
| } OPJ_RSIZ_CAPABILITIES; | | } OPJ_RSIZ_CAPABILITIES; | |
| | | | |
| /** | | /** | |
|
| | | * DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead | |
| * Digital cinema operation mode | | * Digital cinema operation mode | |
| * */ | | * */ | |
| typedef enum CINEMA_MODE { | | typedef enum CINEMA_MODE { | |
|
| OPJ_OFF = 0, /** Not Digital Cinema*/ | | OPJ_OFF = 0, /** Not Digital Cinema*/ | |
| OPJ_CINEMA2K_24 = 1, /** 2K Digital Cinema at 24 fps*/ | | OPJ_CINEMA2K_24 = 1, /** 2K Digital Cinema at 24 fps*/ | |
| OPJ_CINEMA2K_48 = 2, /** 2K Digital Cinema at 48 fps*/ | | OPJ_CINEMA2K_48 = 2, /** 2K Digital Cinema at 48 fps*/ | |
| OPJ_CINEMA4K_24 = 3 /** 4K Digital Cinema at 24 fps*/ | | OPJ_CINEMA4K_24 = 3 /** 4K Digital Cinema at 24 fps*/ | |
| }OPJ_CINEMA_MODE; | | }OPJ_CINEMA_MODE; | |
| | | | |
| /** | | /** | |
| * Progression order | | * Progression order | |
| * */ | | * */ | |
| typedef enum PROG_ORDER { | | typedef enum PROG_ORDER { | |
| OPJ_PROG_UNKNOWN = -1, /**< place-holder */ | | OPJ_PROG_UNKNOWN = -1, /**< place-holder */ | |
| OPJ_LRCP = 0, /**< layer-resolution-component-prec
inct order */ | | OPJ_LRCP = 0, /**< layer-resolution-component-prec
inct order */ | |
| OPJ_RLCP = 1, /**< resolution-layer-component-prec
inct order */ | | OPJ_RLCP = 1, /**< resolution-layer-component-prec
inct order */ | |
| OPJ_RPCL = 2, /**< resolution-precinct-component-l
ayer order */ | | OPJ_RPCL = 2, /**< resolution-precinct-component-l
ayer order */ | |
| OPJ_PCRL = 3, /**< precinct-component-resolution-l
ayer order */ | | OPJ_PCRL = 3, /**< precinct-component-resolution-l
ayer order */ | |
| OPJ_CPRL = 4 /**< component-precinct-resolution-l
ayer order */ | | OPJ_CPRL = 4 /**< component-precinct-resolution-l
ayer order */ | |
| } OPJ_PROG_ORDER; | | } OPJ_PROG_ORDER; | |
| | | | |
| /** | | /** | |
| * Supported image color spaces | | * Supported image color spaces | |
| */ | | */ | |
| typedef enum COLOR_SPACE { | | typedef enum COLOR_SPACE { | |
|
| OPJ_CLRSPC_UNKNOWN = -1, /**< not supported by the library */ | | OPJ_CLRSPC_UNKNOWN = -1, /**< not supported by the library */ | |
| OPJ_CLRSPC_UNSPECIFIED = 0, /**< not specified in the codestream | | OPJ_CLRSPC_UNSPECIFIED = 0, /**< not specified in the codestream | |
| */ | | */ | |
| OPJ_CLRSPC_SRGB = 1, /**< sRGB */ | | OPJ_CLRSPC_SRGB = 1, /**< sRGB */ | |
| OPJ_CLRSPC_GRAY = 2, /**< grayscale */ | | OPJ_CLRSPC_GRAY = 2, /**< grayscale */ | |
| OPJ_CLRSPC_SYCC = 3 /**< YUV */ | | OPJ_CLRSPC_SYCC = 3, /**< YUV */ | |
| | | OPJ_CLRSPC_EYCC = 4, /**< e-YCC */ | |
| | | OPJ_CLRSPC_CMYK = 5 /**< CMYK */ | |
| } OPJ_COLOR_SPACE; | | } OPJ_COLOR_SPACE; | |
| | | | |
| /** | | /** | |
| * Supported codec | | * Supported codec | |
| */ | | */ | |
| typedef enum CODEC_FORMAT { | | typedef enum CODEC_FORMAT { | |
| OPJ_CODEC_UNKNOWN = -1, /**< place-holder */ | | OPJ_CODEC_UNKNOWN = -1, /**< place-holder */ | |
| OPJ_CODEC_J2K = 0, /**< JPEG-2000 codestream : read/wri
te */ | | OPJ_CODEC_J2K = 0, /**< JPEG-2000 codestream : read/wri
te */ | |
| OPJ_CODEC_JPT = 1, /**< JPT-stream (JPEG 2000, JPIP) :
read only */ | | OPJ_CODEC_JPT = 1, /**< JPT-stream (JPEG 2000, JPIP) :
read only */ | |
|
| OPJ_CODEC_JP2 = 2 /**< JPEG-2000 file format : read/wr | | OPJ_CODEC_JP2 = 2, /**< JP2 file format : read/write */ | |
| ite */ | | OPJ_CODEC_JPP = 3, /**< JPP-stream (JPEG 2000, JPIP) : | |
| | | to be coded */ | |
| | | OPJ_CODEC_JPX = 4 /**< JPX file format (JPEG 2000 Part-2) : to | |
| | | be coded */ | |
| } OPJ_CODEC_FORMAT; | | } OPJ_CODEC_FORMAT; | |
| | | | |
| /* | | /* | |
| ========================================================== | | ========================================================== | |
| event manager typedef definitions | | event manager typedef definitions | |
| ========================================================== | | ========================================================== | |
| */ | | */ | |
| | | | |
| /** | | /** | |
| * Callback function prototype for events | | * Callback function prototype for events | |
| | | | |
| skipping to change at line 315 | | skipping to change at line 378 | |
| /** csty : coding style */ | | /** csty : coding style */ | |
| int csty; | | int csty; | |
| /** progression order (default OPJ_LRCP) */ | | /** progression order (default OPJ_LRCP) */ | |
| OPJ_PROG_ORDER prog_order; | | OPJ_PROG_ORDER prog_order; | |
| /** progression order changes */ | | /** progression order changes */ | |
| opj_poc_t POC[32]; | | opj_poc_t POC[32]; | |
| /** number of progression order changes (POC), default to 0 */ | | /** number of progression order changes (POC), default to 0 */ | |
| OPJ_UINT32 numpocs; | | OPJ_UINT32 numpocs; | |
| /** number of layers */ | | /** number of layers */ | |
| int tcp_numlayers; | | int tcp_numlayers; | |
|
| /** rates of layers */ | | /** rates of layers - might be subsequently limited by the max_cs_size
field */ | |
| float tcp_rates[100]; | | float tcp_rates[100]; | |
| /** different psnr for successive layers */ | | /** different psnr for successive layers */ | |
| float tcp_distoratio[100]; | | float tcp_distoratio[100]; | |
| /** number of resolutions */ | | /** number of resolutions */ | |
| int numresolution; | | int numresolution; | |
| /** initial code block width, default to 64 */ | | /** initial code block width, default to 64 */ | |
| int cblockw_init; | | int cblockw_init; | |
| /** initial code block height, default to 64 */ | | /** initial code block height, default to 64 */ | |
| int cblockh_init; | | int cblockh_init; | |
| /** mode switch (cblk_style) */ | | /** mode switch (cblk_style) */ | |
| | | | |
| skipping to change at line 396 | | skipping to change at line 459 | |
| int jpwl_sens_range; | | int jpwl_sens_range; | |
| /** sensitivity method for MH (-1=no,0-7) */ | | /** sensitivity method for MH (-1=no,0-7) */ | |
| int jpwl_sens_MH; | | int jpwl_sens_MH; | |
| /** tile number of sensitivity specification (>=0) */ | | /** tile number of sensitivity specification (>=0) */ | |
| int jpwl_sens_TPH_tileno[JPWL_MAX_NO_TILESPECS]; | | int jpwl_sens_TPH_tileno[JPWL_MAX_NO_TILESPECS]; | |
| /** sensitivity methods for TPHs (-1=no,0-7) */ | | /** sensitivity methods for TPHs (-1=no,0-7) */ | |
| int jpwl_sens_TPH[JPWL_MAX_NO_TILESPECS]; | | int jpwl_sens_TPH[JPWL_MAX_NO_TILESPECS]; | |
| /*@}*/ | | /*@}*/ | |
| /* <<UniPG */ | | /* <<UniPG */ | |
| | | | |
|
| /** Digital Cinema compliance 0-not compliant, 1-compliant*/ | | /** | |
| OPJ_CINEMA_MODE cp_cinema; | | * DEPRECATED: use RSIZ, OPJ_PROFILE_* and MAX_COMP_SIZE instead | |
| /** Maximum rate for each component. If == 0, component size limitat | | * Digital Cinema compliance 0-not compliant, 1-compliant | |
| ion is not considered */ | | * */ | |
| | | OPJ_CINEMA_MODE cp_cinema; | |
| | | /** | |
| | | * Maximum size (in bytes) for each component. | |
| | | * If == 0, component size limitation is not considered | |
| | | * */ | |
| int max_comp_size; | | int max_comp_size; | |
|
| /** Profile name*/ | | /** | |
| OPJ_RSIZ_CAPABILITIES cp_rsiz; | | * DEPRECATED: use RSIZ, OPJ_PROFILE_* and OPJ_EXTENSION_* instead | |
| | | * Profile name | |
| | | * */ | |
| | | OPJ_RSIZ_CAPABILITIES cp_rsiz; | |
| /** Tile part generation*/ | | /** Tile part generation*/ | |
| char tp_on; | | char tp_on; | |
| /** Flag for Tile part generation*/ | | /** Flag for Tile part generation*/ | |
| char tp_flag; | | char tp_flag; | |
| /** MCT (multiple component transform) */ | | /** MCT (multiple component transform) */ | |
| char tcp_mct; | | char tcp_mct; | |
| /** Enable JPIP indexing*/ | | /** Enable JPIP indexing*/ | |
| OPJ_BOOL jpip_on; | | OPJ_BOOL jpip_on; | |
| /** Naive implementation of MCT restricted to a single reversible ar
ray based | | /** Naive implementation of MCT restricted to a single reversible ar
ray based | |
| encoding without offset concerning all the components. */ | | encoding without offset concerning all the components. */ | |
| void * mct_data; | | void * mct_data; | |
|
| | | /** | |
| | | * Maximum size (in bytes) for the whole codestream. | |
| | | * If == 0, codestream size limitation is not considered | |
| | | * If it does not comply with tcp_rates, max_cs_size prevails | |
| | | * and a warning is issued. | |
| | | * */ | |
| | | int max_cs_size; | |
| | | /** RSIZ value | |
| | | To be used to combine OPJ_PROFILE_*, OPJ_EXTENSION_* and (sub)level | |
| | | s values. */ | |
| | | OPJ_UINT16 rsiz; | |
| } opj_cparameters_t; | | } opj_cparameters_t; | |
| | | | |
| #define OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG 0x0001 | | #define OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG 0x0001 | |
| | | | |
| /** | | /** | |
| * Decompression parameters | | * Decompression parameters | |
| * */ | | * */ | |
| typedef struct opj_dparameters { | | typedef struct opj_dparameters { | |
| /** | | /** | |
| Set the number of highest resolution levels to be discarded. | | Set the number of highest resolution levels to be discarded. | |
| | | | |
| skipping to change at line 522 | | skipping to change at line 604 | |
| * Callback function prototype for skip function | | * Callback function prototype for skip function | |
| */ | | */ | |
| typedef OPJ_OFF_T (* opj_stream_skip_fn) (OPJ_OFF_T p_nb_bytes, void * p_us
er_data) ; | | typedef OPJ_OFF_T (* opj_stream_skip_fn) (OPJ_OFF_T p_nb_bytes, void * p_us
er_data) ; | |
| | | | |
| /* | | /* | |
| * Callback function prototype for seek function | | * Callback function prototype for seek function | |
| */ | | */ | |
| typedef OPJ_BOOL (* opj_stream_seek_fn) (OPJ_OFF_T p_nb_bytes, void * p_use
r_data) ; | | typedef OPJ_BOOL (* opj_stream_seek_fn) (OPJ_OFF_T p_nb_bytes, void * p_use
r_data) ; | |
| | | | |
| /* | | /* | |
|
| | | * Callback function prototype for free user data function | |
| | | */ | |
| | | typedef void (* opj_stream_free_user_data_fn) (void * p_user_data) ; | |
| | | | |
| | | /* | |
| * JPEG2000 Stream. | | * JPEG2000 Stream. | |
| */ | | */ | |
| typedef void * opj_stream_t; | | typedef void * opj_stream_t; | |
| | | | |
| /* | | /* | |
| ========================================================== | | ========================================================== | |
| image typedef definitions | | image typedef definitions | |
| ========================================================== | | ========================================================== | |
| */ | | */ | |
| | | | |
| | | | |
| skipping to change at line 560 | | skipping to change at line 647 | |
| /** image depth in bits */ | | /** image depth in bits */ | |
| OPJ_UINT32 bpp; | | OPJ_UINT32 bpp; | |
| /** signed (1) / unsigned (0) */ | | /** signed (1) / unsigned (0) */ | |
| OPJ_UINT32 sgnd; | | OPJ_UINT32 sgnd; | |
| /** number of decoded resolution */ | | /** number of decoded resolution */ | |
| OPJ_UINT32 resno_decoded; | | OPJ_UINT32 resno_decoded; | |
| /** number of division by 2 of the out image compared to the origina
l size of image */ | | /** number of division by 2 of the out image compared to the origina
l size of image */ | |
| OPJ_UINT32 factor; | | OPJ_UINT32 factor; | |
| /** image component data */ | | /** image component data */ | |
| OPJ_INT32 *data; | | OPJ_INT32 *data; | |
|
| | | /** alpha channel */ | |
| | | OPJ_UINT16 alpha; | |
| } opj_image_comp_t; | | } opj_image_comp_t; | |
| | | | |
| /** | | /** | |
| * Defines image data and characteristics | | * Defines image data and characteristics | |
| * */ | | * */ | |
| typedef struct opj_image { | | typedef struct opj_image { | |
| /** XOsiz: horizontal offset from the origin of the reference grid t
o the left side of the image area */ | | /** XOsiz: horizontal offset from the origin of the reference grid t
o the left side of the image area */ | |
| OPJ_UINT32 x0; | | OPJ_UINT32 x0; | |
| /** YOsiz: vertical offset from the origin of the reference grid to
the top side of the image area */ | | /** YOsiz: vertical offset from the origin of the reference grid to
the top side of the image area */ | |
| OPJ_UINT32 y0; | | OPJ_UINT32 y0; | |
| | | | |
| skipping to change at line 1054 | | skipping to change at line 1143 | |
| * Sets the given function to be used as a seek function, the stream is the
n seekable. | | * Sets the given function to be used as a seek function, the stream is the
n seekable. | |
| * @param p_stream the stream to modify | | * @param p_stream the stream to modify | |
| * @param p_function the function to use a skip function. | | * @param p_function the function to use a skip function. | |
| */ | | */ | |
| OPJ_API void OPJ_CALLCONV opj_stream_set_seek_function(opj_stream_t* p_stre
am, opj_stream_seek_fn p_function); | | OPJ_API void OPJ_CALLCONV opj_stream_set_seek_function(opj_stream_t* p_stre
am, opj_stream_seek_fn p_function); | |
| | | | |
| /** | | /** | |
| * Sets the given data to be used as a user data for the stream. | | * Sets the given data to be used as a user data for the stream. | |
| * @param p_stream the stream to modify | | * @param p_stream the stream to modify | |
| * @param p_data the data to set. | | * @param p_data the data to set. | |
|
| | | * @param p_function the function to free p_data when opj
_stream_destroy() is called. | |
| */ | | */ | |
|
| OPJ_API void OPJ_CALLCONV opj_stream_set_user_data (opj_stream_t* p_stream,
void * p_data); | | 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 length of the user data for the stream. | | * Sets the length of the user data for the stream. | |
| * | | * | |
| * @param p_stream the stream to modify | | * @param p_stream the stream to modify | |
| * @param data_length length of the user_data. | | * @param data_length length of the user_data. | |
| */ | | */ | |
| OPJ_API void OPJ_CALLCONV opj_stream_set_user_data_length(opj_stream_t* p_s
tream, OPJ_UINT64 data_length); | | OPJ_API void OPJ_CALLCONV opj_stream_set_user_data_length(opj_stream_t* p_s
tream, OPJ_UINT64 data_length); | |
| | | | |
| /** | | /** | |
|
| * Helper function. | | * Create a stream from a file identified with its filename with default pa | |
| * Sets the stream to be a file stream. The FILE must have been open previo | | rameters (helper function) | |
| usly. | | * @param fname the filename of the file to stream | |
| * @param p_file the file stream to operate on | | | |
| * @param p_is_read_stream whether the stream is a read stream (true) or n
ot (false) | | * @param p_is_read_stream whether the stream is a read stream (true) or n
ot (false) | |
| */ | | */ | |
|
| OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream (F
ILE * p_file, OPJ_BOOL p_is_read_stream); | | OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream (c
onst char *fname, OPJ_BOOL p_is_read_stream); | |
| | | | |
|
| /** | | /** Create a stream from a file identified with its filename with a specifi | |
| * FIXME DOC | | c buffer size | |
| * @param p_file the file stream to operate on | | * @param fname the filename of the file to stream | |
| * @param p_buffer_size size of the chunk used to stream | | * @param p_buffer_size size of the chunk used to stream | |
| * @param p_is_read_stream whether the stream is a read stream (true) or n
ot (false) | | * @param p_is_read_stream whether the stream is a read stream (true) or n
ot (false) | |
| */ | | */ | |
|
| OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream (FILE * p_ | | OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream (const cha | |
| file, OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_read_stream); | | r *fname, | |
| | | OPJ_SI | |
| | | ZE_T p_buffer_size, | |
| | | OPJ_BO | |
| | | OL p_is_read_stream); | |
| | | | |
| /* | | /* | |
| ========================================================== | | ========================================================== | |
| event manager functions definitions | | event manager functions definitions | |
| ========================================================== | | ========================================================== | |
| */ | | */ | |
| /** | | /** | |
| * Set the info handler use by openjpeg. | | * Set the info handler use by openjpeg. | |
| * @param p_codec the codec previously initialise | | * @param p_codec the codec previously initialise | |
| * @param p_callback the callback function which will be used | | * @param p_callback the callback function which will be used | |
| | | | |
End of changes. 20 change blocks. |
| 34 lines changed or deleted | | 159 lines changed or added | |
|