opj_bool opj_jp2_encode(opj_jp2_t *jp2, opj_cio_t *cio, opj_image_t *image, opj_codestream_info_t *cstr_info) {
int pos_iptr, pos_cidx, pos_jp2c, len_jp2c, len_cidx, end_pos, pos_fidx, len_fidx;
+ pos_jp2c = pos_iptr = -1; /* remove a warning */
/* JP2 encoding */
opj_packet_info_t packet;
int resno, precno, layno, num_packet;
int numOfres, numOfprec, numOflayers;
+ packet.end_ph_pos = packet.start_pos = -1;
+ (void)EPHused; /* unused ? */
if( j2klen > pow( 2, 32)){
size_of_coding = 8;
/* printf("cstr_info.packno %d\n", cstr_info.packno); //NMAX? */
+ lenp = -1;
box = (opj_jp2_box_t *)opj_calloc( cstr_info.numcomps, sizeof(opj_jp2_box_t));
for (i=0;i<2;i++){
opj_packet_info_t packet;
int resno, precno, layno, num_packet;
int numOfres, numOfprec, numOflayers;
+ packet.end_pos = packet.end_ph_pos = packet.start_pos = -1;
+ (void)EPHused; /* unused ? */
if( j2klen > pow( 2, 32)){
size_of_coding = 8;