osg.Vec2ui是OpenSceneGraph库中的一个二维无符号整型向量类。它封装了二维向量的坐标信息,用于表示二维空间中的点、向量等。
osg.Vec2ui() # 构造函数1,创建一个坐标为(0,0)的二维向量
osg.Vec2ui(u: int, v: int) # 构造函数2,创建一个坐标为(u,v)的二维向量
osg.Vec2ui(other: osg.Vec2ui) # 构造函数3,拷贝构造函数,从另一个Vec2ui对象创建一个新的对象
length(self) -> float # 返回向量的长度
length2(self) -> float # 返回向量长度的平方
normalize(self) -> osg.Vec2ui # 将向量规格化为单位向量
__add__(self, other: osg.Vec2ui) -> osg.Vec2ui # 向量加法
__sub__(self, other: osg.Vec2ui) -> osg.Vec2ui # 向量减法
__mul__(self, other: float) -> osg.Vec2ui # 向量数乘
__truediv__(self, other: int) -> osg.Vec2ui # 向量数除
__eq__(self, other: object) -> bool # 向量等于
__ne__(self, other: object) -> bool # 向量不等于
__neg__(self) -> osg.Vec2ui # 向量取反
x = 0 # 向量x坐标
y = 0 # 向量y坐标