[cairo] _cairo_color_compute_shorts fails with FPU set to single precision

Keith Packard keithp at keithp.com
Thu Aug 31 08:21:35 PDT 2006


On Thu, 2006-08-31 at 05:30 -0700, Carl Worth wrote:

> 	i = f * 65536.0;
> 	i -= (i >> 16);

Note that this also works for values slightly less than 0, which may be
of interest.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.freedesktop.org/archives/cairo/attachments/20060831/756e476b/attachment-0001.pgp


More information about the cairo mailing list