blink::PaintArtifactCompositor
Blink28610 Loka 2025

blink::PaintArtifactCompositor

turns chunks into compositor layers & updates cc property trees.

Consumes the new PaintArtifact and does the layerization and property‑tree updates required for compositor draw. It supports fast paths when only values changed (e.g., opacity) or when a scroll only induces raster invalidation, avoiding full rebuilds. It owns a subtree of cc layers corresponding to the artifact. (Chromium Git Repositories)

Key fields

  • scoped_refptr<cc::Layer> root_layer_ — root of the Blink‑owned layer subtree.

  • UpdateType needs_update_ — kRepaint vs kFull (or scroll fast path).

  • Caches/maps for synthesized mask clips and scroll translations seen while layerizing. (Chromium Git Repositories)

Most important methods

  • bool TryFastPathUpdate(const PaintArtifact&) — take a cheap path (no topology change). (Chromium Git Repositories)

  • void Update(const PaintArtifact&, const ViewportProperties&, const StackScrollTranslationVector&, Vector<std::unique_ptr<cc::ViewTransitionRequest>>) — full reconciliation to layers + cc property trees. (Chromium Git Repositories)

  • “Direct update” helpers like DirectlyUpdateCompositedOpacityValue(...), DirectlyUpdateScrollOffsetTransform(...) — skip rebuilds for common animations/scrolling. (Chromium Git Repositories)

Hands off to: PropertyTreeManager (internally) to mirror Blink property nodes to cc trees, ready for commit to the compositor thread.


Jaksot(391)

Blink’s LocalFrameView: Orchestrating the Rendering Pipeline

Blink’s LocalFrameView: Orchestrating the Rendering Pipeline

The LocalFrameView class serves as the primary engine for managing a document's visual viewport and orchestrating its rendering pipeline within the Blink engine. It functions as a critical bridge betw...

5 Helmi 40min

Chromium View Transitions: A Complete Implementation Deep-Dive

Chromium View Transitions: A Complete Implementation Deep-Dive

This technical documentation explains how Chromium implements View Transitions by coordinating four distinct architectural layers: Blink, the cc compositor, the Viz service, and CSS animations. It det...

5 Helmi 32min

CSS Scroll-Margin: Specification and Implementation in Blink

CSS Scroll-Margin: Specification and Implementation in Blink

The provided text explains the CSS scroll-margin property, a tool within the Scroll Snap module that establishes additional space around an element when it is scrolled into view. While it functions si...

5 Helmi 31min

Modern CSS Carousels: Engineering Performance and Accessibility

Modern CSS Carousels: Engineering Performance and Accessibility

This text explores the technical evolution of CSS carousels, which allow developers to create interactive slideshows using web standards rather than heavy scripting. It details various implementation ...

5 Helmi 33min

CSS Media Queries: Specification and Chromium Implementation Deep Dive

CSS Media Queries: Specification and Chromium Implementation Deep Dive

This document provides a technical deep dive into the evolution and implementation of CSS media queries, tracing their progress from the initial Level 3 standard to the emerging Level 5 draft. It expl...

5 Helmi 36min

Technical Analysis of CSS Nesting and Cascade Layers

Technical Analysis of CSS Nesting and Cascade Layers

The provided text details the technical evolution and implementation of native CSS Nesting, a feature that allows developers to write hierarchical styles directly in the browser. It tracks the specifi...

5 Helmi 32min

Mastering the Third Dimension: A Guide to CSS Perspective

Mastering the Third Dimension: A Guide to CSS Perspective

The provided text explains the CSS perspective property, a technical tool used to simulate three-dimensional depth by defining the distance between a viewer and the screen. It distinguishes between ap...

5 Helmi 31min

Blink Canvas Implementation: Architecture and Rendering Pipeline

Blink Canvas Implementation: Architecture and Rendering Pipeline

The Blink rendering engine implements the HTML canvas element as a versatile drawing surface that supports 2D, WebGL, and WebGPU graphics. Unlike standard DOM elements, the canvas operates in immediat...

5 Helmi 38min