I would have assumed that GL_FIXED
was faster, but the iPhone docs actually say to use GL_FLOAT
because GL_FIXED
has to be converted to GL_FLOAT
. Is it the same on Android? I suppose it varies by phone, but what about recent popular ones (Nexus One, Droid/Milestone, etc.)?
Bonus points: This appears to be completely undocumented (e.g. search google for GL_FIXED
!) but where is the 'point' in GL_FIXED
? I.e. how much is (GL_FIXED)1
worth?
Like Andreas says, which one is faster depends on the hardware rather than on the gl standard. In general, you can expect GL_FLOAT to probably be the better choice when true hardware acceleration is used. GL_FIXED will usually be faster if the work is done in software on a CPU with poor or zero support for floating point math.
GL_FIXED is a 32 bit format, using 16.16 semantics. So 1 as a GL_FIXED value would be 0x10000.
This has nothing to do with android, it will depend on the actual GPU in the telephone in question. Generally I would think that GL_FLOAT
will be faster on modern GPUs.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With