Introduction

LuxRays is the name we have chosen for the part of LuxRender dedicated to accelerate the ray intersection process by using GPUs. You can find more information about the ongoing effort of integrating OpenCL support in Luxrender here.

An open source component for accelerating any ray tracing application

GPGPU computing is a formidable tool to accelerate any ray tracing application. Test result has shown has modern GPGPUs can easily increase the performance of an ray tracer by an order of magnitude. This is a simple path tracer (SmallptGPU) running on a GPU at the eye-popping speed of 114,000,000 of samples/sec:

This is exactly the same scene rendered first with Luxrender for 60 seconds with Metropolis sampler and Path surface integrator:

Integrating GPU support is going to be a mandatory task for any open source rendering engine. The Luxrender team wants to share its effort with other open source developers and decided to develop LuxRays as a stand-alone library. This library will be developed with the main task of accelerating Luxrender but it will be available for any other project that does not want to waste its time developing a duplicate of our work. Indeed, as in any open source project, any contribution will be highly welcome.

License

All the code included in LuxRays repository (i.e. LuxRays, LuxCore, LuxCore implementation aka SLG) has been released under a new license: Apache Licence 2.0. It is a very liberal license allowing the use of the code inside commercial products too.

Features

LuxRays will have the following list of features (in bold the features already implemented):

C++ API;

a wrapper written in C in order to expose the API to C application too;

Multiple OS support (i.e. Linux, Windows, MacOS);

Multiple hardware support (i.e. ATI and NVIDIA via OpenCL);

Support for rendering over a wide range of heterogeneous devices like CPU, GPU, CPU+GPU, CPU+Multiple-GPUs;

a level of abstraction over rendering device available with support for:

support for Virtual Devices (i.e. many GPUs seen as a single device or one GPU seen as multiple devices).

LuxRays is mainly developed to accelerate off-line renderings. Even if the current generation of GPUs are so fast to offer near real-time rendering time, we are going to optimize for bandwidth (i.e. number of ray intersections per seconds) over latency.

A data parallel model

LuxRays uses a Data Parallel Model: it doesn't reduce the time spent to trace a single ray but it is able to trace many thousands of rays in parallel.

Hybrid CPU/GPU mode

LuxRays supports Hybrid CPU/GPU mode where only the ray intersection task is off load to the GPUs while everything else run on the CPU and can be written with usual tools and languages.

GPU-only mode

LuxRays support also GPU-only mode where all the work is done by the GPUs and the code is all written in OpenCL. This is an example where i7 860 + 5870 + 5850 are used:

Status of the project

LuxRays is a recently started sub-project of Luxrender. A specification of the API is not yet available. SmallLuxGPU has been used as test to define how the API should work and to collect performance results:

Building on Linux

Ubuntu 10.04

Install the OpenCL SDK for your GPU. AMD/ATI OpenCL SDK is available here. NVIDIA OpenCL headers and libraries should be already included with the X11 driver. (Check /usr/include/CL/ for all headers listed on the page linked below and download them manually if required).
OpenCL C++ bindings (i.e. cl.hpp) are included in ATI SDK and they will be part of OpenCL standard from version 1.1. NVIDIA doesn't yet include this file in its SDK but you can find a copy here (linked from this page)