adding debug vulkan resources names

This commit is contained in:
Kbz-8
2024-09-21 12:18:42 +02:00
parent 3f065bc77e
commit 0b3ca8ec0c
27 changed files with 306 additions and 104 deletions

View File

@@ -7,6 +7,7 @@ namespace mlx
{
std::shared_ptr<Mesh> CreateQuad(float x, float y, float width, float height)
{
MLX_PROFILE_FUNCTION();
std::vector<Vertex> data(4);
data[0].position = Vec4f(x, y, 0.0f, 1.0f);
@@ -37,6 +38,7 @@ namespace mlx
Sprite::Sprite(NonOwningPtr<Texture> texture)
{
MLX_PROFILE_FUNCTION();
Verify((bool)texture, "Sprite: invalid texture");
p_mesh = CreateQuad(0, 0, texture->GetWidth(), texture->GetHeight());
p_texture = texture;