File MinecraftUIRenderContext.hpp

Typedefs

using IClientInstance = ClientInstance

Enums

enum TextAlignment

Values:

enumerator Left
enumerator Right
enumerator Center
struct RectangleArea

Public Members

float _x0
float _x1
float _y0
float _y1
struct TextMeasureData

Public Members

float fontSize
int linePadding
bool renderShadow
bool showColorSymbol
bool hideHyphen
struct CaretMeasureData

Public Members

int position
bool shouldRender
class MinecraftUIRenderContext

Public Functions

MinecraftUIRenderContext(IClientInstance &client, ScreenContext &screenContext, const UIScene &currentScene)
virtual ~MinecraftUIRenderContext()
virtual float getLineLength(Font &font, const std::string &text, float fontSize, bool showColorSymbol)
virtual float getTextAlpha()
virtual void setTextAlpha(float alpha)
virtual void drawDebugText(const RectangleArea *rect, const std::string *text, const mce::Color *color, float alpha, ui::TextAlignment alignment, const TextMeasureData *textData, const CaretMeasureData *caretData)
virtual void drawText(Font &font, const RectangleArea &rect, const std::string &text, const mce::Color &color, float alpha, ui::TextAlignment alignment, const TextMeasureData &textData, const CaretMeasureData &caretData)
virtual void flushText(float deltaTime)
virtual void drawImage(const mce::TexturePtr &texture, const glm::tvec2<float> *position, const glm::tvec2<float> *size, glm::tvec2<float> *uv, glm::tvec2<float> *uvSize, int degree)
virtual void drawNineslice(const mce::TexturePtr *texture, const NinesliceInfo *nineslice)
virtual void flushImages(const mce::Color &color, float alpha, const HashedString &materialNameHash)
virtual void beginSharedMeshBatch(ComponentRenderBatch &renderBatch)
virtual void endSharedMeshBatch(ComponentRenderBatch &renderBatch)
virtual void drawRectangle(const RectangleArea *rect, const mce::Color *color, float alpha, int thickness)
virtual void fillRectangle(const RectangleArea *rect, const mce::Color *color, float alpha)
virtual void increaseStencilRef()
virtual void decreaseStencilRef()
virtual void resetStencilRef()
virtual void fillRectangleStencil(const RectangleArea &rect)
virtual void enableScissorTest(const RectangleArea &rect)
virtual void disableScissorTest()
virtual void setClippingRectangle(const RectangleArea &rect)
virtual void setFullClippingRectangle()
virtual void saveCurrentClippingRectangle()
virtual void restoreSavedClippingRectangle()
virtual RectangleArea getFullClippingRectangle()
virtual bool updateCustom(gsl::not_null<CustomRenderComponent*> customRenderer)
virtual void renderCustom(gsl::not_null<CustomRenderComponent*> customRenderer, int pass, RectangleArea &renderAABB)
virtual void cleanup()
virtual void removePersistentMeshes()
virtual mce::TexturePtr getTexture(const ResourceLocation *resourceLocation, bool forceReload)
virtual mce::TexturePtr getZippedTexture(const Core::Path &zippedFolderPath, const ResourceLocation &resourceLocation, bool forceReload)
virtual void unloadTexture(ResourceLocation const&)

Public Members

IClientInstance *mClient
ScreenContext *mScreenContext
std::byte padding24[224]
const UIScene *mCurrentScene
namespace ui

Enums

enum TextAlignment

Values:

enumerator Left
enumerator Right
enumerator Center
namespace mce
namespace Core