File NinesliceHelper.hpp

namespace Amethyst
struct TextureUV

Public Members

glm::tvec2<float> uvPos
glm::tvec2<float> uvSize
float width
float height
class NinesliceHelper

Public Functions

NinesliceHelper(int textureWidth, int textureHeight, int ninesliceWidth, int nicesliceHeight)
void Draw(RectangleArea &rect, const mce::TexturePtr *texture, MinecraftUIRenderContext *ctx)

Private Functions

TextureUV Slice(int x, int y, int xSize, int ySize) const
ImageInfo Scale(TextureUV *slice, float x, float y, float xSize, float ySize)

Private Members

float mTextureWidth
float mTextureHeight
float mNinesliceWidth
float mNinesliceHeight
TextureUV mSlices[9]