C# Class CSharpGL.IModelSpaceHelper

Datei anzeigen Open project: bitzhuwei/CSharpGL

Public Methods

Method Description
CopyModelSpaceStateFrom ( this dest, IModelSpace source ) : void

Copy IModelSpace state from specified source.

GetBoundingBox ( this model ) : BoundingBox

GetMaxMinPosition ( this model, vec3 &maxPosition, vec3 &minPosition ) : void

Gets max and min position of the AABB box that wraps specified model.

GetModelMatrix ( this model ) : CSharpGL.mat4

Get model matrix.

LegacyTransform ( this model ) : void

Run legacy model transform.(from model space to world space)

Rotate ( this model, float angleDegree, vec3 axis ) : void

Rotate this model based on all previous rotation actions. Thus all rotations will take part in model's rotation result.

在目前的旋转状态下继续旋转一次,即所有的旋转操作都会(按照发生顺序)生效。

Method Details

CopyModelSpaceStateFrom() public static method

Copy IModelSpace state from specified source.
public static CopyModelSpaceStateFrom ( this dest, IModelSpace source ) : void
dest this
source IModelSpace
return void

GetBoundingBox() public static method

public static GetBoundingBox ( this model ) : BoundingBox
model this
return BoundingBox

GetMaxMinPosition() public static method

Gets max and min position of the AABB box that wraps specified model.
public static GetMaxMinPosition ( this model, vec3 &maxPosition, vec3 &minPosition ) : void
model this
maxPosition vec3
minPosition vec3
return void

GetModelMatrix() public static method

Get model matrix.
public static GetModelMatrix ( this model ) : CSharpGL.mat4
model this
return CSharpGL.mat4

LegacyTransform() public static method

Run legacy model transform.(from model space to world space)
public static LegacyTransform ( this model ) : void
model this
return void

Rotate() public static method

Rotate this model based on all previous rotation actions. Thus all rotations will take part in model's rotation result.

在目前的旋转状态下继续旋转一次,即所有的旋转操作都会(按照发生顺序)生效。

public static Rotate ( this model, float angleDegree, vec3 axis ) : void
model this
angleDegree float Angle in Degree.
axis vec3
return void