Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Scene = Scene {
- sceneProjection :: Transform
- sceneInvProjection :: Transform
- sceneView :: Transform
- sceneInvView :: Transform
- sceneViewPos :: Vec3
- sceneViewDir :: Vec3
- sceneTweaks :: Vec4
- sceneFog :: Vec4
- sceneEnvCube :: Int32
- sceneNumLights :: Word32
- emptyScene :: Scene
- allocate :: (Traversable textures, Traversable cubes) => Tagged '[Scene] DescriptorSetLayout -> textures (Texture Flat) -> cubes (Texture CubeMap) -> Maybe (Allocated 'Coherent Sun) -> ("shadow maps" ::: Vector ImageView) -> Maybe (Allocated 'Coherent Material) -> ResourceT (StageRIO st) (FrameResource '[Scene])
- allocateEmpty :: Tagged '[Scene] DescriptorSetLayout -> ResourceT (StageRIO st) (FrameResource '[Scene])
- updateSet0Ds :: (HasVulkan context, Traversable textures, Traversable cubes) => context -> Tagged '[Scene] (Vector DescriptorSet) -> Allocated 'Coherent Scene -> textures (Texture Flat) -> cubes (Texture CubeMap) -> Maybe (Allocated 'Coherent Sun) -> Vector (Sampler, ImageView) -> Maybe (Allocated 'Coherent Material) -> ResourceT (StageRIO st) ()
- set0 :: Traversable samplers => samplers Sampler -> Either Word32 (Vector (Texture Flat)) -> Either Word32 (Vector (Texture CubeMap)) -> Word32 -> Tagged Scene DsBindings
- set0_ :: Tagged Scene DsBindings
- vertexPos :: (VertexInputRate, [Format])
- instanceTransform :: (VertexInputRate, [Format])
- data FrameResource (ds :: [Type]) = FrameResource {
- frDescSets :: Tagged ds (Vector DescriptorSet)
- frBuffer :: Buffer
- frObserver :: ObserverIO Scene
- extendResourceDS :: FrameResource ds -> Tagged ext DescriptorSet -> FrameResource (Extend ds ext)
- type Buffer = Allocated 'Coherent Scene
- type Process = Merge Scene
- observe :: MonadUnliftIO m => Process -> FrameResource ds -> m ()
- withBoundSet0 :: MonadIO m => FrameResource ds -> Pipeline ds vertices instances -> CommandBuffer -> Bound ds Void Void m b -> m b
Documentation
Scene | |
|
Instances
emptyScene :: Scene Source #
allocate :: (Traversable textures, Traversable cubes) => Tagged '[Scene] DescriptorSetLayout -> textures (Texture Flat) -> cubes (Texture CubeMap) -> Maybe (Allocated 'Coherent Sun) -> ("shadow maps" ::: Vector ImageView) -> Maybe (Allocated 'Coherent Material) -> ResourceT (StageRIO st) (FrameResource '[Scene]) Source #
allocateEmpty :: Tagged '[Scene] DescriptorSetLayout -> ResourceT (StageRIO st) (FrameResource '[Scene]) Source #
Minimal viable Scene
without textures and lighting.
updateSet0Ds :: (HasVulkan context, Traversable textures, Traversable cubes) => context -> Tagged '[Scene] (Vector DescriptorSet) -> Allocated 'Coherent Scene -> textures (Texture Flat) -> cubes (Texture CubeMap) -> Maybe (Allocated 'Coherent Sun) -> Vector (Sampler, ImageView) -> Maybe (Allocated 'Coherent Material) -> ResourceT (StageRIO st) () Source #
set0 :: Traversable samplers => samplers Sampler -> Either Word32 (Vector (Texture Flat)) -> Either Word32 (Vector (Texture CubeMap)) -> Word32 -> Tagged Scene DsBindings Source #
instanceTransform :: (VertexInputRate, [Format]) Source #
data FrameResource (ds :: [Type]) Source #
FrameResource | |
|
extendResourceDS :: FrameResource ds -> Tagged ext DescriptorSet -> FrameResource (Extend ds ext) Source #
observe :: MonadUnliftIO m => Process -> FrameResource ds -> m () Source #
withBoundSet0 :: MonadIO m => FrameResource ds -> Pipeline ds vertices instances -> CommandBuffer -> Bound ds Void Void m b -> m b Source #