24class UISystem :
public System {
27 ~UISystem()
override =
default;
29 UISystem(
const UISystem& other) =
delete;
30 UISystem& operator=(
const UISystem& other) =
delete;
32 UISystem(UISystem && other) =
delete;
33 UISystem& operator=(UISystem && other) =
delete;
60 size_t blockersBefore;
79 glm::vec2 resolveElement(
82 const UIRect& parentRect,
121 const UIElement& element,
139 const UIElement& element,
158 const UIElement& element,
175 void breakLines(std::string_view text,
const FontAsset& font,
float scale,
float maxWidth,
bool wrap);
185 void resolveInteraction(FrameContext& ctx);
204 const glm::vec2& uv0,
205 const glm::vec2& uv1,
206 const glm::vec4& color,
207 const glm::vec4& bottom,
208 const glm::vec2& shape,
209 const glm::vec4& border,
222 void recolourQuad(uint32_t first,
const glm::vec4& top,
const glm::vec4& bottom);
235 const glm::vec4& color,
236 const UIShape& shape,
242 UIDrawData m_drawData;
244 std::vector<CanvasRef> m_canvases;
246 std::vector<ButtonHit> m_buttonHits;
253 std::vector<ScrollTarget> m_scrollTargets;
256 std::vector<std::string_view> m_lines;
259 std::vector<EntityId> m_pointerBlockers;
261 EntityId m_pressedButton{};
262 glm::vec2 m_pointer{0.0f};
263 float m_wheel = 0.0f;
264 bool m_mouseDown =
false;
265 bool m_mouseDownEdge =
false;
266 bool m_mouseUpEdge =
false;
267 bool m_cursorFree =
false;
268 bool m_pointerIsOurs =
false;
Per-frame state bundle passed to every system.
Definition system.h:55