Improved online performance for canvases with many components

This commit is contained in:
Yousef Khadadeh 2025-07-26 21:20:14 +03:00
parent 8a36bc4b6d
commit b6a25280e6
16 changed files with 406 additions and 183 deletions

View file

@ -12,11 +12,10 @@ class EraserTool {
void tool_update();
void reset_tool();
void draw(SkCanvas* canvas, const DrawData& drawData);
private:
std::unordered_set<CollabListType::ObjectInfoPtr> erasedComponents;
std::unordered_set<std::shared_ptr<DrawingProgramCacheBVHNode>> erasedBVHNodes;
void move_erased_components_from_bvh_nodes_recursive(const std::shared_ptr<DrawingProgramCacheBVHNode>& bvhNode);
private:
DrawingProgram& drawP;
};