# TileCompressionPlugin

class in `3d-tiles-renderer/three/plugins`

```js
import { TileCompressionPlugin } from '3d-tiles-renderer/three/plugins';
```

Plugin that processes tile geometry buffer attributes into smaller data types on load
and disables texture mipmaps to save memory. Can reduce geometry memory footprint by
more than half and texture memory by around a third. Note that the default attribute
size when compression is enabled is fairly aggressive and may cause visual artifacts.

## Constructor

```js
new TileCompressionPlugin( options?: Object )
```

- `options`, `Object`, optional
  - `generateNormals`, `boolean`, optional, default `false`: Generate vertex normals if absent.
  - `disableMipmaps`, `boolean`, optional, default `true`: Disable mipmap generation on tile textures.
  - `compressIndex`, `boolean`, optional, default `true`: Compress index buffers to the smallest fitting integer type.
  - `compressNormals`, `boolean`, optional, default `false`: Compress normal attributes.
  - `compressUvs`, `boolean`, optional, default `false`: Compress UV attributes.
  - `compressPosition`, `boolean`, optional, default `false`: Compress position attributes.
  - `uvType`, `TypedArrayConstructor`, optional, default `Int8Array`: Target type for UV compression.
  - `normalType`, `TypedArrayConstructor`, optional, default `Int8Array`: Target type for normal compression.
  - `positionType`, `TypedArrayConstructor`, optional, default `Int16Array`: Target type for position compression.
