FpsTracker class

Tracks frame rendering performance using Flutter engine callbacks.

Measures average FPS, total frames, and slow frames (>16 ms).

Constructors

FpsTracker()

Properties

averageFps double
Rolling average FPS based on recent frame durations.
no setter
hashCode int
The hash code for this object.
no setterinherited
isTracking bool
Whether the tracker is currently active.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
slowFrames int
Number of frames that exceeded slowFrameThreshold.
no setter
totalFrames int
Total frames observed since tracking started.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reset() → void
Reset all counters.
start() → void
Start listening to frame timings from the Flutter engine.
stop() → void
Stop listening to frame timings.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

maxRecentFrames → const int
Maximum recent frames kept for rolling FPS calculation.
slowFrameThreshold → const Duration
Frames exceeding this duration are considered slow (targeting 60 fps).