[trunk] continue work on getting API to use off_t instead of long toward LFS support in JPIP (codestream_param_t)
This commit is contained in:
parent
0a97782339
commit
3b268d1656
@ -41,7 +41,7 @@
|
||||
#define logstream stderr
|
||||
#endif /*SERVER */
|
||||
|
||||
codestream_param_t set_codestream( int fd, Byte8_t offset, Byte8_t length)
|
||||
codestream_param_t set_codestream( int fd, OPJ_OFF_T offset, OPJ_SIZE_T length)
|
||||
{
|
||||
codestream_param_t cs;
|
||||
|
||||
@ -52,22 +52,22 @@ codestream_param_t set_codestream( int fd, Byte8_t offset, Byte8_t length)
|
||||
return cs;
|
||||
}
|
||||
|
||||
Byte_t * fetch_codestreambytes( codestream_param_t *cs, long offset, int size)
|
||||
Byte_t * fetch_codestreambytes( codestream_param_t *cs, OPJ_OFF_T offset, OPJ_SIZE_T size)
|
||||
{
|
||||
return fetch_bytes( cs->fd, cs->offset+offset, size);
|
||||
}
|
||||
|
||||
Byte_t fetch_codestream1byte( codestream_param_t *cs, long offset)
|
||||
Byte_t fetch_codestream1byte( codestream_param_t *cs, OPJ_OFF_T offset)
|
||||
{
|
||||
return fetch_1byte( cs->fd, cs->offset+offset);
|
||||
}
|
||||
|
||||
Byte2_t fetch_codestream2bytebigendian( codestream_param_t *cs, long offset)
|
||||
Byte2_t fetch_codestream2bytebigendian( codestream_param_t *cs, OPJ_OFF_T offset)
|
||||
{
|
||||
return fetch_2bytebigendian( cs->fd, cs->offset+offset);
|
||||
}
|
||||
|
||||
Byte4_t fetch_codestream4bytebigendian( codestream_param_t *cs, long offset)
|
||||
Byte4_t fetch_codestream4bytebigendian( codestream_param_t *cs, OPJ_OFF_T offset)
|
||||
{
|
||||
return fetch_4bytebigendian( cs->fd, cs->offset+offset);
|
||||
}
|
||||
|
@ -36,7 +36,7 @@
|
||||
/** codestream parameters*/
|
||||
typedef struct codestream_param{
|
||||
int fd; /**< file descriptor*/
|
||||
Byte8_t offset; /**< byte position of DBox (Box Contents) in the file*/
|
||||
OPJ_OFF_T offset; /**< byte position of DBox (Box Contents) in the file*/
|
||||
Byte8_t length; /**< content length*/
|
||||
} codestream_param_t;
|
||||
|
||||
@ -49,7 +49,7 @@ typedef struct codestream_param{
|
||||
* @param[in] length codestream length
|
||||
* @return structure of generated codestream parameters
|
||||
*/
|
||||
codestream_param_t set_codestream( int fd, Byte8_t offset, Byte8_t length);
|
||||
codestream_param_t set_codestream( int fd, OPJ_OFF_T offset, OPJ_SIZE_T length);
|
||||
|
||||
|
||||
/**
|
||||
@ -60,7 +60,7 @@ codestream_param_t set_codestream( int fd, Byte8_t offset, Byte8_t length);
|
||||
* @param[in] size Byte length
|
||||
* @return pointer to the fetched data
|
||||
*/
|
||||
Byte_t * fetch_codestreambytes( codestream_param_t *cs, long offset, int size);
|
||||
Byte_t * fetch_codestreambytes( codestream_param_t *cs, OPJ_OFF_T offset, OPJ_SIZE_T size);
|
||||
|
||||
/**
|
||||
* fetch Codestream 1-byte Byte code in file stream
|
||||
@ -69,7 +69,7 @@ Byte_t * fetch_codestreambytes( codestream_param_t *cs, long offset, int size);
|
||||
* @param[in] offset start Byte position in codestream
|
||||
* @return fetched code
|
||||
*/
|
||||
Byte_t fetch_codestream1byte( codestream_param_t *cs, long offset);
|
||||
Byte_t fetch_codestream1byte( codestream_param_t *cs, OPJ_OFF_T offset);
|
||||
|
||||
/**
|
||||
* fetch Codestream 2-byte big endian Byte codes in file stream
|
||||
@ -78,7 +78,7 @@ Byte_t fetch_codestream1byte( codestream_param_t *cs, long offset);
|
||||
* @param[in] offset start Byte position in codestream
|
||||
* @return fetched code
|
||||
*/
|
||||
Byte2_t fetch_codestream2bytebigendian( codestream_param_t *cs, long offset);
|
||||
Byte2_t fetch_codestream2bytebigendian( codestream_param_t *cs, OPJ_OFF_T offset);
|
||||
|
||||
/**
|
||||
* fetch Codestream 4-byte big endian Byte codes in file stream
|
||||
@ -87,7 +87,7 @@ Byte2_t fetch_codestream2bytebigendian( codestream_param_t *cs, long offset);
|
||||
* @param[in] offset start Byte position in codestream
|
||||
* @return fetched code
|
||||
*/
|
||||
Byte4_t fetch_codestream4bytebigendian( codestream_param_t *cs, long offset);
|
||||
Byte4_t fetch_codestream4bytebigendian( codestream_param_t *cs, OPJ_OFF_T offset);
|
||||
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user