#include <scene.hpp>
◆ VectorScene()
| pulp::canvas::VectorScene::VectorScene |
( |
| ) |
|
|
inline |
◆ from_svg_file()
| VectorScene pulp::canvas::VectorScene::from_svg_file |
( |
const std::string & | path | ) |
|
|
static |
Convenience: load an SVG file and return a populated scene.
◆ from_svg_string()
| VectorScene pulp::canvas::VectorScene::from_svg_string |
( |
const std::string & | svg_data | ) |
|
|
static |
Parse an SVG document string and produce a populated VectorScene.
Reuses the existing nanosvg parser; visible cubic-Bezier shapes become ScenePath nodes parented to the returned scene's root SceneGroup. Fill / stroke / opacity / fill-rule are translated. Returns an empty (root-only) scene if parsing fails.
◆ note_node_dirtied()
| void pulp::canvas::VectorScene::note_node_dirtied |
( |
const SceneNode & | node | ) |
|
Called by SceneNode::mark_dirty() when a node mutates; unions the node's "old + new" bounds into the pending dirty rect.
◆ paint()
| void pulp::canvas::VectorScene::paint |
( |
Canvas & | canvas | ) |
|
Walk + paint the entire scene to canvas.
Captures each node's painted scene-space bounds so the next take_dirty_rect() call can report exact repaint extents.
◆ peek_dirty_rect()
| SceneRect pulp::canvas::VectorScene::peek_dirty_rect |
( |
| ) |
const |
|
inline |
Peek without resetting — useful for diagnostics + tests.
◆ root() [1/2]
◆ root() [2/2]
| const SceneGroup & pulp::canvas::VectorScene::root |
( |
| ) |
const |
|
inline |
◆ set_root()
| void pulp::canvas::VectorScene::set_root |
( |
std::unique_ptr< SceneGroup > | r | ) |
|
|
inline |
Replace the root group entirely (e.g. after a fresh SVG import).
◆ take_dirty_rect()
| SceneRect pulp::canvas::VectorScene::take_dirty_rect |
( |
| ) |
|
Returns the union of "old painted bounds" and "new transformed
bounds" for every node that mutated since the last paint, then resets the internal pending-dirty tracker.
Empty rect ⇒ nothing to repaint.
The documentation for this class was generated from the following file:
- /home/runner/work/pulp/pulp/core/canvas/include/pulp/canvas/scene/scene.hpp