module Engine.Vulkan.Pipeline.Stages ( StageInfo(..) , withLabels ) where import RIO import Vulkan.Core10 qualified as Vk class (Applicative t, Traversable t) => StageInfo t where stageNames :: IsString label => t label stageFlagBits :: t Vk.ShaderStageFlagBits withLabels :: (StageInfo t, IsString label) => t a -> t (label, a) withLabels :: forall (t :: * -> *) label a. (StageInfo t, IsString label) => t a -> t (label, a) withLabels t a staged = (,) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b <$> forall (t :: * -> *) label. (StageInfo t, IsString label) => t label stageNames forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b <*> t a staged