本文整理汇总了C#中VECTOR类的典型用法代码示例。如果您正苦于以下问题:C# VECTOR类的具体用法?C# VECTOR怎么用?C# VECTOR使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
VECTOR类属于命名空间,在下文中一共展示了VECTOR类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: VectorToAstroCoord
public static CartesianCrood VectorToAstroCoord(VECTOR vector)
{
double fNormal = Math.Sqrt(vector.X * vector.X +
vector.Y * vector.Y +
vector.Z * vector.Z);
// VECTOR is struct, in c#, it is call by value type
double x = vector.X / fNormal;
double y = vector.Y / fNormal;
double z = vector.Z / fNormal;
return new CartesianCrood
{
Phi = Math.Atan2(y, x),
Theta = Math.Asin(z)
};
}
示例2: dx_MV1SetPhysicsWorldGravity_x64
extern static int dx_MV1SetPhysicsWorldGravity_x64( int MHandle, VECTOR Gravity);
示例3: dx_DrawCone3D_x64
extern static int dx_DrawCone3D_x64( VECTOR TopPos, VECTOR BottomPos, float r, int DivNum, uint DifColor, uint SpcColor, int FillFlag);
示例4: dx_DrawCapsule3D_x64
extern static int dx_DrawCapsule3D_x64( VECTOR Pos1, VECTOR Pos2, float r, int DivNum, uint DifColor, uint SpcColor, int FillFlag);
示例5: dx_DrawSphere3D_x64
extern static int dx_DrawSphere3D_x64( VECTOR CenterPos, float r, int DivNum, uint DifColor, uint SpcColor, int FillFlag);
示例6: DrawTriangle3D
public static int DrawTriangle3D( VECTOR Pos1, VECTOR Pos2, VECTOR Pos3, uint Color, int FillFlag)
{
if( System.IntPtr.Size == 4 )
{
return dx_DrawTriangle3D_x86( Pos1 , Pos2 , Pos3 , Color , FillFlag );
}
else
{
return dx_DrawTriangle3D_x64( Pos1 , Pos2 , Pos3 , Color , FillFlag );
}
}
示例7: DrawLine3D
public static int DrawLine3D( VECTOR Pos1, VECTOR Pos2, uint Color)
{
if( System.IntPtr.Size == 4 )
{
return dx_DrawLine3D_x86( Pos1 , Pos2 , Color );
}
else
{
return dx_DrawLine3D_x64( Pos1 , Pos2 , Color );
}
}
示例8: DrawPixel3D
public static int DrawPixel3D( VECTOR Pos, uint Color)
{
if( System.IntPtr.Size == 4 )
{
return dx_DrawPixel3D_x86( Pos , Color );
}
else
{
return dx_DrawPixel3D_x64( Pos , Color );
}
}
示例9: dx_MV1CollCheck_Sphere_x64
extern static MV1_COLL_RESULT_POLY_DIM dx_MV1CollCheck_Sphere_x64( int MHandle, int FrameIndex, VECTOR CenterPos, float r);
示例10: MV1CollCheck_LineDim
public static MV1_COLL_RESULT_POLY_DIM MV1CollCheck_LineDim( int MHandle, int FrameIndex, VECTOR PosStart, VECTOR PosEnd)
{
if( System.IntPtr.Size == 4 )
{
return dx_MV1CollCheck_LineDim_x86( MHandle , FrameIndex , PosStart , PosEnd );
}
else
{
return dx_MV1CollCheck_LineDim_x64( MHandle , FrameIndex , PosStart , PosEnd );
}
}
示例11: dx_MV1CollCheck_LineDim_x64
extern static MV1_COLL_RESULT_POLY_DIM dx_MV1CollCheck_LineDim_x64( int MHandle, int FrameIndex, VECTOR PosStart, VECTOR PosEnd);
示例12: dx_MV1CollCheck_Line_x86
extern static MV1_COLL_RESULT_POLY dx_MV1CollCheck_Line_x86( int MHandle, int FrameIndex, VECTOR PosStart, VECTOR PosEnd);
示例13: MV1GetTriangleListPolygonVertexPosition
public static int MV1GetTriangleListPolygonVertexPosition( int MHandle, int TListIndex, int PolygonIndex, out VECTOR VertexPositions)
{
if( System.IntPtr.Size == 4 )
{
return dx_MV1GetTriangleListPolygonVertexPosition_x86( MHandle , TListIndex , PolygonIndex , out VertexPositions );
}
else
{
return dx_MV1GetTriangleListPolygonVertexPosition_x64( MHandle , TListIndex , PolygonIndex , out VertexPositions );
}
}
示例14: dx_MV1GetTriangleListPolygonVertexPosition_x64
extern static int dx_MV1GetTriangleListPolygonVertexPosition_x64( int MHandle, int TListIndex, int PolygonIndex, out VECTOR VertexPositions);
示例15: MV1SetPhysicsWorldGravity
public static int MV1SetPhysicsWorldGravity( int MHandle, VECTOR Gravity)
{
if( System.IntPtr.Size == 4 )
{
return dx_MV1SetPhysicsWorldGravity_x86( MHandle , Gravity );
}
else
{
return dx_MV1SetPhysicsWorldGravity_x64( MHandle , Gravity );
}
}