Go to the source code of this file.
Data Structures | |
| struct | font_s |
| a font | |
| struct | lensflare_s |
| a lens flare | |
| struct | light_s |
| a light object | |
| struct | mesh_s |
| a 3d mesh | |
| class | renderer_c |
| Renderer class. More... | |
| struct | shader_s |
| A texture shader. | |
| struct | shader_waveform_s |
| a shader wave form definition | |
| struct | shaderpass_s |
| a single shader pass | |
| struct | state_s |
| struct | triangle_s |
| an indexed triangle | |
Typedefs | |
| typedef triangle_s | triangle_t |
| an indexed triangle | |
| typedef mesh_s | mesh_t |
| a 3d mesh | |
| typedef light_s | light_t |
| a light object | |
| typedef lensflare_s | lensflare_t |
| a lens flare | |
| typedef shader_waveform_s | shader_waveform_t |
| a shader wave form definition | |
| typedef shaderpass_s | shaderpass_t |
| a single shader pass | |
| typedef shader_s | shader_t |
| A texture shader. | |
| typedef font_s | font_t |
| a font | |
Functions | |
| color_t | color_from_floats (float r, float g, float b, float a) |
| convert 4 floats to color | |
| color_t | color_from_vec (const vec4_t in) |
| convert a vec4 to color | |
| void | color_to_vec (color_t color, vec4_t out) |
| convert a color to a vec4 | |
| color_t | color_interpolate (color_t color1, color_t color2, float frac) |
| interpolate two colors | |
| shader_t * | shader_create_simple (ushort blendtype, sshort texture) |
| create a simple shader | |
| shader_t * | shader_create () |
| create a shader | |
| void | shader_init (shader_t *shader, ushort blendtype, sshort texture) |
| initialize a shader | |
| void | shader_initstage (shader_t *shad, ushort n) |
| init shader stage | |
| float | shader_get_waveform_frac (const shader_waveform_t *wf) |
| shader_t * | shader_load (const char *fname) |
Contains all rendering stuff.
Definition in file render.h.
|
|
This creates a new empty shader. Shaders created with the shader_create* functions will be automatically deleted on shutdown. Definition at line 269 of file r_shader.cpp. Referenced by shader_load(). |
|
||||||||||||
|
This creates a shader with 1 stage, the given texture and blendtype. See shader_init for details. Shaders created with the shader_create* functions will be automatically deleted on shutdown. Definition at line 229 of file r_shader.cpp. References shader_init(). Referenced by shader_load(). |
|
|
get waveform amplitude Gets the current amplitude for a shader wave form between 0 and 1. Definition at line 190 of file r_shader.cpp. References PI2. Referenced by renderer_c::render_verts(). |
|
||||||||||||||||
|
Initializes a shader. It will have one shaderstage with the following properties: shader->dynamic = 0;
shader->passes[n].scalex = 1;
shader->passes[n].scaley = 1;
shader->passes[n].soffsetx =
shader->passes[n].soffsety =
shader->passes[n].offsetx =
shader->passes[n].offsety = 0;
shader->passes[n].magfilter = TF_LINEAR;
shader->passes[n].minfilter = TF_LINEAR;
shader->passes[n].texwrapu =
shader->passes[n].texwrapv = TW_REPEAT;
shader->passes[n].rotation =
shader->passes[n].scrollx =
shader->passes[n].scrolly = 0.0f;
shader->passes[n].shiny = 0;
shader->passes[n].colorwave.type = 0;
shader->passes[n].colorwave.bias = 1;
shader->passes[n].color1 =
shader->passes[n].color2 = 0xFFFFFFFF;
shader->passes[n].scalewavex.type = 0;
shader->passes[n].scalewavex.bias = 1;
shader->passes[n].scalewavey.type = 0;
shader->passes[n].scalewavey.bias = 1;
shader->passes[n].lightmap = 1;
shader->passes[n].blendtype = BT_OPAQUE;
shader->passes[n].twosided = 0;
shader->passes[n].nodepth = 0;
shader->passes[0].blendtype = blendtype;
shader->passes[0].texture = texture;
Definition at line 247 of file r_shader.cpp. References shader_initstage(). Referenced by shader_create_simple(). |
|
||||||||||||
|
This initializes a shader stage. See shader_init for details. Definition at line 138 of file r_shader.cpp. Referenced by shader_init(), and shader_load(). |
|
1.2.18