Cross-platform 3D Gaussian Splatting implementation with KeyFrame Animation system using pure Vulkan compute shaders — no CUDA dependencies. Python support.
Real-time rendering with keyframe animation system and configurable parameters on NVIDIA RTX 3060 ti
Example PLY: https://huggingface.co/datasets/dylanebert/3dgs/tree/main/bonsai/point_cloud/iteration_30000 SH_DEGREE=3
Most 3DGS implementations rely on CUDA, locking them to NVIDIA GPUs. This project uses standard Vulkan 1.3, and provides:
-
✅ Cross-platform: Runs on Windows, macOS, and Linux
-
✅ Any GPU vendor: NVIDIA, AMD, Intel, Apple Silicon
-
✅ HPC render: 30-90fps real-time gaussian rendering.
-
✅ Python Integration: Bindings to run the renderer from python. For this, check Vulkan 3dgs Python
-
✅ ImGui control System: Features a Keyframe Animation system for real-time rendering, adjustable FOV, wireframe mode, position, rotation, performance metrics, and more.
-
✅ World Axis Reference: Easily modify the coordinate system to match your target PLY file, useful for tilted point clouds or specific viewing rotations.
Note: For AMD change the SUBGROUP_SIZE to 64 in the radix_sort/radixsort.comp shader
Camera Animation:
- Keyframe Recording: Capture camera positions, rotations, and rendering parameters at specific time points
- Smooth Interpolation: Automatic interpolation between keyframes for cinematic camera movements
- Playback Control: Play, stop, and loop through your animation sequences
- Parameter Animation: Animate FOV, near/far planes, wireframe mode, and more
Real-time Controls via ImGui:
-
Camera Settings:
- FOV adjustment (30 - 120)
- Mouse sensitivity (0.01 - 0.4)
- Movement speed (1.0 - 10.0)
-
Rendering Options:
- Distance culling with adjustable near/far planes
- Wireframe mode with Gaussian scale control
- Real-time performance metrics (FPS, GPU memory)
- Tile size configuration (currently fixed at 16)
-
Animation Keyframes Include:
- Camera position (X, Y, Z)
- Camera rotation (Yaw, Pitch)
- Field of View
- Near/Far culling planes
- Wireframe mode toggle
- Timing control
- Vulkan SDK 1.3+ - Download from https://vulkan.lunarg.com/
- Compiler: Visual Studio 2022 (Windows) or GCC/Clang (Linux/macOS)
- CMake 3.16+
git clone --recursive https://github.com/AlejandroAmat/3dgs-vulkan-cpp.git
cd 3dgs-vulkan-cpp
mkdir build
cd build
cmake ..
For Visual Studio users, specify the generator:
cmake -G "Visual Studio 17 2022" ..
# Release build (recommended)
cmake --build . --config Release
# Debug build
cmake --build . --config Debug
Alternative for Visual Studio:
- Open
build/vulkan-3dgs.sln
- Set
vulkan-3dgs
as the startup project - Press F5 to build and run
- Note: The program expects PLY path and optionally width and height - configure these in project properties
The executable will be created in:
- Windows:
build/vulkan-3dgs/Release/vulkan-3dgs.exe
(orDebug/
) - Linux/macOS:
build/vulkan-3dgs/vulkan-3dgs
# Navigate to the executable directory (vulkan-3dgs MacOs/Linux, vulkan-3dgs/Release Windows)
cd vulkan-3dgs/Release
# Run with a PLY file
./vulkan-3dgs.exe path/to/your/pointcloud.ply (optional): width height
#Example
./vulkan-3dgs.exe bonsai.ply
./vulkan-3dgs.exe bonsai.ply 1600 800
- Metal Argument Buffers: For some Vulkan/MoltenVK versions, set
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS=0
before running - Vulkan SDK 1.3.290 is tested and does not require this workaround
build/
└── vulkan-3dgs/
└── Release/
├── vulkan-3dgs.exe
├── Shaders/
│ ├── preprocess.spv
│ ├── render.spv
│ └── ... (other shader files)
└── (place your .ply file here or specify full path)
- WASD - Move forward/backward/left/right
- Q/E - Rotate (Roll)
- C/Space - Move up/down
- Right Mouse + Drag / Two-finger drag (trackpad) - Look around
- Enter Sequence Mode - Click "Enter Sequence" in the Camera Sequence window
- Position Camera - Navigate to desired viewpoint
- Add Keyframe - Captures current camera state and parameters
- Repeat - Add multiple keyframes at different times
- Play - Watch smooth interpolated animation
- Export - Record to video with consistent framerate
- Performance Panel - Real-time FPS, frame time, GPU memory usage
- Camera Panel - Position, rotation, FOV, speed controls
- Rendering Panel - Culling, wireframe, tile size options
- Sequence Panel - Keyframe management and playback
- Graphics API: Vulkan 1.3 (compute + graphics)
- Language: C++17 with modern practices
- Shaders: GLSL → SPIR-V compilation
- Math Library: GLM for transforms
- UI Framework: Dear ImGui for controls
- Build System: CMake (cross-platform)
- Windowing: GLFW for cross-platform support
- Radix Sort: VkRadixSort by MircoWerner for GPU depth sorting with modifications done by 3ds.cpp
- Platforms: Windows, Linux, macOS (mobile planned)
- Vulkan 1.3 compatible GPU and drivers
- C++17 compiler
- CMake 3.16+
- Vulkan SDK
MIT