keid-core-0.1.4.0: Core parts of Keid engine.
Safe HaskellNone
LanguageHaskell2010

Engine.Vulkan.Swapchain

Synopsis

Documentation

data SwapchainInfo Source #

Constructors

SwapchainInfo 

Fields

allocSwapchainResources Source #

Arguments

:: (MonadResource (RIO env), HasVulkan env, HasLogFunc env) 
=> SwapchainKHR

Previous swapchain, can be NULL_HANDLE

-> Extent2D

If the swapchain size determines the surface size, use this size

-> SurfaceKHR 
-> ProjectionProcess 
-> RIO env SwapchainResources 

Allocate everything which depends on the swapchain

recreateSwapchainResources Source #

Arguments

:: (MonadResource (RIO env), HasVulkan env, HasLogFunc env) 
=> Extent2D 
-> SwapchainResources

The reference to these resources will be dropped

-> RIO env SwapchainResources 

createSwapchain Source #

Arguments

:: (MonadResource m, MonadVulkan env m, HasLogFunc env) 
=> SwapchainKHR

Old swapchain, can be NULL_HANDLE

-> Extent2D

If the swapchain size determines the surface size, use this size

-> SurfaceKHR 
-> m SwapchainInfo 

Create a swapchain from a SurfaceKHR

threwSwapchainError :: MonadUnliftIO f => f () -> f Bool Source #

Catch an ERROR_OUT_OF_DATE_KHR exception and return True if that happened

class HasSwapchain a where Source #

Methods

getSurfaceExtent :: a -> Extent2D Source #

getSurfaceFormat :: a -> Format Source #

getDepthFormat :: a -> Format Source #

getMultisample :: a -> SampleCountFlagBits Source #

getAnisotropy :: a -> "max sampler anisotropy" ::: Float Source #

getSwapchainViews :: a -> Vector ImageView Source #

getMinImageCount :: a -> Word32 Source #

getImageCount :: a -> Word32 Source #

setDynamic :: MonadIO io => CommandBuffer -> ("viewport" ::: Rect2D) -> ("scissor" ::: Rect2D) -> io () Source #

setDynamicFullscreen :: MonadIO io => CommandBuffer -> SwapchainResources -> io () Source #