|
GREM 3.12.0
Game/Rendering Engine Modules for C++
|
Set of reflection probes in 3D space. More...
#include <GREM/graphics_3d/ReflectionProbes3D.hpp>
Classes | |
| struct | AtlasParameters |
| Struct of shader parameters representing the reflection probe atlases. More... | |
| struct | ProbeFields |
| Struct of shader fields representing a reflection probe. More... | |
Public Types | |
| using | AtlasBuffer = UniformBuffer<AtlasParameters, "ReflectionProbes3DAtlases"> |
| Shader buffer for reflection probe atlases. | |
| using | ProbeBuffer = StorageBuffer<ProbeFields, "LightProbeVolumes3DProbes"> |
| Shader buffer for reflection probes. | |
Public Member Functions | |
| ReflectionProbes3D (Device &device, const ReflectionProbes3DOptions &options={}) | |
| Construct an empty set of reflection probes. | |
| ReflectionProbes3D (Device &device, Texture reflectionMaps, ArrayList< ReflectionProbeOptions3D > probeOptions, const ReflectionProbes3DOptions &options) | |
| Construct a pre-baked set of reflection probes. | |
| void | clearReflectionProbes () noexcept |
| Remove all reflection probes from the set. | |
| void | addReflectionProbe (const ReflectionProbeOptions3D &options) |
| Add a reflection probe to the set. | |
| void | setReflectionProbes (const ReflectionProbes3DOptions &newOptions) |
| Set the reflection probe set to the default empty set with new options. | |
| void | setReflectionProbes (Texture newReflectionMaps, ArrayList< ReflectionProbeOptions3D > newProbeOptions, const ReflectionProbes3DOptions &newOptions) |
| Assign a pre-baked set of reflection probes to the reflection probe set. | |
| const Texture & | getReflectionMaps () const noexcept |
| Get the reflection maps of the reflection probes. | |
| Span< const ReflectionProbeOptions3D > | getProbeOptions () const noexcept |
| Get the configuration options for the reflection probes in the set. | |
| ReflectionProbes3DOptions | getOptions () const noexcept |
| Get the configuration options of the reflection probe set. | |
Static Public Attributes | |
| static constexpr TextureSamplerOptions | REFLECTION_MAPS_SAMPLER_OPTIONS |
| Sampler options to use for the reflection maps of reflection probes. | |
Set of reflection probes in 3D space.
| using grem::graphics::ReflectionProbes3D::AtlasBuffer = UniformBuffer<AtlasParameters, "ReflectionProbes3DAtlases"> |
Shader buffer for reflection probe atlases.
| using grem::graphics::ReflectionProbes3D::ProbeBuffer = StorageBuffer<ProbeFields, "LightProbeVolumes3DProbes"> |
Shader buffer for reflection probes.
|
explicit |
Construct an empty set of reflection probes.
| device | device to create the set for. Must outlive the set. |
| options | reflection probe set options, see ReflectionProbes3DOptions. |
| graphics::Error | if resource creation failed. |
| std::length_error | if an internal size limit was exceeded. |
| std::bad_array_new_length | if an internal size limit was exceeded. |
| std::bad_alloc | on allocation failure. |
| grem::graphics::ReflectionProbes3D::ReflectionProbes3D | ( | Device & | device, |
| Texture | reflectionMaps, | ||
| ArrayList< ReflectionProbeOptions3D > | probeOptions, | ||
| const ReflectionProbes3DOptions & | options ) |
Construct a pre-baked set of reflection probes.
| device | device to create the set for. Must outlive the set. |
| reflectionMaps | pre-baked reflection maps for the reflection probes. Must be a valid sampled cube array texture in an RGB(A) color format, or empty if there are no probes. The texture's sampler options should be ReflectionProbes3D::REFLECTION_MAPS_SAMPLER_OPTIONS. |
| probeOptions | list of reflection probe options. |
| options | reflection probe set options, see ReflectionProbes3DOptions. |
| graphics::Error | if resource creation failed. |
| std::length_error | if an internal size limit was exceeded. |
| std::bad_array_new_length | if an internal size limit was exceeded. |
| std::bad_alloc | on allocation failure. |
|
noexcept |
Remove all reflection probes from the set.
| void grem::graphics::ReflectionProbes3D::addReflectionProbe | ( | const ReflectionProbeOptions3D & | options | ) |
Add a reflection probe to the set.
| options | reflection probe options, see ReflectionProbeOptions3D. |
| std::bad_alloc | on allocation failure. |
| std::length_error | if an internal size limit was exceeded. |
| std::bad_array_new_length | if an internal size limit was exceeded. |
| void grem::graphics::ReflectionProbes3D::setReflectionProbes | ( | const ReflectionProbes3DOptions & | newOptions | ) |
Set the reflection probe set to the default empty set with new options.
| newOptions | reflection probe set options, see ReflectionProbes3DOptions. |
| graphics::Error | if resource creation failed. |
| std::length_error | if an internal size limit was exceeded. |
| std::bad_array_new_length | if an internal size limit was exceeded. |
| std::bad_alloc | on allocation failure. |
| void grem::graphics::ReflectionProbes3D::setReflectionProbes | ( | Texture | newReflectionMaps, |
| ArrayList< ReflectionProbeOptions3D > | newProbeOptions, | ||
| const ReflectionProbes3DOptions & | newOptions ) |
Assign a pre-baked set of reflection probes to the reflection probe set.
| newReflectionMaps | pre-baked reflection maps for the reflection probes. Must be a valid sampled cube array texture in an RGB(A) color format, or empty if there are no probes. |
| newProbeOptions | list of reflection probe options. |
| newOptions | reflection probe set options, see ReflectionProbes3DOptions. |
| graphics::Error | if resource creation failed. |
| std::length_error | if an internal size limit was exceeded. |
| std::bad_array_new_length | if an internal size limit was exceeded. |
| std::bad_alloc | on allocation failure. |
|
inlinenodiscardnoexcept |
Get the reflection maps of the reflection probes.
|
inlinenodiscardnoexcept |
Get the configuration options for the reflection probes in the set.
|
inlinenodiscardnoexcept |
Get the configuration options of the reflection probe set.
|
staticconstexpr |
Sampler options to use for the reflection maps of reflection probes.