30 lines
712 B
C++
30 lines
712 B
C++
// Copyright (c) 2023 Dominic Masters
|
|
//
|
|
// This software is released under the MIT License.
|
|
// https://opensource.org/licenses/MIT
|
|
|
|
#pragma once
|
|
#include "UIComponentRenderable.hpp"
|
|
#include "display/mesh/QuadMesh.hpp"
|
|
|
|
#define UI_BORDER_QUAD_COUNT 9
|
|
|
|
namespace Dawn {
|
|
class UIBorder : public UIComponentRenderable {
|
|
private:
|
|
Mesh mesh;
|
|
|
|
public:
|
|
// @optional
|
|
StateProperty<glm::vec2> borderSize;
|
|
// @optional
|
|
StateProperty<Texture*> texture;
|
|
|
|
UIBorder(SceneItem *item);
|
|
|
|
float_t getContentWidth() override;
|
|
float_t getContentHeight() override;
|
|
std::vector<struct ShaderPassItem> getUIRenderPasses() override;
|
|
void onStart() override;
|
|
};
|
|
} |