gazebosim / gazebosim/gz-rendering
Ogre2: Implement Global Illumination using VCT
- Dominant language
- C++
- Stars
- 81
- Forks
- 90
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 10
Description
Note this ticket is for tracking my work. I'm the one implementing it.
The work can currently be found in [matias-global-illumination](https://github.com/darksylinc/ign-rendering/tree/matias-global-illumination) branch
## Desired behavior
Obtain realtime Global Illumination when using the Ogre2 engine
Ogre2 provides various [GI methods](https://ogrecave.github.io/ogre-next/api/2.3/_gi_methods.html), out of which VCT (Voxel Cone Tracing) is the most reliable and accurate one for simulations.
The class hierarchy is the following:
- **GlobalIlluminationBase** → Contains options shared with most GI solutions
- **GlobalIlluminationVct** → Interface to handle VCT specific parameters
- **BaseGlobalIlluminationVct** → ign-rendering abstraction / implementation detail
- **Ogre2GlobalIlluminationVct** → Engine implementation
The reason for having `GlobalIlluminationBase` is that there may be multiple solutions implemented in the future; including raytracing
## What about render engines that have natural GI (e.g. OptiX)
It is unclear. Technically speaking `GlobalIlluminationBase` is an object where users can specify GI parameters. Users can create more than one if they wish to use different parameters, but only one can be active at the same time.
Right now `GlobalIlluminationBase` only contains simple properties such as `BounceCount`. Probably render engines with natural GI like ray and path tracers could move their bounce count settings to this class.
Since it is likely that there will be a raytracing implementation in the future taking advantage of `VK_KHR_ray_tracing_pipeline`, it should be smart that raytracing-specific options should be centralized into `GlobalIlluminationBase` (or derived implementations if too specific), that includes raytracer/pathtracer engines like OptiX.
This would provide users a familiar interface that can handle multiple engines; and avoid getting into the situtation where certain settings are in a completely different place when changing engines
## Remaining tasks
- [x] Write GI/VCT code
- [x] Light changes should notify GI to recalculate lighting
- [x] Make sample
- [ ] Make unit test
Contributor guide
Assessment
This issue has not been assessed yet.