]> granicus.if.org Git - openjpeg/commitdiff
remove deprecated v1 style function jp2_read_boxhdr
authorMickael Savinaud <savmickael@users.noreply.github.com>
Fri, 10 Aug 2012 10:57:51 +0000 (10:57 +0000)
committerMickael Savinaud <savmickael@users.noreply.github.com>
Fri, 10 Aug 2012 10:57:51 +0000 (10:57 +0000)
libopenjpeg/jp2.c

index 73d472a5f79ee20c215a39dde09b536a618b1117..78d29cf5d28853304427f1af4477d0d906afe745 100644 (file)
 /** @name Local static functions */
 /*@{*/
 
-/**
-Read box headers
-@param cinfo Codec context info
-@param cio Input stream
-@param box
-@return Returns true if successful, returns false otherwise
-*/
-static opj_bool jp2_read_boxhdr(opj_common_ptr cinfo, opj_cio_t *cio, opj_jp2_box_t *box);
+
 /*static void jp2_write_url(opj_cio_t *cio, char *Idx_file);*/
 
 /**
@@ -449,26 +442,6 @@ static void opj_jp2_setup_header_reading (opj_jp2_v2_t *jp2);
 
 /* ----------------------------------------------------------------------- */
 
-static opj_bool jp2_read_boxhdr(opj_common_ptr cinfo, opj_cio_t *cio, opj_jp2_box_t *box) {
-       box->init_pos = cio_tell(cio);
-       box->length = cio_read(cio, 4);
-       box->type = cio_read(cio, 4);
-       if (box->length == 1) {
-               if (cio_read(cio, 4) != 0) {
-                       opj_event_msg(cinfo, EVT_ERROR, "Cannot handle box sizes higher than 2^32\n");
-                       return OPJ_FALSE;
-               }
-               box->length = cio_read(cio, 4);
-               if (box->length == 0) 
-                       box->length = cio_numbytesleft(cio) + 12;
-       }
-       else if (box->length == 0) {
-               box->length = cio_numbytesleft(cio) + 8;
-       }
-       
-       return OPJ_TRUE;
-}
-
 /**
  * Reads a box header. The box is the way data is packed inside a jpeg2000 file structure.
  *