Wiki > TV3D65 Index

TV_3DVECTOR

This convenient structure holds 3 variables and is primarily used to hold a point in the 3D world. It is used intensively throughout the engine.

DECLARATION

VB.NET Public Structure TV_3DVECTOR
Public x As Single, y, z
End Structure
C++ public: struct TV_3DVECTOR {
float x, y, z;
};
C# public struct TV_3DVECTOR {
float x, y, z;
};

MEMBERS

Name Description
x The x value of the vector
y The y value of the vector
z The z value of the vector

CONSTRUCTORS

VB.NET TV_3DVECTOR(ByVal x As Single, ByVal y As Single, ByVal z As Single)
TV_3DVECTOR()
C++ TV_3DVECTOR(float x, float y, float z)
TV_3DVECTOR(void)
TV_3DVECTOR(TV_3DVECTOR*)

EXAMPLES

C#.NET

TV_3DVECTOR vec1 = new TV_3DVECTOR(0.5f, 0.5f, 0.5f);

TIPS

  • You can perform addition, subtraction, multiplication and division operations on TV_3DVECTOR objects using the standard +, -, /, * symbols
  • For more information about vectors in general you might want to check out this wiki page about Vector space
 
tv3d65_doc/tv_3dvector.txt · Last modified: 2013/11/22 13:31