{
if(img->numcomps < 3)
{
- img->color_space = CLRSPC_GRAY;
+ img->color_space = OPJ_CLRSPC_GRAY;
return;
}
__FILE__,__LINE__);
return;
}
- img->color_space = CLRSPC_SRGB;
+ img->color_space = OPJ_CLRSPC_SRGB;
}/* color_sycc_to_rgb() */
in_type = TYPE_RGB_16;
out_type = TYPE_RGB_16;
out_prof = cmsCreate_sRGBProfile();
- image->color_space = CLRSPC_SRGB;
+ image->color_space = OPJ_CLRSPC_SRGB;
}
else
if(out_space == cmsSigGrayData) /* enumCS 17 */
in_type = TYPE_GRAY_8;
out_type = TYPE_RGB_8;
out_prof = cmsCreate_sRGBProfile();
- image->color_space = CLRSPC_SRGB;
+ image->color_space = OPJ_CLRSPC_SRGB;
}
else
if(out_space == cmsSigYCbCrData) /* enumCS 18 */
in_type = TYPE_YCbCr_16;
out_type = TYPE_RGB_16;
out_prof = cmsCreate_sRGBProfile();
- image->color_space = CLRSPC_SRGB;
+ image->color_space = OPJ_CLRSPC_SRGB;
}
else
{
#endif
static int tga_writeheader(FILE *fp, int bits_per_pixel, int width, int height,
- opj_bool flip_image)
+ OPJ_BOOL flip_image)
{
unsigned short image_w, image_h, us0;
unsigned char uc0, image_type;
opj_image_cmptparm_t cmptparm[4]; /* maximum 4 components */
int numcomps;
OPJ_COLOR_SPACE color_space;
- opj_bool mono ;
- opj_bool save_alpha;
+ OPJ_BOOL mono ;
+ OPJ_BOOL save_alpha;
int subsampling_dx, subsampling_dy;
int i;
save_alpha = (pixel_bit_depth == 16) || (pixel_bit_depth == 32); /* Mono with alpha, or RGB with alpha */
if (mono) {
- color_space = CLRSPC_GRAY;
+ color_space = OPJ_CLRSPC_GRAY;
numcomps = save_alpha ? 2 : 1;
}
else {
numcomps = save_alpha ? 4 : 3;
- color_space = CLRSPC_SRGB;
+ color_space = OPJ_CLRSPC_SRGB;
}
subsampling_dx = parameters->subsampling_dx;
int imagetotga(opj_image_t * image, const char *outfile) {
int width, height, bpp, x, y;
- opj_bool write_alpha;
+ OPJ_BOOL write_alpha;
int i, adjustR, adjustG, adjustB;
unsigned int alpha_channel;
float r,g,b,a;
if (Info_h.biBitCount == 24)
{
numcomps = 3;
- color_space = CLRSPC_SRGB;
+ color_space = OPJ_CLRSPC_SRGB;
/* initialize image components */
memset(&cmptparm[0], 0, 3 * sizeof(opj_image_cmptparm_t));
for(i = 0; i < numcomps; i++)
W++;
numcomps = gray_scale ? 1 : 3;
- color_space = gray_scale ? CLRSPC_GRAY : CLRSPC_SRGB;
+ color_space = gray_scale ? OPJ_CLRSPC_GRAY : OPJ_CLRSPC_SRGB;
/* initialize image components */
memset(&cmptparm[0], 0, 3 * sizeof(opj_image_cmptparm_t));
for(i = 0; i < numcomps; i++)
gray_scale = 0;
numcomps = gray_scale ? 1 : 3;
- color_space = gray_scale ? CLRSPC_GRAY : CLRSPC_SRGB;
+ color_space = gray_scale ? OPJ_CLRSPC_GRAY : OPJ_CLRSPC_SRGB;
/* initialize image components */
memset(&cmptparm[0], 0, 3 * sizeof(opj_image_cmptparm_t));
for (i = 0; i < numcomps; i++)
opj_image_comp_t *comp = NULL;
numcomps = 1;
- color_space = CLRSPC_GRAY;
+ color_space = OPJ_CLRSPC_GRAY;
memset(&cmptparm, 0, sizeof(opj_image_cmptparm_t));
default: fclose(fp); return NULL;
}
if(numcomps < 3)
- color_space = CLRSPC_GRAY;/* GRAY, GRAYA */
+ color_space = OPJ_CLRSPC_GRAY;/* GRAY, GRAYA */
else
- color_space = CLRSPC_SRGB;/* RGB, RGBA */
+ color_space = OPJ_CLRSPC_SRGB;/* RGB, RGBA */
prec = has_prec(header_info.maxval);
if(tiPhoto == PHOTOMETRIC_RGB) /* RGB(A) */
{
numcomps = 3 + has_alpha;
- color_space = CLRSPC_SRGB;
+ color_space = OPJ_CLRSPC_SRGB;
/*#define USETILEMODE*/
for(j = 0; j < numcomps; j++)
if(tiPhoto == PHOTOMETRIC_MINISBLACK) /* GRAY(A) */
{
numcomps = 1 + has_alpha;
- color_space = CLRSPC_GRAY;
+ color_space = OPJ_CLRSPC_GRAY;
for(j = 0; j < numcomps; ++j)
{
RAW IMAGE FORMAT
<<-- <<-- <<-- <<-- */
-static opj_image_t* rawtoimage_common(const char *filename, opj_cparameters_t *parameters, raw_cparameters_t *raw_cp, opj_bool big_endian) {
+static opj_image_t* rawtoimage_common(const char *filename, opj_cparameters_t *parameters, raw_cparameters_t *raw_cp, OPJ_BOOL big_endian) {
int subsampling_dx = parameters->subsampling_dx;
int subsampling_dy = parameters->subsampling_dy;
return NULL;
}
numcomps = raw_cp->rawComp;
- color_space = CLRSPC_SRGB;
+ color_space = OPJ_CLRSPC_SRGB;
w = raw_cp->rawWidth;
h = raw_cp->rawHeight;
cmptparm = (opj_image_cmptparm_t*) malloc(numcomps * sizeof(opj_image_cmptparm_t));
return rawtoimage_common(filename, parameters, raw_cp, OPJ_TRUE);
}
-static int imagetoraw_common(opj_image_t * image, const char *outfile, opj_bool big_endian)
+static int imagetoraw_common(opj_image_t * image, const char *outfile, OPJ_BOOL big_endian)
{
FILE *rawFile = NULL;
size_t res;
cmptparm[i].h = height;
}
- image = opj_image_create(nr_comp, &cmptparm[0], CLRSPC_SRGB);
+ image = opj_image_create(nr_comp, &cmptparm[0], OPJ_CLRSPC_SRGB);
if(image == NULL) goto fin;
/** bit depth of the raw image */
int rawBitDepth;
/** signed/unsigned raw image */
- opj_bool rawSigned;
+ OPJ_BOOL rawSigned;
/*@}*/
} raw_cparameters_t;
cstr_info->tile[tileno].tp[tilepartno].tp_end_pos
);
- if (cstr_info->prog == LRCP) { /* LRCP */
+ if (cstr_info->prog == OPJ_LRCP) { /* LRCP */
fprintf(stream, "LRCP\npack_nb tileno layno resno compno precno start_pos end_ph_pos end_pos");
if (disto_on)
fprintf(stream, " disto");
}
} /* LRCP */
- else if (cstr_info->prog == RLCP) { /* RLCP */
+ else if (cstr_info->prog == OPJ_RLCP) { /* RLCP */
fprintf(stream, "RLCP\npack_nb tileno resno layno compno precno start_pos end_ph_pos end_pos\n");
if (disto_on)
fprintf(stream, " disto");
}
} /* RLCP */
- else if (cstr_info->prog == RPCL) { /* RPCL */
+ else if (cstr_info->prog == OPJ_RPCL) { /* RPCL */
fprintf(stream, "RPCL\npack_nb tileno resno precno compno layno start_pos end_ph_pos end_pos");
if (disto_on)
} /* resno */
} /* RPCL */
- else if (cstr_info->prog == PCRL) { /* PCRL */
+ else if (cstr_info->prog == OPJ_PCRL) { /* PCRL */
/* I suppose components have same XRsiz, YRsiz */
int x0 = cstr_info->tile_Ox + tileno - (int)floor( (float)tileno/(float)cstr_info->tw ) * cstr_info->tw * cstr_info->tile_x;
int y0 = cstr_info->tile_Ox + (int)floor( (float)tileno/(float)cstr_info->tw ) * cstr_info->tile_y;
fprintf(stdout,"\n");
fprintf(stdout,"-h : display the help information \n ");
fprintf(stdout,"\n");
- fprintf(stdout,"-cinema2K : Digital Cinema 2K profile compliant codestream for 2K resolution.(-cinema2k 24 or 48) \n");
+ fprintf(stdout,"-OPJ_CINEMA2K : Digital Cinema 2K profile compliant codestream for 2K resolution.(-OPJ_CINEMA2K 24 or 48) \n");
fprintf(stdout," Need to specify the frames per second for a 2K resolution. Only 24 or 48 fps is allowed\n");
fprintf(stdout,"\n");
- fprintf(stdout,"-cinema4K : Digital Cinema 4K profile compliant codestream for 4K resolution \n");
+ fprintf(stdout,"-OPJ_CINEMA4K : Digital Cinema 4K profile compliant codestream for 4K resolution \n");
fprintf(stdout," Frames per second not required. Default value is 24fps\n");
fprintf(stdout,"\n");
fprintf(stdout,"-r : different compression ratios for successive layers (-r 20,10,5)\n ");
static OPJ_PROG_ORDER give_progression(const char progression[4]) {
if(strncmp(progression, "LRCP", 4) == 0) {
- return LRCP;
+ return OPJ_LRCP;
}
if(strncmp(progression, "RLCP", 4) == 0) {
- return RLCP;
+ return OPJ_RLCP;
}
if(strncmp(progression, "RPCL", 4) == 0) {
- return RPCL;
+ return OPJ_RPCL;
}
if(strncmp(progression, "PCRL", 4) == 0) {
- return PCRL;
+ return OPJ_PCRL;
}
if(strncmp(progression, "CPRL", 4) == 0) {
- return CPRL;
+ return OPJ_CPRL;
}
- return PROG_UNKNOWN;
+ return OPJ_PROG_UNKNOWN;
}
static unsigned int get_num_images(char *imgdirpath){
POC[0].layno1 = 1;
POC[0].resno1 = numres-1;
POC[0].compno1 = 3;
- POC[0].prg1 = CPRL;
+ POC[0].prg1 = OPJ_CPRL;
POC[1].tile = 1;
POC[1].resno0 = numres-1;
POC[1].compno0 = 0;
POC[1].layno1 = 1;
POC[1].resno1 = numres;
POC[1].compno1 = 3;
- POC[1].prg1 = CPRL;
+ POC[1].prg1 = OPJ_CPRL;
return 2;
}
parameters->csty |= 0x01;
/*The progression order shall be CPRL*/
- parameters->prog_order = CPRL;
+ parameters->prog_order = OPJ_CPRL;
/* No ROI */
parameters->roi_compno = -1;
float temp_rate;
switch (parameters->cp_cinema){
- case CINEMA2K_24:
- case CINEMA2K_48:
+ case OPJ_CINEMA2K_24:
+ case OPJ_CINEMA2K_48:
if(parameters->numresolution > 6){
parameters->numresolution = 6;
}
fprintf(stdout,"Image coordinates %d x %d is not 2K compliant.\nJPEG Digital Cinema Profile-3 "
"(2K profile) compliance requires that at least one of coordinates match 2048 x 1080\n",
image->comps[0].w,image->comps[0].h);
- parameters->cp_rsiz = STD_RSIZ;
+ parameters->cp_rsiz = OPJ_STD_RSIZ;
}
break;
- case CINEMA4K_24:
+ case OPJ_CINEMA4K_24:
if(parameters->numresolution < 1){
parameters->numresolution = 1;
}else if(parameters->numresolution > 7){
fprintf(stdout,"Image coordinates %d x %d is not 4K compliant.\nJPEG Digital Cinema Profile-4"
"(4K profile) compliance requires that at least one of coordinates match 4096 x 2160\n",
image->comps[0].w,image->comps[0].h);
- parameters->cp_rsiz = STD_RSIZ;
+ parameters->cp_rsiz = OPJ_STD_RSIZ;
}
parameters->numpocs = initialise_4K_poc(parameters->POC,parameters->numresolution);
break;
}
switch (parameters->cp_cinema){
- case CINEMA2K_24:
- case CINEMA4K_24:
+ case OPJ_CINEMA2K_24:
+ case OPJ_CINEMA4K_24:
for(i=0 ; i<parameters->tcp_numlayers ; i++){
temp_rate = 0 ;
if (img_fol->rates[i]== 0){
parameters->max_comp_size = COMP_24_CS;
break;
- case CINEMA2K_48:
+ case OPJ_CINEMA2K_48:
for(i=0 ; i<parameters->tcp_numlayers ; i++){
temp_rate = 0 ;
if (img_fol->rates[i]== 0){
img_fol_t *img_fol, raw_cparameters_t *raw_cp, char *indexfilename) {
int i, j, totlen, c;
opj_option_t long_option[]={
- {"cinema2K",REQ_ARG, NULL ,'w'},
- {"cinema4K",NO_ARG, NULL ,'y'},
+ {"OPJ_CINEMA2K",REQ_ARG, NULL ,'w'},
+ {"OPJ_CINEMA4K",NO_ARG, NULL ,'y'},
{"ImgDir",REQ_ARG, NULL ,'z'},
{"TP",REQ_ARG, NULL ,'u'},
{"SOP",NO_ARG, NULL ,'S'},
int fps=0;
sscanf(opj_optarg,"%d",&fps);
if(fps == 24){
- parameters->cp_cinema = CINEMA2K_24;
+ parameters->cp_cinema = OPJ_CINEMA2K_24;
}else if(fps == 48 ){
- parameters->cp_cinema = CINEMA2K_48;
+ parameters->cp_cinema = OPJ_CINEMA2K_48;
}else {
fprintf(stderr,"Incorrect value!! must be 24 or 48\n");
return 1;
}
fprintf(stdout,"CINEMA 2K compliant codestream\n");
- parameters->cp_rsiz = CINEMA2K;
+ parameters->cp_rsiz = OPJ_CINEMA2K;
}
break;
case 'y': /* Digital Cinema 4K profile compliance*/
{
- parameters->cp_cinema = CINEMA4K_24;
+ parameters->cp_cinema = OPJ_CINEMA4K_24;
fprintf(stdout,"CINEMA 4K compliant codestream\n");
- parameters->cp_rsiz = CINEMA4K;
+ parameters->cp_rsiz = OPJ_CINEMA4K;
}
break;
/* check for possible errors */
if (parameters->cp_cinema){
if(parameters->tcp_numlayers > 1){
- parameters->cp_rsiz = STD_RSIZ;
+ parameters->cp_rsiz = OPJ_STD_RSIZ;
fprintf(stdout,"Warning: DC profiles do not allow more than one quality layer. The codestream created will not be compliant with the DC profile\n");
}
}
img_fol_t img_fol;
dircnt_t *dirptr = NULL;
- opj_bool bSuccess;
- opj_bool bUseTiles = OPJ_FALSE; /* OPJ_TRUE */
+ OPJ_BOOL bSuccess;
+ OPJ_BOOL bUseTiles = OPJ_FALSE; /* OPJ_TRUE */
OPJ_UINT32 l_nb_tiles = 4;
/* set encoding parameters to default values */
case J2K_CFMT: /* JPEG-2000 codestream */
{
/* Get a decoder handle */
- l_codec = opj_create_compress(CODEC_J2K);
+ l_codec = opj_create_compress(OPJ_CODEC_J2K);
break;
}
case JP2_CFMT: /* JPEG 2000 compressed image data */
{
/* Get a decoder handle */
- l_codec = opj_create_compress(CODEC_JP2);
+ l_codec = opj_create_compress(OPJ_CODEC_JP2);
break;
}
default:
case J2K_CFMT: /* JPEG-2000 codestream */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_J2K);
+ l_codec = opj_create_decompress(OPJ_CODEC_J2K);
break;
}
case JP2_CFMT: /* JPEG 2000 compressed image data */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JP2);
+ l_codec = opj_create_decompress(OPJ_CODEC_JP2);
break;
}
case JPT_CFMT: /* JPEG 2000, JPIP */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JPT);
+ l_codec = opj_create_decompress(OPJ_CODEC_JPT);
break;
}
default:
opj_stream_destroy(l_stream);
fclose(fsrc);
- if(image->color_space == CLRSPC_SYCC){
+ if(image->color_space == OPJ_CLRSPC_SYCC){
color_sycc_to_rgb(image); /* FIXME */
}
dircnt_t *dirptr = NULL;
#ifdef MSD
- opj_bool l_go_on = OPJ_TRUE;
+ OPJ_BOOL l_go_on = OPJ_TRUE;
OPJ_UINT32 l_max_data_size = 1000;
OPJ_BYTE * l_data = (OPJ_BYTE *) malloc(1000);
#endif
case J2K_CFMT: /* JPEG-2000 codestream */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_J2K);
+ l_codec = opj_create_decompress(OPJ_CODEC_J2K);
break;
}
case JP2_CFMT: /* JPEG 2000 compressed image data */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JP2);
+ l_codec = opj_create_decompress(OPJ_CODEC_JP2);
break;
}
case JPT_CFMT: /* JPEG 2000, JPIP */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JPT);
+ l_codec = opj_create_decompress(OPJ_CODEC_JPT);
break;
}
default:
free(filenameComponentPGX);
}
- image = opj_image_create(nbFilenamePGX, param_image_read, CLRSPC_UNSPECIFIED);
+ image = opj_image_create(nbFilenamePGX, param_image_read, OPJ_CLRSPC_UNSPECIFIED);
for (it_file = 0; it_file < nbFilenamePGX; it_file++)
{
/* Copy data into output image and free memory*/
param_image_write.prec = image->comps[num_comp_select].prec;
param_image_write.sgnd = image->comps[num_comp_select].sgnd;
- image_write = opj_image_create(1, ¶m_image_write, CLRSPC_GRAY);
+ image_write = opj_image_create(1, ¶m_image_write, OPJ_CLRSPC_GRAY);
memcpy(image_write->comps->data, image->comps[num_comp_select].data, param_image_write.h * param_image_write.w * sizeof(int));
imagetopng(image_write, filename);
return EXIT_FAILURE;
}
- imageDiff = opj_image_create(imageBase->numcomps, param_image_diff, CLRSPC_UNSPECIFIED);
+ imageDiff = opj_image_create(imageBase->numcomps, param_image_diff, OPJ_CLRSPC_UNSPECIFIED);
/* Free memory*/
free(param_image_diff);
case J2K_CFMT: /* JPEG-2000 codestream */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_J2K);
+ l_codec = opj_create_decompress(OPJ_CODEC_J2K);
break;
}
case JP2_CFMT: /* JPEG 2000 compressed image data */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JP2);
+ l_codec = opj_create_decompress(OPJ_CODEC_JP2);
break;
}
case JPT_CFMT: /* JPEG 2000, JPIP */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JPT);
+ l_codec = opj_create_decompress(OPJ_CODEC_JPT);
break;
}
default:
OPJ_UINT32 l_max_data_size = 1000;
OPJ_UINT32 l_tile_index;
OPJ_BYTE * l_data = (OPJ_BYTE *) malloc(1000);
- opj_bool l_go_on = OPJ_TRUE;
+ OPJ_BOOL l_go_on = OPJ_TRUE;
OPJ_INT32 l_tile_x0=0, l_tile_y0=0 ;
OPJ_UINT32 l_tile_width=0, l_tile_height=0, l_nb_tiles_x=0, l_nb_tiles_y=0, l_nb_comps=0 ;
OPJ_INT32 l_current_tile_x0,l_current_tile_y0,l_current_tile_x1,l_current_tile_y1;
case J2K_CFMT: /* JPEG-2000 codestream */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_J2K);
+ l_codec = opj_create_decompress(OPJ_CODEC_J2K);
break;
}
case JP2_CFMT: /* JPEG 2000 compressed image data */
{
/* Get a decoder handle */
- l_codec = opj_create_decompress(CODEC_JP2);
+ l_codec = opj_create_decompress(OPJ_CODEC_JP2);
break;
}
default:
l_param.irreversible = irreversible;
/* do not bother with mct, the rsiz is set when calling opj_set_MCT*/
- /*l_param.cp_rsiz = STD_RSIZ;*/
+ /*l_param.cp_rsiz = OPJ_STD_RSIZ;*/
/* no cinema */
/*l_param.cp_cinema = 0;*/
l_param.numresolution = 6;
/** progression order to use*/
- /** LRCP, RLCP, RPCL, PCRL, CPRL */
- l_param.prog_order = LRCP;
+ /** OPJ_LRCP, OPJ_RLCP, OPJ_RPCL, PCRL, CPRL */
+ l_param.prog_order = OPJ_LRCP;
/** no "region" of interest, more precisally component */
/* l_param.roi_compno = -1; */
len = strlen( output_file );
if( strcmp( output_file + len - 4, ".jp2" ) == 0 )
{
- l_codec = opj_create_compress(CODEC_JP2);
+ l_codec = opj_create_compress(OPJ_CODEC_JP2);
}
else
{
- l_codec = opj_create_compress(CODEC_J2K);
+ l_codec = opj_create_compress(OPJ_CODEC_J2K);
}
if (!l_codec) {
return 1;
opj_set_warning_handler(l_codec, warning_callback,00);
opj_set_error_handler(l_codec, error_callback,00);
- l_image = opj_image_tile_create(num_comps,l_params,CLRSPC_SRGB);
+ l_image = opj_image_tile_create(num_comps,l_params,OPJ_CLRSPC_SRGB);
if (! l_image) {
opj_destroy_codec(l_codec);
return 1;
l_image->y0 = 0;
l_image->x1 = image_width;
l_image->y1 = image_height;
- l_image->color_space = CLRSPC_SRGB;
+ l_image->color_space = OPJ_CLRSPC_SRGB;
if (! opj_setup_encoder(l_codec,&l_param,l_image)) {
fprintf(stderr, "ERROR -> test_tile_encoder: failed to setup the codec!\n");
{
const char * v = opj_version();
- const OPJ_COLOR_SPACE color_space = CLRSPC_GRAY;
+ const OPJ_COLOR_SPACE color_space = OPJ_CLRSPC_GRAY;
int numcomps = 1;
int i;
int image_width = 256;
opj_image_cmptparm_t cmptparm;
opj_image_t *image;
opj_codec_t* l_codec = 00;
- opj_bool bSuccess;
+ OPJ_BOOL bSuccess;
FILE *f;
opj_stream_t *l_stream = 00;
(void)argc;
opj_set_warning_handler(l_codec, warning_callback,00);\r
opj_set_error_handler(l_codec, error_callback,00);
- l_codec = opj_create_compress(CODEC_J2K);
+ l_codec = opj_create_compress(OPJ_CODEC_J2K);
opj_set_info_handler(l_codec, info_callback,00);
opj_set_warning_handler(l_codec, warning_callback,00);
opj_set_error_handler(l_codec, error_callback,00);
{
const char * v = opj_version();
- const OPJ_COLOR_SPACE color_space = CLRSPC_GRAY;
+ const OPJ_COLOR_SPACE color_space = OPJ_CLRSPC_GRAY;
int numcomps = 1;
int i;
int image_width = 256;
opj_image_cmptparm_t cmptparm;
opj_image_t *image;
opj_codec_t* l_codec = 00;
- opj_bool bSuccess;
+ OPJ_BOOL bSuccess;
FILE *f;
opj_stream_t *l_stream = 00;
(void)argc;
opj_set_warning_handler(l_codec, warning_callback,00);\r
opj_set_error_handler(l_codec, error_callback,00);
- l_codec = opj_create_compress(CODEC_J2K);
+ l_codec = opj_create_compress(OPJ_CODEC_J2K);
opj_set_info_handler(l_codec, info_callback,00);
opj_set_warning_handler(l_codec, warning_callback,00);
opj_set_error_handler(l_codec, error_callback,00);
opj_dparameters_t dparameters;
assert( fsrc );
- d_codec = opj_create_decompress(CODEC_J2K);
+ d_codec = opj_create_decompress(OPJ_CODEC_J2K);
opj_set_info_handler(d_codec, info_callback,00);
opj_set_warning_handler(d_codec, warning_callback,00);
opj_set_error_handler(d_codec, error_callback,00);