keid-core-0.1.9.0: Core parts of Keid engine.
Safe HaskellSafe-Inferred
LanguageGHC2021

Render.Draw

Synopsis

Documentation

triangle_ :: MonadUnliftIO m => CommandBuffer -> Bound dsl () () m () Source #

Single triangle, binding nothing.

triangles_ :: MonadUnliftIO m => CommandBuffer -> Word32 -> Bound dsl () () m () Source #

Multiple shader-driven triangles without bindings.

quads :: MonadUnliftIO m => CommandBuffer -> Allocated stage instances -> Bound dsl () instances m () Source #

Instanced quads.

indexed :: (MonadUnliftIO m, HasVertexBuffers instances) => CommandBuffer -> Indexed storage pos attrs -> instances -> Bound dsl (Vertex pos attrs) (VertexBuffersOf instances) m () Source #

Draw whole-model instances.

indexedRanges :: (MonadUnliftIO m, HasVertexBuffers instances) => CommandBuffer -> Indexed storage pos attrs -> instances -> [IndexRange] -> Bound dsl (Vertex pos attrs) (VertexBuffersOf instances) m () Source #

Draw subrange of each instance.

E.g. chunks of the same material drawn in different places.

indexedParts :: (MonadUnliftIO m, HasVertexBuffers instances, Foldable t) => Bool -> CommandBuffer -> Indexed storage pos attrs -> instances -> Int -> t IndexRange -> Bound dsl (Vertex pos attrs) (VertexBuffersOf instances) m () Source #

Draw ranges and instances zipped.

E.g. range materials stored in instances.

indexedPos :: (MonadUnliftIO m, HasVertexBuffers instances) => CommandBuffer -> Indexed storage pos unusedAttrs -> instances -> Bound dsl (Vertex pos ignoreAttrs) (VertexBuffersOf instances) m () Source #

Draw whole-model instances, ignoring attributes.

indexedPosRanges :: (MonadUnliftIO m, HasVertexBuffers instances) => CommandBuffer -> Indexed storage pos unusedAttrs -> instances -> [IndexRange] -> Bound dsl (Vertex pos ignoreAttrs) (VertexBuffersOf instances) m () Source #

Draw subrange of each instances, ignoring attributes.

unsafeIndexedRanges :: (MonadUnliftIO io, HasVertexBuffers instances, Foldable t) => Bool -> CommandBuffer -> Indexed storage pos attrs -> instances -> t IndexRange -> io () Source #

Common unchecked part for pos/attrs

unsafeIndexedParts :: (MonadUnliftIO io, HasVertexBuffers instances, Foldable t) => Bool -> CommandBuffer -> Indexed storage pos attrs -> instances -> Int -> t IndexRange -> io () Source #

Instance/range zipped