From e25b20717523e579bb6f1e0d17b635c71bad6fab Mon Sep 17 00:00:00 2001 From: quou Date: Sun, 29 Dec 2024 23:28:00 +1100 Subject: resource names --- ui.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'ui.cpp') diff --git a/ui.cpp b/ui.cpp index f6caedd..bd7a90d 100644 --- a/ui.cpp +++ b/ui.cpp @@ -78,6 +78,7 @@ static Texture_Id create_atlas(Device* d, Arena* a) { int x, y; int size = 10 * font_w; Buffer_Id buf = d->create_buffer( + "font atlas stage", size, Buffer_Flags::copy_src | Buffer_Flags::cpu_readwrite @@ -94,6 +95,7 @@ static Texture_Id create_atlas(Device* d, Arena* a) { } d->unmap_buffer(buf); tex = d->create_texture( + "font atlas", texture_format_r8i, Texture_Flags::sampleable | Texture_Flags::copy_dst, font_w, @@ -111,7 +113,7 @@ static Sampler_Id create_clamped_point(Device* dev) { s.mag = Filter_Mode::point; s.address_u = Address_Mode::clamp; s.address_v = Address_Mode::clamp; - return dev->create_sampler(s); + return dev->create_sampler("clamped point", s); } UI* UI::create(Device* dev, Arena* a, Shader_Id sh) { @@ -140,11 +142,13 @@ void UI::init(Device* dev, Arena* a, Texture_Id at, Shader_Id sh) { atlas = at; shader = sh; mesh = device->create_buffer( + "UI Mesh", mesh_size, Buffer_Flags::vertex_buffer | Buffer_Flags::cpu_readwrite ); config_buf = device->create_buffer( + "UI Cbuffer", sizeof(UI_CBuffer), Buffer_Flags::constant_buffer | Buffer_Flags::cpu_readwrite -- cgit v1.2.3-54-g00ecf