DeclAPIExample

Undocumented in source.

Constructors

this
this(string[] args)
Undocumented in source.

Members

Classes

PerImage
class PerImage
Undocumented in source.

Functions

dispose
void dispose()
Undocumented in source. Be warned that the author may not have intended to support it.
prepare
void prepare()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareBuffers
void prepareBuffers()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareDescriptorSet
void prepareDescriptorSet()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareFramebuffers
void prepareFramebuffers()
Undocumented in source. Be warned that the author may not have intended to support it.
preparePipeline
void preparePipeline()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareRenderPass
void prepareRenderPass()
Undocumented in source. Be warned that the author may not have intended to support it.
recordCmds
void recordCmds(size_t cmdBufInd, size_t imgInd)
Undocumented in source. Be warned that the author may not have intended to support it.
updateMatrices
void updateMatrices(Matrices[] mat)
Undocumented in source. Be warned that the author may not have intended to support it.

Manifest constants

cubeCount
enum cubeCount;
Undocumented in source.
maxLights
enum maxLights;
Undocumented in source.

Structs

Light
struct Light
Undocumented in source.
Lights
struct Lights
Undocumented in source.
Matrices
struct Matrices
Undocumented in source.
Vertex
struct Vertex
Undocumented in source.

Variables

cubeLen
size_t cubeLen;
Undocumented in source.
declEng
DeclarativeEngine declEng;
Undocumented in source.
descPool
Rc!DescriptorPool descPool;
Undocumented in source.
framebuffers
PerImage[] framebuffers;
Undocumented in source.
indBuf
Rc!Buffer indBuf;
Undocumented in source.
indices
const(ushort)[] indices;
Undocumented in source.
layout
Rc!PipelineLayout layout;
Undocumented in source.
ligBuf
Rc!Buffer ligBuf;
Undocumented in source.
matBuf
Rc!Buffer matBuf;
Undocumented in source.
pipeline
Rc!Pipeline pipeline;
Undocumented in source.
renderPass
Rc!RenderPass renderPass;
Undocumented in source.
set
DescriptorSet set;
Undocumented in source.
setLayout
Rc!DescriptorSetLayout setLayout;
Undocumented in source.
vertBuf
Rc!Buffer vertBuf;
Undocumented in source.

Inherited Members

From Example

title
string title;
Undocumented in source.
args
string[] args;
Undocumented in source.
display
Rc!Display display;
Undocumented in source.
window
Window window;
Undocumented in source.
instance
Rc!Instance instance;
Undocumented in source.
graphicsQueueIndex
uint graphicsQueueIndex;
Undocumented in source.
presentQueueIndex
uint presentQueueIndex;
Undocumented in source.
physicalDevice
PhysicalDevice physicalDevice;
Undocumented in source.
device
Rc!Device device;
Undocumented in source.
graphicsQueue
Queue graphicsQueue;
Undocumented in source.
presentQueue
Queue presentQueue;
Undocumented in source.
surfaceSize
uint[2] surfaceSize;
Undocumented in source.
hasAlpha
bool hasAlpha;
Undocumented in source.
swapchain
Rc!Swapchain swapchain;
Undocumented in source.
scImages
ImageBase[] scImages;
Undocumented in source.
imageAvailableSem
Rc!Semaphore imageAvailableSem;
Undocumented in source.
renderingFinishSem
Rc!Semaphore renderingFinishSem;
Undocumented in source.
cmdPool
Rc!CommandPool cmdPool;
Undocumented in source.
cmdBufs
CommandBuffer[] cmdBufs;
Undocumented in source.
fences
Fence[] fences;
Undocumented in source.
numCmdBufs
enum numCmdBufs;
Undocumented in source.
cmdBufInd
size_t cmdBufInd;
Undocumented in source.
dispose
void dispose()
Undocumented in source. Be warned that the author may not have intended to support it.
prepare
void prepare()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareDevice
void prepareDevice()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareSwapchain
void prepareSwapchain(Swapchain former)
Undocumented in source. Be warned that the author may not have intended to support it.
prepareSync
void prepareSync()
Undocumented in source. Be warned that the author may not have intended to support it.
prepareCmds
void prepareCmds()
Undocumented in source. Be warned that the author may not have intended to support it.
recordCmds
void recordCmds(size_t cmdBufInd, size_t imgInd)
Undocumented in source.
nextCmdBuf
size_t nextCmdBuf()
Undocumented in source. Be warned that the author may not have intended to support it.
render
void render()
Undocumented in source. Be warned that the author may not have intended to support it.
submit
void submit(ulong cmdBufInd)
Undocumented in source. Be warned that the author may not have intended to support it.
findSupportedFormat
Format findSupportedFormat(Format[] candidates, ImageTiling tiling, FormatFeatures features)

Find a format supported by the device for the given tiling and features

findDepthFormat
Format findDepthFormat()

Find a supported depth format

findMemType
uint findMemType(MemoryRequirements mr, MemProps props)

Return the index of a memory type supporting all of props, or uint.max if none was found.

createBuffer
Buffer createBuffer(size_t dataSize, BufferUsage usage, MemProps props)

Create a buffer for usage, bind memory of dataSize with memProps Return null if no memory type can be found

createDynamicBuffer
Buffer createDynamicBuffer(size_t dataSize, BufferUsage usage)

Create a buffer, binds memory to it, and leave content undefined The buffer will be host visible and host coherent such as content can be updated without staging buffer

createStaticBuffer
Buffer createStaticBuffer(const(void)[] data, BufferUsage usage)
Buffer createStaticBuffer(const(T)[] data, BufferUsage usage)
Buffer createStaticBuffer(T data, BufferUsage usage)

Create a buffer, and bind it with memory filled with data. The bound memory will be deviceLocal, without guarantee to be host visible.

bindImageMemory
bool bindImageMemory(Image img, MemProps props)
Undocumented in source. Be warned that the author may not have intended to support it.
createTextureImage
Image createTextureImage(const(void)[] data, ImageInfo info)

create an image to be used as texture

createDepthImage
Image createDepthImage(uint width, uint height)

Create an image for depth attachment usage

createStencilImage
Image createStencilImage(uint width, uint height)

Create an image for stencil attachment usage

copyBuffer
void copyBuffer(Buffer srcBuf, Buffer dstBuf, size_t size, CommandBuffer cmdBuf)

copy the content of one buffer to another srcBuf and dstBuf must support transferSrc and transferDst respectively.

copyBufferToImage
void copyBufferToImage(Buffer srcBuf, Image dstImg, CommandBuffer cmdBuf)

copy the content of one buffer to an image. the image layout must be transferDstOptimal buffer the call

autoCmdBuf
AutoCmdBuf autoCmdBuf(CommandPool pool)

Get a RAII command buffer that is meant to be trashed after usage. Returned buffer is ready to record data, and execute commands on the graphics queue at end of scope.

Meta