OpenVDB is an open-source C++ library and file format for storing and processing sparse volumetric data on a three-dimensional grid, such as smoke density, fire temperature, cloud shapes and signed distance fields. In 3D graphics & animation, files with the .vdb extension, often simply called VDB files, are the standard way to move volumes between simulation, lighting and rendering software.
OpenVDB was developed at DreamWorks Animation, released as open source in 2012, and is now hosted by the Academy Software Foundation. It is part of the VFX Reference Platform, received a Scientific and Technical Academy Award, and is supported by Houdini, Blender, Maya, Arnold, RenderMan, Redshift and most other major tools. Its strength is that it stores only the voxels that matter while still allowing fast random access.
How the VDB tree stores sparse volumes
OpenVDB organizes voxels in a shallow, hierarchical tree inspired by B+ trees. A dense grid of 2,000 cubed voxels would contain 8 billion values, most of them empty air. The VDB structure instead allocates memory only for regions that contain meaningful data, while the rest of the domain is represented by a single background value.
The default configuration uses a fixed four-level hierarchy. Each level has a fixed branching factor, which keeps tree depth constant and makes lookups predictable. The table below shows the standard layout.
| Level | Node size | Role |
|---|---|---|
| Root node | Sparse hash map | Covers an effectively unbounded index space |
| Upper internal node | 32 x 32 x 32 children | Coarse spatial subdivision |
| Lower internal node | 16 x 16 x 16 children | Finer subdivision |
| Leaf node | 8 x 8 x 8 voxels | Stores actual voxel values |
Regions with a uniform value can be stored as tiles at any internal level, so a large solid interior costs almost nothing. OpenVDB also caches the last visited nodes, so neighboring voxel access during simulation or ray marching is close to constant time. The index space is unbounded, which means a volume can grow in any direction without being resized.
Grid types and typical contents
A single VDB file can contain multiple named grids, each with its own value type, transform and metadata. Simulation tools commonly export a density grid, a temperature grid and a velocity grid together in one file per frame.
| Grid type | Value per voxel | Typical use |
|---|---|---|
| Fog volume | Float density from 0 to 1 | Smoke, clouds, dust rendering |
| Level set | Narrow-band signed distance | Liquid surfaces, collision, meshing |
| Vector grid | Three-component vector | Velocity fields for motion blur |
| Scalar attribute grid | Float or integer | Temperature, flame, fuel, masks |
| Point data grid | Compressed point attributes | Particle caches with millions of points |
Level sets deserve special attention. They store distance to a surface only in a thin band around it, typically three voxels on each side, which makes them very compact. The library includes tools to convert meshes to level sets and back, perform CSG unions and differences, smooth surfaces and fill holes.
OpenVDB compared with other volume and cache formats
Within 3D file formats & pipelines, OpenVDB occupies a specific niche: it is the exchange format for voxel data, while other formats carry meshes, animation or scene description. The table places it alongside formats that pipeline engineers often confuse with it.
| Format | Primary content | Relationship to OpenVDB |
|---|---|---|
| OpenVDB | Sparse voxel grids | Standard for volumes and level sets |
| Alembic | Baked geometry and animation | Carries meshes and points, not volumes |
| USD | Scene description and composition | References VDB files as volume fields |
| OpenEXR | High dynamic range images | Stores rendered output of volumes |
| Field3D | Dense and sparse voxel fields | Older format largely replaced by VDB |
In a USD-based pipeline, a volume prim points to an external .vdb file through an OpenVDBAsset field, so lighting artists can assemble scenes without copying heavy voxel data into the scene file. Renderers then load the VDB directly at render time.
Working with VDB files in production
Most studios write one VDB file per frame, named with a frame number, because simulations change topology constantly. Good practice keeps file sizes manageable and avoids slow renders. The following guidelines reflect common pipeline practice:
- Prune and clip grids before export, removing voxels below a density threshold and outside the camera frustum.
- Store density and temperature as 16-bit half floats when full precision is not visible in the render.
- Enable Blosc or Zip compression; Blosc is usually faster to decompress during rendering.
- Keep consistent grid names such as density, temperature and vel, because renderers and shaders look them up by name.
- Record the voxel size in pipeline metadata, since resampling between different resolutions changes the look.
For real-time and GPU use, the related NanoVDB representation flattens the tree into a single linear buffer that can be uploaded to graphics memory. It is read-only but well suited to GPU ray marching and fast previews.
Limitations and common pitfalls
OpenVDB is efficient but not free of trade-offs. The most frequent problems come from resolution choices and unmanaged file sizes, not from the format itself.
| Symptom | Likely cause | Fix |
|---|---|---|
| Files of several gigabytes per frame | No pruning or full-float precision | Prune, clip and use half floats |
| Blocky or stepped smoke | Voxel size too large for camera distance | Resimulate or upsample with care |
| Missing motion blur | Velocity grid not exported | Include the vel grid in the cache |
| Volume misaligned in scene | Transform lost or units mismatched | Check grid transform and scene scale |
| Slow interactive viewport | Full-resolution grids loaded | Use proxy grids or NanoVDB previews |
Another limitation is that OpenVDB stores values, not shading. Color, scattering and emission come from the renderer’s volume shader, so the same VDB file can look different across renderers unless the shader setup is matched carefully.
The idea in brief
Picture a huge empty warehouse with a small cloud of smoke in one corner. You could describe every cubic inch of the building. Most of that description would say nothing is there. OpenVDB is smarter. It records only the places where smoke actually exists. Empty space is summed up in one short note.
That is why artists use it for smoke, fire, clouds and splashing water. The files stay small enough to move between programs. One shared format lets simulation, lighting and rendering tools all read the same volume.
A practical scenario
A visual effects team is adding a burning building to a live-action shot that lasts 240 frames. An effects artist simulates the fire and smoke in Houdini at a voxel size of about 5 centimeters, then exports density, temperature, flame and velocity grids into one VDB file per frame.
Unpruned, each frame would be close to 3 gigabytes. After clipping voxels outside the camera view, pruning near-empty regions and saving density as half floats, each file shrinks to roughly 400 megabytes. The lighting team references the sequence through a USD volume prim and renders it in a production path tracer with motion blur from the velocity grid. The shot renders on the farm without memory failures, and the same cache is reused for two alternate camera angles.