ParticlePainter class abstract interface

Abstract interface for rendering particles in a ParticleEffect.

Implement this interface to create custom particle visualizations that can be used with ParticleEffect.

Example:

class CustomParticle implements ParticlePainter {
  @override
  void paint(Canvas canvas, Offset position, Tangent tangent, Paint basePaint) {
    // Custom rendering logic
  }

  @override
  Size get size => const Size(10, 10);
}
Implementers

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
size Size
The size of the particle. Used for layout calculations and bounds checking.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
paint(Canvas canvas, Offset position, Tangent tangent, Paint basePaint) → void
Paints the particle at the given position along the connection path.
toString() String
A string representation of this object.
inherited

Operators

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