summaryrefslogtreecommitdiff
path: root/API.md
diff options
context:
space:
mode:
authorjussi2022-08-19 16:20:59 +0300
committerjussi2022-08-19 16:20:59 +0300
commite5f437d05e8277861ea85e6c8d2ede32c4be32ef (patch)
tree36e7985b18e6632a56100f88df8c21cdac689e77 /API.md
parent8972ac89f4cafbf9c2305222e61ba067f51eec75 (diff)
downloadreilua-enhanced-e5f437d05e8277861ea85e6c8d2ede32c4be32ef.tar.gz
reilua-enhanced-e5f437d05e8277861ea85e6c8d2ede32c4be32ef.tar.bz2
reilua-enhanced-e5f437d05e8277861ea85e6c8d2ede32c4be32ef.zip
New math functions.
Diffstat (limited to 'API.md')
-rw-r--r--API.md151
1 files changed, 151 insertions, 0 deletions
diff --git a/API.md b/API.md
index d5041a4..793d6c2 100644
--- a/API.md
+++ b/API.md
@@ -4726,6 +4726,24 @@ Remap input value within input range to output range
---
+> result = RL_Wrap( float value, float min, float max )
+
+Wrap input value from min to max
+
+- Failure return false
+- Success return float
+
+---
+
+> result = RL_FloatEquals( float x, float y )
+
+Check whether two given floats are almost equal
+
+- Failure return false
+- Success return int
+
+---
+
## Math - Vector2
---
@@ -4818,6 +4836,15 @@ Calculate distance between two vectors
---
+> result = RL_Vector2DistanceSqr( Vector2 v1, Vector2 v2 )
+
+Calculate square distance between two vectors
+
+- Failure return false
+- Success return float
+
+---
+
> result = RL_Vector2Angle( Vector2 v1, Vector2 v2 )
Calculate angle from two vectors
@@ -4872,6 +4899,15 @@ Normalize provided vector
---
+> result = RL_Vector2Transform( Vector2 v, Matrix mat )
+
+Transforms a Vector2 by a given Matrix
+
+- Failure return false
+- Success return Vector2
+
+---
+
> result = RL_Vector2Lerp( Vector2 v1, Vector2 v2, float amount )
Calculate linear interpolation between two vectors
@@ -4908,6 +4944,43 @@ Move Vector towards target
---
+> result = RL_Vector2Invert( Vector2 v )
+
+Invert the given vector
+
+- Failure return false
+- Success return Vector2
+
+---
+
+> result = RL_Vector2Clamp( Vector2 v, Vector2 min, Vector2 max )
+
+Clamp the components of the vector between
+min and max values specified by the given vectors
+
+- Failure return false
+- Success return Vector2
+
+---
+
+> result = RL_Vector2ClampValue( Vector2 v, float min, float max )
+
+Clamp the magnitude of the vector between two min and max values
+
+- Failure return false
+- Success return Vector2
+
+---
+
+> result = RL_Vector2Equals( Vector2 v1, Vector2 v2 )
+
+Check whether two given vectors are almost equal
+
+- Failure return false
+- Success return int
+
+---
+
## Math - Vector 3
---
@@ -5036,6 +5109,15 @@ Calculate distance between two vectors
---
+> result = RL_Vector3DistanceSqr( Vector3 v1, Vector3 v2 )
+
+Calculate square distance between two vectors
+
+- Failure return false
+- Success return float
+
+---
+
> result = RL_Vector3Angle( Vector3 v1, Vector3 v2 )
Calculate angle between two vectors
@@ -5100,6 +5182,15 @@ Transform a vector by quaternion rotation
---
+> result = RL_Vector3RotateByAxisAngle( Vector3 v, Vector3 axis, float angle )
+
+Rotates a vector around an axis
+
+- Failure return false
+- Success return Vector3
+
+---
+
> result = RL_Vector3Lerp( Vector3 v1, Vector3 v2, float amount )
Calculate linear interpolation between two vectors
@@ -5156,6 +5247,57 @@ NOTE: We are avoiding calling other raymath functions despite available
---
+> result = RL_Vector3Invert( Vector3 v )
+
+Invert the given vector
+
+- Failure return false
+- Success return Vector3
+
+---
+
+> result = RL_Vector3Clamp( Vector3 v, Vector3 min, Vector3 max )
+
+Clamp the components of the vector between
+min and max values specified by the given vectors
+
+- Failure return false
+- Success return Vector3
+
+---
+
+> result = RL_Vector3ClampValue( Vector3 v, float min, float max )
+
+Clamp the magnitude of the vector between two values
+
+- Failure return false
+- Success return Vector3
+
+---
+
+> result = RL_Vector3Equals( Vector3 v1, Vector3 v2 )
+
+Check whether two given vectors are almost equal
+
+- Failure return false
+- Success return int
+
+---
+
+> result = RL_Vector3Refract( Vector3 v, Vector3 n, float r )
+
+Compute the direction of a refracted ray where v specifies the
+normalized direction of the incoming ray, n specifies the
+normalized normal vector of the interface of two optical media,
+and r specifies the ratio of the refractive index of the medium
+from where the ray comes to the refractive index of the medium
+on the other side of the surface
+
+- Failure return false
+- Success return Vector3
+
+---
+
## Math - Matrix
---
@@ -5543,6 +5685,15 @@ Transform a quaternion given a transformation matrix
---
+> result = RL_QuaternionEquals( Quaternion q1, Quaternion q2 )
+
+Check whether two given quaternions are almost equal
+
+- Failure return false
+- Success return int
+
+---
+
## Gui - Global
---