mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-10-30 08:01:01 +00:00
Document smlua_gfx_utils.h
This commit is contained in:
parent
a8a8d50a0c
commit
15c57943ea
3 changed files with 95 additions and 0 deletions
|
|
@ -8063,107 +8063,126 @@ end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets a value of the global fog color
|
||||||
function get_fog_color(index)
|
function get_fog_color(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @return number
|
--- @return number
|
||||||
|
--- Gets the intensity of the fog
|
||||||
function get_fog_intensity()
|
function get_fog_intensity()
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets a value of the global lighting color
|
||||||
function get_lighting_color(index)
|
function get_lighting_color(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets a value of the global ambient lighting color
|
||||||
function get_lighting_color_ambient(index)
|
function get_lighting_color_ambient(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return number
|
--- @return number
|
||||||
|
--- Gets a value of the global lighting direction
|
||||||
function get_lighting_dir(index)
|
function get_lighting_dir(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets the current skybox
|
||||||
function get_skybox()
|
function get_skybox()
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets a value of the global skybox color
|
||||||
function get_skybox_color(index)
|
function get_skybox_color(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets a value of the global vertex shading color
|
||||||
function get_vertex_color(index)
|
function get_vertex_color(index)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value integer
|
--- @param value integer
|
||||||
|
--- Sets a value of the global fog color
|
||||||
function set_fog_color(index, value)
|
function set_fog_color(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param intensity number
|
--- @param intensity number
|
||||||
|
--- Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a desirable range)
|
||||||
function set_fog_intensity(intensity)
|
function set_fog_intensity(intensity)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value integer
|
--- @param value integer
|
||||||
|
--- Sets a value of the global lighting color
|
||||||
function set_lighting_color(index, value)
|
function set_lighting_color(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value integer
|
--- @param value integer
|
||||||
|
--- Sets a value of the global lighting color (run this after `set_lighting_color` for the ambient color to not be overriden)
|
||||||
function set_lighting_color_ambient(index, value)
|
function set_lighting_color_ambient(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value number
|
--- @param value number
|
||||||
|
--- Sets a value of the global lighting direction
|
||||||
function set_lighting_dir(index, value)
|
function set_lighting_dir(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param far number
|
--- @param far number
|
||||||
|
--- Sets the override far plane
|
||||||
function set_override_far(far)
|
function set_override_far(far)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param fov number
|
--- @param fov number
|
||||||
|
--- Sets the override FOV
|
||||||
function set_override_fov(fov)
|
function set_override_fov(fov)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param near number
|
--- @param near number
|
||||||
|
--- Sets the override near plane
|
||||||
function set_override_near(near)
|
function set_override_near(near)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param background integer
|
--- @param background integer
|
||||||
|
--- Sets the override skybox
|
||||||
function set_override_skybox(background)
|
function set_override_skybox(background)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value integer
|
--- @param value integer
|
||||||
|
--- Sets a value of the global skybox color
|
||||||
function set_skybox_color(index, value)
|
function set_skybox_color(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @param index integer
|
--- @param index integer
|
||||||
--- @param value integer
|
--- @param value integer
|
||||||
|
--- Sets a value of the global vertex shading color
|
||||||
function set_vertex_color(index, value)
|
function set_vertex_color(index, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -1780,6 +1780,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`u8 get_fog_color(u8 index);`
|
`u8 get_fog_color(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global fog color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1798,6 +1801,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`f32 get_fog_intensity(void);`
|
`f32 get_fog_intensity(void);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets the intensity of the fog
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1818,6 +1824,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`u8 get_lighting_color(u8 index);`
|
`u8 get_lighting_color(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global lighting color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1838,6 +1847,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`u8 get_lighting_color_ambient(u8 index);`
|
`u8 get_lighting_color_ambient(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global ambient lighting color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1858,6 +1870,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`f32 get_lighting_dir(u8 index);`
|
`f32 get_lighting_dir(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global lighting direction
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1876,6 +1891,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`s8 get_skybox(void);`
|
`s8 get_skybox(void);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets the current skybox
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1896,6 +1914,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`u8 get_skybox_color(u8 index);`
|
`u8 get_skybox_color(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global skybox color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1916,6 +1937,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`u8 get_vertex_color(u8 index);`
|
`u8 get_vertex_color(u8 index);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets a value of the global vertex shading color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1937,6 +1961,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_fog_color(u8 index, u8 value);`
|
`void set_fog_color(u8 index, u8 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global fog color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1957,6 +1984,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_fog_intensity(f32 intensity);`
|
`void set_fog_intensity(f32 intensity);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a desirable range)
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1978,6 +2008,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_lighting_color(u8 index, u8 value);`
|
`void set_lighting_color(u8 index, u8 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global lighting color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -1999,6 +2032,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_lighting_color_ambient(u8 index, u8 value);`
|
`void set_lighting_color_ambient(u8 index, u8 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global lighting color (run this after `set_lighting_color` for the ambient color to not be overriden)
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2020,6 +2056,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_lighting_dir(u8 index, f32 value);`
|
`void set_lighting_dir(u8 index, f32 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global lighting direction
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2040,6 +2079,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_override_far(f32 far);`
|
`void set_override_far(f32 far);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets the override far plane
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2060,6 +2102,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_override_fov(f32 fov);`
|
`void set_override_fov(f32 fov);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets the override FOV
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2080,6 +2125,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_override_near(f32 near);`
|
`void set_override_near(f32 near);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets the override near plane
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2100,6 +2148,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_override_skybox(s8 background);`
|
`void set_override_skybox(s8 background);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets the override skybox
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2121,6 +2172,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_skybox_color(u8 index, u8 value);`
|
`void set_skybox_color(u8 index, u8 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global skybox color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
@ -2142,6 +2196,9 @@
|
||||||
### C Prototype
|
### C Prototype
|
||||||
`void set_vertex_color(u8 index, u8 value);`
|
`void set_vertex_color(u8 index, u8 value);`
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Sets a value of the global vertex shading color
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
|
||||||
|
|
@ -3,29 +3,48 @@
|
||||||
|
|
||||||
#include "types.h"
|
#include "types.h"
|
||||||
|
|
||||||
|
/* |description|Sets the override FOV|descriptionEnd| */
|
||||||
void set_override_fov(f32 fov);
|
void set_override_fov(f32 fov);
|
||||||
|
/* |description|Sets the override near plane|descriptionEnd| */
|
||||||
void set_override_near(f32 near);
|
void set_override_near(f32 near);
|
||||||
|
/* |description|Sets the override far plane|descriptionEnd| */
|
||||||
void set_override_far(f32 far);
|
void set_override_far(f32 far);
|
||||||
|
|
||||||
|
/* |description|Gets a value of the global lighting direction|descriptionEnd| */
|
||||||
f32 get_lighting_dir(u8 index);
|
f32 get_lighting_dir(u8 index);
|
||||||
|
/* |description|Sets a value of the global lighting direction|descriptionEnd| */
|
||||||
void set_lighting_dir(u8 index, f32 value);
|
void set_lighting_dir(u8 index, f32 value);
|
||||||
|
|
||||||
|
/* |description|Gets a value of the global lighting color|descriptionEnd| */
|
||||||
u8 get_lighting_color(u8 index);
|
u8 get_lighting_color(u8 index);
|
||||||
|
/* |description|Gets a value of the global ambient lighting color|descriptionEnd| */
|
||||||
u8 get_lighting_color_ambient(u8 index);
|
u8 get_lighting_color_ambient(u8 index);
|
||||||
|
/* |description|Sets a value of the global lighting color|descriptionEnd| */
|
||||||
void set_lighting_color(u8 index, u8 value);
|
void set_lighting_color(u8 index, u8 value);
|
||||||
|
/* |description|Sets a value of the global lighting color (run this after `set_lighting_color` for the ambient color to not be overriden)|descriptionEnd| */
|
||||||
void set_lighting_color_ambient(u8 index, u8 value);
|
void set_lighting_color_ambient(u8 index, u8 value);
|
||||||
|
|
||||||
|
/* |description|Gets a value of the global vertex shading color|descriptionEnd| */
|
||||||
u8 get_vertex_color(u8 index);
|
u8 get_vertex_color(u8 index);
|
||||||
|
/* |description|Sets a value of the global vertex shading color|descriptionEnd| */
|
||||||
void set_vertex_color(u8 index, u8 value);
|
void set_vertex_color(u8 index, u8 value);
|
||||||
|
|
||||||
|
/* |description|Gets a value of the global fog color|descriptionEnd| */
|
||||||
u8 get_fog_color(u8 index);
|
u8 get_fog_color(u8 index);
|
||||||
|
/* |description|Sets a value of the global fog color|descriptionEnd| */
|
||||||
void set_fog_color(u8 index, u8 value);
|
void set_fog_color(u8 index, u8 value);
|
||||||
|
/* |description|Gets the intensity of the fog|descriptionEnd| */
|
||||||
f32 get_fog_intensity(void);
|
f32 get_fog_intensity(void);
|
||||||
|
/* |description|Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a desirable range)|descriptionEnd| */
|
||||||
void set_fog_intensity(f32 intensity);
|
void set_fog_intensity(f32 intensity);
|
||||||
|
|
||||||
|
/* |description|Gets the current skybox|descriptionEnd| */
|
||||||
s8 get_skybox(void);
|
s8 get_skybox(void);
|
||||||
|
/* |description|Sets the override skybox|descriptionEnd| */
|
||||||
void set_override_skybox(s8 background);
|
void set_override_skybox(s8 background);
|
||||||
|
/* |description|Gets a value of the global skybox color|descriptionEnd| */
|
||||||
u8 get_skybox_color(u8 index);
|
u8 get_skybox_color(u8 index);
|
||||||
|
/* |description|Sets a value of the global skybox color|descriptionEnd| */
|
||||||
void set_skybox_color(u8 index, u8 value);
|
void set_skybox_color(u8 index, u8 value);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue