nngn
Loading...
Searching...
No Matches
nngn::Gen Struct Reference

#include <gen.h>

Static Public Member Functions

static void quad_indices (u64 i, u64 n, u32 *p)
 
static void quad_vertices (Vertex **p, vec2 bl, vec2 tr, float z, vec3 norm, u32 tex, vec2 uv0, vec2 uv1)
 
static void quad_vertices (Vertex **p, vec2 bl, vec2 tr, float z, vec3 norm, vec3 color)
 
static void quad_vertices_persp (Vertex **p, vec2 bl, vec2 tr, float y, vec3 norm, u32 tex, vec2 uv0, vec2 uv1)
 
static void quad_vertices_zsprite (Vertex **p, vec2 bl, vec2 tr, float z, vec3 norm, u32 tex, vec2 uv0, vec2 uv1)
 
static void cube_vertices (Vertex **p, vec3 pos, vec3 size, vec3 color)
 
static void cube_vertices (Vertex **p, vec3 pos, vec3 size, u32 tex, const std::array< vec4, 6 > &uv)
 
static float text_color (u8 r, u8 g, u8 b)
 
static float text_color (u32 c)
 
static void sprite_ortho (Vertex **p, SpriteRenderer *x)
 
static void sprite_orthoz (Vertex **p, SpriteRenderer *x)
 
static void sprite_persp (Vertex **p, SpriteRenderer *x)
 
static void screen_sprite (Vertex **p, SpriteRenderer *x)
 
static void cube_ortho (Vertex **p, CubeRenderer *x)
 
static void cube_persp (Vertex **p, CubeRenderer *x)
 
static void voxel_ortho (Vertex **p, VoxelRenderer *x)
 
static void voxel_persp (Vertex **p, VoxelRenderer *x)
 
static void sprite_debug (Vertex **p, SpriteRenderer *x)
 
static void cube_debug (Vertex **p, CubeRenderer *x)
 
static void voxel_debug (Vertex **p, VoxelRenderer *x)
 
static void text (Vertex **p, u64 n, const Font &font, const Text &txt, bool mono, float left, vec2 *pos_p, float *color_p, u64 *i_p, u64 *n_visible_p)
 
static void textbox (Vertex **p, const Textbox &x)
 
static void selection (Vertex **p, const SpriteRenderer &x)
 
static void aabb (Vertex **p, const AABBCollider &x, vec3 color)
 
static void aabb_circle (Vertex **p, const AABBCollider &x)
 
static void bb (Vertex **p, const BBCollider &x, vec3 color)
 
static void coll_sphere (Vertex **p, const SphereCollider &x)
 
static void light (Vertex **p, const Light &x, vec3 pos)
 
static void light_range (Vertex **p, const Light &x)
 

Static Private Attributes

static constexpr std::array< vec2, 2 > CIRCLE_UV_32 = {{{ 32/512.0f, 1}, { 64/512.0f, 1 - 32/512.0f}}}
 
static constexpr std::array< vec2, 2 > CIRCLE_UV_64 = {{{128/512.0f, 1}, {256/512.0f, 1 - 128/512.0f}}}
 

Member Function Documentation

◆ aabb()

void nngn::Gen::aabb ( Vertex ** p,
const AABBCollider & x,
vec3 color )
inlinestatic
Here is the call graph for this function:

◆ aabb_circle()

void nngn::Gen::aabb_circle ( Vertex ** p,
const AABBCollider & x )
inlinestatic
Here is the call graph for this function:

◆ bb()

void nngn::Gen::bb ( Vertex ** p,
const BBCollider & x,
vec3 color )
inlinestatic

◆ coll_sphere()

void nngn::Gen::coll_sphere ( Vertex ** p,
const SphereCollider & x )
inlinestatic
Here is the call graph for this function:

◆ cube_debug()

void nngn::Gen::cube_debug ( Vertex ** p,
CubeRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ cube_ortho()

void nngn::Gen::cube_ortho ( Vertex ** p,
CubeRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ cube_persp()

void nngn::Gen::cube_persp ( Vertex ** p,
CubeRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ cube_vertices() [1/2]

void nngn::Gen::cube_vertices ( Vertex ** p,
vec3 pos,
vec3 size,
u32 tex,
const std::array< vec4, 6 > & uv )
inlinestatic
Here is the call graph for this function:

◆ cube_vertices() [2/2]

void nngn::Gen::cube_vertices ( Vertex ** p,
vec3 pos,
vec3 size,
vec3 color )
inlinestatic
Here is the caller graph for this function:

◆ light()

void nngn::Gen::light ( Vertex ** p,
const Light & x,
vec3 pos )
inlinestatic
Here is the call graph for this function:

◆ light_range()

void nngn::Gen::light_range ( Vertex ** p,
const Light & x )
inlinestatic
Here is the call graph for this function:

◆ quad_indices()

void nngn::Gen::quad_indices ( u64 i,
u64 n,
u32 * p )
inlinestatic
Here is the caller graph for this function:

◆ quad_vertices() [1/2]

void nngn::Gen::quad_vertices ( Vertex ** p,
vec2 bl,
vec2 tr,
float z,
vec3 norm,
u32 tex,
vec2 uv0,
vec2 uv1 )
inlinestatic
Here is the caller graph for this function:

◆ quad_vertices() [2/2]

void nngn::Gen::quad_vertices ( Vertex ** p,
vec2 bl,
vec2 tr,
float z,
vec3 norm,
vec3 color )
inlinestatic

◆ quad_vertices_persp()

void nngn::Gen::quad_vertices_persp ( Vertex ** p,
vec2 bl,
vec2 tr,
float y,
vec3 norm,
u32 tex,
vec2 uv0,
vec2 uv1 )
inlinestatic
Here is the caller graph for this function:

◆ quad_vertices_zsprite()

void nngn::Gen::quad_vertices_zsprite ( Vertex ** p,
vec2 bl,
vec2 tr,
float z,
vec3 norm,
u32 tex,
vec2 uv0,
vec2 uv1 )
inlinestatic
Here is the caller graph for this function:

◆ screen_sprite()

void nngn::Gen::screen_sprite ( Vertex ** p,
SpriteRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ selection()

void nngn::Gen::selection ( Vertex ** p,
const SpriteRenderer & x )
inlinestatic
Here is the call graph for this function:

◆ sprite_debug()

void nngn::Gen::sprite_debug ( Vertex ** p,
SpriteRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ sprite_ortho()

void nngn::Gen::sprite_ortho ( Vertex ** p,
SpriteRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ sprite_orthoz()

void nngn::Gen::sprite_orthoz ( Vertex ** p,
SpriteRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ sprite_persp()

void nngn::Gen::sprite_persp ( Vertex ** p,
SpriteRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ text()

void nngn::Gen::text ( Vertex ** p,
u64 n,
const Font & font,
const Text & txt,
bool mono,
float left,
vec2 * pos_p,
float * color_p,
u64 * i_p,
u64 * n_visible_p )
inlinestatic
Here is the call graph for this function:

◆ text_color() [1/2]

float nngn::Gen::text_color ( u32 c)
inlinestatic

◆ text_color() [2/2]

float nngn::Gen::text_color ( u8 r,
u8 g,
u8 b )
inlinestatic
Here is the call graph for this function:
Here is the caller graph for this function:

◆ textbox()

void nngn::Gen::textbox ( Vertex ** p,
const Textbox & x )
inlinestatic
Here is the call graph for this function:

◆ voxel_debug()

void nngn::Gen::voxel_debug ( Vertex ** p,
VoxelRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ voxel_ortho()

void nngn::Gen::voxel_ortho ( Vertex ** p,
VoxelRenderer * x )
inlinestatic
Here is the call graph for this function:

◆ voxel_persp()

void nngn::Gen::voxel_persp ( Vertex ** p,
VoxelRenderer * x )
inlinestatic
Here is the call graph for this function:

Member Data Documentation

◆ CIRCLE_UV_32

std::array<vec2, 2> nngn::Gen::CIRCLE_UV_32 = {{{ 32/512.0f, 1}, { 64/512.0f, 1 - 32/512.0f}}}
staticconstexprprivate

◆ CIRCLE_UV_64

std::array<vec2, 2> nngn::Gen::CIRCLE_UV_64 = {{{128/512.0f, 1}, {256/512.0f, 1 - 128/512.0f}}}
staticprivate

The documentation for this struct was generated from the following file: