|
Nebula
|
Implements the shader server used by Vulkan.
Classes | |
| struct | BindlessRegistryCreateInfo |
| class | CameraContext |
| Handles cameras. More... | |
| class | CameraSettings |
| class | EnvironmentContext |
| The environment context deals with anything related to the sky and atmosphere effects. More... | |
| struct | GlobalConstantsCreateInfo |
| struct | GraphicsContextFunctionBundle |
| struct | ContextEntityId |
| struct | GraphicsContextState |
| A graphics context is a resource which holds a contextual representation for a graphics entity. More... | |
| class | GraphicsContext |
| class | GraphicsDisplayEventHandler |
| Handles DisplayEvents that are relevant for the graphics system. More... | |
| struct | GraphicsEntityId |
| The graphics entity is only an Id, to which we can attach GraphicsContexts. More... | |
| struct | FrameContext |
| class | GraphicsServer |
| The graphics server is the main singleton for the Graphics subsystem. More... | |
| struct | ViewId |
| struct | ViewCreateInfo |
| class | LightProbeContext |
| Adds a light probe component to graphics entities. More... | |
Typedefs | |
| typedef uint32_t | BindlessIndex |
| using | ViewIndependentCall = void(*)(const Graphics::FrameContext& ctx) |
| using | ViewDependentCall = void(*)(const ViewId view, const Graphics::FrameContext& ctx) |
| typedef uint16_t | StageMask |
| typedef Ids::IdAllocator< Shared::ViewConstants::STRUCT, Shared::ShadowViewConstants::STRUCT, CoreGraphics::TextureId, Math::rectangle< int >, Graphics::StageMask, bool(*)(const Math::rectangle< int > &viewport, IndexT frameIndex, IndexT bufferIndex), GraphicsEntityId, bool > | ViewAllocator |
Enumerations | |
| enum class | GlobalTables { GraphicsQueue , ComputeQueue , NumQueues } |
| enum | { View_ViewConstants , View_ShadowConstants , View_OutputTarget , View_Viewport , View_StageMask , View_FrameScriptFunc , View_Camera , View_Enabled } |
Functions | |
| void | CreateBindlessRegistry (const BindlessRegistryCreateInfo &info) |
| Create bindless registry. | |
| void | DestroyBindlessRegistry () |
| Destroy bindless registry. | |
| BindlessIndex | RegisterTexture (const CoreGraphics::TextureId &tex, CoreGraphics::TextureType type, bool depth=false, bool stencil=false) |
| Register texture. | |
| void | ReregisterTexture (const CoreGraphics::TextureId &tex, CoreGraphics::TextureType type, BindlessIndex id, bool depth=false, bool stencil=false) |
| Reregister texture on the same slot. | |
| void | UnregisterTexture (const BindlessIndex id, const CoreGraphics::TextureType type) |
| Unregister texture. | |
| __ImplementContext (CameraContext, CameraContext::cameraAllocator) | |
| __ImplementPluginContext (EnvironmentContext) | |
| Math::vec4 | CalculateZenithLuminanceYxy (float t, float thetaS) |
| void | CalculatePerezDistribution (float t, Math::vec4 &A, Math::vec4 &B, Math::vec4 &C, Math::vec4 &D, Math::vec4 &E) |
| void | CreateGlobalConstants (const GlobalConstantsCreateInfo &info) |
| Create global constants. | |
| void | DestroyGlobalConstants () |
| Destroy global constants. | |
| void | AllocateGlobalConstants () |
| Run when starting frame. | |
| void | UpdateTickParams (const Shared::PerTickParams::STRUCT &tickParams) |
| Set tick params. | |
| void | UpdateViewConstants (const Shared::ViewConstants::STRUCT &viewConstants) |
| Set view params. | |
| void | UpdateShadowConstants (const Shared::ShadowViewConstants::STRUCT &shadowViewConstants) |
| Set camera params. | |
| void | FlushUpdates (const CoreGraphics::CmdBufferId buf, const CoreGraphics::QueueType queue) |
| Flush constants by recording update command to command buffer. | |
| void | GetOffsets (uint64_t &tickOffset, uint64_t &viewOffset, uint64_t &shadowOffset, const GlobalTables table) |
| Get frame constant offsets. | |
| const Shared::PerTickParams::STRUCT & | GetTickParams () |
| Get tick params constant buffer. | |
| void | SetGlobalEnvironmentTextures (const CoreGraphics::TextureId &env, const CoreGraphics::TextureId &irr, const SizeT numMips) |
| Set global irradiance and cubemaps. | |
| void | SetupBufferConstants () |
| Setup gbuffer bindings. | |
| const CoreGraphics::ResourceTableId | GetFrameResourceTable (uint32_t bufferIndex, GlobalTables table) |
| Get per-tick resource table for queue. | |
| const std::array< CoreGraphics::ResourceTableId,(uint) GlobalTables::NumQueues > | GetFrameResourceTables (uint32_t bufferIndex) |
| Get per-tick resource tables for all queues. | |
| const CoreGraphics::ResourceTableId | GetTickResourceTable (uint32_t bufferIndex, GlobalTables table) |
| Get per-tick resource table for queue. | |
| const std::array< CoreGraphics::ResourceTableId,(uint) GlobalTables::NumQueues > | GetTickResourceTables (uint32_t bufferIndex) |
| Get per-tick resource table for all queues. | |
| const std::array< CoreGraphics::QueueType,(uint) GlobalTables::NumQueues > | GetTableQueues () |
| Get the different per-queue resource tables. | |
| __ImplementClass (Graphics::GraphicsDisplayEventHandler, 'WGEH', CoreGraphics::DisplayEventHandler) | |
| __ImplementClass (Graphics::GraphicsServer, 'GFXS', Core::RefCounted) | |
| __ImplementSingleton (Graphics::GraphicsServer) | |
| static GraphicsEntityId | CreateEntity () |
| static void | DestroyEntity (const GraphicsEntityId id) |
| template<typename ... CONTEXTS> | |
| static void | RegisterEntity (const GraphicsEntityId id) |
| template<typename ... CONTEXTS> | |
| static void | DeregisterEntity (const GraphicsEntityId id) |
| template<typename ... CONTEXTS> | |
| static void | DeregisterEntityImmediate (const GraphicsEntityId id) |
| ViewId | CreateView (const ViewCreateInfo &info) |
| Create a new view. | |
| void | DestroyView (const ViewId id) |
| Destroy view. | |
| void | ViewApply (const ViewId id) |
| Apply view. | |
| bool | ViewRender (const ViewId id, const IndexT frameIndex, const Timing::Time time, const IndexT bufferIndex) |
| Render view. | |
| void | ViewSetFrameScript (const ViewId id, bool(*func)(const Math::rectangle< int > &viewport, IndexT frameIndex, IndexT bufferIndex)) |
| Set view frame script. | |
| void | ViewSetViewport (const ViewId id, const Math::rectangle< int > &rect) |
| Set view viewport. | |
| const Math::rectangle< int > & | ViewGetViewport (const ViewId id) |
| Get view viewport. | |
| void | ViewSetCamera (const ViewId id, const GraphicsEntityId &camera) |
| Set view camera. | |
| const GraphicsEntityId & | ViewGetCamera (const ViewId id) |
| Get view camera. | |
| Shared::ViewConstants::STRUCT & | ViewGetViewConstants (const ViewId id) |
| Get view constants. | |
| Shared::ShadowViewConstants::STRUCT & | ViewGetShadowConstants (const ViewId id) |
| Get shadow view constants. | |
| void | ViewSetStageMask (const ViewId id, const Graphics::StageMask stage) |
| Set view stage. | |
| const Graphics::StageMask | ViewGetStageMask (const ViewId id) |
| Get view stage. | |
| void | ViewEnable (const ViewId id) |
| Enable view. | |
| void | ViewDisable (const ViewId id) |
| Disable view. | |
| bool | ViewIsEnabled (const ViewId id) |
| Check if view is enabled. | |
| static constexpr StageMask | StageMaskFromIndex (const IndexT stageIndex) |
| __ImplementContext (LightProbeContext, LightProbeContext::lightProbeAllocator) | |
| typedef uint32_t Graphics::BindlessIndex |
| typedef uint16_t Graphics::StageMask |
| typedef Ids::IdAllocator< Shared::ViewConstants::STRUCT, Shared::ShadowViewConstants::STRUCT, CoreGraphics::TextureId, Math::rectangle<int>, Graphics::StageMask, bool (*)(const Math::rectangle<int>& viewport, IndexT frameIndex, IndexT bufferIndex), GraphicsEntityId, bool> Graphics::ViewAllocator |
| using Graphics::ViewDependentCall = void(*)(const ViewId view, const Graphics::FrameContext& ctx) |
| using Graphics::ViewIndependentCall = void(*)(const Graphics::FrameContext& ctx) |
| anonymous enum |
|
strong |
| Graphics::__ImplementClass | ( | Graphics::GraphicsDisplayEventHandler | , |
| 'WGEH' | , | ||
| CoreGraphics::DisplayEventHandler | ) |
| Graphics::__ImplementClass | ( | Graphics::GraphicsServer | , |
| 'GFXS' | , | ||
| Core::RefCounted | ) |
| Graphics::__ImplementContext | ( | CameraContext | , |
| CameraContext::cameraAllocator | ) |
| Graphics::__ImplementContext | ( | LightProbeContext | , |
| LightProbeContext::lightProbeAllocator | ) |
| Graphics::__ImplementPluginContext | ( | EnvironmentContext | ) |
| void Graphics::AllocateGlobalConstants | ( | ) |
Run when starting frame.
| void Graphics::CalculatePerezDistribution | ( | float | t, |
| Math::vec4 & | A, | ||
| Math::vec4 & | B, | ||
| Math::vec4 & | C, | ||
| Math::vec4 & | D, | ||
| Math::vec4 & | E ) |
| Math::vec4 Graphics::CalculateZenithLuminanceYxy | ( | float | t, |
| float | thetaS ) |
| void Graphics::CreateBindlessRegistry | ( | const BindlessRegistryCreateInfo & | info | ) |
Create bindless registry.
|
static |
| void Graphics::CreateGlobalConstants | ( | const GlobalConstantsCreateInfo & | info | ) |
Create global constants.
| ViewId Graphics::CreateView | ( | const ViewCreateInfo & | info | ) |
Create a new view.
|
static |
|
static |
| void Graphics::DestroyBindlessRegistry | ( | ) |
Destroy bindless registry.
|
static |
| void Graphics::DestroyGlobalConstants | ( | ) |
Destroy global constants.
| void Graphics::DestroyView | ( | const ViewId | id | ) |
Destroy view.
| void Graphics::FlushUpdates | ( | const CoreGraphics::CmdBufferId | buf, |
| const CoreGraphics::QueueType | queue ) |
Flush constants by recording update command to command buffer.
| const CoreGraphics::ResourceTableId Graphics::GetFrameResourceTable | ( | uint32_t | bufferIndex, |
| GlobalTables | table ) |
Get per-tick resource table for queue.
| const std::array< CoreGraphics::ResourceTableId,(uint) GlobalTables::NumQueues > Graphics::GetFrameResourceTables | ( | uint32_t | bufferIndex | ) |
Get per-tick resource tables for all queues.
| void Graphics::GetOffsets | ( | uint64_t & | tickOffset, |
| uint64_t & | viewOffset, | ||
| uint64_t & | shadowOffset, | ||
| const GlobalTables | table ) |
Get frame constant offsets.
| const std::array< CoreGraphics::QueueType,(uint) GlobalTables::NumQueues > Graphics::GetTableQueues | ( | ) |
Get the different per-queue resource tables.
| const Shared::PerTickParams::STRUCT & Graphics::GetTickParams | ( | ) |
Get tick params constant buffer.
| const CoreGraphics::ResourceTableId Graphics::GetTickResourceTable | ( | uint32_t | bufferIndex, |
| GlobalTables | table ) |
Get per-tick resource table for queue.
| const std::array< CoreGraphics::ResourceTableId,(uint) GlobalTables::NumQueues > Graphics::GetTickResourceTables | ( | uint32_t | bufferIndex | ) |
Get per-tick resource table for all queues.
|
static |
| BindlessIndex Graphics::RegisterTexture | ( | const CoreGraphics::TextureId & | tex, |
| CoreGraphics::TextureType | type, | ||
| bool | depth, | ||
| bool | stencil ) |
Register texture.
| void Graphics::ReregisterTexture | ( | const CoreGraphics::TextureId & | tex, |
| CoreGraphics::TextureType | type, | ||
| BindlessIndex | index, | ||
| bool | depth, | ||
| bool | stencil ) |
Reregister texture on the same slot.
| void Graphics::SetGlobalEnvironmentTextures | ( | const CoreGraphics::TextureId & | env, |
| const CoreGraphics::TextureId & | irr, | ||
| const SizeT | numMips ) |
Set global irradiance and cubemaps.
| void Graphics::SetupBufferConstants | ( | ) |
Setup gbuffer bindings.
| void Graphics::UnregisterTexture | ( | const BindlessIndex | id, |
| const CoreGraphics::TextureType | type ) |
Unregister texture.
| void Graphics::UpdateShadowConstants | ( | const Shared::ShadowViewConstants::STRUCT & | shadowViewConstants | ) |
Set camera params.
| void Graphics::UpdateTickParams | ( | const Shared::PerTickParams::STRUCT & | tickParams | ) |
Set tick params.
| void Graphics::UpdateViewConstants | ( | const Shared::ViewConstants::STRUCT & | viewConstants | ) |
Set view params.
| void Graphics::ViewApply | ( | const ViewId | id | ) |
Apply view.
| void Graphics::ViewDisable | ( | const ViewId | id | ) |
Disable view.
| void Graphics::ViewEnable | ( | const ViewId | id | ) |
Enable view.
| const GraphicsEntityId & Graphics::ViewGetCamera | ( | const ViewId | id | ) |
Get view camera.
| Shared::ShadowViewConstants::STRUCT & Graphics::ViewGetShadowConstants | ( | const ViewId | id | ) |
Get shadow view constants.
| const Graphics::StageMask Graphics::ViewGetStageMask | ( | const ViewId | id | ) |
Get view stage.
| Shared::ViewConstants::STRUCT & Graphics::ViewGetViewConstants | ( | const ViewId | id | ) |
Get view constants.
| const Math::rectangle< int > & Graphics::ViewGetViewport | ( | const ViewId | id | ) |
Get view viewport.
| bool Graphics::ViewIsEnabled | ( | const ViewId | id | ) |
Check if view is enabled.
| bool Graphics::ViewRender | ( | const ViewId | id, |
| const IndexT | frameIndex, | ||
| const Timing::Time | time, | ||
| const IndexT | bufferIndex ) |
Render view.
| void Graphics::ViewSetCamera | ( | const ViewId | id, |
| const GraphicsEntityId & | camera ) |
Set view camera.
| void Graphics::ViewSetFrameScript | ( | const ViewId | id, |
| bool(* | func )(const Math::rectangle< int > &viewport, IndexT frameIndex, IndexT bufferIndex) ) |
Set view frame script.
| void Graphics::ViewSetStageMask | ( | const ViewId | id, |
| const Graphics::StageMask | stage ) |
Set view stage.
| void Graphics::ViewSetViewport | ( | const ViewId | id, |
| const Math::rectangle< int > & | rect ) |
Set view viewport.
|
staticconstexpr |
| Threading::CriticalSection Graphics::bindResourceCriticalSection |
| int Graphics::bits |
| Math::vec4 Graphics::bloomColor |
| float Graphics::bloomIntensity |
| bool Graphics::computeDirty |
|
staticconstexpr |
| CoreGraphics::TextureId Graphics::defaultEnvironmentMap |
| CoreGraphics::TextureId Graphics::defaultIrradianceMap |
| struct { ... } Graphics::envState |
| float Graphics::fadeValue |
| Math::vec4 Graphics::fogColor |
| float Graphics::fogDistances[2] |
| Util::FixedArray<CoreGraphics::ResourceTableId> Graphics::frameResourceTables[(uint) GlobalTables::NumQueues] |
| struct { ... } Graphics::globalConstantState |
| bool Graphics::graphicsDirty |
| float Graphics::maxEyeLuminance |
| int Graphics::numGlobalEnvironmentMips |
|
staticconstexpr |
| Core::CVar* Graphics::r_show_env_params |
| float Graphics::saturation |
|
staticconstexpr |
| uint64_t Graphics::shadowViewCboOffset[(uint) GlobalTables::NumQueues] |
| Shared::ShadowViewConstants::STRUCT Graphics::shadowViewConstants |
| DirtySet Graphics::shadowViewConstantsDirty |
| Graphics::GraphicsEntityId Graphics::skyBoxEntity |
| float Graphics::skyTurbidity |
| struct { ... } Graphics::state |
| Graphics::GraphicsEntityId Graphics::sunEntity |
| CoreGraphics::ResourcePipelineId Graphics::tableLayout |
| Util::FixedPool<uint32_t> Graphics::texturePool |
| uint64_t Graphics::tickCboOffset[(uint) GlobalTables::NumQueues] |
| Shared::PerTickParams::STRUCT Graphics::tickParams |
| DirtySet Graphics::tickParamsDirty |
| Util::FixedArray<CoreGraphics::ResourceTableId> Graphics::tickResourceTables[(uint) GlobalTables::NumQueues] |
| ViewAllocator Graphics::viewAllocator |
| uint64_t Graphics::viewCboOffset[(uint) GlobalTables::NumQueues] |
| Shared::ViewConstants::STRUCT Graphics::viewConstants |
| DirtySet Graphics::viewConstantsDirty |