@param bio BIO handle
@return Returns OPJ_TRUE if successful, returns OPJ_FALSE otherwise
*/
-static opj_bool opj_bio_byteout(opj_bio_t *bio);
+static OPJ_BOOL opj_bio_byteout(opj_bio_t *bio);
/**
Read a byte
@param bio BIO handle
@return Returns OPJ_TRUE if successful, returns OPJ_FALSE otherwise
*/
-static opj_bool opj_bio_bytein(opj_bio_t *bio);
+static OPJ_BOOL opj_bio_bytein(opj_bio_t *bio);
/*@}*/
==========================================================
*/
-opj_bool opj_bio_byteout(opj_bio_t *bio) {
+OPJ_BOOL opj_bio_byteout(opj_bio_t *bio) {
bio->buf = (bio->buf << 8) & 0xffff;
bio->ct = bio->buf == 0xff00 ? 7 : 8;
if (bio->bp >= bio->end) {
return OPJ_TRUE;
}
-opj_bool opj_bio_bytein(opj_bio_t *bio) {
+OPJ_BOOL opj_bio_bytein(opj_bio_t *bio) {
bio->buf = (bio->buf << 8) & 0xffff;
bio->ct = bio->buf == 0xff00 ? 7 : 8;
if (bio->bp >= bio->end) {
return v;
}
-opj_bool opj_bio_flush(opj_bio_t *bio) {
+OPJ_BOOL opj_bio_flush(opj_bio_t *bio) {
bio->ct = 0;
if (! opj_bio_byteout(bio)) {
return OPJ_FALSE;
return OPJ_TRUE;
}
-opj_bool opj_bio_inalign(opj_bio_t *bio) {
+OPJ_BOOL opj_bio_inalign(opj_bio_t *bio) {
bio->ct = 0;
if ((bio->buf & 0xff) == 0xff) {
if (! opj_bio_bytein(bio)) {
@param bio BIO handle
@return Returns OPJ_TRUE if successful, returns OPJ_FALSE otherwise
*/
-opj_bool opj_bio_flush(opj_bio_t *bio);
+OPJ_BOOL opj_bio_flush(opj_bio_t *bio);
/**
Passes the ending bits (coming from flushing)
@param bio BIO handle
@return Returns OPJ_TRUE if successful, returns OPJ_FALSE otherwise
*/
-opj_bool opj_bio_inalign(opj_bio_t *bio);
+OPJ_BOOL opj_bio_inalign(opj_bio_t *bio);
/* ----------------------------------------------------------------------- */
/*@}*/
}
}
-opj_stream_t* OPJ_CALLCONV opj_stream_create(OPJ_SIZE_T p_buffer_size,opj_bool l_is_input)
+opj_stream_t* OPJ_CALLCONV opj_stream_create(OPJ_SIZE_T p_buffer_size,OPJ_BOOL l_is_input)
{
opj_stream_private_t * l_stream = 00;
l_stream = (opj_stream_private_t*) opj_malloc(sizeof(opj_stream_private_t));
return (opj_stream_t *) l_stream;
}
-opj_stream_t* OPJ_CALLCONV opj_stream_default_create(opj_bool l_is_input)
+opj_stream_t* OPJ_CALLCONV opj_stream_default_create(OPJ_BOOL l_is_input)
{
return opj_stream_create(OPJ_J2K_STREAM_CHUNK_SIZE,l_is_input);
}
}
-opj_bool opj_stream_flush (opj_stream_private_t * p_stream, opj_event_mgr_t * p_event_mgr)
+OPJ_BOOL opj_stream_flush (opj_stream_private_t * p_stream, opj_event_mgr_t * p_event_mgr)
{
/* the number of bytes written on the media. */
OPJ_SIZE_T l_current_write_nb_bytes = 0;
OPJ_OFF_T opj_stream_write_skip (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, opj_event_mgr_t * p_event_mgr)
{
- opj_bool l_is_written = 0;
+ OPJ_BOOL l_is_written = 0;
OPJ_OFF_T l_current_skip_nb_bytes = 0;
OPJ_OFF_T l_skip_nb_bytes = 0;
return p_stream->m_opj_skip(p_stream,p_size,p_event_mgr);
}
-opj_bool opj_stream_read_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, opj_event_mgr_t * p_event_mgr)
+OPJ_BOOL opj_stream_read_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, opj_event_mgr_t * p_event_mgr)
{
OPJ_ARG_NOT_USED(p_event_mgr);
p_stream->m_current_data = p_stream->m_stored_data;
return OPJ_TRUE;
}
-opj_bool opj_stream_write_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, opj_event_mgr_t * p_event_mgr)
+OPJ_BOOL opj_stream_write_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, opj_event_mgr_t * p_event_mgr)
{
if (! opj_stream_flush(p_stream,p_event_mgr)) {
p_stream->m_status |= opj_stream_e_error;
return OPJ_TRUE;
}
-opj_bool opj_stream_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr)
+OPJ_BOOL opj_stream_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr)
{
assert(p_size >= 0);
return p_stream->m_opj_seek(p_stream,p_size,p_event_mgr);
}
-opj_bool opj_stream_has_seek (const opj_stream_private_t * p_stream)
+OPJ_BOOL opj_stream_has_seek (const opj_stream_private_t * p_stream)
{
return p_stream->m_seek_fn != opj_stream_default_seek;
}
return (OPJ_OFF_T) -1;
}
-opj_bool opj_stream_default_seek (OPJ_OFF_T p_nb_bytes, void * p_user_data)
+OPJ_BOOL opj_stream_default_seek (OPJ_OFF_T p_nb_bytes, void * p_user_data)
{
OPJ_ARG_NOT_USED(p_nb_bytes);
OPJ_ARG_NOT_USED(p_user_data);
/**
* FIXME DOC.
*/
- opj_bool (* m_opj_seek) (struct opj_stream_private * , OPJ_OFF_T , struct opj_event_mgr *);
+ OPJ_BOOL (* m_opj_seek) (struct opj_stream_private * , OPJ_OFF_T , struct opj_event_mgr *);
/**
* number of bytes containing in the buffer.
* @param p_event_mgr the user event manager to be notified of special events.
* @return true if the data could be flushed, false else.
*/
-opj_bool opj_stream_flush (opj_stream_private_t * p_stream, struct opj_event_mgr * p_event_mgr);
+OPJ_BOOL opj_stream_flush (opj_stream_private_t * p_stream, struct opj_event_mgr * p_event_mgr);
/**
* Skips a number of bytes from the stream.
* @param p_event_mgr the user event manager to be notified of special events.
* @return OPJ_TRUE if success, or OPJ_FALSE if an error occured.
*/
-opj_bool opj_stream_read_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
+OPJ_BOOL opj_stream_read_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
/**
* Skips a number of bytes from the stream.
* @param p_event_mgr the user event manager to be notified of special events.
* @return the number of bytes skipped, or -1 if an error occured.
*/
-opj_bool opj_stream_write_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
+OPJ_BOOL opj_stream_write_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
/**
* Seeks a number of bytes from the stream.
* @param p_event_mgr the user event manager to be notified of special events.
* @return true if the stream is seekable.
*/
-opj_bool opj_stream_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
+OPJ_BOOL opj_stream_seek (opj_stream_private_t * p_stream, OPJ_OFF_T p_size, struct opj_event_mgr * p_event_mgr);
/**
* Tells if the given stream is seekable.
*/
-opj_bool opj_stream_has_seek (const opj_stream_private_t * p_stream);
+OPJ_BOOL opj_stream_has_seek (const opj_stream_private_t * p_stream);
/**
* FIXME DOC.
/**
* FIXME DOC.
*/
-opj_bool opj_stream_default_seek (OPJ_OFF_T p_nb_bytes, void * p_user_data);
+OPJ_BOOL opj_stream_default_seek (OPJ_OFF_T p_nb_bytes, void * p_user_data);
/* ----------------------------------------------------------------------- */
/*@}*/
/**
Inverse wavelet transform in 2-D.
*/
-static opj_bool opj_dwt_decode_tile(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 i, DWT1DFN fn);
+static OPJ_BOOL opj_dwt_decode_tile(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 i, DWT1DFN fn);
-static opj_bool opj_dwt_encode_procedure( opj_tcd_tilecomp_t * tilec,
+static OPJ_BOOL opj_dwt_encode_procedure( opj_tcd_tilecomp_t * tilec,
void (*p_function)(OPJ_INT32 *, OPJ_INT32,OPJ_INT32,OPJ_INT32) );
static OPJ_UINT32 opj_dwt_max_resolution(opj_tcd_resolution_t* restrict r, OPJ_UINT32 i);
/* <summary> */
/* Forward 5-3 wavelet transform in 2-D. */
/* </summary> */
-INLINE opj_bool opj_dwt_encode_procedure(opj_tcd_tilecomp_t * tilec,void (*p_function)(OPJ_INT32 *, OPJ_INT32,OPJ_INT32,OPJ_INT32) )
+INLINE OPJ_BOOL opj_dwt_encode_procedure(opj_tcd_tilecomp_t * tilec,void (*p_function)(OPJ_INT32 *, OPJ_INT32,OPJ_INT32,OPJ_INT32) )
{
OPJ_INT32 i, j, k;
OPJ_INT32 *a = 00;
/* Forward 5-3 wavelet transform in 2-D. */
/* </summary> */
-opj_bool opj_dwt_encode(opj_tcd_tilecomp_t * tilec)
+OPJ_BOOL opj_dwt_encode(opj_tcd_tilecomp_t * tilec)
{
return opj_dwt_encode_procedure(tilec,opj_dwt_encode_1);
}
/* <summary> */
/* Inverse 5-3 wavelet transform in 2-D. */
/* </summary> */
-opj_bool opj_dwt_decode(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres) {
+OPJ_BOOL opj_dwt_decode(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres) {
return opj_dwt_decode_tile(tilec, numres, &opj_dwt_decode_1);
}
/* <summary> */
/* Forward 9-7 wavelet transform in 2-D. */
/* </summary> */
-opj_bool opj_dwt_encode_real(opj_tcd_tilecomp_t * tilec)
+OPJ_BOOL opj_dwt_encode_real(opj_tcd_tilecomp_t * tilec)
{
return opj_dwt_encode_procedure(tilec,opj_dwt_encode_1_real);
}
/* <summary> */
/* Inverse wavelet transform in 2-D. */
/* </summary> */
-opj_bool opj_dwt_decode_tile(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres, DWT1DFN dwt_1D) {
+OPJ_BOOL opj_dwt_decode_tile(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres, DWT1DFN dwt_1D) {
dwt_t h;
dwt_t v;
/* <summary> */
/* Inverse 9-7 wavelet transform in 2-D. */
/* </summary> */
-opj_bool opj_dwt_decode_real(opj_tcd_tilecomp_t* restrict tilec, OPJ_UINT32 numres)
+OPJ_BOOL opj_dwt_decode_real(opj_tcd_tilecomp_t* restrict tilec, OPJ_UINT32 numres)
{
v4dwt_t h;
v4dwt_t v;
Apply a reversible DWT transform to a component of an image.
@param tilec Tile component information (current tile)
*/
-opj_bool opj_dwt_encode(opj_tcd_tilecomp_t * tilec);
+OPJ_BOOL opj_dwt_encode(opj_tcd_tilecomp_t * tilec);
/**
Inverse 5-3 wavelet tranform in 2-D.
@param tilec Tile component information (current tile)
@param numres Number of resolution levels to decode
*/
-opj_bool opj_dwt_decode(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres);
+OPJ_BOOL opj_dwt_decode(opj_tcd_tilecomp_t* tilec, OPJ_UINT32 numres);
/**
Get the gain of a subband for the reversible 5-3 DWT.
Apply an irreversible DWT transform to a component of an image.
@param tilec Tile component information (current tile)
*/
-opj_bool opj_dwt_encode_real(opj_tcd_tilecomp_t * tilec);
+OPJ_BOOL opj_dwt_encode_real(opj_tcd_tilecomp_t * tilec);
/**
Inverse 9-7 wavelet transform in 2-D.
Apply an irreversible inverse DWT transform to a component of an image.
@param tilec Tile component information (current tile)
@param numres Number of resolution levels to decode
*/
-opj_bool opj_dwt_decode_real(opj_tcd_tilecomp_t* restrict tilec, OPJ_UINT32 numres);
+OPJ_BOOL opj_dwt_decode_real(opj_tcd_tilecomp_t* restrict tilec, OPJ_UINT32 numres);
/**
Get the gain of a subband for the irreversible 9-7 DWT.
/* ----------------------------------------------------------------------- */
-opj_bool opj_event_msg(opj_event_mgr_t* p_event_mgr, int event_type, const char *fmt, ...) {
+OPJ_BOOL opj_event_msg(opj_event_mgr_t* p_event_mgr, int event_type, const char *fmt, ...) {
#define MSG_SIZE 512 /* 512 bytes should be more than enough for a short message */
opj_msg_callback msg_handler = 00;
void * l_data = 00;
*
* @return Returns true if successful, returns false otherwise
*/
-opj_bool opj_event_msg(opj_event_mgr_t* event_mgr, int event_type, const char *fmt, ...);
+OPJ_BOOL opj_event_msg(opj_event_mgr_t* event_mgr, int event_type, const char *fmt, ...);
/* ----------------------------------------------------------------------- */
/**
opj_free(p_list);
}
-opj_bool opj_procedure_list_add_procedure (opj_procedure_list_t * p_validation_list, opj_procedure p_procedure)
+OPJ_BOOL opj_procedure_list_add_procedure (opj_procedure_list_t * p_validation_list, opj_procedure p_procedure)
{
if (p_validation_list->m_nb_max_procedures == p_validation_list->m_nb_procedures)
{
*
* @return OPJ_TRUE if the procedure could be added.
*/
-opj_bool opj_procedure_list_add_procedure (opj_procedure_list_t * p_validation_list, opj_procedure p_procedure);
+OPJ_BOOL opj_procedure_list_add_procedure (opj_procedure_list_t * p_validation_list, opj_procedure p_procedure);
/**
* Gets the number of validation procedures.
/**
* LUP decomposition
*/
-static opj_bool opj_lupDecompose(OPJ_FLOAT32 * matrix,
+static OPJ_BOOL opj_lupDecompose(OPJ_FLOAT32 * matrix,
OPJ_UINT32 * permutations,
OPJ_FLOAT32 * p_swap_area,
OPJ_UINT32 nb_compo);
/**
* Matrix inversion.
*/
-opj_bool opj_matrix_inversion_f(OPJ_FLOAT32 * pSrcMatrix,
+OPJ_BOOL opj_matrix_inversion_f(OPJ_FLOAT32 * pSrcMatrix,
OPJ_FLOAT32 * pDestMatrix,
OPJ_UINT32 nb_compo)
{
Local functions
==========================================================
*/
-opj_bool opj_lupDecompose(OPJ_FLOAT32 * matrix,OPJ_UINT32 * permutations,
+OPJ_BOOL opj_lupDecompose(OPJ_FLOAT32 * matrix,OPJ_UINT32 * permutations,
OPJ_FLOAT32 * p_swap_area,
OPJ_UINT32 nb_compo)
{
* @param n size of the matrix
* @return OPJ_TRUE if the inversion is successful, OPJ_FALSE if the matrix is singular.
*/
-opj_bool opj_matrix_inversion_f(OPJ_FLOAT32 * pSrcMatrix,
+OPJ_BOOL opj_matrix_inversion_f(OPJ_FLOAT32 * pSrcMatrix,
OPJ_FLOAT32 * pDestMatrix,
OPJ_UINT32 nb_compo);
/* ----------------------------------------------------------------------- */
/**
* The read header procedure.
*/
-static opj_bool opj_j2k_read_header_procedure( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_header_procedure( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager);
*
* @return true if the parameters are correct.
*/
-static opj_bool opj_j2k_encoding_validation ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_encoding_validation ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return true if the parameters are correct.
*/
-static opj_bool opj_j2k_decoding_validation ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_decoding_validation ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return true if the parameters are correct.
*/
-static opj_bool opj_j2k_mct_validation (opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_mct_validation (opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
/**
* Builds the tcd decoder to use to decode tile.
*/
-static opj_bool opj_j2k_build_decoder ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_build_decoder ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
/**
* Builds the tcd encoder to use to encode tile.
*/
-static opj_bool opj_j2k_build_encoder ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_build_encoder ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_create_tcd( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_create_tcd( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return true if all the procedures were successfully executed.
*/
-static opj_bool opj_j2k_exec ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_exec ( opj_j2k_t * p_j2k,
opj_procedure_list_t * p_procedure_list,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_update_rates( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_update_rates( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* Copies the decoding tile parameters onto all the tile parameters.
* Creates also the tile decoder.
*/
-static opj_bool opj_j2k_copy_default_tcp_and_create_tcd ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_copy_default_tcp_and_create_tcd ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
/**
* Destroys the memory associated with the decoding of headers.
*/
-static opj_bool opj_j2k_destroy_header_memory ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_destroy_header_memory ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return FIXME DOC
*/
-static opj_bool opj_j2k_write_SPCod_SPCoc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_SPCod_SPCoc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_BYTE * p_data,
* @param p_header_size the size of the data contained in the COM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_SPCod_SPCoc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_SPCod_SPCoc( opj_j2k_t *p_j2k,
OPJ_UINT32 compno,
OPJ_BYTE * p_header_data,
OPJ_UINT32 * p_header_size,
* @param p_manager the user event manager.
*
*/
-static opj_bool opj_j2k_write_SQcd_SQcc(opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_SQcd_SQcc(opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_BYTE * p_data,
* @param p_manager the user event manager.
*
*/
-static opj_bool opj_j2k_read_SQcd_SQcc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_SQcd_SQcc( opj_j2k_t *p_j2k,
OPJ_UINT32 compno,
OPJ_BYTE * p_header_data,
OPJ_UINT32 * p_header_size,
/**
* Reads the tiles.
*/
-static opj_bool opj_j2k_decode_tiles ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_decode_tiles ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager);
-static opj_bool opj_j2k_pre_write_tile ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_pre_write_tile ( opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
-static opj_bool opj_j2k_update_image_data (opj_tcd_t * p_tcd, OPJ_BYTE * p_data, opj_image_t* p_output_image);
+static OPJ_BOOL opj_j2k_update_image_data (opj_tcd_t * p_tcd, OPJ_BYTE * p_data, opj_image_t* p_output_image);
static void opj_j2k_get_tile_data (opj_tcd_t * p_tcd, OPJ_BYTE * p_data);
-static opj_bool opj_j2k_post_write_tile (opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_post_write_tile (opj_j2k_t * p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
opj_stream_private_t *p_stream,
*/
static void opj_j2k_setup_header_writing (opj_j2k_t *p_j2k);
-static opj_bool opj_j2k_write_first_tile_part( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_first_tile_part( opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_total_data_size,
opj_stream_private_t *p_stream,
struct opj_event_mgr * p_manager );
-static opj_bool opj_j2k_write_all_tile_parts( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_all_tile_parts( opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_total_data_size,
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_get_end_header( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_get_end_header( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
-static opj_bool opj_j2k_allocate_tile_element_cstr_index(opj_j2k_t *p_j2k);
+static OPJ_BOOL opj_j2k_allocate_tile_element_cstr_index(opj_j2k_t *p_j2k);
/*
* -----------------------------------------------------------------------
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_soc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_soc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_stream XXX needs data
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_soc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_soc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_siz( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_siz( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the SIZ marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_siz(opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_siz(opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_com( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_com( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the COM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_com ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_com ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_cod( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_cod( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the COD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_cod ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_cod ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_coc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_coc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_comp_no,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the COC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_coc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_coc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_qcd( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_qcd( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the QCD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_qcd ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_qcd ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_qcc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_qcc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_comp_no,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the QCC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_qcc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_qcc( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_poc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_poc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
/**
* @param p_header_size the size of the data contained in the POC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_poc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_poc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_crg ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_crg ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_tlm ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_tlm ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_updated_tlm( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_updated_tlm( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_plm ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_plm ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_header_size the size of the data contained in the PLT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_plt ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_plt ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the POC marker.
* @param p_manager the user event manager.
*/
-static opj_bool j2k_read_ppm_v2 (
+static OPJ_BOOL j2k_read_ppm_v2 (
opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
);
#endif
-static opj_bool j2k_read_ppm_v3 (
+static OPJ_BOOL j2k_read_ppm_v3 (
opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
* @param p_header_size the size of the data contained in the PPT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_ppt ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_ppt ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_tlm( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_tlm( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_sot( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_sot( opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
const opj_stream_private_t *p_stream,
* @param p_header_size the size of the data contained in the PPT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_sot ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_sot ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_sod( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_sod( opj_j2k_t *p_j2k,
opj_tcd_t * p_tile_coder,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
* @param p_stream FIXME DOC
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_sod( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_sod( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_rgn( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_rgn( opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_UINT32 nb_comps,
* @param p_header_size the size of the data contained in the POC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_rgn (opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_rgn (opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_eoc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_eoc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_stream FIXME DOC
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_eoc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_eoc ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_mct_data_group( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_mct_data_group( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_init_info( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_init_info( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
@param pos byte offset of marker segment
@param len length of marker segment
*/
-static opj_bool opj_j2k_add_mhmarker(opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len) ;
+static OPJ_BOOL opj_j2k_add_mhmarker(opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len) ;
/**
Add tile header marker information
@param tileno tile index number
@param pos byte offset of marker segment
@param len length of marker segment
*/
-static opj_bool opj_j2k_add_tlmarker(OPJ_UINT32 tileno, opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len);
+static OPJ_BOOL opj_j2k_add_tlmarker(OPJ_UINT32 tileno, opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len);
/**
* Reads an unknown marker
*
* @return true if the marker could be deduced.
*/
-static opj_bool opj_j2k_read_unk( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_unk( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
OPJ_UINT32 *output_marker,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_mct_record( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_mct_record( opj_j2k_t *p_j2k,
opj_mct_data_t * p_mct_record,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the MCT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_mct ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_mct ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_mcc_record( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_mcc_record( opj_j2k_t *p_j2k,
opj_simple_mcc_decorrelation_data_t * p_mcc_record,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the MCC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_mcc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_mcc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_mco( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_mco( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the MCO marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_mco ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_mco ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
-static opj_bool opj_j2k_add_mct(opj_tcp_t * p_tcp, opj_image_t * p_image, OPJ_UINT32 p_index);
+static OPJ_BOOL opj_j2k_add_mct(opj_tcp_t * p_tcp, opj_image_t * p_image, OPJ_UINT32 p_index);
static void opj_j2k_read_int16_to_float (const void * p_src_data, void * p_dest_data, OPJ_UINT32 p_nb_elem);
static void opj_j2k_read_int32_to_float (const void * p_src_data, void * p_dest_data, OPJ_UINT32 p_nb_elem);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_end_encoding( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_end_encoding( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_cbd( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_cbd( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_header_size the size of the data contained in the CBD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_cbd ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_cbd ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_image_components( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_image_components( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_regions( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_regions( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_write_epc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_write_epc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return true if the pocs are valid.
*/
-static opj_bool opj_j2k_check_poc_val( const opj_poc_t *p_pocs,
+static OPJ_BOOL opj_j2k_check_poc_val( const opj_poc_t *p_pocs,
OPJ_UINT32 p_nb_pocs,
OPJ_UINT32 p_nb_resolutions,
OPJ_UINT32 numcomps,
*
* @return true if the function was successful, false else.
*/
-static opj_bool opj_j2k_calculate_tp( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_calculate_tp( opj_j2k_t *p_j2k,
opj_cp_t *cp,
OPJ_UINT32 * p_nb_tiles,
opj_image_t *image,
/** value of the state when the marker can appear */
OPJ_UINT32 states;
/** action linked to the marker */
- opj_bool (*handler) ( opj_j2k_t *p_j2k,
+ OPJ_BOOL (*handler) ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
return po->str_prog;
}
-opj_bool opj_j2k_check_poc_val( const opj_poc_t *p_pocs,
+OPJ_BOOL opj_j2k_check_poc_val( const opj_poc_t *p_pocs,
OPJ_UINT32 p_nb_pocs,
OPJ_UINT32 p_nb_resolutions,
OPJ_UINT32 p_num_comps,
OPJ_UINT32 step_c = 1;
OPJ_UINT32 step_r = p_num_comps * step_c;
OPJ_UINT32 step_l = p_nb_resolutions * step_r;
- opj_bool loss = OPJ_FALSE;
+ OPJ_BOOL loss = OPJ_FALSE;
OPJ_UINT32 layno0 = 0;
packet_array = (OPJ_UINT32*) opj_calloc(step_l * p_num_layers, sizeof(OPJ_UINT32));
return tpnum;
}
-opj_bool opj_j2k_calculate_tp( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_calculate_tp( opj_j2k_t *p_j2k,
opj_cp_t *cp,
OPJ_UINT32 * p_nb_tiles,
opj_image_t *image,
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_soc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_soc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
#ifdef USE_JPWL
/* update markers struct */
/*
- opj_bool res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOC, p_stream_tell(p_stream) - 2, 2);
+ OPJ_BOOL res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOC, p_stream_tell(p_stream) - 2, 2);
*/
assert( 0 && "TODO" );
#endif /* USE_JPWL */
* @param p_stream FIXME DOC
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_soc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_soc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_siz( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_siz( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
* @param p_header_size the size of the data contained in the SIZ marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_siz(opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_siz(opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_com( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_com( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
* @param p_header_size the size of the data contained in the COM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_com ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_com ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_cod( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_cod( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
* @param p_header_size the size of the data contained in the COD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_cod ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_cod ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_coc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_coc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_comp_no,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
* @param p_header_size the size of the data contained in the COC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_coc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_coc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_qcd( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_qcd( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
* @param p_header_size the size of the data contained in the QCD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_qcd ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_qcd ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_qcc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_qcc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_comp_no,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
* @param p_header_size the size of the data contained in the QCC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_qcc( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_qcc( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_poc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_poc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
* @param p_header_size the size of the data contained in the POC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_poc ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_poc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_crg ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_crg ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_tlm ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_tlm ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
* @param p_header_size the size of the data contained in the TLM marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_plm ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_plm ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
* @param p_header_size the size of the data contained in the PLT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_plt ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_plt ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
}
#if 0
-opj_bool j2k_read_ppm_v2 (
+OPJ_BOOL j2k_read_ppm_v2 (
opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
}
#endif
-opj_bool j2k_read_ppm_v3 (
+OPJ_BOOL j2k_read_ppm_v3 (
opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
* @param p_header_size the size of the data contained in the PPT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_ppt ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_ppt ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_tlm( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_tlm( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_sot( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_sot( opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
const opj_stream_private_t *p_stream,
#ifdef USE_JPWL
/* update markers struct */
/*
- opj_bool res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOT, p_j2k->sot_start, len + 2);
+ OPJ_BOOL res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOT, p_j2k->sot_start, len + 2);
*/
assert( 0 && "TODO" );
#endif /* USE_JPWL */
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_sot ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_sot ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager )
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_sod( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_sod( opj_j2k_t *p_j2k,
opj_tcd_t * p_tile_coder,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
/* UniPG>> */
#ifdef USE_JPWL
/* update markers struct */
- /*opj_bool res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOD, p_j2k->sod_start, 2);
+ /*OPJ_BOOL res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_SOD, p_j2k->sod_start, 2);
*/
assert( 0 && "TODO" );
#endif /* USE_JPWL */
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_sod (opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_sod (opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
OPJ_BYTE ** l_current_data = 00;
opj_tcp_t * l_tcp = 00;
OPJ_UINT32 * l_tile_len = 00;
- opj_bool l_sot_length_pb_detected = OPJ_FALSE;
+ OPJ_BOOL l_sot_length_pb_detected = OPJ_FALSE;
/* preconditions */
assert(p_j2k != 00);
return OPJ_TRUE;
}
- opj_bool opj_j2k_write_rgn(opj_j2k_t *p_j2k,
+ OPJ_BOOL opj_j2k_write_rgn(opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_UINT32 nb_comps,
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_eoc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_eoc( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
#ifdef USE_JPWL
/* update markers struct */
/*
- opj_bool res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_EOC, p_stream_tell(p_stream) - 2, 2);
+ OPJ_BOOL res = j2k_add_marker(p_j2k->cstr_info, J2K_MS_EOC, p_stream_tell(p_stream) - 2, 2);
*/
#endif /* USE_JPWL */
* @param p_header_size the size of the data contained in the POC marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_rgn (opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_rgn (opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return 0;
}
-opj_bool opj_j2k_update_rates( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_update_rates( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_eoc ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_eoc ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
opj_tcd_t * l_tcd = 00;
OPJ_UINT32 l_nb_tiles;
opj_tcp_t * l_tcp = 00;
- opj_bool l_success;
+ OPJ_BOOL l_success;
/* preconditions */
assert(p_j2k != 00);
return OPJ_TRUE;
}
-opj_bool opj_j2k_get_end_header(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_get_end_header(opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_mct_data_group( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_mct_data_group( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_image_components(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_image_components(opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_regions( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_regions( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_epc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_epc( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_unk ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_unk ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
OPJ_UINT32 *output_marker,
opj_event_mgr_t * p_manager
/* Add the marker to the codestream index*/
if (l_marker_handler->id != J2K_MS_SOT)
{
- opj_bool res = opj_j2k_add_mhmarker(p_j2k->cstr_index, J2K_MS_UNK,
+ OPJ_BOOL res = opj_j2k_add_mhmarker(p_j2k->cstr_index, J2K_MS_UNK,
(OPJ_UINT32) opj_stream_tell(p_stream) - l_size_unk,
l_size_unk);
if (res == OPJ_FALSE) {
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_mct_record( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_mct_record( opj_j2k_t *p_j2k,
opj_mct_data_t * p_mct_record,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
* @param p_header_size the size of the data contained in the MCT marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_mct ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_mct ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_mcc_record( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_mcc_record( opj_j2k_t *p_j2k,
struct opj_simple_mcc_decorrelation_data * p_mcc_record,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_mcc ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_mcc ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager )
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_mco( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_mco( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager
)
* @param p_header_size the size of the data contained in the MCO marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_mco ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_mco ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_j2k_add_mct(opj_tcp_t * p_tcp, opj_image_t * p_image, OPJ_UINT32 p_index)
+OPJ_BOOL opj_j2k_add_mct(opj_tcp_t * p_tcp, opj_image_t * p_image, OPJ_UINT32 p_index)
{
OPJ_UINT32 i;
opj_simple_mcc_decorrelation_data_t * l_mcc_record;
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_cbd( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_cbd( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
* @param p_header_size the size of the data contained in the CBD marker.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_read_cbd ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_read_cbd ( opj_j2k_t *p_j2k,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
}
}
-static opj_bool opj_j2k_add_mhmarker(opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len)
+static OPJ_BOOL opj_j2k_add_mhmarker(opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len)
{
assert(cstr_index != 00);
return OPJ_TRUE;
}
-static opj_bool opj_j2k_add_tlmarker(OPJ_UINT32 tileno, opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len)
+static OPJ_BOOL opj_j2k_add_tlmarker(OPJ_UINT32 tileno, opj_codestream_index_t *cstr_index, OPJ_UINT32 type, OPJ_OFF_T pos, OPJ_UINT32 len)
{
assert(cstr_index != 00);
assert(cstr_index->tile_index != 00);
* -----------------------------------------------------------------------
*/
-opj_bool opj_j2k_end_decompress(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_end_decompress(opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_header( opj_stream_private_t *p_stream,
+OPJ_BOOL opj_j2k_read_header( opj_stream_private_t *p_stream,
opj_j2k_t* p_j2k,
opj_image_t** p_image,
opj_event_mgr_t* p_manager )
}
-opj_bool opj_j2k_mct_validation ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_mct_validation ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
- opj_bool l_is_valid = OPJ_TRUE;
+ OPJ_BOOL l_is_valid = OPJ_TRUE;
OPJ_UINT32 i,j;
/* preconditions */
return l_is_valid;
}
-opj_bool opj_j2k_setup_mct_encoding(opj_tcp_t * p_tcp, opj_image_t * p_image)
+OPJ_BOOL opj_j2k_setup_mct_encoding(opj_tcp_t * p_tcp, opj_image_t * p_image)
{
OPJ_UINT32 i;
OPJ_UINT32 l_indix = 1;
return OPJ_TRUE;
}
-opj_bool opj_j2k_build_decoder (opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_build_decoder (opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_build_encoder (opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_build_encoder (opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_encoding_validation ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_encoding_validation ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
- opj_bool l_is_valid = OPJ_TRUE;
+ OPJ_BOOL l_is_valid = OPJ_TRUE;
/* preconditions */
assert(p_j2k != 00);
return l_is_valid;
}
-opj_bool opj_j2k_decoding_validation ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_decoding_validation ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
{
- opj_bool l_is_valid = OPJ_TRUE;
+ OPJ_BOOL l_is_valid = OPJ_TRUE;
/* preconditions*/
assert(p_j2k != 00);
return l_is_valid;
}
-opj_bool opj_j2k_read_header_procedure( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_header_procedure( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager)
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_exec ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_exec ( opj_j2k_t * p_j2k,
opj_procedure_list_t * p_procedure_list,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
- opj_bool (** l_procedure) (opj_j2k_t * ,opj_stream_private_t *,opj_event_mgr_t *) = 00;
- opj_bool l_result = OPJ_TRUE;
+ OPJ_BOOL (** l_procedure) (opj_j2k_t * ,opj_stream_private_t *,opj_event_mgr_t *) = 00;
+ OPJ_BOOL l_result = OPJ_TRUE;
OPJ_UINT32 l_nb_proc, i;
/* preconditions*/
assert(p_manager != 00);
l_nb_proc = opj_procedure_list_get_nb_procedures(p_procedure_list);
- l_procedure = (opj_bool (**) (opj_j2k_t * ,opj_stream_private_t *,opj_event_mgr_t *)) opj_procedure_list_get_first_procedure(p_procedure_list);
+ l_procedure = (OPJ_BOOL (**) (opj_j2k_t * ,opj_stream_private_t *,opj_event_mgr_t *)) opj_procedure_list_get_first_procedure(p_procedure_list);
for (i=0;i<l_nb_proc;++i) {
l_result = l_result && ((*l_procedure) (p_j2k,p_stream,p_manager));
}
/* FIXME DOC*/
-static opj_bool opj_j2k_copy_default_tcp_and_create_tcd ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_copy_default_tcp_and_create_tcd ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
}
}
-opj_bool opj_j2k_read_tile_header( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_read_tile_header( opj_j2k_t * p_j2k,
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_go_on,
+ OPJ_BOOL * p_go_on,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_decode_tile ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_decode_tile ( opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
return OPJ_TRUE;
}
-opj_bool opj_j2k_update_image_data (opj_tcd_t * p_tcd, OPJ_BYTE * p_data, opj_image_t* p_output_image)
+OPJ_BOOL opj_j2k_update_image_data (opj_tcd_t * p_tcd, OPJ_BYTE * p_data, opj_image_t* p_output_image)
{
OPJ_UINT32 i,j,k = 0;
OPJ_UINT32 l_width_src,l_height_src;
return OPJ_TRUE;
}
-opj_bool opj_j2k_set_decode_area( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_set_decode_area( opj_j2k_t *p_j2k,
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,
}
}
-opj_bool opj_j2k_write_SPCod_SPCoc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_SPCod_SPCoc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_BYTE * p_data,
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_SPCod_SPCoc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_SPCod_SPCoc( opj_j2k_t *p_j2k,
OPJ_UINT32 compno,
OPJ_BYTE * p_header_data,
OPJ_UINT32 * p_header_size,
}
}
-opj_bool opj_j2k_write_SQcd_SQcc( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_SQcd_SQcc( opj_j2k_t *p_j2k,
OPJ_UINT32 p_tile_no,
OPJ_UINT32 p_comp_no,
OPJ_BYTE * p_data,
return OPJ_TRUE;
}
-opj_bool opj_j2k_read_SQcd_SQcc(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_read_SQcd_SQcc(opj_j2k_t *p_j2k,
OPJ_UINT32 p_comp_no,
OPJ_BYTE* p_header_data,
OPJ_UINT32 * p_header_size,
}
-void j2k_dump_image_header(opj_image_t* img_header, opj_bool dev_dump_flag, FILE* out_stream)
+void j2k_dump_image_header(opj_image_t* img_header, OPJ_BOOL dev_dump_flag, FILE* out_stream)
{
char tab[2];
fprintf(out_stream, "}\n");
}
-void j2k_dump_image_comp_header(opj_image_comp_t* comp_header, opj_bool dev_dump_flag, FILE* out_stream)
+void j2k_dump_image_comp_header(opj_image_comp_t* comp_header, OPJ_BOOL dev_dump_flag, FILE* out_stream)
{
char tab[3];
return l_cstr_index;
}
-opj_bool opj_j2k_allocate_tile_element_cstr_index(opj_j2k_t *p_j2k)
+OPJ_BOOL opj_j2k_allocate_tile_element_cstr_index(opj_j2k_t *p_j2k)
{
OPJ_UINT32 it_tile=0;
return OPJ_TRUE;
}
-opj_bool opj_j2k_decode_tiles ( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_decode_tiles ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager)
{
- opj_bool l_go_on = OPJ_TRUE;
+ OPJ_BOOL l_go_on = OPJ_TRUE;
OPJ_UINT32 l_current_tile_no;
OPJ_UINT32 l_data_size,l_max_data_size;
OPJ_INT32 l_tile_x0,l_tile_y0,l_tile_x1,l_tile_y1;
/*
* Read and decode one tile.
*/
-static opj_bool opj_j2k_decode_one_tile ( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_decode_one_tile ( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager)
{
- opj_bool l_go_on = OPJ_TRUE;
+ OPJ_BOOL l_go_on = OPJ_TRUE;
OPJ_UINT32 l_current_tile_no;
OPJ_UINT32 l_tile_no_to_dec;
OPJ_UINT32 l_data_size,l_max_data_size;
}
-opj_bool opj_j2k_decode(opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_decode(opj_j2k_t * p_j2k,
opj_stream_private_t * p_stream,
opj_image_t * p_image,
opj_event_mgr_t * p_manager)
return OPJ_TRUE;
}
-opj_bool opj_j2k_get_tile( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_get_tile( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager,
return OPJ_TRUE;
}
-opj_bool opj_j2k_set_decoded_resolution_factor(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_set_decoded_resolution_factor(opj_j2k_t *p_j2k,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager)
{
return OPJ_FALSE;
}
-opj_bool opj_j2k_encode_v2( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_encode_v2( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_end_compress( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_end_compress( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager)
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_start_compress(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_start_compress(opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_image_t * p_image,
opj_event_mgr_t * p_manager)
return OPJ_TRUE;
}
-opj_bool opj_j2k_pre_write_tile ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_pre_write_tile ( opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
}
}
-opj_bool opj_j2k_post_write_tile ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_post_write_tile ( opj_j2k_t * p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
opj_stream_private_t *p_stream,
opj_procedure_list_add_procedure(p_j2k->m_procedure_list,(opj_procedure)opj_j2k_update_rates);
}
-opj_bool opj_j2k_write_first_tile_part (opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_first_tile_part (opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_total_data_size,
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_all_tile_parts( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_all_tile_parts( opj_j2k_t *p_j2k,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_total_data_size,
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_updated_tlm( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_write_updated_tlm( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_j2k_end_encoding( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_end_encoding( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
/**
* Destroys the memory associated with the decoding of headers.
*/
-static opj_bool opj_j2k_destroy_header_memory ( opj_j2k_t * p_j2k,
+static OPJ_BOOL opj_j2k_destroy_header_memory ( opj_j2k_t * p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
return OPJ_TRUE;
}
-opj_bool opj_j2k_init_info( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_init_info( opj_j2k_t *p_j2k,
struct opj_stream_private *p_stream,
struct opj_event_mgr * p_manager )
{
* @param p_j2k J2K codec.
* @param p_manager the user event manager.
*/
-static opj_bool opj_j2k_create_tcd( opj_j2k_t *p_j2k,
+static OPJ_BOOL opj_j2k_create_tcd( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
return OPJ_TRUE;
}
-opj_bool opj_j2k_write_tile (opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_write_tile (opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
/* UniPG>> */
#ifdef USE_JPWL
/** enables writing of EPC in MH, thus activating JPWL */
- opj_bool epc_on;
+ OPJ_BOOL epc_on;
/** enables writing of EPB, in case of activated JPWL */
- opj_bool epb_on;
+ OPJ_BOOL epb_on;
/** enables writing of ESD, in case of activated JPWL */
- opj_bool esd_on;
+ OPJ_BOOL esd_on;
/** enables writing of informative techniques of ESD, in case of activated JPWL */
- opj_bool info_on;
+ OPJ_BOOL info_on;
/** enables writing of RED, in case of activated JPWL */
- opj_bool red_on;
+ OPJ_BOOL red_on;
/** error protection method for MH (0,1,16,32,37-128) */
int hprot_MH;
/** tile number of header protection specification (>=0) */
/** sensitivity methods for TPHs (-1,0-7) */
int sens_TPH[JPWL_MAX_NO_TILESPECS];
/** enables JPWL correction at the decoder */
- opj_bool correct;
+ OPJ_BOOL correct;
/** expected number of components at the decoder */
int exp_comps;
/** maximum number of tiles at the decoder */
* It is useful in the case of PSot is equal to zero. The sot length will be compute in the
* SOD reader function. FIXME NOT USED for the moment
*/
- opj_bool m_last_tile_part;
+ OPJ_BOOL m_last_tile_part;
/** to tell that a tile can be decoded. */
OPJ_UINT32 m_can_decode : 1;
OPJ_UINT32 m_discard_tiles : 1;
typedef struct opj_j2k
{
/* J2K codestream is decoded*/
- opj_bool m_is_decoder;
+ OPJ_BOOL m_is_decoder;
/* FIXME DOC*/
union
* Ends the decompression procedures and possibiliy add data to be read after the
* codestream.
*/
-opj_bool opj_j2k_end_decompress(opj_j2k_t *j2k,
+OPJ_BOOL opj_j2k_end_decompress(opj_j2k_t *j2k,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager);
*
* @return true if the box is valid.
*/
-opj_bool opj_j2k_read_header( opj_stream_private_t *p_stream,
+OPJ_BOOL opj_j2k_read_header( opj_stream_private_t *p_stream,
opj_j2k_t* p_j2k,
opj_image_t** p_image,
opj_event_mgr_t* p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-opj_bool opj_j2k_decode_tile ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_decode_tile ( opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-opj_bool opj_j2k_read_tile_header ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_read_tile_header ( opj_j2k_t * p_j2k,
OPJ_UINT32 * p_tile_index,
OPJ_UINT32 * p_data_size,
OPJ_INT32 * p_tile_x0,
OPJ_INT32 * p_tile_x1,
OPJ_INT32 * p_tile_y1,
OPJ_UINT32 * p_nb_comps,
- opj_bool * p_go_on,
+ OPJ_BOOL * p_go_on,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
*
* @return true if the area could be set.
*/
-opj_bool opj_j2k_set_decode_area( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_set_decode_area( opj_j2k_t *p_j2k,
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,
*@param dev_dump_flag flag to describe if we are in the case of this function is use outside j2k_dump function
*@param out_stream output stream where dump the elements.
*/
-void j2k_dump_image_header(opj_image_t* image, opj_bool dev_dump_flag, FILE* out_stream);
+void j2k_dump_image_header(opj_image_t* image, OPJ_BOOL dev_dump_flag, FILE* out_stream);
/**
* Dump a component image header structure.
*@param dev_dump_flag flag to describe if we are in the case of this function is use outside j2k_dump function
*@param out_stream output stream where dump the elements.
*/
-void j2k_dump_image_comp_header(opj_image_comp_t* comp, opj_bool dev_dump_flag, FILE* out_stream);
+void j2k_dump_image_comp_header(opj_image_comp_t* comp, OPJ_BOOL dev_dump_flag, FILE* out_stream);
/**
* Get the codestream info from a JPEG2000 codec.
* @param p_manager FIXME DOC
* @return FIXME DOC
*/
-opj_bool opj_j2k_decode(opj_j2k_t *j2k,
+OPJ_BOOL opj_j2k_decode(opj_j2k_t *j2k,
opj_stream_private_t *p_stream,
opj_image_t *p_image,
opj_event_mgr_t *p_manager);
-opj_bool opj_j2k_get_tile( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_get_tile( opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager,
OPJ_UINT32 tile_index );
-opj_bool opj_j2k_set_decoded_resolution_factor(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_set_decoded_resolution_factor(opj_j2k_t *p_j2k,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager);
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-opj_bool opj_j2k_write_tile ( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_write_tile ( opj_j2k_t * p_j2k,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
/**
* Encodes an image into a JPEG-2000 codestream
*/
-opj_bool opj_j2k_encode_v2( opj_j2k_t * p_j2k,
+OPJ_BOOL opj_j2k_encode_v2( opj_j2k_t * p_j2k,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
*
* @return true if the codec is valid.
*/
-opj_bool opj_j2k_start_compress(opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_start_compress(opj_j2k_t *p_j2k,
opj_stream_private_t *p_stream,
opj_image_t * p_image,
opj_event_mgr_t * p_manager);
* Ends the compression procedures and possibiliy add data to be read after the
* codestream.
*/
-opj_bool opj_j2k_end_compress( opj_j2k_t *p_j2k,
+OPJ_BOOL opj_j2k_end_compress( opj_j2k_t *p_j2k,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager);
-opj_bool opj_j2k_setup_mct_encoding (opj_tcp_t * p_tcp, opj_image_t * p_image);
+OPJ_BOOL opj_j2k_setup_mct_encoding (opj_tcp_t * p_tcp, opj_image_t * p_image);
#endif /* __J2K_H */
*
* @return true if the image header is valid, false else.
*/
-static opj_bool opj_jp2_read_ihdr( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_ihdr( opj_jp2_t *jp2,
OPJ_BYTE *p_image_header_data,
OPJ_UINT32 p_image_header_size,
opj_event_mgr_t * p_manager );
*
* @return true if the bpc header is valid, fale else.
*/
-static opj_bool opj_jp2_read_bpcc( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_bpcc( opj_jp2_t *jp2,
OPJ_BYTE * p_bpc_header_data,
OPJ_UINT32 p_bpc_header_size,
opj_event_mgr_t * p_manager );
-static opj_bool opj_jp2_read_cdef( opj_jp2_t * jp2,
+static OPJ_BOOL opj_jp2_read_cdef( opj_jp2_t * jp2,
OPJ_BYTE * p_cdef_header_data,
OPJ_UINT32 p_cdef_header_size,
opj_event_mgr_t * p_manager );
*
* @return true if writing was successful.
*/
-static opj_bool opj_jp2_write_ftyp( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_write_ftyp( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
*
* @return true if the FTYP box is valid.
*/
-static opj_bool opj_jp2_read_ftyp( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_ftyp( opj_jp2_t *jp2,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
-opj_bool opj_jp2_skip_jp2c( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_skip_jp2c( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
*
* @return true if the JP2 Header box was successfully reconized.
*/
-static opj_bool opj_jp2_read_jp2h( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_jp2h( opj_jp2_t *jp2,
OPJ_BYTE *p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager );
*
* @return true if writing was successful.
*/
-static opj_bool opj_jp2_write_jp2c( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_write_jp2c( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
* @param jp2 the jpeg2000 file codec.
* @param p_manager user event manager.
*/
-static opj_bool opj_jpip_write_iptr( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_iptr( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
* @param jp2 the jpeg2000 file codec.
* @param p_manager user event manager.
*/
-static opj_bool opj_jpip_write_cidx(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_cidx(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
* @param jp2 the jpeg2000 file codec.
* @param p_manager user event manager.
*/
-static opj_bool opj_jpip_write_fidx(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_fidx(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
#endif /* USE_JPIP */
*
* @return true if the file signature box is valid.
*/
-static opj_bool opj_jp2_read_jp(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_jp(opj_jp2_t *jp2,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
*
* @return true if writing was successful.
*/
-static opj_bool opj_jp2_write_jp( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_write_jp( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
*
* @return Returns true if successful, returns false otherwise
*/
-static opj_bool opj_jp2_read_pclr( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_pclr( opj_jp2_t *jp2,
OPJ_BYTE * p_pclr_header_data,
OPJ_UINT32 p_pclr_header_size,
opj_event_mgr_t * p_manager );
* @return Returns true if successful, returns false otherwise
*/
-static opj_bool opj_jp2_read_cmap( opj_jp2_t * jp2,
+static OPJ_BOOL opj_jp2_read_cmap( opj_jp2_t * jp2,
OPJ_BYTE * p_cmap_header_data,
OPJ_UINT32 p_cmap_header_size,
opj_event_mgr_t * p_manager );
*
* @return true if the bpc header is valid, fale else.
*/
-static opj_bool opj_jp2_read_colr( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_colr( opj_jp2_t *jp2,
OPJ_BYTE * p_colr_header_data,
OPJ_UINT32 p_colr_header_size,
opj_event_mgr_t * p_manager );
*
* @return true if the box is valid.
*/
-static opj_bool opj_jp2_read_header_procedure( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_header_procedure( opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager );
*
* @return true if all the procedures were successfully executed.
*/
-static opj_bool opj_jp2_exec ( opj_jp2_t * jp2,
+static OPJ_BOOL opj_jp2_exec ( opj_jp2_t * jp2,
opj_procedure_list_t * p_procedure_list,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager );
*
* @return true if the box is reconized, false otherwise
*/
-static opj_bool opj_jp2_read_boxhdr(opj_jp2_box_t *box,
+static OPJ_BOOL opj_jp2_read_boxhdr(opj_jp2_box_t *box,
OPJ_UINT32 * p_number_bytes_read,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager);
*/
static void opj_jp2_setup_header_writing (opj_jp2_t *jp2);
-opj_bool opj_jp2_default_validation ( opj_jp2_t * jp2,
+OPJ_BOOL opj_jp2_default_validation ( opj_jp2_t * jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager );
*
* @return true if the box is reconized, false otherwise
*/
-static opj_bool opj_jp2_read_boxhdr_char( opj_jp2_box_t *box,
+static OPJ_BOOL opj_jp2_read_boxhdr_char( opj_jp2_box_t *box,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_number_bytes_read,
OPJ_UINT32 p_box_max_size,
/* ----------------------------------------------------------------------- */
- opj_bool opj_jp2_read_boxhdr(opj_jp2_box_t *box,
+ OPJ_BOOL opj_jp2_read_boxhdr(opj_jp2_box_t *box,
OPJ_UINT32 * p_number_bytes_read,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager
}
#endif
-opj_bool opj_jp2_read_ihdr( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_read_ihdr( opj_jp2_t *jp2,
OPJ_BYTE *p_image_header_data,
OPJ_UINT32 p_image_header_size,
opj_event_mgr_t * p_manager )
return l_bpcc_data;
}
-opj_bool opj_jp2_read_bpcc( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_read_bpcc( opj_jp2_t *jp2,
OPJ_BYTE * p_bpc_header_data,
OPJ_UINT32 p_bpc_header_size,
opj_event_mgr_t * p_manager
}/* apply_pclr() */
-opj_bool opj_jp2_read_pclr( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_read_pclr( opj_jp2_t *jp2,
OPJ_BYTE * p_pclr_header_data,
OPJ_UINT32 p_pclr_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_jp2_read_cmap( opj_jp2_t * jp2,
+OPJ_BOOL opj_jp2_read_cmap( opj_jp2_t * jp2,
OPJ_BYTE * p_cmap_header_data,
OPJ_UINT32 p_cmap_header_size,
opj_event_mgr_t * p_manager
}/* jp2_apply_cdef() */
-opj_bool opj_jp2_read_cdef( opj_jp2_t * jp2,
+OPJ_BOOL opj_jp2_read_cdef( opj_jp2_t * jp2,
OPJ_BYTE * p_cdef_header_data,
OPJ_UINT32 p_cdef_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_jp2_read_colr( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_read_colr( opj_jp2_t *jp2,
OPJ_BYTE * p_colr_header_data,
OPJ_UINT32 p_colr_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_jp2_decode(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_decode(opj_jp2_t *jp2,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager)
return OPJ_TRUE;
}
-opj_bool opj_jp2_write_jp2h(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_write_jp2h(opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager
)
OPJ_INT32 i, l_nb_pass;
/* size of data for super box*/
OPJ_INT32 l_jp2h_size = 8;
- opj_bool l_result = OPJ_TRUE;
+ OPJ_BOOL l_result = OPJ_TRUE;
/* to store the data of the super box */
OPJ_BYTE l_jp2h_data [8];
return l_result;
}
-opj_bool opj_jp2_write_ftyp(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_write_ftyp(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
OPJ_UINT32 i;
OPJ_UINT32 l_ftyp_size = 16 + 4 * jp2->numcl;
OPJ_BYTE * l_ftyp_data, * l_current_data_ptr;
- opj_bool l_result;
+ OPJ_BOOL l_result;
/* preconditions */
assert(cio != 00);
return l_result;
}
-opj_bool opj_jp2_write_jp2c(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_write_jp2c(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-opj_bool opj_jp2_write_jp( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_write_jp( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
jp2->jpip_on = parameters->jpip_on;
}
-opj_bool opj_jp2_encode(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_encode(opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager)
{
return opj_j2k_encode_v2(jp2->j2k, stream, p_manager);
}
-opj_bool opj_jp2_end_decompress(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_end_decompress(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager
)
return opj_j2k_end_decompress(jp2->j2k, cio, p_manager);
}
-opj_bool opj_jp2_end_compress( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_end_compress( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager
)
/* DEVELOPER CORNER, add your custom procedures */
}
-opj_bool opj_jp2_default_validation ( opj_jp2_t * jp2,
+OPJ_BOOL opj_jp2_default_validation ( opj_jp2_t * jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager
)
{
- opj_bool l_is_valid = OPJ_TRUE;
+ OPJ_BOOL l_is_valid = OPJ_TRUE;
OPJ_UINT32 i;
/* preconditions */
return l_is_valid;
}
-opj_bool opj_jp2_read_header_procedure( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_read_header_procedure( opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager
)
*
* @return true if all the procedures were successfully executed.
*/
-static opj_bool opj_jp2_exec ( opj_jp2_t * jp2,
+static OPJ_BOOL opj_jp2_exec ( opj_jp2_t * jp2,
opj_procedure_list_t * p_procedure_list,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager
)
{
- opj_bool (** l_procedure) (opj_jp2_t * jp2, opj_stream_private_t *, opj_event_mgr_t *) = 00;
- opj_bool l_result = OPJ_TRUE;
+ OPJ_BOOL (** l_procedure) (opj_jp2_t * jp2, opj_stream_private_t *, opj_event_mgr_t *) = 00;
+ OPJ_BOOL l_result = OPJ_TRUE;
OPJ_UINT32 l_nb_proc, i;
/* preconditions */
assert(p_manager != 00);
l_nb_proc = opj_procedure_list_get_nb_procedures(p_procedure_list);
- l_procedure = (opj_bool (**) (opj_jp2_t * jp2, opj_stream_private_t *, opj_event_mgr_t *)) opj_procedure_list_get_first_procedure(p_procedure_list);
+ l_procedure = (OPJ_BOOL (**) (opj_jp2_t * jp2, opj_stream_private_t *, opj_event_mgr_t *)) opj_procedure_list_get_first_procedure(p_procedure_list);
for (i=0;i<l_nb_proc;++i) {
l_result = l_result && (*l_procedure) (jp2,stream,p_manager);
return l_result;
}
-opj_bool opj_jp2_start_compress(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_start_compress(opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_image_t * p_image,
opj_event_mgr_t * p_manager
*
* @return true if the file signature box is valid.
*/
-static opj_bool opj_jp2_read_jp(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_jp(opj_jp2_t *jp2,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
*
* @return true if the FTYP box is valid.
*/
-static opj_bool opj_jp2_read_ftyp( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_ftyp( opj_jp2_t *jp2,
OPJ_BYTE * p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_jp2_skip_jp2c( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_skip_jp2c( opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-static opj_bool opj_jpip_skip_iptr( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_skip_iptr( opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager )
{
*
* @return true if the JP2 Header box was successfully reconized.
*/
-static opj_bool opj_jp2_read_jp2h( opj_jp2_t *jp2,
+static OPJ_BOOL opj_jp2_read_jp2h( opj_jp2_t *jp2,
OPJ_BYTE *p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager
return OPJ_TRUE;
}
-opj_bool opj_jp2_read_boxhdr_char( opj_jp2_box_t *box,
+OPJ_BOOL opj_jp2_read_boxhdr_char( opj_jp2_box_t *box,
OPJ_BYTE * p_data,
OPJ_UINT32 * p_number_bytes_read,
OPJ_UINT32 p_box_max_size,
return OPJ_TRUE;
}
-opj_bool opj_jp2_read_header( opj_stream_private_t *p_stream,
+OPJ_BOOL opj_jp2_read_header( opj_stream_private_t *p_stream,
opj_jp2_t *jp2,
opj_image_t ** p_image,
opj_event_mgr_t * p_manager
/* DEVELOPER CORNER, add your custom procedures */
}
-opj_bool opj_jp2_read_tile_header ( opj_jp2_t * p_jp2,
+OPJ_BOOL opj_jp2_read_tile_header ( opj_jp2_t * p_jp2,
OPJ_UINT32 * p_tile_index,
OPJ_UINT32 * p_data_size,
OPJ_INT32 * p_tile_x0,
OPJ_INT32 * p_tile_x1,
OPJ_INT32 * p_tile_y1,
OPJ_UINT32 * p_nb_comps,
- opj_bool * p_go_on,
+ OPJ_BOOL * p_go_on,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager
)
p_manager);
}
-opj_bool opj_jp2_write_tile ( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_write_tile ( opj_jp2_t *p_jp2,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
return opj_j2k_write_tile (p_jp2->j2k,p_tile_index,p_data,p_data_size,p_stream,p_manager);
}
-opj_bool opj_jp2_decode_tile ( opj_jp2_t * p_jp2,
+OPJ_BOOL opj_jp2_decode_tile ( opj_jp2_t * p_jp2,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
}
}
-opj_bool opj_jp2_set_decode_area( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_set_decode_area( opj_jp2_t *p_jp2,
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,
return opj_j2k_set_decode_area(p_jp2->j2k, p_image, p_start_x, p_start_y, p_end_x, p_end_y, p_manager);
}
-opj_bool opj_jp2_get_tile( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_get_tile( opj_jp2_t *p_jp2,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager,
/* JP2 encoder interface */
/* ----------------------------------------------------------------------- */
-opj_jp2_t* opj_jp2_create(opj_bool p_is_decoder)
+opj_jp2_t* opj_jp2_create(OPJ_BOOL p_is_decoder)
{
opj_jp2_t *jp2 = (opj_jp2_t*)opj_malloc(sizeof(opj_jp2_t));
if (jp2) {
return j2k_get_cstr_info(p_jp2->j2k);
}
-opj_bool opj_jp2_set_decoded_resolution_factor(opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_set_decoded_resolution_factor(opj_jp2_t *p_jp2,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager)
{
/* JPIP specific */
#ifdef USE_JPIP
-static opj_bool opj_jpip_write_iptr(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_iptr(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-static opj_bool opj_jpip_write_fidx(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_fidx(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
return OPJ_TRUE;
}
-static opj_bool opj_jpip_write_cidx(opj_jp2_t *jp2,
+static OPJ_BOOL opj_jpip_write_cidx(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager )
{
*/
OPJ_OFF_T j2k_codestream_offset;
OPJ_OFF_T jpip_iptr_offset;
- opj_bool jpip_on;
+ OPJ_BOOL jpip_on;
OPJ_UINT32 jp2_state;
OPJ_UINT32 jp2_img_state;
opj_jp2_color_t color;
- opj_bool ignore_pclr_cmap_cdef;
+ OPJ_BOOL ignore_pclr_cmap_cdef;
}
opj_jp2_t;
/* marker value */
OPJ_UINT32 id;
/* action linked to the marker */
- opj_bool (*handler) ( opj_jp2_t *jp2,
+ OPJ_BOOL (*handler) ( opj_jp2_t *jp2,
OPJ_BYTE *p_header_data,
OPJ_UINT32 p_header_size,
opj_event_mgr_t * p_manager);
*
* @return true if writing was successful.
*/
-opj_bool opj_jp2_write_jp2h(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_write_jp2h(opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager );
*
* @return Returns a decoded image if successful, returns NULL otherwise
*/
-opj_bool opj_jp2_decode(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_decode(opj_jp2_t *jp2,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager);
@param p_manager event manager
@return Returns true if successful, returns false otherwise
*/
-opj_bool opj_jp2_encode( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_encode( opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_event_mgr_t * p_manager);
*
* @return true if the codec is valid.
*/
-opj_bool opj_jp2_start_compress(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_start_compress(opj_jp2_t *jp2,
opj_stream_private_t *stream,
opj_image_t * p_image,
opj_event_mgr_t * p_manager);
* Ends the compression procedures and possibiliy add data to be read after the
* codestream.
*/
-opj_bool opj_jp2_end_compress( opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_end_compress( opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager);
* Ends the decompression procedures and possibiliy add data to be read after the
* codestream.
*/
-opj_bool opj_jp2_end_decompress(opj_jp2_t *jp2,
+OPJ_BOOL opj_jp2_end_decompress(opj_jp2_t *jp2,
opj_stream_private_t *cio,
opj_event_mgr_t * p_manager);
*
* @return true if the box is valid.
*/
-opj_bool opj_jp2_read_header( opj_stream_private_t *p_stream,
+OPJ_BOOL opj_jp2_read_header( opj_stream_private_t *p_stream,
opj_jp2_t *jp2,
opj_image_t ** p_image,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-opj_bool opj_jp2_read_tile_header ( opj_jp2_t * p_jp2,
+OPJ_BOOL opj_jp2_read_tile_header ( opj_jp2_t * p_jp2,
OPJ_UINT32 * p_tile_index,
OPJ_UINT32 * p_data_size,
OPJ_INT32 * p_tile_x0,
OPJ_INT32 * p_tile_x1,
OPJ_INT32 * p_tile_y1,
OPJ_UINT32 * p_nb_comps,
- opj_bool * p_go_on,
+ OPJ_BOOL * p_go_on,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager );
* @param p_stream the stream to write data to.
* @param p_manager the user event manager.
*/
-opj_bool opj_jp2_write_tile ( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_write_tile ( opj_jp2_t *p_jp2,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
*
* @return FIXME DOC
*/
-opj_bool opj_jp2_decode_tile ( opj_jp2_t * p_jp2,
+OPJ_BOOL opj_jp2_decode_tile ( opj_jp2_t * p_jp2,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
*
* @return an empty jpeg2000 file codec.
*/
-opj_jp2_t* opj_jp2_create (opj_bool p_is_decoder);
+opj_jp2_t* opj_jp2_create (OPJ_BOOL p_is_decoder);
/**
Destroy a JP2 decompressor handle
*
* @return true if the area could be set.
*/
-opj_bool opj_jp2_set_decode_area( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_set_decode_area( opj_jp2_t *p_jp2,
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,
/**
*
*/
-opj_bool opj_jp2_get_tile( opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_get_tile( opj_jp2_t *p_jp2,
opj_stream_private_t *p_stream,
opj_image_t* p_image,
opj_event_mgr_t * p_manager,
/**
*
*/
-opj_bool opj_jp2_set_decoded_resolution_factor(opj_jp2_t *p_jp2,
+OPJ_BOOL opj_jp2_set_decoded_resolution_factor(opj_jp2_t *p_jp2,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager);
}
-opj_bool opj_mct_encode_custom(
+OPJ_BOOL opj_mct_encode_custom(
OPJ_BYTE * pCodingdata,
OPJ_UINT32 n,
OPJ_BYTE ** pData,
return OPJ_TRUE;
}
-opj_bool opj_mct_decode_custom(
+OPJ_BOOL opj_mct_decode_custom(
OPJ_BYTE * pDecodingData,
OPJ_UINT32 n,
OPJ_BYTE ** pData,
@param is_signed tells if the data is signed
@return OPJ_FALSE if function encounter a problem, OPJ_TRUE otherwise
*/
-opj_bool opj_mct_encode_custom(
+OPJ_BOOL opj_mct_encode_custom(
OPJ_BYTE * p_coding_data,
OPJ_UINT32 n,
OPJ_BYTE ** p_data,
@param isSigned tells if the data is signed
@return OPJ_FALSE if function encounter a problem, OPJ_TRUE otherwise
*/
-opj_bool opj_mct_decode_custom(
+OPJ_BOOL opj_mct_decode_custom(
OPJ_BYTE * pDecodingData,
OPJ_UINT32 n,
OPJ_BYTE ** pData,
}
}
-opj_bool opj_mqc_init_dec(opj_mqc_t *mqc, OPJ_BYTE *bp, OPJ_UINT32 len) {
+OPJ_BOOL opj_mqc_init_dec(opj_mqc_t *mqc, OPJ_BYTE *bp, OPJ_UINT32 len) {
opj_mqc_setcurctx(mqc, 0);
mqc->start = bp;
mqc->end = bp + len;
@param bp Pointer to the start of the buffer from which the bytes will be read
@param len Length of the input buffer
*/
-opj_bool opj_mqc_init_dec(opj_mqc_t *mqc, OPJ_BYTE *bp, OPJ_UINT32 len);
+OPJ_BOOL opj_mqc_init_dec(opj_mqc_t *mqc, OPJ_BYTE *bp, OPJ_UINT32 len);
/**
Decode a symbol
@param mqc MQC handle
typedef struct opj_decompression
{
/** Main header reading function handler*/
- opj_bool (*opj_read_header) ( struct opj_stream_private * cio,
+ OPJ_BOOL (*opj_read_header) ( struct opj_stream_private * cio,
void * p_codec,
opj_image_t **p_image,
struct opj_event_mgr * p_manager);
/** Decoding function */
- opj_bool (*opj_decode) ( void * p_codec,
+ OPJ_BOOL (*opj_decode) ( void * p_codec,
struct opj_stream_private *p_cio,
opj_image_t *p_image,
struct opj_event_mgr * p_manager);
/** FIXME DOC */
- opj_bool (*opj_read_tile_header)( void * p_codec,
+ OPJ_BOOL (*opj_read_tile_header)( void * p_codec,
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,
+ OPJ_BOOL * p_should_go_on,
struct opj_stream_private *p_cio,
struct opj_event_mgr * p_manager);
/** FIXME DOC */
- opj_bool (*opj_decode_tile_data)( void * p_codec,
+ OPJ_BOOL (*opj_decode_tile_data)( void * p_codec,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
struct opj_stream_private *p_cio,
struct opj_event_mgr * p_manager);
/** Reading function used after codestream if necessary */
- opj_bool (* opj_end_decompress) ( void *p_codec,
+ OPJ_BOOL (* opj_end_decompress) ( void *p_codec,
struct opj_stream_private *cio,
struct opj_event_mgr * p_manager);
/** Codec destroy function handler*/
/** Setup decoder function handler */
void (*opj_setup_decoder) (void * p_codec, opj_dparameters_t * p_param);
/** Set decode area function handler */
- opj_bool (*opj_set_decode_area) ( void * p_codec,
+ OPJ_BOOL (*opj_set_decode_area) ( void * p_codec,
opj_image_t* p_image,
OPJ_INT32 p_start_x, OPJ_INT32 p_end_x,
OPJ_INT32 p_start_y, OPJ_INT32 p_end_y,
struct opj_event_mgr * p_manager);
/** Get tile function */
- opj_bool (*opj_get_decoded_tile) ( void *p_codec,
+ OPJ_BOOL (*opj_get_decoded_tile) ( void *p_codec,
opj_stream_private_t *p_cio,
opj_image_t *p_image,
struct opj_event_mgr * p_manager,
OPJ_UINT32 tile_index);
/** Set the decoded resolution factor */
- opj_bool (*opj_set_decoded_resolution_factor) ( void * p_codec,
+ OPJ_BOOL (*opj_set_decoded_resolution_factor) ( void * p_codec,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager);
*/
typedef struct opj_compression
{
- opj_bool (* opj_start_compress) ( void *p_codec,
+ OPJ_BOOL (* opj_start_compress) ( void *p_codec,
struct opj_stream_private *cio,
struct opj_image * p_image,
struct opj_event_mgr * p_manager);
- opj_bool (* opj_encode) ( void * p_codec,
+ OPJ_BOOL (* opj_encode) ( void * p_codec,
struct opj_stream_private *p_cio,
struct opj_event_mgr * p_manager);
- opj_bool (* opj_write_tile) ( void * p_codec,
+ OPJ_BOOL (* opj_write_tile) ( void * p_codec,
OPJ_UINT32 p_tile_index,
OPJ_BYTE * p_data,
OPJ_UINT32 p_data_size,
struct opj_stream_private * p_cio,
struct opj_event_mgr * p_manager);
- opj_bool (* opj_end_compress) ( void * p_codec,
+ OPJ_BOOL (* opj_end_compress) ( void * p_codec,
struct opj_stream_private *p_cio,
struct opj_event_mgr * p_manager);
/** Event handler */
opj_event_mgr_t m_event_mgr;
/** Flag to indicate if the codec is used to decode or encode*/
- opj_bool is_decompressor;
+ OPJ_BOOL is_decompressor;
void (*opj_dump_codec) (void * p_codec, OPJ_INT32 info_flag, FILE* output_stream);
opj_codestream_info_v2_t* (*opj_get_codec_info)(void* p_codec);
opj_codestream_index_t* (*opj_get_codec_index)(void* p_codec);
/* ---------------------------------------------------------------------- */
/* Functions to set the message handlers */
-opj_bool OPJ_CALLCONV opj_set_info_handler( opj_codec_t * p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_set_info_handler( opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data)
{
return OPJ_TRUE;
}
-opj_bool OPJ_CALLCONV opj_set_warning_handler( opj_codec_t * p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_set_warning_handler( opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data)
{
return OPJ_TRUE;
}
-opj_bool OPJ_CALLCONV opj_set_error_handler(opj_codec_t * p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_set_error_handler(opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data)
{
return p_nb_bytes;
}
-static opj_bool opj_seek_from_file (OPJ_OFF_T p_nb_bytes, FILE * p_user_data)
+static OPJ_BOOL opj_seek_from_file (OPJ_OFF_T p_nb_bytes, FILE * p_user_data)
{
if (OPJ_FSEEK(p_user_data,p_nb_bytes,SEEK_SET)) {
return OPJ_FALSE;
l_codec->opj_get_codec_index = (opj_codestream_index_t* (*) (void*) ) j2k_get_cstr_index;
l_codec->m_codec_data.m_decompression.opj_decode =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
opj_image_t*, struct opj_event_mgr * )) opj_j2k_decode;
l_codec->m_codec_data.m_decompression.opj_end_decompress =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
struct opj_event_mgr *)) opj_j2k_end_decompress;
l_codec->m_codec_data.m_decompression.opj_read_header =
- (opj_bool (*) ( struct opj_stream_private *,
+ (OPJ_BOOL (*) ( struct opj_stream_private *,
void *,
opj_image_t **,
struct opj_event_mgr * )) opj_j2k_read_header;
(void (*) (void * , opj_dparameters_t * )) opj_j2k_setup_decoder;
l_codec->m_codec_data.m_decompression.opj_read_tile_header =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
OPJ_UINT32*,
OPJ_UINT32*,
OPJ_INT32*, OPJ_INT32*,
OPJ_INT32*, OPJ_INT32*,
OPJ_UINT32*,
- opj_bool*,
+ OPJ_BOOL*,
struct opj_stream_private *,
struct opj_event_mgr * )) opj_j2k_read_tile_header;
l_codec->m_codec_data.m_decompression.opj_decode_tile_data =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
OPJ_UINT32,
OPJ_BYTE*,
OPJ_UINT32,
struct opj_event_mgr *)) opj_j2k_decode_tile;
l_codec->m_codec_data.m_decompression.opj_set_decode_area =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
opj_image_t*,
OPJ_INT32, OPJ_INT32, OPJ_INT32, OPJ_INT32,
struct opj_event_mgr *)) opj_j2k_set_decode_area;
l_codec->m_codec_data.m_decompression.opj_get_decoded_tile =
- (opj_bool (*) ( void *p_codec,
+ (OPJ_BOOL (*) ( void *p_codec,
opj_stream_private_t *p_cio,
opj_image_t *p_image,
struct opj_event_mgr * p_manager,
OPJ_UINT32 tile_index)) opj_j2k_get_tile;
l_codec->m_codec_data.m_decompression.opj_set_decoded_resolution_factor =
- (opj_bool (*) ( void * p_codec,
+ (OPJ_BOOL (*) ( void * p_codec,
OPJ_UINT32 res_factor,
struct opj_event_mgr * p_manager)) opj_j2k_set_decoded_resolution_factor;
l_codec->opj_get_codec_index = (opj_codestream_index_t* (*) (void*) ) jp2_get_cstr_index;
l_codec->m_codec_data.m_decompression.opj_decode =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
opj_image_t*,
struct opj_event_mgr * )) opj_jp2_decode;
l_codec->m_codec_data.m_decompression.opj_end_decompress =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
struct opj_event_mgr *)) opj_jp2_end_decompress;
l_codec->m_codec_data.m_decompression.opj_read_header =
- (opj_bool (*) ( struct opj_stream_private *,
+ (OPJ_BOOL (*) ( struct opj_stream_private *,
void *,
opj_image_t **,
struct opj_event_mgr * )) opj_jp2_read_header;
l_codec->m_codec_data.m_decompression.opj_read_tile_header =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
OPJ_UINT32*,
OPJ_UINT32*,
OPJ_INT32*,
OPJ_INT32 * ,
OPJ_INT32 * ,
OPJ_UINT32 * ,
- opj_bool *,
+ OPJ_BOOL *,
struct opj_stream_private *,
struct opj_event_mgr * )) opj_jp2_read_tile_header;
l_codec->m_codec_data.m_decompression.opj_decode_tile_data =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
OPJ_UINT32,OPJ_BYTE*,OPJ_UINT32,
struct opj_stream_private *,
struct opj_event_mgr * )) opj_jp2_decode_tile;
(void (*) (void * ,opj_dparameters_t * )) opj_jp2_setup_decoder;
l_codec->m_codec_data.m_decompression.opj_set_decode_area =
- (opj_bool (*) ( void *,
+ (OPJ_BOOL (*) ( void *,
opj_image_t*,
OPJ_INT32,OPJ_INT32,OPJ_INT32,OPJ_INT32,
struct opj_event_mgr * )) opj_jp2_set_decode_area;
l_codec->m_codec_data.m_decompression.opj_get_decoded_tile =
- (opj_bool (*) ( void *p_codec,
+ (OPJ_BOOL (*) ( void *p_codec,
opj_stream_private_t *p_cio,
opj_image_t *p_image,
struct opj_event_mgr * p_manager,
OPJ_UINT32 tile_index)) opj_jp2_get_tile;
l_codec->m_codec_data.m_decompression.opj_set_decoded_resolution_factor =
- (opj_bool (*) ( void * p_codec,
+ (OPJ_BOOL (*) ( void * p_codec,
OPJ_UINT32 res_factor,
opj_event_mgr_t * p_manager)) opj_jp2_set_decoded_resolution_factor;
}
}
-opj_bool OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec,
opj_dparameters_t *parameters
)
{
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_read_header ( opj_stream_t *p_stream,
+OPJ_BOOL OPJ_CALLCONV opj_read_header ( opj_stream_t *p_stream,
opj_codec_t *p_codec,
opj_image_t **p_image )
{
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_decode( opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_decode( opj_codec_t *p_codec,
opj_stream_t *p_stream,
opj_image_t* p_image)
{
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_set_decode_area( opj_codec_t *p_codec,
+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
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_read_tile_header( opj_codec_t *p_codec,
+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)
+ OPJ_BOOL * p_should_go_on)
{
if (p_codec && p_stream && p_data_size && p_tile_index) {
opj_codec_private_t * l_codec = (opj_codec_private_t *) p_codec;
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_decode_tile_data( opj_codec_t *p_codec,
+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,
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_get_decoded_tile( opj_codec_t *p_codec,
+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)
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_set_decoded_resolution_factor(opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_set_decoded_resolution_factor(opj_codec_t *p_codec,
OPJ_UINT32 res_factor )
{
opj_codec_private_t * l_codec = (opj_codec_private_t *) p_codec;
switch(p_format) {
case OPJ_CODEC_J2K:
- l_codec->m_codec_data.m_compression.opj_encode = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_encode = (OPJ_BOOL (*) (void *,
struct opj_stream_private *,
struct opj_event_mgr * )) opj_j2k_encode_v2;
- l_codec->m_codec_data.m_compression.opj_end_compress = (opj_bool (*) ( void *,
+ l_codec->m_codec_data.m_compression.opj_end_compress = (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
struct opj_event_mgr *)) opj_j2k_end_compress;
- l_codec->m_codec_data.m_compression.opj_start_compress = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_start_compress = (OPJ_BOOL (*) (void *,
struct opj_stream_private *,
struct opj_image * ,
struct opj_event_mgr *)) opj_j2k_start_compress;
- l_codec->m_codec_data.m_compression.opj_write_tile = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_write_tile = (OPJ_BOOL (*) (void *,
OPJ_UINT32,
OPJ_BYTE*,
OPJ_UINT32,
case OPJ_CODEC_JP2:
/* get a JP2 decoder handle */
- l_codec->m_codec_data.m_compression.opj_encode = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_encode = (OPJ_BOOL (*) (void *,
struct opj_stream_private *,
struct opj_event_mgr * )) opj_jp2_encode;
- l_codec->m_codec_data.m_compression.opj_end_compress = (opj_bool (*) ( void *,
+ l_codec->m_codec_data.m_compression.opj_end_compress = (OPJ_BOOL (*) ( void *,
struct opj_stream_private *,
struct opj_event_mgr *)) opj_jp2_end_compress;
- l_codec->m_codec_data.m_compression.opj_start_compress = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_start_compress = (OPJ_BOOL (*) (void *,
struct opj_stream_private *,
struct opj_image * ,
struct opj_event_mgr *)) opj_jp2_start_compress;
- l_codec->m_codec_data.m_compression.opj_write_tile = (opj_bool (*) (void *,
+ l_codec->m_codec_data.m_compression.opj_write_tile = (OPJ_BOOL (*) (void *,
OPJ_UINT32,
OPJ_BYTE*,
OPJ_UINT32,
}
}
-opj_bool OPJ_CALLCONV opj_setup_encoder(opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_setup_encoder(opj_codec_t *p_codec,
opj_cparameters_t *parameters,
opj_image_t *p_image)
{
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_start_compress ( opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_start_compress ( opj_codec_t *p_codec,
opj_image_t * p_image,
opj_stream_t *p_stream)
{
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_encode(opj_codec_t *p_info, opj_stream_t *p_stream)
+OPJ_BOOL OPJ_CALLCONV opj_encode(opj_codec_t *p_info, opj_stream_t *p_stream)
{
if (p_info && p_stream) {
opj_codec_private_t * l_codec = (opj_codec_private_t *) p_info;
}
-opj_bool OPJ_CALLCONV opj_end_compress (opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_end_compress (opj_codec_t *p_codec,
opj_stream_t *p_stream)
{
if (p_codec && p_stream) {
}
-opj_bool OPJ_CALLCONV opj_end_decompress ( opj_codec_t *p_codec,
+OPJ_BOOL OPJ_CALLCONV opj_end_decompress ( opj_codec_t *p_codec,
opj_stream_t *p_stream)
{
if (p_codec && p_stream) {
return OPJ_FALSE;
}
-opj_bool OPJ_CALLCONV opj_set_MCT(opj_cparameters_t *parameters,
+OPJ_BOOL OPJ_CALLCONV opj_set_MCT(opj_cparameters_t *parameters,
OPJ_FLOAT32 * pEncodingMatrix,
OPJ_INT32 * p_dc_shift,OPJ_UINT32 pNbComp)
{
return OPJ_TRUE;
}
-opj_bool OPJ_CALLCONV opj_write_tile ( opj_codec_t *p_codec,
+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* OPJ_CALLCONV opj_stream_create_default_file_stream (FILE * p_file, opj_bool p_is_read_stream)
+opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream (FILE * p_file, OPJ_BOOL p_is_read_stream)
{
return opj_stream_create_file_stream(p_file,OPJ_J2K_STREAM_CHUNK_SIZE,p_is_read_stream);
}
opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream ( FILE * p_file,
OPJ_SIZE_T p_size,
- opj_bool p_is_read_stream)
+ OPJ_BOOL p_is_read_stream)
{
opj_stream_t* l_stream = 00;
#endif /* OPJ_EXPORTS */
#endif /* !OPJ_STATIC || !_WIN32 */
-typedef int opj_bool; /*FIXME it should be to follow the name of others OPJ_TYPE -> OPJ_BOOL*/
+typedef int OPJ_BOOL; /*FIXME it should be to follow the name of others OPJ_TYPE -> OPJ_BOOL*/
#define OPJ_TRUE 1
#define OPJ_FALSE 0
* */
typedef struct opj_cparameters {
/** size of tile: tile_size_on = false (not in argument) or = true (in argument) */
- opj_bool tile_size_on;
+ OPJ_BOOL tile_size_on;
/** XTOsiz */
int cp_tx0;
/** YTOsiz */
/**@name JPWL encoding parameters */
/*@{*/
/** enables writing of EPC in MH, thus activating JPWL */
- opj_bool jpwl_epc_on;
+ OPJ_BOOL jpwl_epc_on;
/** error protection method for MH (0,1,16,32,37-128) */
int jpwl_hprot_MH;
/** tile number of header protection specification (>=0) */
/** MCT (multiple component transform) */
char tcp_mct;
/** Enable JPIP indexing*/
- opj_bool jpip_on;
+ OPJ_BOOL jpip_on;
/** Naive implementation of MCT restricted to a single reversible array based encoding without offset concerning all the components. */
void * mct_data;
} opj_cparameters_t;
/** Decoding area bottom boundary */
OPJ_UINT32 DA_y1;
/** Verbose mode */
- opj_bool m_verbose;
+ OPJ_BOOL m_verbose;
/** tile number ot the decoded tile*/
OPJ_UINT32 tile_index;
/**@name JPWL decoding parameters */
/*@{*/
/** activates the JPWL correction capabilities */
- opj_bool jpwl_correct;
+ OPJ_BOOL jpwl_correct;
/** expected number of components */
int jpwl_exp_comps;
/** maximum number of tiles */
* Callback function prototype for seek function
* FIXME DOC
*/
-typedef opj_bool (* opj_stream_seek_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) ;
/*
* JPEG2000 Stream.
*
* @return a stream object.
*/
-OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_default_create(opj_bool p_is_input);
+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.
*
* @return a stream object.
*/
-OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create(OPJ_SIZE_T p_buffer_size, opj_bool p_is_input);
+OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create(OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_input);
/**
* Destroys a stream created by opj_create_stream. This function does NOT close the abstract stream. If needed the user must
* @param p_file the file stream to operate on
* @param p_is_read_stream whether the stream is a read stream (true) or not (false)
*/
-OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream (FILE * p_file, opj_bool p_is_read_stream);
+OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream (FILE * p_file, OPJ_BOOL p_is_read_stream);
/**
* FIXME DOC
* @param p_buffer_size FIXME DOC
* @param p_is_read_stream FIXME DOC
*/
-OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream (FILE * p_file, OPJ_SIZE_T p_buffer_size, opj_bool p_is_read_stream);
+OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream (FILE * p_file, OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_read_stream);
/*
==========================================================
* @param p_callback the callback function which will be used
* @param p_user_data FIXME DOC
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_info_handler(opj_codec_t * p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_info_handler(opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data);
/**
* @param p_callback the callback function which will be used
* @param p_user_data FIXME DOC
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_warning_handler(opj_codec_t * p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_warning_handler(opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data);
/**
* @param p_callback the callback function which will be used
* @param p_user_data FIXME DOC
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_error_handler(opj_codec_t * p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_error_handler(opj_codec_t * p_codec,
opj_msg_callback p_callback,
void * p_user_data);
* @param p_codec the JPEG2000 codec to read.
* @param p_stream the JPEG2000 stream.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_end_decompress ( opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_decompress ( opj_codec_t *p_codec,
opj_stream_t *p_stream);
*
* @return true if the decoder is correctly set
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec,
opj_dparameters_t *parameters );
/**
*
* @return true if the main header of the codestream and the JP2 header is correctly read.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_read_header ( opj_stream_t *p_stream,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_read_header ( opj_stream_t *p_stream,
opj_codec_t *p_codec,
opj_image_t **p_image);
*
* @return true if the area could be set.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_decode_area( opj_codec_t *p_codec,
+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 );
* @param p_image the decoded image
* @return true if success, otherwise false
* */
-OPJ_API opj_bool OPJ_CALLCONV opj_decode( opj_codec_t *p_decompressor,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_decode( opj_codec_t *p_decompressor,
opj_stream_t *p_stream,
opj_image_t *p_image);
*
* @return true if success, otherwise false
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_get_decoded_tile( opj_codec_t *p_codec,
+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);
*
* @return true if success, otherwise false
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_decoded_resolution_factor(opj_codec_t *p_codec, OPJ_UINT32 res_factor);
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decoded_resolution_factor(opj_codec_t *p_codec, OPJ_UINT32 res_factor);
/**
* Writes a tile with the given data.
*
* @return true if the data could be written.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_write_tile ( opj_codec_t *p_codec,
+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,
* @return true if the tile header could be decoded. In case the decoding should end, the returned value is still true.
* returning false may be the result of a shortage of memory or an internal error.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_read_tile_header( opj_codec_t *p_codec,
+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 );
+ OPJ_BOOL * p_should_go_on );
/**
* Reads a tile data. This function is compulsory and allows one to decode tile data. opj_read_tile_header should be called before.
*
* @return true if the data could be decoded.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_decode_tile_data( opj_codec_t *p_codec,
+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,
* @param parameters Compression parameters
* @param image Input filled image
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_setup_encoder(opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_encoder(opj_codec_t *p_codec,
opj_cparameters_t *parameters,
opj_image_t *image);
/**
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_start_compress ( opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_start_compress ( opj_codec_t *p_codec,
opj_image_t * p_image,
opj_stream_t *p_cio);
/**
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_end_compress (opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_compress (opj_codec_t *p_codec,
opj_stream_t *p_stream);
/**
*
* @return Returns true if successful, returns false otherwise
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_encode(opj_codec_t *p_codec,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_encode(opj_codec_t *p_codec,
opj_stream_t *p_stream);
*
* @return true if the parameters could be set.
*/
-OPJ_API opj_bool OPJ_CALLCONV opj_set_MCT( opj_cparameters_t *parameters,
+OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_MCT( opj_cparameters_t *parameters,
OPJ_FLOAT32 * pEncodingMatrix,
OPJ_INT32 * p_dc_shift,
OPJ_UINT32 pNbComp);
@param pi packet iterator to modify
@return returns false if pi pointed to the last packet or else returns true
*/
-static opj_bool opj_pi_next_lrcp(opj_pi_iterator_t * pi);
+static OPJ_BOOL opj_pi_next_lrcp(opj_pi_iterator_t * pi);
/**
Get next packet in resolution-layer-component-precinct order.
@param pi packet iterator to modify
@return returns false if pi pointed to the last packet or else returns true
*/
-static opj_bool opj_pi_next_rlcp(opj_pi_iterator_t * pi);
+static OPJ_BOOL opj_pi_next_rlcp(opj_pi_iterator_t * pi);
/**
Get next packet in resolution-precinct-component-layer order.
@param pi packet iterator to modify
@return returns false if pi pointed to the last packet or else returns true
*/
-static opj_bool opj_pi_next_rpcl(opj_pi_iterator_t * pi);
+static OPJ_BOOL opj_pi_next_rpcl(opj_pi_iterator_t * pi);
/**
Get next packet in precinct-component-resolution-layer order.
@param pi packet iterator to modify
@return returns false if pi pointed to the last packet or else returns true
*/
-static opj_bool opj_pi_next_pcrl(opj_pi_iterator_t * pi);
+static OPJ_BOOL opj_pi_next_pcrl(opj_pi_iterator_t * pi);
/**
Get next packet in component-precinct-resolution-layer order.
@param pi packet iterator to modify
@return returns false if pi pointed to the last packet or else returns true
*/
-static opj_bool opj_pi_next_cprl(opj_pi_iterator_t * pi);
+static OPJ_BOOL opj_pi_next_cprl(opj_pi_iterator_t * pi);
/**
* Updates the coding parameters if the encoding is used with Progression order changes and final (or cinema parameters are used).
/**
* FIXME DOC
*/
-opj_bool opj_pi_check_next_level( OPJ_INT32 pos,
+OPJ_BOOL opj_pi_check_next_level( OPJ_INT32 pos,
opj_cp_t *cp,
OPJ_UINT32 tileno,
OPJ_UINT32 pino,
==========================================================
*/
-opj_bool opj_pi_next_lrcp(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next_lrcp(opj_pi_iterator_t * pi) {
opj_pi_comp_t *comp = NULL;
opj_pi_resolution_t *res = NULL;
OPJ_UINT32 index = 0;
return OPJ_FALSE;
}
-opj_bool opj_pi_next_rlcp(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next_rlcp(opj_pi_iterator_t * pi) {
opj_pi_comp_t *comp = NULL;
opj_pi_resolution_t *res = NULL;
OPJ_UINT32 index = 0;
return OPJ_FALSE;
}
-opj_bool opj_pi_next_rpcl(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next_rpcl(opj_pi_iterator_t * pi) {
opj_pi_comp_t *comp = NULL;
opj_pi_resolution_t *res = NULL;
OPJ_UINT32 index = 0;
return OPJ_FALSE;
}
-opj_bool opj_pi_next_pcrl(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next_pcrl(opj_pi_iterator_t * pi) {
opj_pi_comp_t *comp = NULL;
opj_pi_resolution_t *res = NULL;
OPJ_UINT32 index = 0;
return OPJ_FALSE;
}
-opj_bool opj_pi_next_cprl(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next_cprl(opj_pi_iterator_t * pi) {
opj_pi_comp_t *comp = NULL;
opj_pi_resolution_t *res = NULL;
OPJ_UINT32 index = 0;
-opj_bool opj_pi_check_next_level( OPJ_INT32 pos,
+OPJ_BOOL opj_pi_check_next_level( OPJ_INT32 pos,
opj_cp_t *cp,
OPJ_UINT32 tileno,
OPJ_UINT32 pino,
}
}
-opj_bool opj_pi_next(opj_pi_iterator_t * pi) {
+OPJ_BOOL opj_pi_next(opj_pi_iterator_t * pi) {
switch (pi->poc.prg) {
case OPJ_LRCP:
return opj_pi_next_lrcp(pi);
/** layer that identify the packet */
OPJ_UINT32 layno;
/** 0 if the first packet */
- opj_bool first;
+ OPJ_BOOL first;
/** progression order change information */
opj_poc_t poc;
/** number of components in the image */
@param pi Packet iterator to modify
@return Returns false if pi pointed to the last packet or else returns true
*/
-opj_bool opj_pi_next(opj_pi_iterator_t * pi);
+OPJ_BOOL opj_pi_next(opj_pi_iterator_t * pi);
/* ----------------------------------------------------------------------- */
/*@}*/
@param roishift Region of interest shifting value
@param cblksty Code-block style
*/
-static opj_bool opj_t1_decode_cblk( opj_t1_t *t1,
+static OPJ_BOOL opj_t1_decode_cblk( opj_t1_t *t1,
opj_tcd_cblk_dec_t* cblk,
OPJ_UINT32 orient,
OPJ_UINT32 roishift,
OPJ_UINT32 cblksty);
-opj_bool opj_t1_allocate_buffers( opj_t1_t *t1,
+OPJ_BOOL opj_t1_allocate_buffers( opj_t1_t *t1,
OPJ_UINT32 w,
OPJ_UINT32 h);
return wmsedec;
}
-opj_bool opj_t1_allocate_buffers(
+OPJ_BOOL opj_t1_allocate_buffers(
opj_t1_t *t1,
OPJ_UINT32 w,
OPJ_UINT32 h)
opj_free(p_t1);
}
-opj_bool opj_t1_decode_cblks( opj_t1_t* t1,
+OPJ_BOOL opj_t1_decode_cblks( opj_t1_t* t1,
opj_tcd_tilecomp_t* tilec,
opj_tccp_t* tccp
)
}
-opj_bool opj_t1_decode_cblk(opj_t1_t *t1,
+OPJ_BOOL opj_t1_decode_cblk(opj_t1_t *t1,
opj_tcd_cblk_dec_t* cblk,
OPJ_UINT32 orient,
OPJ_UINT32 roishift,
-opj_bool opj_t1_encode_cblks( opj_t1_t *t1,
+OPJ_BOOL opj_t1_encode_cblks( opj_t1_t *t1,
opj_tcd_tile_t *tile,
opj_tcp_t *tcp,
const OPJ_FLOAT64 * mct_norms
@param tcp Tile coding parameters
@param mct_norms FIXME DOC
*/
-opj_bool opj_t1_encode_cblks( opj_t1_t *t1,
+OPJ_BOOL opj_t1_encode_cblks( opj_t1_t *t1,
opj_tcd_tile_t *tile,
opj_tcp_t *tcp,
const OPJ_FLOAT64 * mct_norms);
@param tilec The tile to decode
@param tccp Tile coding parameters
*/
-opj_bool opj_t1_decode_cblks( opj_t1_t* t1,
+OPJ_BOOL opj_t1_decode_cblks( opj_t1_t* t1,
opj_tcd_tilecomp_t* tilec,
opj_tccp_t* tccp);
@param cstr_info Codestream information structure
@return
*/
-static opj_bool opj_t2_encode_packet( OPJ_UINT32 tileno,
+static OPJ_BOOL opj_t2_encode_packet( OPJ_UINT32 tileno,
opj_tcd_tile_t *tile,
opj_tcp_t *tcp,
opj_pi_iterator_t *pi,
@return FIXME DOC
*/
-static opj_bool opj_t2_decode_packet( opj_t2_t* t2,
+static OPJ_BOOL opj_t2_decode_packet( opj_t2_t* t2,
opj_tcd_tile_t *tile,
opj_tcp_t *tcp,
opj_pi_iterator_t *pi,
OPJ_UINT32 max_length,
opj_packet_info_t *pack_info);
-static opj_bool opj_t2_skip_packet( opj_t2_t* p_t2,
+static OPJ_BOOL opj_t2_skip_packet( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_tcp_t *p_tcp,
opj_pi_iterator_t *p_pi,
OPJ_UINT32 p_max_length,
opj_packet_info_t *p_pack_info);
-static opj_bool opj_t2_read_packet_header( opj_t2_t* p_t2,
+static OPJ_BOOL opj_t2_read_packet_header( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_tcp_t *p_tcp,
opj_pi_iterator_t *p_pi,
- opj_bool * p_is_data_present,
+ OPJ_BOOL * p_is_data_present,
OPJ_BYTE *p_src_data,
OPJ_UINT32 * p_data_read,
OPJ_UINT32 p_max_length,
opj_packet_info_t *p_pack_info);
-static opj_bool opj_t2_read_packet_data(opj_t2_t* p_t2,
+static OPJ_BOOL opj_t2_read_packet_data(opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_pi_iterator_t *p_pi,
OPJ_BYTE *p_src_data,
OPJ_UINT32 p_max_length,
opj_packet_info_t *pack_info);
-static opj_bool opj_t2_skip_packet_data(opj_t2_t* p_t2,
+static OPJ_BOOL opj_t2_skip_packet_data(opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_pi_iterator_t *p_pi,
OPJ_UINT32 * p_data_read,
@param cblksty
@param first
*/
-static opj_bool opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
+static OPJ_BOOL opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
OPJ_UINT32 index,
OPJ_UINT32 cblksty,
OPJ_UINT32 first);
/* ----------------------------------------------------------------------- */
-opj_bool opj_t2_encode_packets( opj_t2_t* p_t2,
+OPJ_BOOL opj_t2_encode_packets( opj_t2_t* p_t2,
OPJ_UINT32 p_tile_no,
opj_tcd_tile_t *p_tile,
OPJ_UINT32 p_maxlayers,
return OPJ_TRUE;
}
-opj_bool opj_t2_decode_packets( opj_t2_t *p_t2,
+OPJ_BOOL opj_t2_decode_packets( opj_t2_t *p_t2,
OPJ_UINT32 p_tile_no,
opj_tcd_tile_t *p_tile,
OPJ_BYTE *p_src,
* l_current_pi->resno is always >= p_tile->comps[l_current_pi->compno].minimum_num_resolutions
* and no l_img_comp->resno_decoded are computed
*/
- opj_bool* first_pass_failed = (opj_bool*)opj_malloc(l_image->numcomps * sizeof(opj_bool));
+ OPJ_BOOL* first_pass_failed = (OPJ_BOOL*)opj_malloc(l_image->numcomps * sizeof(OPJ_BOOL));
if (!first_pass_failed)
{
opj_pi_destroy(l_pi,l_nb_pocs);
return OPJ_FALSE;
}
- memset(first_pass_failed, OPJ_TRUE, l_image->numcomps * sizeof(opj_bool));
+ memset(first_pass_failed, OPJ_TRUE, l_image->numcomps * sizeof(OPJ_BOOL));
while (opj_pi_next(l_current_pi)) {
}
}
-opj_bool opj_t2_decode_packet( opj_t2_t* p_t2,
+OPJ_BOOL opj_t2_decode_packet( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_tcp_t *p_tcp,
opj_pi_iterator_t *p_pi,
OPJ_UINT32 p_max_length,
opj_packet_info_t *p_pack_info)
{
- opj_bool l_read_data;
+ OPJ_BOOL l_read_data;
OPJ_UINT32 l_nb_bytes_read = 0;
OPJ_UINT32 l_nb_total_bytes_read = 0;
return OPJ_TRUE;
}
-opj_bool opj_t2_encode_packet( OPJ_UINT32 tileno,
+OPJ_BOOL opj_t2_encode_packet( OPJ_UINT32 tileno,
opj_tcd_tile_t * tile,
opj_tcp_t * tcp,
opj_pi_iterator_t *pi,
return OPJ_TRUE;
}
-static opj_bool opj_t2_skip_packet( opj_t2_t* p_t2,
+static OPJ_BOOL opj_t2_skip_packet( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_tcp_t *p_tcp,
opj_pi_iterator_t *p_pi,
OPJ_UINT32 p_max_length,
opj_packet_info_t *p_pack_info)
{
- opj_bool l_read_data;
+ OPJ_BOOL l_read_data;
OPJ_UINT32 l_nb_bytes_read = 0;
OPJ_UINT32 l_nb_total_bytes_read = 0;
-opj_bool opj_t2_read_packet_header( opj_t2_t* p_t2,
+OPJ_BOOL opj_t2_read_packet_header( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_tcp_t *p_tcp,
opj_pi_iterator_t *p_pi,
- opj_bool * p_is_data_present,
+ OPJ_BOOL * p_is_data_present,
OPJ_BYTE *p_src_data,
OPJ_UINT32 * p_data_read,
OPJ_UINT32 p_max_length,
return OPJ_TRUE;
}
-opj_bool opj_t2_read_packet_data( opj_t2_t* p_t2,
+OPJ_BOOL opj_t2_read_packet_data( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_pi_iterator_t *p_pi,
OPJ_BYTE *p_src_data,
return OPJ_TRUE;
}
-opj_bool opj_t2_skip_packet_data( opj_t2_t* p_t2,
+OPJ_BOOL opj_t2_skip_packet_data( opj_t2_t* p_t2,
opj_tcd_tile_t *p_tile,
opj_pi_iterator_t *p_pi,
OPJ_UINT32 * p_data_read,
}
-opj_bool opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
+OPJ_BOOL opj_t2_init_seg( opj_tcd_cblk_dec_t* cblk,
OPJ_UINT32 index,
OPJ_UINT32 cblksty,
OPJ_UINT32 first)
@param pino FIXME DOC
@param t2_mode If == 0 In Threshold calculation ,If == 1 Final pass
*/
-opj_bool opj_t2_encode_packets( opj_t2_t* t2,
+OPJ_BOOL opj_t2_encode_packets( opj_t2_t* t2,
OPJ_UINT32 tileno,
opj_tcd_tile_t *tile,
OPJ_UINT32 maxlayers,
@return FIXME DOC
*/
-opj_bool opj_t2_decode_packets( opj_t2_t *t2,
+OPJ_BOOL opj_t2_decode_packets( opj_t2_t *t2,
OPJ_UINT32 tileno,
opj_tcd_tile_t *tile,
OPJ_BYTE *src,
/**
* Allocates memory for a decoding code block.
*/
-static opj_bool opj_tcd_code_block_dec_allocate (opj_tcd_cblk_dec_t * p_code_block);
+static OPJ_BOOL opj_tcd_code_block_dec_allocate (opj_tcd_cblk_dec_t * p_code_block);
/**
* Deallocates the decoding data of the given precinct.
/**
* Allocates memory for an encoding code block.
*/
-static opj_bool opj_tcd_code_block_enc_allocate (opj_tcd_cblk_enc_t * p_code_block);
+static OPJ_BOOL opj_tcd_code_block_enc_allocate (opj_tcd_cblk_enc_t * p_code_block);
/**
* Deallocates the encoding data of the given precinct.
static void opj_tcd_free_tile(opj_tcd_t *tcd);
-static opj_bool opj_tcd_t2_decode ( opj_tcd_t *p_tcd,
+static OPJ_BOOL opj_tcd_t2_decode ( opj_tcd_t *p_tcd,
OPJ_BYTE * p_src_data,
OPJ_UINT32 * p_data_read,
OPJ_UINT32 p_max_src_size,
opj_codestream_index_t *p_cstr_index );
-static opj_bool opj_tcd_t1_decode (opj_tcd_t *p_tcd);
+static OPJ_BOOL opj_tcd_t1_decode (opj_tcd_t *p_tcd);
-static opj_bool opj_tcd_dwt_decode (opj_tcd_t *p_tcd);
+static OPJ_BOOL opj_tcd_dwt_decode (opj_tcd_t *p_tcd);
-static opj_bool opj_tcd_mct_decode (opj_tcd_t *p_tcd);
+static OPJ_BOOL opj_tcd_mct_decode (opj_tcd_t *p_tcd);
-static opj_bool opj_tcd_dc_level_shift_decode (opj_tcd_t *p_tcd);
+static OPJ_BOOL opj_tcd_dc_level_shift_decode (opj_tcd_t *p_tcd);
-static opj_bool opj_tcd_dc_level_shift_encode ( opj_tcd_t *p_tcd );
+static OPJ_BOOL opj_tcd_dc_level_shift_encode ( opj_tcd_t *p_tcd );
-static opj_bool opj_tcd_mct_encode ( opj_tcd_t *p_tcd );
+static OPJ_BOOL opj_tcd_mct_encode ( opj_tcd_t *p_tcd );
-static opj_bool opj_tcd_dwt_encode ( opj_tcd_t *p_tcd );
+static OPJ_BOOL opj_tcd_dwt_encode ( opj_tcd_t *p_tcd );
-static opj_bool opj_tcd_t1_encode ( opj_tcd_t *p_tcd );
+static OPJ_BOOL opj_tcd_t1_encode ( opj_tcd_t *p_tcd );
-static opj_bool opj_tcd_t2_encode ( opj_tcd_t *p_tcd,
+static OPJ_BOOL opj_tcd_t2_encode ( opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_max_dest_size,
opj_codestream_info_t *p_cstr_info );
-static opj_bool opj_tcd_rate_allocate_encode( opj_tcd_t *p_tcd,
+static OPJ_BOOL opj_tcd_rate_allocate_encode( opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest_data,
OPJ_UINT32 p_max_dest_size,
opj_codestream_info_t *p_cstr_info );
/**
Create a new TCD handle
*/
-opj_tcd_t* opj_tcd_create(opj_bool p_is_decoder)
+opj_tcd_t* opj_tcd_create(OPJ_BOOL p_is_decoder)
{
opj_tcd_t *l_tcd = 00;
}
}
-opj_bool opj_tcd_rateallocate( opj_tcd_t *tcd,
+OPJ_BOOL opj_tcd_rateallocate( opj_tcd_t *tcd,
OPJ_BYTE *dest,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 len,
for (layno = 0; layno < tcd_tcp->numlayers; layno++) {
OPJ_FLOAT64 lo = min;
OPJ_FLOAT64 hi = max;
- opj_bool success = OPJ_FALSE;
+ OPJ_BOOL success = OPJ_FALSE;
OPJ_UINT32 maxlen = tcd_tcp->rates[layno] ? opj_uint_min(((OPJ_UINT32) ceil(tcd_tcp->rates[layno])), len) : len;
OPJ_FLOAT64 goodthresh = 0;
OPJ_FLOAT64 stable_thresh = 0;
return OPJ_TRUE;
}
-opj_bool opj_tcd_init( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_init( opj_tcd_t *p_tcd,
opj_image_t * p_image,
opj_cp_t * p_cp )
{
/* ----------------------------------------------------------------------- */
#define MACRO_TCD_ALLOCATE(FUNCTION,TYPE,FRACTION,ELEMENT,FUNCTION_ELEMENT) \
-opj_bool FUNCTION ( opj_tcd_t *p_tcd, \
+OPJ_BOOL FUNCTION ( opj_tcd_t *p_tcd, \
OPJ_UINT32 p_tile_no \
) \
{ \
/**
* Allocates memory for an encoding code block.
*/
-opj_bool opj_tcd_code_block_enc_allocate (opj_tcd_cblk_enc_t * p_code_block)
+OPJ_BOOL opj_tcd_code_block_enc_allocate (opj_tcd_cblk_enc_t * p_code_block)
{
if (! p_code_block->data) {
/**
* Allocates memory for a decoding code block.
*/
-opj_bool opj_tcd_code_block_dec_allocate (opj_tcd_cblk_dec_t * p_code_block)
+OPJ_BOOL opj_tcd_code_block_dec_allocate (opj_tcd_cblk_dec_t * p_code_block)
{
OPJ_UINT32 l_seg_size;
return l_data_size;
}
-opj_bool opj_tcd_encode_tile( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_encode_tile( opj_tcd_t *p_tcd,
OPJ_UINT32 p_tile_no,
OPJ_BYTE *p_dest,
OPJ_UINT32 * p_data_written,
return OPJ_TRUE;
}
-opj_bool opj_tcd_decode_tile( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_decode_tile( opj_tcd_t *p_tcd,
OPJ_BYTE *p_src,
OPJ_UINT32 p_max_length,
OPJ_UINT32 p_tile_no,
return OPJ_TRUE;
}
-opj_bool opj_tcd_update_tile_data ( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_update_tile_data ( opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest,
OPJ_UINT32 p_dest_length
)
}
-opj_bool opj_tcd_t2_decode (opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_t2_decode (opj_tcd_t *p_tcd,
OPJ_BYTE * p_src_data,
OPJ_UINT32 * p_data_read,
OPJ_UINT32 p_max_src_size,
return OPJ_TRUE;
}
-opj_bool opj_tcd_t1_decode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_t1_decode ( opj_tcd_t *p_tcd )
{
OPJ_UINT32 compno;
opj_t1_t * l_t1;
}
-opj_bool opj_tcd_dwt_decode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_dwt_decode ( opj_tcd_t *p_tcd )
{
OPJ_UINT32 compno;
opj_tcd_tile_t * l_tile = p_tcd->tcd_image->tiles;
return OPJ_TRUE;
}
-opj_bool opj_tcd_mct_decode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_mct_decode ( opj_tcd_t *p_tcd )
{
opj_tcd_tile_t * l_tile = p_tcd->tcd_image->tiles;
opj_tcp_t * l_tcp = p_tcd->tcp;
}
-opj_bool opj_tcd_dc_level_shift_decode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_dc_level_shift_decode ( opj_tcd_t *p_tcd )
{
OPJ_UINT32 compno;
opj_tcd_tilecomp_t * l_tile_comp = 00;
return l_data_size;
}
-opj_bool opj_tcd_dc_level_shift_encode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_dc_level_shift_encode ( opj_tcd_t *p_tcd )
{
OPJ_UINT32 compno;
opj_tcd_tilecomp_t * l_tile_comp = 00;
return OPJ_TRUE;
}
-opj_bool opj_tcd_mct_encode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_mct_encode ( opj_tcd_t *p_tcd )
{
opj_tcd_tile_t * l_tile = p_tcd->tcd_image->tiles;
opj_tcd_tilecomp_t * l_tile_comp = p_tcd->tcd_image->tiles->comps;
return OPJ_TRUE;
}
-opj_bool opj_tcd_dwt_encode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_dwt_encode ( opj_tcd_t *p_tcd )
{
opj_tcd_tile_t * l_tile = p_tcd->tcd_image->tiles;
opj_tcd_tilecomp_t * l_tile_comp = p_tcd->tcd_image->tiles->comps;
return OPJ_TRUE;
}
-opj_bool opj_tcd_t1_encode ( opj_tcd_t *p_tcd )
+OPJ_BOOL opj_tcd_t1_encode ( opj_tcd_t *p_tcd )
{
opj_t1_t * l_t1;
const OPJ_FLOAT64 * l_mct_norms;
return OPJ_TRUE;
}
-opj_bool opj_tcd_t2_encode (opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_t2_encode (opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest_data,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 p_max_dest_size,
}
-opj_bool opj_tcd_rate_allocate_encode( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_rate_allocate_encode( opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest_data,
OPJ_UINT32 p_max_dest_size,
opj_codestream_info_t *p_cstr_info )
}
-opj_bool opj_tcd_copy_tile_data ( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_copy_tile_data ( opj_tcd_t *p_tcd,
OPJ_BYTE * p_src,
OPJ_UINT32 p_src_length )
{
@param p_is_decoder FIXME DOC
@return Returns a new TCD handle if successful returns NULL otherwise
*/
-opj_tcd_t* opj_tcd_create(opj_bool p_is_decoder);
+opj_tcd_t* opj_tcd_create(OPJ_BOOL p_is_decoder);
/**
Destroy a previously created TCD handle
*
* @return true if the encoding values could be set (false otherwise).
*/
-opj_bool opj_tcd_init( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_init( opj_tcd_t *p_tcd,
opj_image_t * p_image,
opj_cp_t * p_cp );
*
* @return true if the remaining data is sufficient.
*/
-opj_bool opj_tcd_init_decode_tile(opj_tcd_t *p_tcd, OPJ_UINT32 p_tile_no);
+OPJ_BOOL opj_tcd_init_decode_tile(opj_tcd_t *p_tcd, OPJ_UINT32 p_tile_no);
void opj_tcd_makelayer_fixed(opj_tcd_t *tcd, OPJ_UINT32 layno, OPJ_UINT32 final);
OPJ_FLOAT64 thresh,
OPJ_UINT32 final);
-opj_bool opj_tcd_rateallocate( opj_tcd_t *tcd,
+OPJ_BOOL opj_tcd_rateallocate( opj_tcd_t *tcd,
OPJ_BYTE *dest,
OPJ_UINT32 * p_data_written,
OPJ_UINT32 len,
* @param p_cstr_info Codestream information structure
* @return true if the coding is successfull.
*/
-opj_bool opj_tcd_encode_tile( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_encode_tile( opj_tcd_t *p_tcd,
OPJ_UINT32 p_tile_no,
OPJ_BYTE *p_dest,
OPJ_UINT32 * p_data_written,
@param tileno Number that identifies one of the tiles to be decoded
@param cstr_info FIXME DOC
*/
-opj_bool opj_tcd_decode_tile( opj_tcd_t *tcd,
+OPJ_BOOL opj_tcd_decode_tile( opj_tcd_t *tcd,
OPJ_BYTE *src,
OPJ_UINT32 len,
OPJ_UINT32 tileno,
/**
* Copies tile data from the system onto the given memory block.
*/
-opj_bool opj_tcd_update_tile_data ( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_update_tile_data ( opj_tcd_t *p_tcd,
OPJ_BYTE * p_dest,
OPJ_UINT32 p_dest_length );
*
* @return true if the encoding values could be set (false otherwise).
*/
-opj_bool opj_tcd_init_encode_tile ( opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_init_encode_tile ( opj_tcd_t *p_tcd,
OPJ_UINT32 p_tile_no );
/**
* Copies tile data from the given memory block onto the system.
*/
-opj_bool opj_tcd_copy_tile_data (opj_tcd_t *p_tcd,
+OPJ_BOOL opj_tcd_copy_tile_data (opj_tcd_t *p_tcd,
OPJ_BYTE * p_src,
OPJ_UINT32 p_src_length );