2013.02.13 22:03 "[Tiff] 32 bit to 16bit conversion", by james wells

2013.02.14 19:26 "[Tiff] TIFF support for 16 bit floats", by Richard Nolde

On 02/14/2013 10:00 AM, tiff-request@lists.maptools.org wrote:

> 4. Re: 32 bit to 16bit conversion (Bob Friesenhahn)
>
>
>
> Message: 4
> Date: Thu, 14 Feb 2013 09:08:33 -0600 (CST)
> From: Bob Friesenhahn <bfriesen@simple.dallas.tx.us>
> Subject: Re: [Tiff] 32 bit to 16bit conversion
> To: james wells <jwneuror@gmail.com>
> Cc: "tiff@lists.maptools.org" <tiff@lists.maptools.org>
> Message-ID:
> <alpine.GSO.2.01.1302140905120.11141@freddy.simplesystems.org>
> Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

It's a 32 bit float, a hightmap, and I need to convert it to a 16 bit float, so hopefully it's not as painful?

I'll take a look at ILM's half library when I get home, looks interesting, hopefully not too out of my league.

There are also C-language implementations of 16-bit 'Half' in GraphicsMagick and in littlecms (lcms). Both of these are offered under a liberal (MIT/X11) license.

OpenEXR is quite large and primarily written in C++ so using it just for Half support would be painful.

I'd be interesting in seeing a sample of the data. I have C routines to convert between 16, 24, and 32 bit floats that I'm hoping to update in the not-to-distant future and I'd like to compare results with my routines to whatever else you might find out there. I can also share them in their present form if you are interested. Bob can comment on the differences between the implementations. The ones in lcms are table based whereas mine are iterative. I have options to round out of domain values to the maximum supported by the desired bit depth or to treat them as errors. My plan is to eventually add these routines to tiffcrop so that you could use tiffcrop to do this for you in one step.

Richard Nolde