| 1 | #pragma once |
|---|---|
| 2 | |
| 3 | #include <gfx/seadCamera.h> |
| 4 | #include <gfx/seadColor.h> |
| 5 | #include <gfx/seadDrawContext.h> |
| 6 | #include <gfx/seadProjection.h> |
| 7 | #include <heap/seadDisposer.h> |
| 8 | #include "nvn/nvn.h" |
| 9 | #include "thread/seadAtomic.h" |
| 10 | |
| 11 | namespace sead |
| 12 | { |
| 13 | class UniformBlockBuffer |
| 14 | { |
| 15 | public: |
| 16 | void swap(u32 temp, u32 size) |
| 17 | { |
| 18 | _4 = temp; |
| 19 | if (temp + size < size) |
| 20 | { |
| 21 | u32 mod = temp % size; |
| 22 | _4 = mod; |
| 23 | _0 = mod; |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | u32 get_0() const { return _0; } |
| 28 | |
| 29 | private: |
| 30 | Atomic<u32> _0, _4; |
| 31 | }; |
| 32 | |
| 33 | // unknown contents and size |
| 34 | class FontBase |
| 35 | { |
| 36 | public: |
| 37 | virtual ~FontBase(); |
| 38 | |
| 39 | virtual float getHeight() const = 0; |
| 40 | virtual float getWidth() const = 0; |
| 41 | virtual float getCharWidth(char16_t c) const = 0; |
| 42 | virtual u32 getEncoding() const = 0; |
| 43 | virtual u32 getMaxDrawNum() const = 0; |
| 44 | virtual void begin(DrawContext* ctx) const = 0; |
| 45 | virtual void end(DrawContext* ctx) const = 0; |
| 46 | virtual void print(DrawContext* ctx, const Projection& proj, const Camera& cam, |
| 47 | const Matrix34f& mtx, const Color4f& color, const void* text, |
| 48 | int len) const = 0; |
| 49 | }; |
| 50 | |
| 51 | } // namespace sead |
| 52 |