[trunk] replace more void* object pointer to proper function pointer: opj_procedure. Remove some warnings reported by gcc -pedantic
This commit is contained in:
parent
8e65846f32
commit
e6f8b59010
|
@ -650,7 +650,7 @@ OPJ_SIZE_T opj_stream_write_data (opj_stream_private_t * p_stream,const OPJ_BYTE
|
|||
while(1)
|
||||
{
|
||||
l_remaining_bytes = p_stream->m_buffer_size - p_stream->m_bytes_in_buffer;
|
||||
// we have more memory than required
|
||||
/* we have more memory than required */
|
||||
if
|
||||
(l_remaining_bytes >= p_size)
|
||||
{
|
||||
|
@ -662,7 +662,7 @@ OPJ_SIZE_T opj_stream_write_data (opj_stream_private_t * p_stream,const OPJ_BYTE
|
|||
return l_write_nb_bytes;
|
||||
}
|
||||
|
||||
// we copy data and then do an actual read on the stream
|
||||
/* we copy data and then do an actual read on the stream */
|
||||
if
|
||||
(l_remaining_bytes)
|
||||
{
|
||||
|
|
|
@ -59,6 +59,12 @@ Get pointer to the current position in the stream
|
|||
*/
|
||||
unsigned char *cio_getbp(opj_cio_t *cio);
|
||||
/**
|
||||
*/
|
||||
opj_bool cio_byteout(opj_cio_t *cio, unsigned char v);
|
||||
/**
|
||||
*/
|
||||
unsigned char cio_bytein(opj_cio_t *cio);
|
||||
/**
|
||||
Write some bytes
|
||||
@param cio CIO handle
|
||||
@param v Value to write
|
||||
|
|
|
@ -2059,7 +2059,7 @@ void jp2_setup_end_header_writting (opj_jp2_v2_t *jp2)
|
|||
/* preconditions */
|
||||
assert(jp2 != 00);
|
||||
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_write_jp2c );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_write_jp2c );
|
||||
/* DEVELOPER CORNER, add your custom procedures */
|
||||
}
|
||||
|
||||
|
@ -2071,7 +2071,7 @@ void jp2_setup_end_header_reading (opj_jp2_v2_t *jp2)
|
|||
{
|
||||
/* preconditions */
|
||||
assert(jp2 != 00);
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_read_header_procedure );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_read_header_procedure );
|
||||
/* DEVELOPER CORNER, add your custom procedures */
|
||||
}
|
||||
|
||||
|
@ -2695,7 +2695,7 @@ void jp2_setup_encoding_validation (opj_jp2_v2_t *jp2)
|
|||
/* preconditions */
|
||||
assert(jp2 != 00);
|
||||
|
||||
opj_procedure_list_add_procedure(jp2->m_validation_list, (void*)jp2_default_validation);
|
||||
opj_procedure_list_add_procedure(jp2->m_validation_list, (opj_procedure)jp2_default_validation);
|
||||
/* DEVELOPER CORNER, add your custom validation procedure */
|
||||
}
|
||||
|
||||
|
@ -2719,10 +2719,10 @@ void jp2_setup_header_writting (opj_jp2_v2_t *jp2)
|
|||
/* preconditions */
|
||||
assert(jp2 != 00);
|
||||
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_write_jp );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_write_ftyp );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_write_jp2h );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_skip_jp2c );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_write_jp );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_write_ftyp );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_write_jp2h );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_skip_jp2c );
|
||||
|
||||
/* DEVELOPER CORNER, insert your custom procedures */
|
||||
|
||||
|
@ -2737,7 +2737,7 @@ void jp2_setup_header_reading (opj_jp2_v2_t *jp2)
|
|||
/* preconditions */
|
||||
assert(jp2 != 00);
|
||||
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(void*)jp2_read_header_procedure );
|
||||
opj_procedure_list_add_procedure(jp2->m_procedure_list,(opj_procedure)jp2_read_header_procedure );
|
||||
/* DEVELOPER CORNER, add your custom procedures */
|
||||
}
|
||||
|
||||
|
|
|
@ -3241,15 +3241,15 @@ opj_bool tcd_mct_encode ( opj_tcd_v2_t *p_tcd )
|
|||
++l_tile_comp;
|
||||
}
|
||||
|
||||
if (! mct_encode_custom(// MCT data
|
||||
if (! mct_encode_custom(/* MCT data */
|
||||
(OPJ_BYTE*) p_tcd->tcp->m_mct_coding_matrix,
|
||||
// size of components
|
||||
/* size of components */
|
||||
samples,
|
||||
// components
|
||||
/* components */
|
||||
l_data,
|
||||
// nb of components (i.e. size of pData)
|
||||
/* nb of components (i.e. size of pData) */
|
||||
l_tile->numcomps,
|
||||
// tells if the data is signed
|
||||
/* tells if the data is signed */
|
||||
p_tcd->image->comps->sgnd) )
|
||||
{
|
||||
opj_free(l_data);
|
||||
|
@ -3306,7 +3306,7 @@ opj_bool tcd_t1_encode ( opj_tcd_v2_t *p_tcd )
|
|||
}
|
||||
|
||||
if (l_tcp->mct == 1) {
|
||||
// irreversible encoding
|
||||
/* irreversible encoding */
|
||||
if (l_tcp->tccps->qmfbid == 0) {
|
||||
l_mct_norms = get_mct_norms_real();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue