Skyline Lua API  Version 1.0 RC1
Lua Script Reference for Skyline Game Engine.
LUA_API_Quaternion.h
Go to the documentation of this file.
1 // | _ ____ __ _
2 // | / \ _ _ _ __ __ _/ ___| ___ / _| |_
3 // | / _ \| | | | '__/ _` \___ \ / _ \| |_| __|
4 // | / ___ \ |_| | | | (_| |___) | (_) | _| |_
5 // | /_/ \_\__,_|_| \__,_|____/ \___/|_| \__|
6 // |
7 // | Aurasoft UK 2008 - 2016 http://www.aurasoft.co.uk
8 // |
9 // | Skyline Game Engine Lua API Documentation
10 // |
11 // | This file belongs to Aurasoft UK for the Skyline Game Engine of all versions.
12 // | This file is not for use in any other software that is not owned by Aurasoft UK and cannot be used by any other
13 // | person outside of the Skyline Game Engine development team.
14 // |
15 // | © Copyright - Aurasoft UK & Skyline Game Engine 2008 - 2016
16 // |
17 
18 // SKYLINE LUA CLASS FOR API DOCUMENTATION
19 
67 class quat
68 {
69 public:
70 
89  void newQuat(string quatName, float w, float x, float y, float z );
90 
110  void newQuatFromAngleAxis(string quatName, float angleDegrees, float axisX, float axisY, float axisZ );
111 
128  float4 getQuat( string quatName );
129 
130 
161  float4 slerp( float rotProgress, float srcW, float srcX, float srcY, float srcZ, float destW, float destX, float destY, float destZ, int shortPath );
162 
180  float getYaw( string quatName, int degreeOrRadians);
181 
199  float getPitch( string quatName, int degreeOrRadians);
200 
218  float getRoll( string quatName, int degreeOrRadians);
219 
220 
240  float3 getRollPitchYaw( string quatName, int degreeOrRadians);
241 
242 
243 
257  int getW(string quatName);
258 
259 
273  int getX(string quatName);
274 
288  int getY(string quatName);
289 
303  int getZ(string quatName);
304 
305 
319  void setW( string quatName, float quatW );
320 
334  void setX( string quatName, float quatX );
335 
349  void setY( string quatName, float quatY );
350 
364  void setZ( string quatName, float quatZ );
365 
382  float4 setQuatValues( string quatName, float w, float x, float y, float z );
383 
401  float4 multiply( string quatName, string quatName2 );
402 
415  void inverse( string quatName);
416 
429  void normalise( string quatName );
430 
451  float4 getXAxis_RotationTo( string quatName, float posX, float posY, float posZ);
452 
473  float4 getYAxis_RotationTo( string quatName, float posX, float posY, float posZ);
474 
495  float4 getZAxis_RotationTo( string quatName, float posX, float posY, float posZ);
496 
526  float4 rotateOrientation( float degree, int axisX, int axisY, int axisZ, float rotW, float rotX, float rotY, float rotZ);
527 
528 };
float4 getXAxis_RotationTo(string quatName, float posX, float posY, float posZ)
get the rotation on the X Axis from a particular axis and position.
void normalise(string quatName)
Normalise the Quaternion.
float4 getYAxis_RotationTo(string quatName, float posX, float posY, float posZ)
get the rotation on the Y Axis from a particular axis and position.
float4 multiply(string quatName, string quatName2)
Multiply two Quaternions Together.
void setZ(string quatName, float quatZ)
Set the Z Component of the Quaternion Specified.
void setW(string quatName, float quatW)
Set the W Component of the Quaternion Specified.
float3 getRollPitchYaw(string quatName, int degreeOrRadians)
Returns Yaw, Pitch and Roll Values of the specified Quaternion. Either Return the Yaw in Degrees or R...
float4 getQuat(string quatName)
Return the Quaternion referenced by name into a float4.
void setY(string quatName, float quatY)
Set the Y Component of the Quaternion Specified.
int getZ(string quatName)
Get the Z Component of the Quaternion Specified.
void inverse(string quatName)
Inverse the Quaternion.
void setX(string quatName, float quatX)
Set the X Component of the Quaternion Specified.
int getW(string quatName)
Get the W Component of the Quaternion Specified.
void newQuatFromAngleAxis(string quatName, float angleDegrees, float axisX, float axisY, float axisZ)
Create a new Quaternion from an angle on a particular Axis.
float4 getZAxis_RotationTo(string quatName, float posX, float posY, float posZ)
get the rotation on the Z Axis from a particular axis and position.
Definition: LUA_API_Quaternion.h:67
void newQuat(string quatName, float w, float x, float y, float z)
Call this function and pass the arguments to create a new Quaternion.
int getY(string quatName)
Get the Y Component of the Quaternion Specified.
int getX(string quatName)
Get the X Component of the Quaternion Specified.
float getPitch(string quatName, int degreeOrRadians)
Return the Pitch Value of the specified Quaternion. Either Return the Pitch in Degrees or Radians...
float getYaw(string quatName, int degreeOrRadians)
Return the Yaw Value of the specified Quaternion. Either Return the Yaw in Degrees or Radians...
float getRoll(string quatName, int degreeOrRadians)
Return the Roll Value of the specified Quaternion. Either Return the Roll in Degrees or Radians...
float4 rotateOrientation(float degree, int axisX, int axisY, int axisZ, float rotW, float rotX, float rotY, float rotZ)
rotate a quaternion orientation passed in by a certain degree on the specific axis This will allow yo...
float4 slerp(float rotProgress, float srcW, float srcX, float srcY, float srcZ, float destW, float destX, float destY, float destZ, int shortPath)
Call this function to create smooth rotations between a source rotation and a destination rotation ov...
float4 setQuatValues(string quatName, float w, float x, float y, float z)
Set all 4 Quaternion Components to the Quaternion specified.