CullingEngine class
Provides viewport culling to skip rendering off-screen elements.
All painters should use culling before iterating through data to avoid unnecessary draw calls.
Constructors
- CullingEngine()
-
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
clipLine(
Offset p1, Offset p2, Rect bounds) → (Offset, Offset)? - Cohen-Sutherland line clipping algorithm.
-
cullBars(
List< BarPrimitive> bars, ChartViewport viewport) → List<(BarPrimitive, int)> - Filters bars to only those visible within the viewport.
-
cullPoints(
List< Offset> points, Size canvasSize) → List<Offset> - Filters points to only those within the canvas bounds.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited