Skip to content

Commit

Permalink
deps: update moltenvk to 1.2.9
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-lysiuk committed May 9, 2024
1 parent dea490f commit a87a7d7
Show file tree
Hide file tree
Showing 7 changed files with 359 additions and 1,098 deletions.
1,074 changes: 8 additions & 1,066 deletions deps/moltenvk/include/MoltenVK/mvk_config.h

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions deps/moltenvk/include/MoltenVK/mvk_datatypes.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* mvk_datatypes.h
*
* Copyright (c) 2015-2023 The Brenwill Workshop Ltd. (http://www.brenwill.com)
* Copyright (c) 2015-2024 The Brenwill Workshop Ltd. (http://www.brenwill.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -342,6 +342,9 @@ MTLBlendOperation mvkMTLBlendOperationFromVkBlendOp(VkBlendOp vkBlendOp);
/** Returns the Metal MTLBlendFactor corresponding to the specified Vulkan VkBlendFactor. */
MTLBlendFactor mvkMTLBlendFactorFromVkBlendFactor(VkBlendFactor vkBlendFactor);

/** Returns the Metal MTLLogicOperation corresponding to the specified Vulkan VkLogicOp. */
NSUInteger mvkMTLLogicOperationFromVkLogicOp(VkLogicOp vkBlendOp);

/**
* Returns the Metal MTLVertexFormat corresponding to the specified
* Vulkan VkFormat as used as a vertex attribute format.
Expand Down Expand Up @@ -449,7 +452,7 @@ static inline MTLOrigin mvkMTLOriginFromVkOffset3D(VkOffset3D vkOffset) {
}

/** Returns a Vulkan VkOffset3D constructed from a Metal MTLOrigin. */
static inline VkOffset3D mvkVkOffset3DFromMTLSize(MTLOrigin mtlOrigin) {
static inline VkOffset3D mvkVkOffset3DFromMTLOrigin(MTLOrigin mtlOrigin) {
return { (int32_t)mtlOrigin.x, (int32_t)mtlOrigin.y, (int32_t)mtlOrigin.z };
}

Expand Down Expand Up @@ -479,9 +482,6 @@ static inline VkExtent3D mvkVkExtent3DFromMTLSize(MTLSize mtlSize) {
/** Macro indicating the Vulkan memory type bits corresponding to Metal memoryless memory (not host visible and lazily allocated). */
#define MVK_VK_MEMORY_TYPE_METAL_MEMORYLESS (VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT | VK_MEMORY_PROPERTY_LAZILY_ALLOCATED_BIT)

/** Returns the Metal storage mode corresponding to the specified Vulkan memory flags. */
MTLStorageMode mvkMTLStorageModeFromVkMemoryPropertyFlags(VkMemoryPropertyFlags vkFlags);

/** Returns the Metal CPU cache mode corresponding to the specified Vulkan memory flags. */
MTLCPUCacheMode mvkMTLCPUCacheModeFromVkMemoryPropertyFlags(VkMemoryPropertyFlags vkFlags);

Expand Down
20 changes: 18 additions & 2 deletions deps/moltenvk/include/MoltenVK/mvk_deprecated_api.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* mvk_deprecated_api.h
*
* Copyright (c) 2015-2023 The Brenwill Workshop Ltd. (http://www.brenwill.com)
* Copyright (c) 2015-2024 The Brenwill Workshop Ltd. (http://www.brenwill.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -24,7 +24,7 @@
extern "C" {
#endif // __cplusplus

#include <MoltenVK/mvk_config.h>
#include <MoltenVK/mvk_private_api.h>
#include <IOSurface/IOSurfaceRef.h>


Expand All @@ -34,6 +34,7 @@ extern "C" {
/**
* This header contains obsolete and deprecated MoltenVK functions, that were originally
* part of the obsolete and deprecated non-standard VK_MVK_moltenvk extension.
* This header is provided for legacy compatibility only.
*
* NOTE: USE OF THE FUNCTIONS BELOW IS NOT RECOMMENDED. THE VK_MVK_moltenvk EXTENSION,
* AND THE FUNCTIONS BELOW ARE NOT SUPPORTED BY THE VULKAN LOADER AND LAYERS.
Expand All @@ -49,6 +50,7 @@ extern "C" {
#pragma mark -
#pragma mark Function types

typedef VkResult (VKAPI_PTR *PFN_vkSetMoltenVKConfigurationMVK)(VkInstance ignored, const MVKConfiguration* pConfiguration, size_t* pConfigurationSize);
typedef void (VKAPI_PTR *PFN_vkGetVersionStringsMVK)(char* pMoltenVersionStringBuffer, uint32_t moltenVersionStringBufferLength, char* pVulkanVersionStringBuffer, uint32_t vulkanVersionStringBufferLength);
typedef void (VKAPI_PTR *PFN_vkSetWorkgroupSizeMVK)(VkShaderModule shaderModule, uint32_t x, uint32_t y, uint32_t z);
typedef VkResult (VKAPI_PTR *PFN_vkUseIOSurfaceMVK)(VkImage image, IOSurfaceRef ioSurface);
Expand All @@ -72,6 +74,20 @@ typedef void (VKAPI_PTR *PFN_vkGetMTLCommandQueueMVK)(VkQueue queue, id<MTLComma
#define MVK_DEPRECATED_USE_MTL_OBJS VKAPI_ATTR [[deprecated("Use the VK_EXT_metal_objects extension instead.")]]


/**
* DEPRECATED.
* To set configuration values, use one of the following mechansims:
*
* - The standard Vulkan VK_EXT_layer_settings extension (layer name "MoltenVK").
* - Application runtime environment variables.
* - Build settings at MoltenVK build time.
*/
VKAPI_ATTR [[deprecated("Use the VK_EXT_layer_settings extension, or environment variables, instead.")]]
VkResult VKAPI_CALL vkSetMoltenVKConfigurationMVK(
VkInstance instance,
const MVKConfiguration* pConfiguration,
size_t* pConfigurationSize);

/**
* DEPRECATED.
* Returns a human readable version of the MoltenVK and Vulkan versions.
Expand Down
Loading

0 comments on commit a87a7d7

Please sign in to comment.