Page 1 of 1

Size and Point data types.

Posted: Wed Mar 07, 2007 08:52
by maxim
I wish there wouldn't be separate types for size and point data. They are both just 2D-vectors after all so why bother? How about using HLSL-style naming conventions instead, as they're getting increasingly popular.

Size -> float2
Point -> float2
----
float2 temp(0.1f,0.1f);

float x=temp[0];
float y=temp[1];
//and or
float x=temp.x;
float y=temp.y;


Cheers

Posted: Mon Mar 12, 2007 13:56
by LennyH
You can just use UVector2. But readability is better when you use self describing naming conventions...