Minor TIFF updates
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3971 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
ca15acf7a8
commit
e66950a8e9
@ -203,14 +203,18 @@
|
|||||||
#define TIFF_RGB_STRIPBCOFFSET 248
|
#define TIFF_RGB_STRIPBCOFFSET 248
|
||||||
|
|
||||||
/* Debug *******************************************************************/
|
/* Debug *******************************************************************/
|
||||||
|
/* CONFIG_DEBUG_TIFFOFFSETS may be defined (along with CONFIG_DEBUG and
|
||||||
|
* CONFIG_DEBUG_GRAPHICS) in order to verify the pre-determined TIFF file
|
||||||
|
* offsets.
|
||||||
|
*/
|
||||||
|
|
||||||
#ifndef CONFIG_DEBUG
|
#if !defined(CONFIG_DEBUG) || !defined(CONFIG_DEBUG_GRAPHICS)
|
||||||
# undef CONFIG_DEBUG_GRAPHICS
|
# undef CONFIG_DEBUG_TIFFOFFSETS
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_DEBUG_GRAPHICS
|
#ifdef CONFIG_DEBUG_TIFFOFFSETS
|
||||||
# define tiff_offset(o,l) (o) += (l)
|
# define tiff_offset(o,l) (o) += (l)
|
||||||
# define tiff_checkoffs(o,x) ASSERT((o) == (x));
|
# define tiff_checkoffs(o,x) ASSERT((o) == (x))
|
||||||
#else
|
#else
|
||||||
# define tiff_offset(o,l)
|
# define tiff_offset(o,l)
|
||||||
# define tiff_checkoffs(o,x)
|
# define tiff_checkoffs(o,x)
|
||||||
@ -307,7 +311,7 @@ static inline int tiff_putheader(FAR struct tiff_info_s *info)
|
|||||||
|
|
||||||
/* 4-7: Offset to the first IFD */
|
/* 4-7: Offset to the first IFD */
|
||||||
|
|
||||||
tiff_put16(hdr.offset, TIFF_IFD_OFFSET);
|
tiff_put32(hdr.offset, TIFF_IFD_OFFSET);
|
||||||
|
|
||||||
/* Write the header to the output file */
|
/* Write the header to the output file */
|
||||||
|
|
||||||
@ -446,7 +450,7 @@ static int tiff_datetime(FAR char *timbuf, unsigned int buflen)
|
|||||||
int tiff_initialize(FAR struct tiff_info_s *info)
|
int tiff_initialize(FAR struct tiff_info_s *info)
|
||||||
{
|
{
|
||||||
uint16_t val16;
|
uint16_t val16;
|
||||||
#if CONFIG_DEBUG_GRAPHICS
|
#if CONFIG_DEBUG_TIFFOFFSETS
|
||||||
off_t offset = 0;
|
off_t offset = 0;
|
||||||
#endif
|
#endif
|
||||||
char timbuf[TIFF_DATETIME_STRLEN + 8];
|
char timbuf[TIFF_DATETIME_STRLEN + 8];
|
||||||
|
Loading…
Reference in New Issue
Block a user