convert to txt not working on floating point?

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
deklund
Posts: 3
Joined: 2014-08-28T18:15:20-07:00
Authentication code: 6789

convert to txt not working on floating point?

Post by deklund »

I tried using convert to text with a 16 bit int tiff file, it worked fine and the output values were as expected. Not so when I tried doing the same thing on a 32 bit float tiff. I thought this might be caused by the bit depth, so I converted to 16 bit depth and viewed the file (a ramp) to confirm ImageMagick had processed it correctly. I tried using convert to text on the 16 bit file, but I'm getting nonsense data. The file is an RGB ramp with increasing values from left to right, but when I read out a row, all the values are coming out the same #1F721F721F72.

Don
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: convert to txt not working on floating point?

Post by fmw42 »

Not sure if this will help, but see the -define for tiff floating point and -depth.

"To specify a single-precision floating-point format, use -define quantum:format=floating-point. Set the depth to 64 for a double-precision floating-point format"

see
http://www.imagemagick.org/script/formats.php
http://www.imagemagick.org/script/comma ... php#define

You may have to work in Q32 or HDRI IM compile.

Or it could be a bug in IM or a bad TIFF file? I do not know enough to say.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: convert to txt not working on floating point?

Post by snibgo »

The question is rather vague.

Please give the actual commands you used so other people can try them.

Please also state the version of IM, Q-number and whether using HDRI. And platform.
snibgo's IM pages: im.snibgo.com
deklund
Posts: 3
Joined: 2014-08-28T18:15:20-07:00
Authentication code: 6789

Re: convert to txt not working on floating point?

Post by deklund »

Sorry, in preparing a sample to share I found the problem was mine. The image was matted and i had not noticed.
Post Reply