# processSource

Function

Source: https://github.com/playcanvas/splat-transform/blob/b6424a5b3b929695fbaafe738a995adb1240d675/src/lib/process-source.ts#L58

```ts
processSource(source: ChunkSource, actions: ProcessAction[], pool: ChunkDataPool, options?: ProcessOptions): Promise<ChunkSource>
```

Apply a sequence of processing actions to a [ChunkSource](https://api.playcanvas.com/splat-transform/interfaces/ChunkSource.md), the streaming
analog of `processDataTable`. Transforms compose lazily onto the pending
`meta.transform` (via mapSource); filters scan the source and return a
filtered view (via filterSource); `stats` streams a one-pass
per-LOD accumulation (via computeSourceStats) — a diagnostic pass
that leaves the data unchanged.

Supports only the SOURCE_ACTION_KINDS; throws on any unsupported
action rather than silently dropping it ([processSourceBridged](https://api.playcanvas.com/splat-transform/functions/processSourceBridged.md) owns
the `processDataTable` fallback for everything else).

**Parameters**

- `source` ([`ChunkSource`](https://api.playcanvas.com/splat-transform/interfaces/ChunkSource.md)): The input source.
- `actions` ([`ProcessAction`](https://api.playcanvas.com/splat-transform/types/ProcessAction.md)`[]`): Actions to apply in order.
- `pool` ([`ChunkDataPool`](https://api.playcanvas.com/splat-transform/interfaces/ChunkDataPool.md)): Pool for the filter passes' temporary read buffers.
- `options` ([`ProcessOptions`](https://api.playcanvas.com/splat-transform/types/ProcessOptions.md), optional): Process options; `sourceFormat` is reported by `info`/`stats`.

**Returns** `Promise<`[`ChunkSource`](https://api.playcanvas.com/splat-transform/interfaces/ChunkSource.md)`>`: The processed source (a view chain over `source`).
