diff options
author | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-18 12:03:15 +1000 |
---|---|---|
committer | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-18 12:03:15 +1000 |
commit | 4d198fe4f5cbe9e022776bdbd0bd8ec8094c8953 (patch) | |
tree | 4fbbf2feba811ded8923bd964f940f1c71c78c0d /src/ral | |
parent | c3737fff1be704e14a2bada69bbf8a6709c5f670 (diff) |
draw pbr container
Diffstat (limited to 'src/ral')
-rw-r--r-- | src/ral/backends/opengl/backend_opengl.c | 4 | ||||
-rw-r--r-- | src/ral/ral_types.h | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/ral/backends/opengl/backend_opengl.c b/src/ral/backends/opengl/backend_opengl.c index ecf0e80..f4786b9 100644 --- a/src/ral/backends/opengl/backend_opengl.c +++ b/src/ral/backends/opengl/backend_opengl.c @@ -126,7 +126,7 @@ GPU_Pipeline* GPU_GraphicsPipeline_Create(GraphicsPipelineDesc description, assert(binding_id < MAX_PIPELINE_UNIFORM_BUFFERS); ShaderBinding binding = sdl.bindings[binding_j]; // Do I want Buffer vs Bytes? - if (binding.kind == BINDING_BUFFER) { + if (binding.kind == BINDING_BYTES) { static u32 s_binding_point = 0; BufferHandle ubo_handle = GPU_BufferCreate(binding.data.bytes.size, BUFFER_UNIFORM, BUFFER_FLAG_GPU, NULL); // no data right now @@ -317,7 +317,7 @@ PUB void GPU_EncodeBindShaderData(GPU_CmdEncoder* encoder, u32 group, ShaderData } } if (!found) { - ERROR("Couldnt find uniform buffer object!!"); + ERROR("Couldnt find uniform buffer object for %s!!", binding.label); } i32 blockIndex = glGetUniformBlockIndex(encoder->pipeline->shader_id, binding.label); diff --git a/src/ral/ral_types.h b/src/ral/ral_types.h index 092bb2b..54dba56 100644 --- a/src/ral/ral_types.h +++ b/src/ral/ral_types.h @@ -21,6 +21,7 @@ CORE_DEFINE_HANDLE(ShaderHandle); CORE_DEFINE_HANDLE(PipelineLayoutHandle); CORE_DEFINE_HANDLE(PipelineHandle); CORE_DEFINE_HANDLE(RenderpassHandle); +#define INVALID_TEX_HANDLE ((TextureHandle){.raw = 9999999 }) // --- Buffers typedef enum GPU_BufferType{ |