---
title: "SpriteGeometry"
description: "SpriteGeometry"
language: "en"
canonical: "https://l7.antv.antgroup.com/en/api/other/sprite/"
---

[Resource index](/llms.txt)

## Introduction

SpriteGeometry is a universal particle layer provided by L7, which can be used to draw various particle effects.

### demo

Set up a normal particle layer.

```javascript
import { Scene, GeometryLayer } from '@antv/l7';

let layer = new GeometryLayer()
  .shape('sprite')
  .size(10)
  .style({
    opacity: 0.3,
    center: [120, 30],
    spriteCount: 120,
    spriteRadius: 10,
    spriteTop: 300,
    spriteUpdate: 10,
    spriteScale: 0.6,
  });
```

<img width="60%" style="display: block;margin: 0 auto;" alt="案例" src='https://gw.alipayobjects.com/mdn/rms_816329/afts/img/A*PEd7RasIpiEAAAAAAAAAAAAAARQnAQ'>

[Online case](/en/examples/geometry/geometry/snow/)

### source

🌟 SpriteGeometry does not need to set the source, we give its position information through center in style.

### style

SpriteGeometry mainly sets position, size and other properties through the style method.

#### center: \[lng: number, lat: number]

Sets the position of the SpriteGeometry. Positioning is the center of the SpriteGeometry.

#### mapTexture: string

Set the sprite's texture map.

#### spriteRadius: number

The radius of action of particles, default is 10.\
🌟 Individual particles will be randomly distributed within the radius of the layer position.

#### spriteAnimate: string

The particle's movement defaults to 'down', which means downward movement. Optional values ​​are 'down'/'up'.

#### spriteCount: number

The number of particles generated by the layer, default is 100.

#### spriteTop: number

The height range of particle movement, the default is 300.

#### spriteUpdate: number

The step size of particle motion refresh, expressed as motion speed, default is 10.

#### spriteScale: number

Particle size scaling, default is 1.
