pub fn transform_extracted_to_nodes(
retained: ResMut<'_, RetainedScene>,
previous: ResMut<'_, PreviousScene>,
rects: Query<'_, '_, &ExtractedRect>,
borders: Query<'_, '_, &ExtractedBorder>,
shadows: Query<'_, '_, &ExtractedShadow>,
outlines: Query<'_, '_, &ExtractedOutline>,
texts: Query<'_, '_, &ExtractedText>,
images: Query<'_, '_, (&ExtractedImage, Option<&ImageBlob>)>,
svgs: Query<'_, '_, &SvgPayload>,
clips: Query<'_, '_, &ExtractedClipBox>,
scrollbars: Query<'_, '_, &ExtractedScrollbar>,
)Expand description
Builds a RetainedScene from the flat Extracted* components in the render world.
Walks every ExtractedRect/Shadow/Outline/Text/Image/Svg/ClipBox once, sorts the leaves by
PaintOrder, folds the clip pairs around the leaves they enclose, and produces an Arc<Node::Container>
containing the painter-ordered children. The previous frame’s root is moved into PreviousScene so the
walker can diff against it.
Runs in crate::render_world::RenderStage::Prepare (registered by App::new).