Hi Alex, its strange that they don't work the same...
pow(x, -n) is mathematically the same as 1/pow(x, n).
So if you know that n is less than zero you can always do:
1.0/pow(x, -n); // note that by writing -n its effectively making it
positive, probably faster than doing abs.
if you aren't sure whether n is less than zero or not you can always do:
n>0 ? pow(x, n) : 1.0/pow(x, -n);
hope that solves your problem!
Memo (Mehmet S. Akten)
www.memo.tv
On Apr 9, 2008, at 6:42 PM, Alex Drinkwater wrote:
> This is probably way off topic, but...
>
> has anyone noticed differences between the way the GLSL pow()
function works on the two graphics card types? It appears that if you
pass a number less than 0 as either of the parameters of the pow()
function, on an ATI/Radeon-equipped machine you get a number, while on
a machine with an NVIDIA/GeForce card, you get 'undefined'. I wonder
if anyone happens to know how I can mimic the result from the ATI card
on the NVIDIA GPUs?
>
> A long-shot, I know...
>
> alx
> http://machinesdontcare.wordpress.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com
This email sent to [EMAIL PROTECTED]