3#ifndef WISDOM_MODULE_DECL
9#define WISDOM_EXPORT export
1256 DescriptorBufferExtension = 1,
1257 ExtendedAllocation = 2,
2323inline constexpr Result success{
2327template<
typename RetTy>
2338 template<
typename Callable,
typename Callee,
typename... Args>
2339 requires std::is_member_function_pointer_v<Callable>
2341 : value(std::invoke(f, self, status, std::forward<Args>(args)...))
2344 template<
typename Callable,
typename... Args>
2346 : value(f(status, std::forward<Args>(args)...))
2350 template<
typename Callable,
typename Callee,
typename... Args>
2354 rv.value = std::invoke(f, self, rv.status, std::forward<Args>(args)...);
2359template<u
int32_t s,
typename RetTy>
2362 if constexpr (s == 0) {
2363 return std::forward<Result>(rv.status);
2365 return std::forward<RetTy>(rv.value);
ASGeometryType
Type of the geometry in the Acceleration Structure.
@ Triangles
Triangles geometry type. Used for triangle meshes.
@ AABBs
Axis Aligned Bounding Boxes geometry type. Used for bounding volume hierarchies.
BlendFactor
Blend factor for color blending operations.
@ InvSrc1Color
Use the inverse source color for blending. Dual source blending mode.
@ SrcAlphaSat
Use the source alpha saturated for blending.
@ One
Use one for blending.
@ SrcColor
Use the source color for blending.
@ DestAlpha
Use the destination alpha for blending.
@ InvSrcAlpha
Use the inverse source alpha for blending.
@ InvDestColor
Use the inverse destination color for blending.
@ Src1Color
Use the source color for blending. Dual source blending mode.
@ Src1Alpha
Use the source alpha for blending. Dual source blending mode.
@ DestColor
Use the destination color for blending.
@ InvDestAlpha
Use the inverse destination alpha for blending.
@ SrcAlpha
Use the source alpha for blending.
@ Zero
Use zero for blending.
@ InvBlendFactor
Use the inverse constant blend factor for blending.
@ InvSrcColor
Use the inverse source color for blending.
@ ConstantColor
Use a constant blend factor for blending.
@ InvSrc1Alpha
Use the inverse source alpha for blending. Dual source blending mode.
Filter
Filtering mode for texture sampling.
@ Linear
Linear filtering.
InputClass
Input classification for vertex buffer data.
@ PerVertex
Vertex buffer data is vertex data.
@ PerInstance
Vertex buffer data is per instance data.
ShaderStages
Shader stages that can be used in the pipeline. Main use is Root signature and descriptor management....
@ Pixel
Pixel/Fragment shader stage.
@ Hull
Hull/Tessellation control shader stage.
@ Vertex
Vertex shader stage.
@ Amplification
Amplification shader stage.
@ Geometry
Geometry shader stage.
@ Domain
Domain/Tessellation evaluation shader stage.
AddressMode
Address mode for texture sampling.
@ MirrorClampToEdge
Mirror and clamp the texture to the edge.
@ MirroredRepeat
Repeat the texture with mirroring.
@ Repeat
Repeat the texture.
@ ClampToEdge
Clamp the texture to the edge.
@ ClampToBorder
Clamp the texture to the border.
DescriptorMemory
Descriptor memory type. Decides if descriptors are visible and can be bound to GPU.
@ ShaderVisible
Descriptors are visible to GPU. Descriptors can be bound to the GPU pipeline directly.
@ CpuOnly
Descriptors are only visible to CPU. May be used for copying descriptors to the GPU visible pool.
MemoryType
Memory type for resource allocation.
@ Default
Default memory type. Alias for wis::MemoryType::DeviceLocal.
@ Upload
Upload memory type. Used for data that is uploaded to the GPU Local memory using copy operations.
@ DeviceLocal
Default memory type. Local device memory, most efficient for rendering.
@ Readback
Readback memory type. Used for data that is read back from the GPU Local memory using copy operations...
@ GPUUpload
GPU upload memory type. Used for data that is directly uploaded to the GPU Local memory using copy op...
AdapterPreference
Oreders the adapters according to preference using builtin heuristics of underlying APIs.
@ None
No particular preference, list adapters in system divised order.
@ MinConsumption
List the adapters from low power consumption to high. Order is as follows: Integrated,...
@ Performance
List the adapters from high performance to low. Order is as follows: External, Discrete,...
QueueType
Type of the queue to create.
@ VideoDecode
Queue is used for video decoding operations.
@ Copy
Queue is used for copy operations.
@ Compute
Queue is used for compute operations.
@ Graphics
Queue is used for graphics operations.
StoreOperation
Attachment store operation for render pass.
@ Resolve
Resolve the attachment contents. Used for multisampling attachments.
@ Store
Store the attachment contents.
ResourceAccess
Resource access flags. Determine how resource will be accessed. Used in Barriers.
@ ResolveSource
Resolve source access. Used in multisampling.
@ AccelerationStructureRead
Acceleration structure read access.
@ StreamOutput
Stream output access. Applies only to buffers. Reserved for extension.
@ IndirectArgument
Indirect argument access.
@ DepthRead
Depth read access. Applies only to DS textures.
@ NoAccess
No access. Used to indicate no access throughout pipeline.
@ ResolveDest
Resolve destination access. Used in multisampling.
@ AccelerationStructureWrite
Acceleration structure write access.
@ DepthWrite
Depth write access. Applies only to DS textures.
@ ConditionalRendering
Conditional rendering access.
AdapterFlags
Flags that describe adapter.
@ Software
Adapter is software. Used for software rendering.
@ Remote
Adapter is remote. Used for remote rendering.
BlendOp
Blend operation for color blending operations.
@ Subtract
Subtract the source color from the destination color.
@ Max
Use the maximum of the source and destination colors.
@ Min
Use the minimum of the source and destination colors.
@ RevSubtract
Subtract the destination color from the source color.
@ Add
Add the source and destination colors.
RaytracingShaderType
Shader stages that can be used in the raytracing pipeline.
@ Callable
Callable shader stage.
@ Intersection
Intersection shader stage.
@ ClosestHit
Closest hit shader stage.
@ Raygen
Ray generation shader stage.
@ AnyHit
Any hit shader stage.
DSSelect
Depth stencil select flags. Affect which part of the depth stencil buffer is used.
@ DepthStencil
Use both depth and stencil parts of the depth stencil buffer.
@ Depth
Use depth part of the depth stencil buffer.
@ Stencil
Use stencil part of the depth stencil buffer.
DescriptorType
Type of the descriptor in the descriptor table.
@ AccelerationStructure
Descriptor is an acceleration structure.
@ Sampler
Descriptor is a sampler. Sampler is used to sample textures in shaders. Stored in separate descriptor...
@ Buffer
Descriptor is a shader resource buffer. May be bigger than constant buffers, but slower.
@ RWTexture
Descriptor is an unordered access read-write texture. Used for read/write operations in compute shade...
@ RWBuffer
Descriptor is an unordered access read-write buffer. Used for read/write operations in compute shader...
@ Texture
Descriptor is a texture.
@ ConstantBuffer
Descriptor is a constant buffer.
BarrierSync
Barrier synchronization flags. Used to synchronize resources between different stages of the pipeline...
@ Raytracing
Synchronize raytracing commands.
@ Draw
Synchronize draw commands.
@ VertexShading
Synchronize vertex shading commands.
@ ExecuteIndirect
Synchronize execute indirect commands.
@ NonPixelShading
Synchronize non-pixel shading commands.
@ BuildRTAS
Synchronize build raytracing acceleration structure commands.
@ ClearUAV
Synchronize clear UAV commands.
@ CopyRTAS
Synchronize copy raytracing acceleration structure commands.
@ AllShading
Synchronize all shading commands.
@ VideoEncode
Synchronize video encode commands.
@ IndexInput
Synchronize index input commands.
@ PixelShading
Synchronize pixel shading commands.
Status
Represents main error communication source for the API. Compare against wis::Status::Ok for success.
@ InvalidArgument
One or more arguments, or parts of arguments passed to the function were incorrect....
@ Occluded
Swapchain presentation was not visible to the user. Rendering is too fast.
@ Partial
Operation partially succeeded. Some times it means that core value is initialized,...
@ Error
Operation failed. Check wis::Result::error for more details.
@ OutOfMemory
There is no more host memory available. Allocation with malloc or similar call has failed.
@ Timeout
Operation timed out. Counts as a success value in some cases.
@ DeviceLost
Device driver was forcefully stopped. Most of the time happens on swapchain presentation.
CullMode
Cull mode for rasterizer. Triangle culling depends on wis::WindingOrder option.
@ Back
Cull back-facing triangles.
@ Front
Cull front-facing triangles.
void(*)(wis::Severity severity, const char *message, void *user_data) DebugCallback
Debug callback delegate. Used for Library internal log messages.
MemoryFlags
Memory flags. Determine optional properties of the memory allocation.
@ DedicatedAllocation
Memory is dedicated. Used for resources that require dedicated memory. Useful for big resources that ...
@ Mapped
Memory is mapped. Used in combination with wis::MemoryType::Upload or wis::MemoryType::Readback to ma...
@ Exportable
Memory is exportable. If set, memory can be exported to other processes or APIs. Works only with Devi...
PipelineFlags
Pipeline flags for additional pipeline features.
@ DescriptorBuffer
Pipeline is created to be used with DescriptorBuffer extension. Do not mix DescriptorBuffer and non-D...
PrimitiveTopology
Primitive topology for rendering. More info could be found here.
@ LineListAdj
Render lines between vertices with adjacency.
@ TriangleFan
Interpret vertex data to form a fan of triangles.
@ PointList
Render points for each vertex.
@ TriangleStrip
Render triangles between vertices in a strip.
@ LineList
Render lines between vertices.
@ LineStripAdj
Render lines between vertices in a strip with adjacency.
@ TriangleListAdj
Render triangles between vertices with adjacency.
@ LineStrip
Render lines between vertices in a strip.
@ TriangleList
Render triangles between vertices.
@ TriangleStripAdj
Render triangles between vertices in a strip with adjacency.
FenceFlags
Fence flags for additional fence features.
@ Shared
Fence is shared. Used for sharing fences for single physical device.
FactoryExtID
Factory extension ID. Platform extension values start from 2049 0 is reserved as invalid/custom exten...
@ Custom
Custom provided extension. Default initialization of the extension is done by user.
SwapchainScaling
Swapchain scaling mode.
@ Aspect
Aspect scaling. The swapchain size is scaled to the window size with aspect ratio preserved.
@ Stretch
Stretch scaling. The swapchain size is stretched to the window size.
ASLevel
Level of the Raytracing Acceleration Structure. Used to create Acceleration structures.
@ Bottom
Bottom level Acceleration Structure. Contains geometry data.
@ Top
Top level Acceleration Structure. Contains instance data.
ShaderIntermediate
Intermediate shader representation.
@ DXIL
DirectX Intermediate Language.
@ SPIRV
Standard Portable Intermediate Representation for Vulkan.
FillMode
Fill mode for rasterizer.
@ Lines
Draw lines between vertices. Wireframe rendering.
@ Solid
Fill the area between vertices forming polygons.
ComponentSwizzle
Component swizzle for texture sampling.
@ Alpha
Use the alpha component for sampling.
@ Blue
Use the blue component for sampling.
@ Green
Use the green component for sampling.
@ Red
Use the red component for sampling.
TextureViewType
Texture view type.
@ TextureCube
Texture is a cube map.
@ TextureCubeArray
Texture is an array of cube maps.
ColorComponents
Color component flags. Used for color blending operations.
@ A
Use alpha component for blending.
@ B
Use blue component for blending.
@ All
Use all color components for blending.
@ G
Use green component for blending.
@ R
Use red component for blending.
TextureLayout
Texture layout. Determines how texture will be accessed.
@ Texture2DArray
Texture is an array of 2D images. Can also be used for Cube maps.
@ Texture2DMS
Texture is 2D multisampled image.
@ Texture3D
Texture is 3D volume.
@ Texture1DArray
Texture is an array of 1D data.
@ Texture2D
Texture is 2D image, default texture type.
@ Texture2DMSArray
Texture is an array of 2D multisampled images.
@ Texture1D
Texture is 1D array of data. Behaves similarly to Buffer.
LogicOp
Logic operation for color blending operations.
@ AndReverse
Perform a bitwise AND operation on the source and inverted destination values.
@ Noop
Do not modify the destination value.
@ Or
Perform a bitwise OR operation on the source and destination values.
@ Equiv
Perform a bitwise equivalent operation on the source and destination values.
@ Set
Set the destination value.
@ Nor
Perform a bitwise NOR operation on the source and destination values.
@ Xor
Perform a bitwise XOR operation on the source and destination values.
@ OrReverse
Perform a bitwise OR operation on the source and inverted destination values.
@ OrInverted
Perform a bitwise OR operation on the inverted source and destination values.
@ And
Perform a bitwise AND operation on the source and destination values.
@ Nand
Perform a bitwise NAND operation on the source and destination values.
@ Clear
Clear the destination value.
@ AndInverted
Perform a bitwise AND operation on the inverted source and destination values.
@ CopyInverted
Copy the inverted source value to the destination.
RenderPassFlags
Render pass flags. Set of flags that affect render pass behavior. More on render pass flags here.
@ Suspending
Render pass is suspending.
@ Resuming
Render pass is resuming.
Severity
Log message severity. Used with wis::DebugCallback and internal library logging.
@ Warning
Message contains warning. There is something wrong and it may affect performance or stability of the ...
@ Critical
Message contains critical error. The application must be shut down, no further execution.
@ Info
Message contains general information.
@ Debug
Message carries debug information.
@ Trace
Message contains trace point (function call stack info).
ASGeometryFlags
Geometry flags for additional geometry features.
@ NoDuplicateAnyHitInvocation
Geometry has no duplicate any hit invocation.
@ Opaque
Geometry is opaque. Used for opaque geometry.
ASCopyMode
Acceleration structure copy mode.
@ Deserialize
Deserialize the acceleration structure.
@ Serialize
Serialize the acceleration structure.
@ Compact
Compact the acceleration structure.
@ Clone
Clone the acceleration structure.
DeviceFeature
Features that device may support. Query by calling with Device::QueryFeatureSupport....
@ WaitForPresent
Supports waiting for present to finish. Support for VK, always true for DX12. Unlocks Swapchain::Wait...
@ PushDescriptors
Supports push descriptors. Support for VK, always true for DX12.
@ UnusedRenderTargets
Supports unused render targets. Support for VK, always true for DX12.
@ DynamicVSync
Supports dynamic VSync. Support for VK, always true for DX12. Unlocks Swapchain::Present2 function....
@ AdvancedIndexBuffer
Supports advanced index buffer features. Support for VK, always true for DX12. Unlocks CommandList::I...
@ EnchancedBarriers
Core Functionality. Supports enhanced barriers. Support for VK and DX12. Used in all barriers to prov...
StencilOp
Stencil operation for depth and stencil operations.
@ Keep
Keep the current value.
@ Replace
Replace the value with the reference value.
@ DecWrap
Decrement the value and wrap to the maximum value when the minimum value is exceeded.
@ IncWrap
Increment the value and wrap to zero when the maximum value is exceeded.
@ DecClamp
Decrement the value and clamp to the minimum value.
@ Invert
Invert the value.
@ IncClamp
Increment the value and clamp to the maximum value.
@ Zero
Set the value to zero.
TextureUsage
Texture usage flags. Determine how the texture can be used throughout its lifetime.
@ None
No flags set. Texture is not used.
@ HostCopy
Texture is used for host copy operations. Works with ExtendedAllocation extension.
IndexType
Index type for index buffer. Enum values resemble the byte stride of the format.
@ UInt16
16-bit unsigned integer index type.
@ UInt32
32-bit unsigned integer index type.
AccelerationStructureFlags
Acceleration structure flags for additional acceleration structure features.
@ MinimizeMemory
Acceleration structure is minimized for memory usage.
@ PreferFastBuild
Acceleration structure is preferred to be fast built.
@ AllowCompaction
Acceleration structure is allowed to be compacted.
@ PreferFastTrace
Acceleration structure is preferred to be fast traced.
@ AllowUpdate
Acceleration structure is allowed to be updated.
DescriptorHeapType
Descriptor heap type.
@ Descriptor
Descriptor heap type. Used for all descriptor types, except for samplers.
Compare
Comparison function for depth and stencil operations.
@ NotEqual
Pass the comparison if the source value is not equal to the destination value.
@ Less
Pass the comparison if the source value is less than the destination value.
@ Always
Always pass the comparison.
@ Never
Always fail the comparison.
@ GreaterEqual
Pass the comparison if the source value is greater than or equal to the destination value.
@ Greater
Pass the comparison if the source value is greater than the destination value.
@ LessEqual
Pass the comparison if the source value is less than or equal to the destination value.
@ Equal
Pass the comparison if the source value is equal to the destination value.
LoadOperation
Attachment load operation for render pass.
@ DontCare
Do not care about the attachment contents.
@ Load
Load the attachment contents.
SampleRate
Sample rate for multisampling.
@ S16
16 samples per pixel.
BufferUsage
Buffer usage flags. Determine how the buffer can be used throughout its lifetime.
@ VertexBuffer
Buffer is used as a vertex buffer or an instance buffer.
@ ShaderBindingTable
Buffer is used as a shader binding table buffer.
@ AccelerationStructureInput
Buffer is used as a read only acceleration instance input buffer.
@ StorageBuffer
Buffer is used as a storage unordered access buffer.
@ CopyDst
Buffer is used as a destination for copy operations.
@ IndexBuffer
Buffer is used as an index buffer.
@ IndirectBuffer
Buffer is used as an indirect buffer.
@ CopySrc
Buffer is used as a source for copy operations.
@ AccelerationStructureBuffer
Buffer is used as an acceleration structure buffer.
TopologyType
Primitive topology type for rendering.
@ Patch
Vertices are interpret as patch list. Used in tesselation process.
@ Point
Render points for each vertex.
@ Line
Render lines between vertices.
@ Triangle
Render triangles between vertices.
TextureState
Texture state for resource transitions.
@ UnorderedAccess
Unordered Access state.
@ Read
General Read state.
@ VideoDecodeWrite
Video Decode Write state.
@ RenderTarget
Render Target state.
@ DepthStencilRead
Depth Stencil Read state.
@ DepthStencilWrite
Depth Stencil Write state.
@ CopyDest
Copy Destination state.
@ VideoDecodeRead
Video Decode Read state.
@ ShadingRate
Shading Rate state. Used for Variable Shading Rate.
@ ShaderResource
Shader Resource state.
@ Present
Present swapchain state.
@ Undefined
Undefined state.
@ CopySource
Copy Source state.
DeviceExtID
Device extension ID. Platform extension values start from 2049 0 is reserved as invalid/custom extens...
DataFormat
Data format for data. Used as a template for data in several cases. Can be used to describe:
@ BGRA8UnormSrgb
8 bit per channel RGBA format. SRGB non-linear color space. A four-component, 32-bit unsigned normali...
@ BC2RGBAUnormSrgb
BC2/DXT3 compressed format. A four-component, block-compressed format where each 128-bit compressed t...
@ BC3RGBAUnorm
BC3/DXT5 compressed format. A four-component, block-compressed format where each 128-bit compressed t...
@ RGB10A2Uint
10 bit per channel RGB format with 2 bit alpha. A four-component, 32-bit unsigned integer format that...
@ RG8Snorm
8 bit per channel RG format. A two-component, 16-bit signed normalized format that has an 8-bit R com...
@ RG32Sint
32 bit per channel RG format. A two-component, 64-bit signed integer format that has a 32-bit R compo...
@ RG8Unorm
8 bit per channel RG format. A two-component, 16-bit unsigned normalized format that has an 8-bit R c...
@ R32Sint
32 bit per channel R format. A one-component, 32-bit signed integer format that has a 32-bit R compon...
@ BC5RGUnorm
BC5 compressed format. A two-component, block-compressed format where each 128-bit compressed texel b...
@ RGBA8UnormSrgb
8 bit per channel RGBA format. SRGB non-linear color space. A four-component, 32-bit unsigned normali...
@ BC2RGBAUnorm
BC2/DXT3 compressed format. A four-component, block-compressed format where each 128-bit compressed t...
@ R8Unorm
8 bit per channel R format. A one-component, 8-bit unsigned normalized format that has an 8-bit R com...
@ R16Sint
16 bit per channel R format. A one-component, 16-bit signed integer format that has a 16-bit R compon...
@ R16Snorm
16 bit per channel R format. A one-component, 16-bit signed normalized format that has a 16-bit R com...
@ RG16Uint
16 bit per channel RG format. A two-component, 32-bit unsigned integer format that has a 16-bit R com...
@ RGB32Float
32 bit per channel RGB format. A three-component, 96-bit signed floating-point format that has a 32-b...
@ D24UnormS8Uint
24 bit depth, 8 bit stencil format. A combined depth/stencil format with a 24-bit depth component in ...
@ D16Unorm
16 bit depth format. A 16-bit depth format supporting 16-bit unsigned normalized depth values.
@ RGBA32Sint
32 bit per channel RGBA format. A four-component, 128-bit signed integer format that has a 32-bit R c...
@ RGBA16Float
16 bit per channel RGBA format. A four-component, 64-bit signed floating-point format that has a 16-b...
@ D32FloatS8Uint
32 bit depth, 8 bit stencil format. A combined depth/stencil format with a 32-bit depth component in ...
@ BC1RGBAUnorm
BC1/DXT1 compressed format. A four-component, block-compressed format where each 64-bit compressed te...
@ D32Float
32 bit depth format. A 32-bit depth format supporting 32-bit floating-point depth values.
@ RGBA16Uint
16 bit per channel RGBA format. A four-component, 64-bit unsigned integer format that has a 16-bit R ...
@ RGBA8Snorm
8 bit per channel RGBA format. A four-component, 32-bit signed normalized format that has an 8-bit R ...
@ R8Sint
8 bit per channel R format. A one-component, 8-bit signed integer format that has an 8-bit R componen...
@ RGBA16Unorm
16 bit per channel RGBA format. A four-component, 64-bit unsigned normalized format that has a 16-bit...
@ RGB32Sint
32 bit per channel RGB format. A three-component, 96-bit signed integer format that has a 32-bit R co...
@ RG16Snorm
16 bit per channel RG format. A two-component, 32-bit signed normalized format that has a 16-bit R co...
@ R16Float
16 bit per channel R format. A one-component, 16-bit signed floating-point format that has a 16-bit R...
@ RGB10A2Unorm
10 bit per channel RGB format with 2 bit alpha. A four-component, 32-bit unsigned normalized format t...
@ RGBA16Snorm
16 bit per channel RGBA format. A four-component, 64-bit signed normalized format that has a 16-bit R...
@ RG16Float
16 bit per channel RG format. A two-component, 32-bit signed floating-point format that has a 16-bit ...
@ RGB32Uint
32 bit per channel RGB format. A three-component, 96-bit unsigned integer format that has a 32-bit R ...
@ B5G6R5Unorm
16 bit per channel RGB format. A three-component, 16-bit unsigned normalized format that has a 5-bit ...
@ BC5RGSnorm
BC5 compressed format. A two-component, block-compressed format where each 128-bit compressed texel b...
@ RG32Float
32 bit per channel RG format. A two-component, 64-bit signed floating-point format that has a 32-bit ...
@ BC4RUnorm
BC4 compressed format. A single-component, block-compressed format where each 64-bit compressed texel...
@ R8Uint
8 bit per channel R format. A one-component, 8-bit unsigned integer format that has an 8-bit R compon...
@ RGBA16Sint
16 bit per channel RGBA format. A four-component, 64-bit signed integer format that has a 16-bit R co...
@ BC7RGBAUnorm
BC7 compressed format. A four-component, block-compressed format where each 128-bit compressed texel ...
@ RGBA8Uint
8 bit per channel RGBA format. A four-component, 32-bit unsigned integer format that has an 8-bit R c...
@ RGBA8Sint
8 bit per channel RGBA format. A four-component, 32-bit signed integer format that has an 8-bit R com...
@ RG8Sint
8 bit per channel RG format. A two-component, 16-bit signed integer format that has an 8-bit R compon...
@ BC1RGBAUnormSrgb
BC1/DXT1 compressed format. A four-component, block-compressed format where each 64-bit compressed te...
@ R32Uint
32 bit per channel R format. A one-component, 32-bit unsigned integer format that has a 32-bit R comp...
@ R16Unorm
16 bit per channel R format. A one-component, 16-bit unsigned normalized format that has a 16-bit R c...
@ B5G5R5A1Unorm
16 bit per channel RGBA format. A four-component, 16-bit unsigned normalized format that has a 5-bit ...
@ RGB9E5UFloat
9 bit per channel RGB format with shared exponent. A three-component, 32-bit unsigned floating-point ...
@ RG8Uint
8 bit per channel RG format. A two-component, 16-bit unsigned integer format that has an 8-bit R comp...
@ RG16Unorm
16 bit per channel RG format. A two-component, 32-bit unsigned normalized format that has a 16-bit R ...
@ BC3RGBAUnormSrgb
BC3/DXT5 compressed format. A four-component, block-compressed format where each 128-bit compressed t...
@ RGBA8Unorm
8 bit per channel RGBA format. A four-component, 32-bit unsigned normalized format that has an 8-bit ...
@ RGBA32Uint
32 bit per channel RGBA format. A four-component, 128-bit unsigned integer format that has a 32-bit R...
@ RG16Sint
16 bit per channel RG format. A two-component, 32-bit signed integer format that has a 16-bit R compo...
@ R8Snorm
8 bit per channel R format. A one-component, 8-bit signed normalized format that has an 8-bit R compo...
@ R16Uint
16 bit per channel R format. A one-component, 16-bit unsigned integer format that has a 16-bit R comp...
@ R32Float
32 bit per channel R format. A one-component, 32-bit signed floating-point format that has a 32-bit R...
@ BGRA8Unorm
8 bit per channel RGBA format. A four-component, 32-bit unsigned normalized format that has an 8-bit ...
@ RGBA32Float
32 bit per channel RGBA format. A four-component, 128-bit signed floating-point format that has a 32-...
@ BC7RGBAUnormSrgb
BC7 compressed format. A four-component, block-compressed format where each 128-bit compressed texel ...
@ BC6HSfloat16
BC6H compressed format. A three-component, block-compressed format where each 128-bit compressed texe...
@ BC4RSnorm
BC4 compressed format. A single-component, block-compressed format where each 64-bit compressed texel...
@ BC6HUfloat16
BC6H compressed format. A three-component, block-compressed format where each 128-bit compressed texe...
@ RG32Uint
32 bit per channel RG format. A two-component, 64-bit unsigned integer format that has a 32-bit R com...
@ RG11B10Float
11 bit per channel RG format with 10 bit blue. A three-component, 32-bit signed floating-point format...
@ BGRA4Unorm
4 bit per channel RGB format. A four-component, 16-bit unsigned normalized format that has a 4-bit B ...
MutiWaitFlags
Determines the behavior when wait for multiple fences is issued.
@ Any
At least one of the fences from the batch is triggered.
ASInstanceFlags
Instance flags for additional instance features.
@ TriangleCullDisable
Triangle cull is disabled.
@ ForceOpaque
Force opaque.
@ ForceNoOpaque
Force no opaque.
@ TriangleFrontCounterClockwise
Triangle front is counter clockwise.
WindingOrder
Winding order for front-facing triangles.
@ CounterClockwise
Front-facing triangles have counter-clockwise winding order.
@ Clockwise
Front-facing triangles have clockwise winding order.
HitGroupType
Type of the hit group in the raytracing pipeline.
@ Procedural
Hit group for procedural geometry.
Acceleration structure allocation info. Used to query sizes for AS build/update buffers.
uint64_t result_size
Size of the result buffer.
uint64_t scratch_size
Size of the scratch buffer.
uint64_t update_size
Size of the update buffer.
Adapter description. Describes hardware driver identificators as well as memory limits.
uint64_t adapter_id
Adapter unique ID (LUID). Can be used to find the correct adapter.
uint64_t dedicated_system_memory
Dedicated system memory in bytes. Used for Upload and Readback Memory types.
uint32_t subsys_id
Unused.
uint64_t dedicated_video_memory
Dedicated video memory in bytes. Used for Default Memory type.
uint32_t revision
Driver revision. Unused.
uint32_t vendor_id
Vendor ID. Can be used to find the correct adapter.
wis::AdapterFlags flags
Adapter flags. Describe the adapter kind.
std::array< const char, 256 > description
Adapter description. Contains name of the graphics adapter.
uint32_t device_id
Device ID. Together with wis::AdapterDesc::vendor_id uniquely identifies the device.
uint64_t shared_system_memory
Shared system memory in bytes. Used for GPUUpload Memory type.
std::array< uint8_t, 16 > adapter_uuid
UUID of the adapter, used only with Vulkan API on systems with no LUID.
Allocation info for Resource Allocation.
uint64_t alignment_bytes
Alignment of the allocation in bytes.
uint64_t size_bytes
Size of the allocation in bytes.
Blend attachment description for wis::BlendStateDesc.
bool blend_enable
Blend enable. Default is false.
wis::BlendOp alpha_blend_op
Alpha blend operation. Default is wis::BlendOp::Add.
wis::BlendOp color_blend_op
Color blend operation. Default is wis::BlendOp::Add.
wis::BlendFactor src_color_blend
Source color blend factor. Default is wis::BlendFactor::One.
wis::BlendFactor src_alpha_blend
Source alpha blend factor. Default is wis::BlendFactor::One.
wis::BlendFactor dst_alpha_blend
Destination alpha blend factor. Default is wis::BlendFactor::Zero.
wis::ColorComponents color_write_mask
Color write mask. Default is wis::ColorComponents::All.
wis::BlendFactor dst_color_blend
Destination color blend factor. Default is wis::BlendFactor::Zero.
Blend state description for .
wis::LogicOp logic_op
Logic operation. Default is wis::LogicOp::Noop.
bool logic_op_enable
Logic operation enable. Default is false.
uint32_t attachment_count
Blend attachment count.
std::array< wis::BlendAttachmentDesc, 8 > attachments
Blend attachment descriptions. Max Array size is 8.
Buffer barrier for wis::CommandList.
wis::ResourceAccess access_before
Resource access before the barrier.
wis::BarrierSync sync_after
Synchronization after the barrier.
wis::ResourceAccess access_after
Resource access after the barrier.
uint64_t offset
Offset in the buffer in bytes. Default is 0.
wis::BarrierSync sync_before
Synchronization before the barrier.
uint64_t size
Size of the buffer in bytes. Default is UINT64_MAX, which means entire buffer.
Buffer region for copy operations.
uint64_t size_bytes
Size of portion of source buffer to take copy from in bytes.
uint64_t src_offset
Source offset in bytes. Default is 0.
uint64_t dst_offset
Destination offset in bytes. Default is 0.
Buffer to texture copy region.
wis::TextureRegion texture
Texture region.
uint64_t buffer_offset
Buffer offset in bytes.
Component mapping for wis::ShaderResourceDesc.
wis::ComponentSwizzle b
Component mapping for Blue channel. Default is wis::ComponentSwizzle::Blue.
wis::ComponentSwizzle r
Component mapping for Red channel. Default is wis::ComponentSwizzle::Red.
wis::ComponentSwizzle a
Component mapping for Alpha channel. Default is wis::ComponentSwizzle::Alpha.
wis::ComponentSwizzle g
Component mapping for Green channel. Default is wis::ComponentSwizzle::Green.
Depth stencil description for .
bool depth_bound_test
Depth bound test enable. Default is false.
bool depth_enable
Depth test enable. Default is false.
bool stencil_enable
Stencil test enable. Default is false.
wis::StencilDesc stencil_back
Stencil description for back faces.
wis::Compare depth_comp
Depth comparison function. Default is wis::Compare::Less.
wis::StencilDesc stencil_front
Stencil description for front faces.
bool depth_write_enable
Depth write enable. Default is false.
Descriptor binding description for RootSignature and Descriptor Storage creation. Description place i...
wis::DescriptorType binding_type
Binding type. Must be unique in array.
uint32_t space_overlap_count
Number of consecutive spaces this binding occupies. e.g. for binding_space = 1 and space_overlap_coun...
uint32_t binding_space
Binding space number in HLSL.
uint32_t binding_count
How many bindings should be allocated. Affects only the count of descriptors allocated in the descrip...
Descriptor table entry for wis::DescriptorTable.
uint32_t bind_register
Bind register number in HLSL.
wis::DescriptorType type
Descriptor type.
uint32_t binding
Binding number in HLSL.
uint32_t binding_space
Explicit binding space in HLSL. Used for DirectX 12 implementation. Default is 0.
uint32_t count
Descriptor count for Array descriptors. UINT32_MAX means unbounded array.
Descriptor table for wis::DescriptorBuffer.
uint32_t entry_count
Descriptor table entries count.
wis::DescriptorHeapType type
Descriptor heap type. Either Descriptor or Sampler.
const wis::DescriptorTableEntry * entries
Descriptor table entries array.
wis::ShaderStages stage
Shader stage. Defines the stage where the table is used.
Constants that device provide to work with it.
uint32_t min_buffer_offset_alingnment
Minimal structured or RW buffer offset alignment.
uint32_t min_cbuffer_offset_alingnment
Minimal constant buffer offset alignment.
Struct used to query the extensions for C code. Queried results should not be freed,...
void * result
Result of the query. Pointer is populated with the extension with queried ID. If the extension is not...
wis::DeviceExtID extension_id
Extension ID.
Struct used to query the extensions for C code. Queried results should not be freed,...
wis::FactoryExtID extension_id
Extension ID.
void * result
Result of the query. Pointer is populated with the extension with queried ID. If the extension is not...
Hit group description for Raytracing pipeline.
wis::HitGroupType type
Type of the hit group. wis::HitGroupType::Triangles - hit group for triangles. Uses closest hit shade...
uint32_t any_hit_export_index
Any hit shader.
uint32_t intersection_export_index
Intersection shader.
uint32_t closest_hit_export_index
Closest hit shader from wis::ShaderExport.
A set of constants that get pushed directly to the pipeline. Only one set can be created per shader s...
uint32_t size_bytes
Size of the constant in bytes. Must be divisible by 4.
uint32_t bind_register
Bind register number in HLSL.
wis::ShaderStages stage
Shader stage. Defines the stage where the constant is used.
Push descriptor. Used to push data directly to pipeline.
wis::DescriptorType type
Descriptor type. Works only with buffer-like bindings.
wis::ShaderStages stage
Shader stage. Defines the stage where the descriptor is used.
Rasterizer description for .
wis::FillMode fill_mode
Fill mode. Solid or Wireframe. Default is wis::FillMode::Solid.
bool depth_clip_enable
Depth clip enable. Default is true.
wis::CullMode cull_mode
Cull mode. None, Front, Back. Default is wis::CullMode::Back.
bool depth_bias_enable
Depth bias enable. Default is false.
float depth_bias_slope_factor
Depth bias slope factor e.g. for shadows. Default is 0.0f.
wis::WindingOrder front_face
Front face winding order. Clockwise or CounterClockwise. Default is wis::WindingOrder::Clockwise.
float depth_bias_clamp
Depth bias clamp. Default is 0.0f.
float depth_bias
Depth bias. Default is 0.0f.
Constants that device provide to work with raytracing.
uint32_t max_recursion_depth
Max recursion depth for raytracing pipeline.
Raytracing dispatch description for wis::CommandList.
uint32_t miss_shader_table_stride
Stride of the miss shader table in bytes.
uint32_t callable_shader_table_stride
Stride of the callable shader table in bytes.
uint32_t width
Width of the dispatch in number of rays.
uint64_t hit_group_table_address
Address of the hit group shader table.
uint32_t callable_shader_table_size
Size of the callable shader table in bytes.
uint32_t height
Height of the dispatch in number of rays.
uint64_t callable_shader_table_address
Address of the callable shader table.
uint64_t ray_gen_shader_table_address
Address of the ray generation shader table.
uint32_t hit_group_table_size
Size of the hit group shader table in bytes.
uint32_t ray_gen_shader_table_size
Size of the ray generation shader table in bytes.
uint32_t depth
Depth of the dispatch in number of rays.
uint32_t hit_group_table_stride
Stride of the hit group shader table in bytes.
uint64_t miss_shader_table_address
Address of the miss shader table.
uint32_t miss_shader_table_size
Size of the miss shader table in bytes.
Render attachments description for .
std::array< wis::DataFormat, 8 > attachment_formats
Attachment formats array. Describes the format of the render target.
uint32_t attachments_count
Attachment formats count. Max is 8.
wis::DataFormat depth_attachment
Depth attachment format. Describes the format of the depth buffer.
Render target description for wis::RenderTarget creation.
uint32_t base_array_layer
Base array layer of the render target. Default is 0.
uint32_t layer_count
Array layers count of the render target. Default is 1.
wis::TextureLayout layout
Render target layout. Default is wis::TextureLayout::Texture2D.
wis::DataFormat format
Render target format.
uint32_t mip
Mip level of the render target. Default is 0.
Main source of communication of operation success. To check for success compare wis::Result::status w...
wis::Status status
Operation status. Compare with wis::Status::Ok.
const char * error
Error message. nullptr or 'Operation Succeeded.' if no error.
Sample description of Multisampling for .
wis::SampleRate rate
Sample rate. Default is wis::SampleRate::S1.
uint32_t sample_mask
Sample mask. Default is 0xffffffff.
float quality
Sample quality. Default is 0.0f.
Sampler description for wis::Sampler creation.
bool anisotropic
Anisotropic filtering enable.
float max_lod
Max LOD value.
float mip_lod_bias
Mip LOD bias value.
uint32_t max_anisotropy
Max anisotropy level. Max is 16.
wis::Filter min_filter
Minification filter.
wis::AddressMode address_u
Address mode for U coordinate.
std::array< float, 4 > border_color
Border color.
wis::AddressMode address_w
Address mode for W coordinate.
wis::Filter mag_filter
Magnification filter.
float min_lod
Min LOD value.
wis::Compare comparison_op
Comparison operation for comparison samplers.
wis::Filter mip_filter
Mip level filter.
wis::AddressMode address_v
Address mode for V coordinate.
Scissor description for wis::CommandList.
int32_t bottom
Bottom corner y coordinate.
int32_t left
Left corner x coordinate.
int32_t right
Right corner x coordinate.
int32_t top
Top corner y coordinate.
Shader binding table description for Raytracing pipeline.
uint32_t entry_size
Size/stride of the entry in bytes.
uint32_t table_start_alignment
Alignment of the table start in bytes.
Defines export shader functions from a library shader.
wis::RaytracingShaderType shader_type
Type of the shader.
uint32_t shader_array_index
Index of the shader in the shader array.
const char * entry_point
Entry point of the shader.
Shader resource description for .
wis::SubresourceRange subresource_range
Subresource range of the resource.
wis::ComponentMapping component_mapping
Component mapping.
wis::DataFormat format
Resource format.
wis::TextureViewType view_type
Resource view type.
uint32_t depth_or_layers
Depth for 3D textures, layers for 2D arrays.
Stencil description for wis::DepthStencilDesc.
wis::StencilOp pass_op
Stencil operation if the stencil test passes. Default is wis::StencilOp::Keep.
wis::Compare comparison
Stencil comparison function. Default is wis::Compare::Always.
wis::StencilOp depth_fail_op
Stencil operation if the stencil test passes and the depth test fails. Default is wis::StencilOp::Kee...
wis::StencilOp fail_op
Stencil operation if the stencil test fails. Default is wis::StencilOp::Keep.
uint8_t write_mask
Stencil write mask. Default is 0xff.
uint8_t read_mask
Stencil read mask. Default is 0xff.
Subresource range for wis::TextureBarrier.
uint32_t base_array_layer
Base array layer.
uint32_t level_count
Mip levels count.
uint32_t base_mip_level
Base mip level.
uint32_t layer_count
Array layers count.
Swapchain description for wis::SwapChain creation.
wis::Size2D size
Swapchain texture size.
bool stereo
Stereo mode enable. If there is no stereo in the system will be ignored.
uint32_t buffer_count
Swapchain buffer count.
bool tearing
Tearing enable. If VSync is disabled, Tearing may be enabled. If System does not allow tearing the fl...
bool vsync
VSync enable. Specifies Initial VSync. This value may be changed on per-present bases with wis::Devic...
wis::DataFormat format
Swapchain texture format.
wis::SwapchainScaling scaling
Swapchain scaling mode.
Texture barrier for wis::CommandList.
wis::SubresourceRange subresource_range
Subresource range of the texture. Zero initialized range means all subresources are selected.
wis::ResourceAccess access_before
Resource access before the barrier.
wis::TextureState state_after
Texture state after the barrier.
wis::BarrierSync sync_before
Synchronization before the barrier.
wis::TextureState state_before
Texture state before the barrier.
wis::BarrierSync sync_after
Synchronization after the barrier.
wis::ResourceAccess access_after
Resource access after the barrier.
Texture to texture copy region.
wis::TextureRegion dst
Destination texture region.
wis::TextureRegion src
Source texture region.
Texture description for wis::Texture creation.
wis::SampleRate sample_count
Sample count. Default is wis::SampleRate::S1.
uint32_t mip_levels
Mip levels count. Default is 1.
wis::DataFormat format
Texture pixel/block format.
wis::TextureLayout layout
Texture layout. Default is wis::TextureLayout::Texture2D.
wis::TextureUsage usage
Texture usage flags.
wis::Size3D size
Texture size. Third dimension may be used for array layers or depth layers, depending on wis::Texture...
Texture region for copy operations.
wis::Size3D offset
Offset in the texture in pixels. In BufferToTexture determines offset of destination texture....
uint32_t array_layer
Array layer of the texture.
uint32_t mip
Mip level of the texture.
wis::DataFormat format
Format of the texture.
wis::Size3D size
Size of the region in pixels.
Top level acceleration structure build description.
wis::AccelerationStructureFlags flags
Build flags.
uint32_t instance_count
Instance count.
bool indirect
If true Buffer under address contains pointers to the instances, rather than instances themselves.
bool update
true means the acceleration structure is being updated. flags must have contained wis::AccelerationSt...
uint64_t gpu_address
Address of instances.
Unordered access description for RW Texture creation.
wis::DataFormat format
Resource format.
wis::SubresourceRange subresource_range
Subresource range of the resource.
wis::TextureViewType view_type
Resource view type.
Viewport description for wis::CommandList. Viewport is considered from Top Left corner.
float height
Viewport height.
float width
Viewport width.
float min_depth
Minimum depth of the viewport.
float max_depth
Maximum depth of the viewport.
float top_lefty
Top left corner y coordinate.
float top_leftx
Top left corner x coordinate.