Floats in the protocol

Keith Packard keithp at keithp.com
Tue Jan 6 08:06:11 PST 2009


On Tue, 2009-01-06 at 15:18 +0100, Sascha Hlusiak wrote:

> Besides being able to transfer floats with input properties, I'd like to see 
> the possibility to transfer strings as well
> That would also give the possibility of using the workaround that Roland 
> suggested and encode floats (and basically anything else) by using strings.

X is a binary protocol using machine-native data representations.
Converting things to string form is not consistent with the existing
code base, and a source of confusion given the existing usage of IEEE
floats in the GLX extension.

> It's hard to believe for me that platforms interpret IEEE754 in so different 
> ways. Are there any more references where IEEE754 representation can go wrong 
> between different platforms?

If there are, we should be fixing GLX to trap numbers which may cause
problems then. Scanning an array for ill-formatted numbers seems far
more efficient than converting the numbers to a new format.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg/attachments/20090106/294cdabb/attachment.pgp>


More information about the xorg mailing list