Wiki > TV3D65 Index

TV_2DVECTOR

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

DECLARATION

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

MEMBERS

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

CONSTRUCTORS

VB.NET TV_2DVECTOR(Single x, Single y)
TV_2DVECTOR(void)
C++ TV_2DVECTOR(float x, float y)
TV_2DVECTOR(void)
TV_2DVECTOR(TV_2DVECTOR*)

EXAMPLES

C#.NET

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

TIPS

  • You can perform addition, subtraction, multiplication and division operations on TV_2DVECTOR 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_2dvector.txt · Last modified: 2013/11/22 13:31