This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Thursday, June 29, 2006 1:04:05 AM(UTC)
Groups: Registered
Posts: 1
Hello,
is there any option available to get information of the used byte order in a TIF file? In our case we work with TIF files that could have the INTEL (Low-High) byte order or the Motorola(High-Low) byte order. One of our functions is rotating pages from a multipage file and write them back with the Replace option. When the file origin has the Motorola Byte order and we perform a REPLACE, it generates an error about invalid width or height. This is logic because LeadTools write the INTEL Byte Order back into a Motorola Byte Order file. We use the LeadTools V13 OCX. Is there anyone who can help us with this issue? If possible we like to detect the byte order and Replace the pages with the same byte order as the original file.
With kind regards
KN BV
Frank van der Heijden
heyden66@planet.nl
#2
Posted
:
Monday, July 3, 2006 11:02:31 AM(UTC)
Groups: Manager, Tech Support
Posts: 367
Was thanked: 1 time(s) in 1 post(s)
The first 2 bytes in a TIFF file identify the byte order. If they are 4949Hex (the characters 'II'), byte order is always from the least significant byte to the most significant byte. This is called little-endian byte order (or Intel).
If they are 4D4DHex (the characters 'MM'), byte order is most significant to least
significant byte. This is called big-endian byte order (or Motorola).
This means you can write your own code to read the first 2 bytes (after you use LEADTOOLS to make sure it's a valid TIFF).
About saving, LEADTOOLS offers the option of saving either Intel or Motorola byte order with TIFF files that support this, but this is only offered in the DLL API functions, which are part of LEADTOOLS Raster Imaging Pro and higher toolkits. The main OCX does not contain this feature and can only save in the Intel byte order.
Amin Dodin
Senior Support Engineer
LEAD Technologies, Inc.
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.