-Demos:
*added ImGUI styles *added new assets (fonts, shaders) *added cimgui.dll *added imports for bindbc-sdl (for WASM) *added simple demo *added demo launcher *added snake demo *impoved demo utils *added cimgui.bc library for WASM -improved wasm build script -small change in vector
This commit is contained in:
parent
73f2aa6861
commit
cb7609dcaa
82 changed files with 11188 additions and 413 deletions
64
demos/utils/source/ecs_utils/gfx/vertex.d
Normal file
64
demos/utils/source/ecs_utils/gfx/vertex.d
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
module ecs_utils.gfx.vertex;
|
||||
|
||||
import ecs.std;
|
||||
|
||||
struct Vertex
|
||||
{
|
||||
void create()
|
||||
{
|
||||
data = Mallocator.make!Data;
|
||||
}
|
||||
|
||||
void bind()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void enableStates()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void attachBindings(scope Binding[] bindings)
|
||||
{
|
||||
data.bindings = Mallocator.makeArray(bindings);
|
||||
}
|
||||
|
||||
enum Type
|
||||
{
|
||||
byte_r_snorm,
|
||||
byte_r_unorm,
|
||||
byte_rg_snorm,
|
||||
byte_rg_unorm,
|
||||
byte_rgb_snorm,
|
||||
byte_rgb_unorm,
|
||||
byte_rgba_snorm,
|
||||
byte_rgba_unorm,
|
||||
short_r_snorm,
|
||||
short_r_unorm,
|
||||
short_rg_snorm,
|
||||
short_rg_unorm,
|
||||
short_rgb_snorm,
|
||||
short_rgb_unorm,
|
||||
short_rgba_snorm,
|
||||
short_rgba_unorm,
|
||||
float_r,
|
||||
float_rg,
|
||||
float_rgb,
|
||||
float_rgba
|
||||
}
|
||||
|
||||
struct Binding
|
||||
{
|
||||
Type type;
|
||||
uint stride;
|
||||
}
|
||||
|
||||
struct Data
|
||||
{
|
||||
Binding[] bindings;
|
||||
uint size;
|
||||
}
|
||||
|
||||
Data* data;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue