四个方向 分块渲染

This commit is contained in:
2026-08-12 09:01:25 +08:00
parent b34c0d31b1
commit 9331b4cbf6
24 changed files with 788 additions and 108 deletions
+9
View File
@@ -6,6 +6,7 @@
#include <renderive/renderable/base/Renderable_Base.hpp>
#include <atomic>
#include <functional>
#include <mutex>
#include <string>
@@ -40,11 +41,19 @@ public:
void render(const ::Scene_Render_Context& context) final;
protected:
using Paint_Task_Function =
std::function<void(detail::Painter&, const Render_State_View&)>;
virtual void paint(detail::Painter& painter, const Render_State_View& state) = 0;
virtual void build_paint_task_graph(Renderable_Task_Graph& graph);
Renderable_Task_Graph::Task add_paint_task(Renderable_Task_Graph& graph,
std::string name,
Paint_Task_Function function);
void changed() noexcept;
[[nodiscard]] Size viewport_size() const noexcept;
private:
void build_task_graph(Renderable_Task_Graph& graph) final;
friend class detail::Renderable_State_Observer;
Plot_Core& plot_;
mutable std::mutex metadata_mutex_;