LuaSTG-x Core API
math::vec3 Class Reference

Public Member Functions

function vec3 []::_getEdge(local index)
 math.vec3[] More...
 
function vec3 []::_getEdges()
 
function vec3 []::getVertCount()
 
function vec3 []::getVerts(local out)
 
function vec3 []::setTransform(local translate, local scale, local quaternion)
 
function vec3 []::setTransformMat(local transform_mat)
 
static function vec3 []::Tetrahedron()
 
function __add (local other)
 
function __div (local other)
 
function __eq (local other)
 
function __mul (local other)
 
function __sub (local other)
 
function __tostring ()
 
function __unm ()
 
function add (local other)
 
function angle (local other)
 
function clamp (local min, local max)
 
function clone ()
 
function cross (local other)
 
function distance (local other)
 
function distanceSquared (local other)
 
function dot (local other)
 
function fuzzyEquals (local other, local var)
 
function getClamped (local min, local max)
 
function getNormalized ()
 
function getScaled (local scalar)
 
function isFinite ()
 
function isOne ()
 
function isZero ()
 
function length ()
 
function lengthSquared ()
 
function lerp (local target, local alpha)
 
function negate ()
 
function normalize ()
 
static function one ()
 
function scale (local scalar)
 
function set (local xx, local yy, local zz)
 
function setZero ()
 
function smooth (local target, local elapsedTime, local responseTime)
 
function subtract (local other)
 
static function zero ()
 

Public Attributes

table __index
 
number x
 
number y
 
number z
 

Constructor & Destructor Documentation

◆ vec3() [1/7]

function vec3 ( local  transform_mat)

math.vec3[]

[]

Parameters
transform_matmath.mat4 []

◆ vec3() [2/7]

[]

◆ vec3() [3/7]

function vec3 ( local  translate,
local  scale,
local  quaternion 
)
Parameters
translatemath.vec3
scalemath.vec3|number
quaternionmath.quaternion []

◆ vec3() [4/7]

function vec3 ( local  out)
Parameters
transform_matmath.mat4 []

[]

◆ vec3() [5/7]

static function vec3 ( )

[]

◆ vec3() [6/7]

function vec3 ( local  out)

[]

◆ vec3() [7/7]

static function vec3 ( )

[]

Member Function Documentation

◆ __add()

function __add ( local  other)

◆ __div()

function __div ( local  other)

◆ __eq()

function __eq ( local  other)

◆ __mul()

function __mul ( local  other)

◆ __sub()

function __sub ( local  other)

◆ __tostring()

function __tostring ( )

◆ __unm()

function __unm ( )

◆ add()

function add ( local  other)

◆ angle()

function angle ( local  other)

◆ clamp()

function clamp ( local  min,
local  max 
)

◆ clone()

function clone ( )

◆ cross()

function cross ( local  other)

◆ distance()

function distance ( local  other)

◆ distanceSquared()

function distanceSquared ( local  other)

◆ dot()

function dot ( local  other)

◆ fuzzyEquals()

function fuzzyEquals ( local  other,
local  var 
)

◆ getClamped()

function getClamped ( local  min,
local  max 
)

◆ getNormalized()

function getNormalized ( )

◆ getScaled()

function getScaled ( local  scalar)

◆ isFinite()

function isFinite ( )

◆ isOne()

function isOne ( )

◆ isZero()

function isZero ( )

◆ length()

function length ( )

◆ lengthSquared()

function lengthSquared ( )

◆ lerp()

function lerp ( local  target,
local  alpha 
)

◆ negate()

function negate ( )

◆ normalize()

function normalize ( )

◆ one()

static function one ( )

◆ scale()

function scale ( local  scalar)

◆ set()

function set ( local  xx,
local  yy,
local  zz 
)

◆ setZero()

function setZero ( )

◆ smooth()

function smooth ( local  target,
local  elapsedTime,
local  responseTime 
)

◆ subtract()

function subtract ( local  other)

◆ zero()

static function zero ( )

Member Data Documentation

◆ __index

table __index

◆ x

number x

◆ y

number y

◆ z

number z

The documentation for this class was generated from the following files: