System requirements
| Dependency | Version | Purpose |
|---|---|---|
| Rust | ≥ 1.74 | Compiles the dpf engine binary |
| Go | ≥ 1.23 | Builds the Go bridge and your project |
| musl-tools | any (Debian/Ubuntu) | Required for static binary builds only |
| FFmpeg | ≥ 6.0 | Required for video and audio operations |
Image-only workflows do not require FFmpeg. Install it only if you plan to use
video_* or audio_* operations.Build the engine
Run the full build to compile the Rust engine and the Go example:Or build components individually:The Rust release profile uses
opt-level = 3, fat LTO, and codegen-units = 1 for maximum throughput. Expect the initial build to take 1–3 minutes.Verify the installation
Confirm the binary works by printing its capability report:A successful response lists all supported operations, accepted formats, and engine metadata. If the command exits cleanly, the engine is ready to use.
Set up the Go client
Copy the Update the package declaration in each copied file to match your module path. The files use The Go client has no external dependencies beyond the standard library — no
dpf binary and the Go bridge files into your Go project:package dpf by default, which works if you place them in a directory named dpf.Your final project layout should look like this:go get required.Choosing a client mode
The Go bridge exposes two clients. Choose based on your workload:| Client | How it works | Best for |
|---|---|---|
Client | Spawns a new dpf process per job | Scripts, one-off tasks, simple integrations |
StreamClient | Keeps one dpf process alive; sends jobs over stdin | Servers, batch pipelines, high-throughput workloads |
StreamClient eliminates process-spawn overhead on every call. It is thread-safe and intended for use cases where the binary is initialized once at startup and shared across goroutines:
Timeout configuration
Both clients support configurable timeouts. The default is 30 seconds. Increase it for long video operations:Next steps
Quick Start
Process your first image with the CLI and Go client
Go integration guide
Patterns, error handling, and production best practices
Streaming client
Deep dive into the persistent process mode
Building from source
Advanced build options and cross-compilation