1
0
mirror of https://github.com/DigvijaysinhGohil/Godot-Shader-Lib.git synced 2025-09-19 20:05:57 +08:00

Maths node documentation updated

This commit is contained in:
Digvijaysinh Gohil
2024-04-15 22:29:35 +05:30
parent b7c13a973a
commit 8a036a2abf
3 changed files with 54 additions and 0 deletions

View File

@ -18,4 +18,26 @@ Returns the distance between two points using Chebyshev distance matrix.
|Name|Type|Binding|Description|
|---|---|---|---|
|distance|float|None|Distance between 2 points|
**ShaderInc location**
<br>For 2D - `res://addons/ShaderLib/Maths/Vector/Distance/Chebyshev2D.gdshaderinc`
<br>For 3D - `res://addons/ShaderLib/Maths/Vector/Distance/Chebyshev3D.gdshaderinc`
**Method signature**
<br>For 2D - `float chebyshev_distance_2d(vec2 point1, vec2 point2, float power)`
<br>For 3D - `float chebyshev_distance_3d(vec3 point1, vec3 point2, float power)`
**Parameters for 2D**
|Name|Type|Description|
|---|---|---|
|point1|vec2|Point a|
|point2|vec2|Point b|
|power|float|Power for Chebyshev distance|
**Parameters for 3D**
|Name|Type|Description|
|---|---|---|
|point1|vec3|Point a|
|point2|vec3|Point b|
|power|float|Power for Chebyshev distance|
___

View File

@ -17,4 +17,24 @@ Returns the distance between two points using Manhattan distance matrix.
|Name|Type|Binding|Description|
|---|---|---|---|
|distance|float|None|Distance between 2 points|
**ShaderInc location**
<br>For 2D - `res://addons/ShaderLib/Maths/Vector/Distance/Manhattan2D.gdshaderinc`
<br>For 3D - `res://addons/ShaderLib/Maths/Vector/Distance/Manhattan3D.gdshaderinc`
**Method signature**
<br>For 2D - `float manhattan_distance_2d(vec2 point1, vec2 point2)`
<br>For 3D - `float manhattan_distance_3d(vec3 point1, vec3 point2)`
**Parameters for 2D**
|Name|Type|Description|
|---|---|---|
|point1|vec2|Point a|
|point2|vec2|Point b|
**Parameters for 3D**
|Name|Type|Description|
|---|---|---|
|point1|vec3|Point a|
|point2|vec3|Point b|
___