File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change 1
- import type { IDelta , IShapeDrawer , Particle } from "@tsparticles/engine" ;
1
+ import type { IShapeDrawData , IShapeDrawer } from "@tsparticles/engine" ;
2
2
3
3
export class ShapeDrawer implements IShapeDrawer {
4
- draw ( _context : CanvasRenderingContext2D ,
5
- _particle : Particle ,
6
- _radius : number ,
7
- _opacity : number ,
8
- _delta : IDelta ,
9
- _pixelRatio : number ) : void {
4
+ draw ( _data : IShapeDrawData ) : void {
10
5
// draw the particle using the context
11
6
// which is already centered in the particle position
12
- // colors are already handles , just draw the shape
7
+ // colors are already handled , just draw the shape
13
8
// the bounds are -radius to radius
14
9
// delta is the frame time difference between the last frame and this one, in ms, use it for animated shapes
15
10
// pixelRatio is the canvas ratio used by the tsParticles instance, you may need it for density-independent shapes
You can’t perform that action at this time.
0 commit comments