Skip to main content

Crate xgpui_svg

Crate xgpui_svg 

Source
Expand description

Experimental SVG documents, bounded raster targets, progressive scheduling and retained contour trim/dash effects before native stroke tessellation. SvgImage owns GPUI raster tasks and timers; low-level queue APIs remain available.

Modules§

path_effects
Bounded contour effects before native stroke tessellation. Coordinates, dash lengths, phase and tolerance are logical pixels.

Structs§

Job
RasterImage
Full-color CPU image and raster/conversion wall time. Clone shares image bytes.
RasterPolicy
Bounds image buffers, not resvg’s filter intermediates or GPU residency.
RasterQueue
A latest-request queue. Time is supplied by the host for deterministic tests. Active resvg work is never claimed to be interruptible.
Resolution
SchedulerLimits
Shared limits for accounted image memory, not a hard process/GPU-memory cap.
SchedulerStats
SvgDocument
A parsed, immutable static SVG. Clone shares the tree; no hidden image cache.
SvgImage
Full-color SVG with element-owned progressive rendering. The ID must remain stable and unique among siblings. Set layout dimensions with GPUI’s Styled API.
SvgScheduler
Clone one pool into every SvgImage in a gallery. Limits are immutable. Retained RGBA is charged twice (CPU plus nominal GPU); a job reserves three times RGBA for output/conversion/upload. Filter intermediates, atlas packing, parsed trees and allocator/driver retention are outside these estimates.
SvgStatus
Progress for one mounted element. Output budget excludes filter/GPU memory.

Enums§

Stage
SvgPhase

Constants§

MIB

Functions§

image_bytes
svg_image
Construct a contained SVG viewport. Transparent backdrop; fills its parent by default. Raster state lives as long as this ID is rendered in consecutive frames.