OpenGL Concept Exploration - Ray Tracing and Particle Systems

Project maintained by nolnoch Hosted on GitHub Pages — Theme by mattgraham

Premise: The current, shader-based GPU pipeline in OpenGL makes ray tracing in real time prohibitively complex and inflexible, resulting in an industry avoidance of OpenGL for this kind of rendering. By using OpenCL and its OpenGL interoperability to reconfigure this pipeline, we will achieve real-time ray tracing with an OpenGL program on a modest desktop computer. Further, we may approximate this functionality with greater ease and integration with the OpenGL pipeline by exploring the new compute shaders now that parts of the OpenGL 4.3 standard are available.

By completion, this project will ideally render a crystal cube or sphere suspended in a textured skybox and surrounded by or interacting with a particle system-based water feature.

Working branch: opencl

Required libraries: GLEW, Freeglut, GLM, SOIL, Assimp

Stage 1 (complete): Establish controls and render primitive object in a skybox.

Stage 2 (skipped) : Ray trace the cube to give it a crystal appearance using GLSL.

Stage 3 (current) : Integrate OpenCL 1.2 to handle ray tracing in GPU kernels. [branched]

Stage 4 (planned) : Add some simulation of water to this project.

Stage 5 (planned) : Implement compute shaders to handle ray tracing in GPU kernels.

This project is an exploration of modern OpenGL concepts including:

(**) denotes concepts yet to be implemented.

Design Hardware:   Athlon II X4 640, 8GB RAM, Sapphire Radeon HD 6870
Design Software:   Eclipse CDT Juno on Kubuntu 13.04 Raring


OpenCL 1.2 supports built-in gentypes, vector manipulations, and even printfs! This was unexpected.

Custom Program class

Custom Quaternion class

Custom Mesh class

Matrix management