diff options
author | omniscient <17525998+omnisci3nce@users.noreply.github.com> | 2024-08-11 23:41:41 +1000 |
---|---|---|
committer | omniscient <17525998+omnisci3nce@users.noreply.github.com> | 2024-08-11 23:41:41 +1000 |
commit | a8f98ddcf5ddeb3588492f4ad8f9a289147ad7ec (patch) | |
tree | cabfe0ffe5c41758451723557768841a4df003d7 /src/render | |
parent | 272cc9563315566061bbbd7078f76c76a3484e4b (diff) |
clang format
Diffstat (limited to 'src/render')
-rw-r--r-- | src/render/immdraw.h | 26 | ||||
-rw-r--r-- | src/render/render_types.h | 2 |
2 files changed, 13 insertions, 15 deletions
diff --git a/src/render/immdraw.h b/src/render/immdraw.h index 2983356..6b456d5 100644 --- a/src/render/immdraw.h +++ b/src/render/immdraw.h @@ -17,8 +17,8 @@ typedef struct Immdraw_Storage { } Immdraw_Storage; typedef struct ImmediateUniforms { - Mat4 model; - Vec4 colour; + Mat4 model; + Vec4 colour; } ImmediateUniforms; // --- Public API @@ -36,19 +36,17 @@ PUB void Immdraw_TransformGizmo(Transform tf, f32 size); // --- Internal static ShaderDataLayout ImmediateUniforms_GetLayout(void* data) { - ImmediateUniforms* d = (ImmediateUniforms*)data; - bool has_data = data != NULL; + ImmediateUniforms* d = (ImmediateUniforms*)data; + bool has_data = data != NULL; - ShaderBinding b1 = { - .label = "ImmUniforms", - .kind = BINDING_BYTES, - // .vis = VISIBILITY_VERTEX, - .data.bytes.size = sizeof(ImmediateUniforms) - }; + ShaderBinding b1 = { .label = "ImmUniforms", + .kind = BINDING_BYTES, + // .vis = VISIBILITY_VERTEX, + .data.bytes.size = sizeof(ImmediateUniforms) }; - if (has_data) { - b1.data.bytes.data = d; - } + if (has_data) { + b1.data.bytes.data = d; + } - return (ShaderDataLayout) {.bindings = { b1 }, .binding_count = 1}; + return (ShaderDataLayout){ .bindings = { b1 }, .binding_count = 1 }; } diff --git a/src/render/render_types.h b/src/render/render_types.h index 924777a..ce2c7b8 100644 --- a/src/render/render_types.h +++ b/src/render/render_types.h @@ -42,7 +42,7 @@ typedef struct Mesh { BufferHandle index_buffer; Geometry geometry; // NULL means it has been freed CPU-side MaterialHandle material; - bool is_skinned; // false = its static + bool is_skinned; // false = its static bool is_uploaded; // has the data been uploaded to the GPU } Mesh; #ifndef TYPED_MESH_CONTAINERS |