Crate libredr

Source
Expand description

§LibreDR is an open-source ray-tracing differentiable renderer

[Codeberg Repo] [API Document]

LibreDR uses client-server-worker structure to better utilize multiple GPUs (or even multiple nodes on a cluster).
Some code examples are under the examples/ directory.

§To run server and worker under Linux:

  1. Download libredr_linux_*.tar.gz under [releases].
  2. Start server and worker using examples/scripts/{server,worker}.sh or with your own configuration.
    Example configurations are in examples/scripts. Use clinfo to verify OpenCL runtime.

§To run a server and worker under Windows:

  1. Download libredr_windows_*.zip under [releases].
  2. Start server and worker using examples/scripts/{server,worker}.bat or with your own configuration.
    Example configurations are in examples/scripts.

§To run the example Python codes or your own Python code

  1. Download libredr-*.whl under [releases] and install using pip install, or install from [PyPI].
  2. Run Python example codes examples/scripts/run_example.{sh,bat} or your own client codes.

§All the examples are tested on the following platforms:

VersionOSDeviceDriverNote
🟢v0.0.20Debian Bookworm Linux 6.7.12+bpo-amd64CPU: Intel Core i7-8550UPoCL v3.1Tested on both opencl_program = source and spirv64
🟢v0.0.20Debian Bullseye Linux 6.7.12+bpo-amd64GPU: Hygon DCU Z100LHygon Proprietary v25.04Tested on opencl_program = source
🟢v0.0.20Debian Bullseye Linux 6.7.12+bpo-amd64GPU: NVIDIA GeForce RTX 3090NVIDIA Proprietary v535.216.01Tested on opencl_program = source
🟢v0.0.20Debian Bullseye Linux 6.7.12+bpo-amd64GPU: AMD Radeon RX 6700 XTAMD ROCm AOMP v19.0-3Tested on opencl_program = source
🟢v0.0.20Debian Bullseye Linux 6.7.12+bpo-amd64GPU: Intel UHD Graphics 620Intel NEO v22.43.24595.41Tested on opencl_program = spirv64
🟢v0.0.20Windows 10 21H2 (OS Build 19044.5608)GPU: AMD Radeon RX 6700 XTAMD Proprietary v24.12.1Unix socket and spir* are not available
🟢v0.0.20Windows 10 21H2 (OS Build 19044.5608)GPU: Moore Threads MTT S80Moore Threads Proprietary v290.100.1Tested on OpenCLOn12 v1.2404.1.0 ⚠️ with performance issue

To build from source codes for Linux, check the build scripts in examples/scripts_unix/build/. Docker is used to build manylinux-compatible wheels. For Windows, check examples/scripts_windows/build/.

Copyright (c) 2022-2025 Bohan Yu. All rights reserved.
LibreDR is free software licensed under the GNU Affero General Public License, version 3 or any later version.

Modules§

camera
All camera models (Rust and Python)
light_source
All light source models (Rust and Python)

Structs§

Geometry
Rust interface for Geometry
LibreDR
Rust interface for LibreDR client
PyGeometry
Python interface for Geometry
PyLibreDR
Python interface for LibreDR client

Functions§

py_libredr
Initialize Python module.