Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Frame renderpass pipelines resources = Frame {
- fIndex :: Word64
- fWindow :: Window
- fSurface :: SurfaceKHR
- fSwapchainResources :: SwapchainResources
- fRenderpass :: renderpass
- fPipelines :: pipelines
- fRenderFinishedHostSemaphore :: Semaphore
- fStageResources :: (RefCounted, InternalState)
- fGPUWork :: IORef [GPUWork]
- fResources :: (ReleaseKey, InternalState)
- fRecycledResources :: RecycledResources resources
- initial :: RenderPass rp => Maybe SwapchainResources -> DumpResource (RecycledResources rr) -> Stage rp p rr st -> StageRIO st (Frame rp p rr)
- run :: (HasLogFunc env, HasVulkan env, MonadResource (RIO env)) => (RecycledResources rr -> IO ()) -> RIO (env, Frame rp p rr) a -> Frame rp p rr -> RIO env a
- advance :: (HasLogFunc env, HasVulkan env, MonadResource (RIO env), RenderPass rp) => WaitResource (RecycledResources rr) -> Frame rp p rr -> Bool -> RIO env (Frame rp p rr)
- queueSubmit :: MonadVulkan env m => Queue -> Vector (SomeStruct SubmitInfo) -> IORef [GPUWork] -> Semaphore -> Word64 -> m ()
- data RecycledResources a = RecycledResources {
- rrImageAvailableSemaphore :: Semaphore
- rrRenderFinishedSemaphore :: Semaphore
- rrQueues :: Queues CommandPool
- rrData :: a
- initialRecycledResources :: (MonadResource (RIO env), HasVulkan env, HasLogFunc env) => (Queues CommandPool -> rp -> p -> ResourceT (RIO env) rr) -> rp -> p -> ResourceT (RIO env) (RecycledResources rr)
- timeoutError :: MonadThrow m => String -> m a
Documentation
data Frame renderpass pipelines resources Source #
All the information required to render a single frame
Frame | |
|
Instances
HasStateRef st (App GlobalHandles st, Frame rp p rr) Source # | |
Defined in Engine.Types stateRefL :: Lens' (App GlobalHandles st, Frame rp p rr) (SomeRef st) | |
HasDescSet tag rr => HasDescSet tag (env, Frame rp p rr) Source # | |
Defined in Engine.Vulkan.DescSets getDescSet :: (env, Frame rp p rr) -> Tagged tag DescriptorSet Source # | |
HasDescSet tag rr => HasDescSet tag (Frame rp p rr) Source # | |
Defined in Engine.Vulkan.DescSets getDescSet :: Frame rp p rr -> Tagged tag DescriptorSet Source # | |
MonadResource (RIO (env, Frame rp p rr)) Source # | |
Defined in Engine.Types liftResourceT :: ResourceT IO a -> RIO (env, Frame rp p rr) a | |
HasLogFunc env => HasLogFunc (env, Frame rp p rr) Source # | |
Defined in Engine.Types |
initial :: RenderPass rp => Maybe SwapchainResources -> DumpResource (RecycledResources rr) -> Stage rp p rr st -> StageRIO st (Frame rp p rr) Source #
run :: (HasLogFunc env, HasVulkan env, MonadResource (RIO env)) => (RecycledResources rr -> IO ()) -> RIO (env, Frame rp p rr) a -> Frame rp p rr -> RIO env a Source #
advance :: (HasLogFunc env, HasVulkan env, MonadResource (RIO env), RenderPass rp) => WaitResource (RecycledResources rr) -> Frame rp p rr -> Bool -> RIO env (Frame rp p rr) Source #
Derive next frame
queueSubmit :: MonadVulkan env m => Queue -> Vector (SomeStruct SubmitInfo) -> IORef [GPUWork] -> Semaphore -> Word64 -> m () Source #
queueSubmit
and add wait for the timeline Semaphore
before retiring the frame.
data RecycledResources a Source #
These are resources which are reused by a later frame when the current frame is retired
RecycledResources | |
|
Instances
HasDescSet tag rr => HasDescSet tag (RecycledResources rr) Source # | |
Defined in Engine.Vulkan.DescSets getDescSet :: RecycledResources rr -> Tagged tag DescriptorSet Source # |
initialRecycledResources :: (MonadResource (RIO env), HasVulkan env, HasLogFunc env) => (Queues CommandPool -> rp -> p -> ResourceT (RIO env) rr) -> rp -> p -> ResourceT (RIO env) (RecycledResources rr) Source #
timeoutError :: MonadThrow m => String -> m a Source #