载入中...
搜索中...
未找到
PixelWorldGraphics.h
浏览该文件的文档.
1#pragma once
2
3#include "common/Module.h"
4
5#include <cstdint>
6#include <memory>
7
8namespace eve::graphics {
9class Graphics;
10class Texture;
11} // namespace eve::graphics
12
13namespace eve::pixelworld {
14class PixelWorld;
15} // namespace eve::pixelworld
16
18
30public:
32 PixelWorldAtlasRenderer(int originX, int originY, int width, int height);
41
49 int sync(pixelworld::PixelWorld* world, graphics::Graphics* graphics);
50
58 int drawDiagnostics(pixelworld::PixelWorld* world, graphics::Graphics* graphics,
59 float scale);
60
66 graphics::Texture* texture() const noexcept;
68 int originX() const noexcept;
70 int originY() const noexcept;
72 int width() const noexcept;
74 int height() const noexcept;
76 std::uint64_t renderedRevision() const noexcept;
78 std::uint64_t totalUploadedChunks() const noexcept;
80 std::uint64_t uploadCount() const noexcept;
81
82private:
83 struct Impl;
84 std::unique_ptr<Impl> impl_;
85};
86
88class PixelWorldGraphics : public Module {
89public:
91
98 [[nodiscard("retain and delete the returned PixelWorldAtlasRenderer")]]
99 PixelWorldAtlasRenderer* newRenderer(int originX, int originY, int width, int height);
100};
101
102} // namespace eve::pixelworld_graphics
#define EVENGINE_API_WORLD
Definition Export.h:109
std::uint32_t height
std::uint32_t width
std::array< float, 3 > scale
World3D * world
EVENGINE_API_FOUNDATION public API.
Definition Module.h:46
Sparse, chunked, deterministic 2D falling-material world.
Definition PixelWorld.h:224
Render-thread-affine RGBA atlas projection of a rectangular PixelWorld region. @ownership The rendere...
PixelWorldAtlasRenderer(PixelWorldAtlasRenderer &&) noexcept
Pixel world atlas renderer.
~PixelWorldAtlasRenderer()
Pixel world atlas renderer.
Optional rendering satellite for the backend-neutral PixelWorld module.
卡牌游戏 UI 工具模块:工厂 + 脚本绑定入口。 功能参考 ycarowr/UiCard:扇形手牌布局、抽牌/洗牌、悬浮放大、拖拽到落牌区、 敌方手牌(背面/偷看)、费用不足置灰,以及可实时调节的布局...
Definition Animation.h:25