Change TextDrawable base class
This commit is contained in:
@@ -6,9 +6,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "SimpleDrawable.hpp"
|
||||
#include "Drawable.hpp"
|
||||
#include "Texture.hpp"
|
||||
#include "Material.hpp"
|
||||
#include "Geometry.hpp"
|
||||
#include "UniformBuffer.hpp"
|
||||
#include "AtlasData.hpp"
|
||||
@@ -26,10 +25,9 @@ namespace OpenVulkano::Scene
|
||||
float smoothing = 1.f/32.f;
|
||||
};
|
||||
|
||||
class TextDrawable : public SimpleDrawable
|
||||
class TextDrawable : public Drawable
|
||||
{
|
||||
Geometry m_geometry;
|
||||
Material m_material;
|
||||
UniformBuffer m_uniBuffer;
|
||||
std::shared_ptr<AtlasData> m_atlasData;
|
||||
Math::AABB m_bbox;
|
||||
@@ -52,5 +50,9 @@ namespace OpenVulkano::Scene
|
||||
[[nodiscard]] TextConfig& GetConfig() { return m_cfg; }
|
||||
[[nodiscard]] const std::string& GetText() const { return m_text; }
|
||||
[[nodiscard]] const std::shared_ptr<AtlasData> GetAtlasData() { return m_atlasData; }
|
||||
|
||||
[[nodiscard]] Geometry* GetGeometry() { return &m_geometry; }
|
||||
[[nodiscard]] Texture* GetTexture() { return &m_atlasData->texture; }
|
||||
[[nodiscard]] UniformBuffer* GetUniformBuffer() { return &m_uniBuffer; }
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user