MVK_CONFIG_LOG_LEVEL_WARNING=2,/**< Log errors and warning messages. */
MVK_CONFIG_LOG_LEVEL_INFO=3,/**< Log errors, warnings and informational messages. */
MVK_CONFIG_LOG_LEVEL_DEBUG=4,/**< Log errors, warnings, infos and debug messages. */
MVK_CONFIG_LOG_LEVEL_MAX_ENUM=0x7FFFFFFF
}MVKConfigLogLevel;
/** Identifies the level of Vulkan call trace logging MoltenVK should perform. */
typedefenumMVKConfigTraceVulkanCalls{
MVK_CONFIG_TRACE_VULKAN_CALLS_NONE=0,/**< No Vulkan call logging. */
MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER=1,/**< Log the name of each Vulkan call when the call is entered. */
MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER_THREAD_ID=2,/**< Log the name and thread ID of each Vulkan call when the call is entered. */
MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER_EXIT=3,/**< Log the name of each Vulkan call when the call is entered and exited. This effectively brackets any other logging activity within the scope of the Vulkan call. */
MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER_EXIT_THREAD_ID=4,/**< Log the name and thread ID of each Vulkan call when the call is entered and name when exited. This effectively brackets any other logging activity within the scope of the Vulkan call. */
MVK_CONFIG_TRACE_VULKAN_CALLS_DURATION=5,/**< Same as MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER_EXIT, plus logs the time spent inside the Vulkan function. */
MVK_CONFIG_TRACE_VULKAN_CALLS_DURATION_THREAD_ID=6,/**< Same as MVK_CONFIG_TRACE_VULKAN_CALLS_ENTER_EXIT_THREAD_ID, plus logs the time spent inside the Vulkan function. */
MVK_CONFIG_TRACE_VULKAN_CALLS_MAX_ENUM=0x7FFFFFFF
}MVKConfigTraceVulkanCalls;
/** Identifies the scope for Metal to run an automatic GPU capture for diagnostic debugging purposes. */
typedefenumMVKConfigAutoGPUCaptureScope{
MVK_CONFIG_AUTO_GPU_CAPTURE_SCOPE_NONE=0,/**< No automatic GPU capture. */
MVK_CONFIG_AUTO_GPU_CAPTURE_SCOPE_DEVICE=1,/**< Automatically capture all GPU activity during the lifetime of a VkDevice. */
MVK_CONFIG_AUTO_GPU_CAPTURE_SCOPE_FRAME=2,/**< Automatically capture all GPU activity during the rendering and presentation of the first frame. */
/** Identifies the use of Metal Argument Buffers. */
typedefenumMVKUseMetalArgumentBuffers{
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_NEVER=0,/**< Don't use Metal Argument Buffers. */
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_ALWAYS=1,/**< Use Metal Argument Buffers for all pipelines. */
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_DESCRIPTOR_INDEXING=2,/**< Use Metal Argument Buffers only if VK_EXT_descriptor_indexing extension is enabled. */
/** Identifies the Metal functionality used to support Vulkan semaphore functionality (VkSemaphore). */
typedefenumMVKVkSemaphoreSupportStyle{
MVK_CONFIG_VK_SEMAPHORE_SUPPORT_STYLE_SINGLE_QUEUE=0,/**< Limit Vulkan to a single queue, with no explicit semaphore synchronization, and use Metal's implicit guarantees that all operations submitted to a queue will give the same result as if they had been run in submission order. */
MVK_CONFIG_VK_SEMAPHORE_SUPPORT_STYLE_METAL_EVENTS_WHERE_SAFE=1,/**< Use Metal events (MTLEvent) when available on the platform, and where safe. This will revert to same as MVK_CONFIG_VK_SEMAPHORE_USE_SINGLE_QUEUE on some NVIDIA GPUs and Rosetta2, due to potential challenges with MTLEvents on those platforms, or in older environments where MTLEvents are not supported. */
MVK_CONFIG_VK_SEMAPHORE_SUPPORT_STYLE_METAL_EVENTS=2,/**< Always use Metal events (MTLEvent) when available on the platform. This will revert to same as MVK_CONFIG_VK_SEMAPHORE_USE_SINGLE_QUEUE in older environments where MTLEvents are not supported. */
MVK_CONFIG_VK_SEMAPHORE_SUPPORT_STYLE_CALLBACK=3,/**< Use CPU callbacks upon GPU submission completion. This is the slowest technique, but allows multiple queues, compared to MVK_CONFIG_VK_SEMAPHORE_USE_SINGLE_QUEUE. */
/** Identifies the style of Metal command buffer pre-filling to be used. */
typedefenumMVKPrefillMetalCommandBuffersStyle{
MVK_CONFIG_PREFILL_METAL_COMMAND_BUFFERS_STYLE_NO_PREFILL=0,/**< During Vulkan command buffer filling, do not prefill a Metal command buffer for each Vulkan command buffer. A single Metal command buffer is created and encoded for all the Vulkan command buffers included when vkQueueSubmit() is called. MoltenVK automatically creates and drains a single Metal object autorelease pool when vkQueueSubmit() is called. This is the fastest option, but potentially has the largest memory footprint. */
MVK_CONFIG_PREFILL_METAL_COMMAND_BUFFERS_STYLE_DEFERRED_ENCODING=1,/**< During Vulkan command buffer filling, encode to the Metal command buffer when vkEndCommandBuffer() is called. MoltenVK automatically creates and drains a single Metal object autorelease pool when vkEndCommandBuffer() is called. This option has the fastest performance, and the largest memory footprint, of the prefilling options using autorelease pools. */
MVK_CONFIG_PREFILL_METAL_COMMAND_BUFFERS_STYLE_IMMEDIATE_ENCODING=2,/**< During Vulkan command buffer filling, immediately encode to the Metal command buffer, as each command is submitted to the Vulkan command buffer, and do not retain any command content in the Vulkan command buffer. MoltenVK automatically creates and drains a Metal object autorelease pool for each and every command added to the Vulkan command buffer. This option has the smallest memory footprint, and the slowest performance, of the prefilling options using autorelease pools. */
MVK_CONFIG_PREFILL_METAL_COMMAND_BUFFERS_STYLE_IMMEDIATE_ENCODING_NO_AUTORELEASE=3,/**< During Vulkan command buffer filling, immediately encode to the Metal command buffer, as each command is submitted to the Vulkan command buffer, do not retain any command content in the Vulkan command buffer, and assume the app will ensure that each thread that fills commands into a Vulkan command buffer has a Metal autorelease pool. MoltenVK will not create and drain any autorelease pools during encoding. This is the fastest prefilling option, and generally has a small memory footprint, depending on when the app-provided autorelease pool drains. */
/** Identifies when Metal shaders will be compiled with the fast math option. */
typedefenumMVKConfigFastMath{
MVK_CONFIG_FAST_MATH_NEVER=0,/**< Metal shaders will never be compiled with the fast math option. */
MVK_CONFIG_FAST_MATH_ALWAYS=1,/**< Metal shaders will always be compiled with the fast math option. */
MVK_CONFIG_FAST_MATH_ON_DEMAND=2,/**< Metal shaders will be compiled with the fast math option, unless the shader includes execution modes that require it to be compiled without fast math. */
MVK_CONFIG_FAST_MATH_MAX_ENUM=0x7FFFFFFF
}MVKConfigFastMath;
/** Identifies available system data compression algorithms. */
typedefenumMVKConfigCompressionAlgorithm{
MVK_CONFIG_COMPRESSION_ALGORITHM_NONE=0,/**< No compression. */
MVK_CONFIG_COMPRESSION_ALGORITHM_LZFSE=1,/**< Apple proprietary. Good balance of high performance and small compression size, particularly for larger data content. */
MVK_CONFIG_COMPRESSION_ALGORITHM_ZLIB=2,/**< Open cross-platform ZLib format. For smaller data content, has better performance and smaller size than LZFSE. */
MVK_CONFIG_COMPRESSION_ALGORITHM_LZ4=3,/**< Fastest performance. Largest compression size. */
MVK_CONFIG_ACTIVITY_PERFORMANCE_LOGGING_STYLE_FRAME_COUNT=0,/**< Repeatedly log performance after a configured number of frames. */
MVK_CONFIG_ACTIVITY_PERFORMANCE_LOGGING_STYLE_IMMEDIATE=1,/**< Log immediately after each performance measurement. */
MVK_CONFIG_ACTIVITY_PERFORMANCE_LOGGING_STYLE_DEVICE_LIFETIME=2,/**< Log at the end of the VkDevice lifetime. This is useful for one-shot apps such as testing frameworks. */
MVK_CONFIG_ACTIVITY_PERFORMANCE_LOGGING_STYLE_DEVICE_LIFETIME_ACCUMULATE=3,/**< Log at the end of the VkDevice lifetime, but continue to accumulate across mulitiple VkDevices throughout the app process. This is useful for testing frameworks that create many VkDevices serially. */
uint32_tmslVersion;/**< The version of the Metal Shading Language available on this device. The format of the integer is MMmmpp, with two decimal digts each for Major, minor, and patch version values (eg. MSL 1.2 would appear as 010200). */
VkBool32indirectDrawing;/**< If true, draw calls support parameters held in a GPU buffer. */
VkBool32baseVertexInstanceDrawing;/**< If true, draw calls support specifiying the base vertex and instance. */
uint32_tdynamicMTLBufferSize;/**< If greater than zero, dynamic MTLBuffers for setting vertex, fragment, and compute bytes are supported, and their content must be below this value. */
VkBool32shaderSpecialization;/**< If true, shader specialization (aka Metal function constants) is supported. */
VkBool32ioSurfaces;/**< If true, VkImages can be underlaid by IOSurfaces via the vkUseIOSurfaceMVK() function, to support inter-process image transfers. */
VkBool32texelBuffers;/**< If true, texel buffers are supported, allowing the contents of a buffer to be interpreted as an image via a VkBufferView. */
VkBool32layeredRendering;/**< If true, layered rendering to multiple cube or texture array layers is supported. */
VkBool32presentModeImmediate;/**< If true, immediate surface present mode (VK_PRESENT_MODE_IMMEDIATE_KHR), allowing a swapchain image to be presented immediately, without waiting for the vertical sync period of the display, is supported. */
VkBool32stencilViews;/**< If true, stencil aspect views are supported through the MTLPixelFormatX24_Stencil8 and MTLPixelFormatX32_Stencil8 formats. */
VkBool32multisampleArrayTextures;/**< If true, MTLTextureType2DMultisampleArray is supported. */
VkBool32samplerClampToBorder;/**< If true, the border color set when creating a sampler will be respected. */
uint32_tmaxTextureDimension;/**< The maximum size of each texture dimension (width, height, or depth). */
uint32_tmaxPerStageBufferCount;/**< The total number of per-stage Metal buffers available for shader uniform content and attributes. */
uint32_tmaxPerStageTextureCount;/**< The total number of per-stage Metal textures available for shader uniform content. */
uint32_tmaxPerStageSamplerCount;/**< The total number of per-stage Metal samplers available for shader uniform content. */
VkDeviceSizemaxMTLBufferSize;/**< The max size of a MTLBuffer (in bytes). */
VkDeviceSizemtlBufferAlignment;/**< The alignment used when allocating memory for MTLBuffers. Must be PoT. */
VkDeviceSizemaxQueryBufferSize;/**< The maximum size of an occlusion query buffer (in bytes). */
VkDeviceSizemtlCopyBufferAlignment;/**< The alignment required during buffer copy operations (in bytes). */
VkSampleCountFlagssupportedSampleCounts;/**< A bitmask identifying the sample counts supported by the device. */
uint32_tminSwapchainImageCount;/**< The minimum number of swapchain images that can be supported by a surface. */
uint32_tmaxSwapchainImageCount;/**< The maximum number of swapchain images that can be supported by a surface. */
VkBool32combinedStoreResolveAction;/**< If true, the device supports VK_ATTACHMENT_STORE_OP_STORE with a simultaneous resolve attachment. */
VkBool32arrayOfTextures;/**< If true, arrays of textures is supported. */
VkBool32arrayOfSamplers;/**< If true, arrays of texture samplers is supported. */
MTLLanguageVersionmslVersionEnum;/**< The version of the Metal Shading Language available on this device, as a Metal enumeration. */
VkBool32depthSampleCompare;/**< If true, depth texture samplers support the comparison of the pixel value against a reference value. */
VkBool32events;/**< If true, Metal synchronization events (MTLEvent) are supported. */
VkBool32memoryBarriers;/**< If true, full memory barriers within Metal render passes are supported. */
VkBool32multisampleLayeredRendering;/**< If true, layered rendering to multiple multi-sampled cube or texture array layers is supported. */
VkBool32stencilFeedback;/**< If true, fragment shaders that write to [[stencil]] outputs are supported. */
VkBool32textureBuffers;/**< If true, textures of type MTLTextureTypeBuffer are supported. */
VkBool32postDepthCoverage;/**< If true, coverage masks in fragment shaders post-depth-test are supported. */
VkBool32fences;/**< If true, Metal synchronization fences (MTLFence) are supported. */
VkBool32rasterOrderGroups;/**< If true, Raster order groups in fragment shaders are supported. */
VkBool32native3DCompressedTextures;/**< If true, 3D compressed images are supported natively, without manual decompression. */
VkBool32nativeTextureSwizzle;/**< If true, component swizzle is supported natively, without manual swizzling in shaders. */
VkBool32placementHeaps;/**< If true, MTLHeap objects support placement of resources. */
VkDeviceSizepushConstantSizeAlignment;/**< The alignment used internally when allocating memory for push constants. Must be PoT. */
uint32_tmaxTextureLayers;/**< The maximum number of layers in an array texture. */
uint32_tmaxSubgroupSize;/**< The maximum number of threads in a SIMD-group. */
VkDeviceSizevertexStrideAlignment;/**< The alignment used for the stride of vertex attribute bindings. */
VkBool32indirectTessellationDrawing;/**< If true, tessellation draw calls support parameters held in a GPU buffer. */
VkBool32nonUniformThreadgroups;/**< If true, the device supports arbitrary-sized grids in compute workloads. */
VkBool32renderWithoutAttachments;/**< If true, we don't have to create a dummy attachment for a render pass if there isn't one. */
VkBool32deferredStoreActions;/**< If true, render pass store actions can be specified after the render encoder is created. */
VkBool32sharedLinearTextures;/**< If true, linear textures and texture buffers can be created from buffers in Shared storage. */
VkBool32depthResolve;/**< If true, resolving depth textures with filters other than Sample0 is supported. */
VkBool32stencilResolve;/**< If true, resolving stencil textures with filters other than Sample0 is supported. */
uint32_tmaxPerStageDynamicMTLBufferCount;/**< The maximum number of inline buffers that can be set on a command buffer. */
uint32_tmaxPerStageStorageTextureCount;/**< The total number of per-stage Metal textures with read-write access available for writing to from a shader. */
VkBool32astcHDRTextures;/**< If true, ASTC HDR pixel formats are supported. */
VkBool32renderLinearTextures;/**< If true, linear textures are renderable. */
VkBool32pullModelInterpolation;/**< If true, explicit interpolation functions are supported. */
VkBool32samplerMirrorClampToEdge;/**< If true, the mirrored clamp to edge address mode is supported in samplers. */
VkBool32quadPermute;/**< If true, quadgroup permutation functions (vote, ballot, shuffle) are supported in shaders. */
VkBool32simdPermute;/**< If true, SIMD-group permutation functions (vote, ballot, shuffle) are supported in shaders. */
VkBool32simdReduction;/**< If true, SIMD-group reduction functions (arithmetic) are supported in shaders. */
uint32_tminSubgroupSize;/**< The minimum number of threads in a SIMD-group. */
VkBool32tileBasedDeferredRendering;/**< If true, this device uses tile-based deferred rendering. */
VkBool32argumentBuffers;/**< If true, Metal argument buffers are supported. */
VkBool32descriptorSetArgumentBuffers;/**< If true, a Metal argument buffer can be assigned to a descriptor set, and used on any pipeline and pipeline stage. If false, a different Metal argument buffer must be used for each pipeline-stage/descriptor-set combination. */
MVKFloatRoundingclearColorFloatRounding;/**< Identifies the type of rounding Metal uses for MTLClearColor float to integer conversions. */
MVKCounterSamplingFlagscounterSamplingPoints;/**< Identifies the points where pipeline GPU counter sampling may occur. */
VkBool32programmableSamplePositions;/**< If true, programmable MSAA sample positions are supported. */
VkBool32shaderBarycentricCoordinates;/**< If true, fragment shader barycentric coordinates are supported. */
MTLArgumentBuffersTierargumentBuffersTier;/**< The argument buffer tier available on this device, as a Metal enumeration. */
VkBool32needsSampleDrefLodArrayWorkaround;/**< If true, sampling from arrayed depth images with explicit LoD is broken and needs a workaround. */
VkDeviceSizehostMemoryPageSize;/**< The size of a page of host memory on this platform. */
MVKPerformanceTrackerretrieveMTLCommandBuffer;/** Retrieve a MTLCommandBuffer from a MTLQueue, in milliseconds. */
MVKPerformanceTrackercommandBufferEncoding;/** Encode a single VkCommandBuffer to a MTLCommandBuffer (excludes MTLCommandBuffer encoding from configured immediate prefilling), in milliseconds. */
MVKPerformanceTrackersubmitCommandBuffers;/** Submit and encode all VkCommandBuffers in a vkQueueSubmit() operation to MTLCommandBuffers (including both prefilled and deferred encoding), in milliseconds. */
MVKPerformanceTrackermtlCommandBufferExecution;/** Execute a MTLCommandBuffer on the GPU, from commit to completion callback, in milliseconds. */
MVKPerformanceTrackerretrieveCAMetalDrawable;/** Retrieve next CAMetalDrawable from a CAMetalLayer, in milliseconds. */
MVKPerformanceTrackerpresentSwapchains;/** Present the swapchains in a vkQueuePresentKHR() on the GPU, from commit to presentation callback, in milliseconds. */
MVKPerformanceTrackerframeInterval;/** Frame presentation interval (1000/FPS), in milliseconds. */