Merge pull request #1603 from scandit-opm/reorder-ctor
Fix reorder-ctor warnings
This commit is contained in:
commit
d7890c7b98
@ -1039,15 +1039,15 @@ MVKCommandEncoder::MVKCommandEncoder(MVKCommandBuffer* cmdBuffer) : MVKBaseDevic
|
|||||||
_scissorState(this),
|
_scissorState(this),
|
||||||
_depthBiasState(this),
|
_depthBiasState(this),
|
||||||
_blendColorState(this),
|
_blendColorState(this),
|
||||||
|
_depthStencilState(this),
|
||||||
|
_stencilReferenceValueState(this),
|
||||||
|
_graphicsResourcesState(this),
|
||||||
|
_computeResourcesState(this),
|
||||||
_vertexPushConstants(this, VK_SHADER_STAGE_VERTEX_BIT),
|
_vertexPushConstants(this, VK_SHADER_STAGE_VERTEX_BIT),
|
||||||
_tessCtlPushConstants(this, VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT),
|
_tessCtlPushConstants(this, VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT),
|
||||||
_tessEvalPushConstants(this, VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT),
|
_tessEvalPushConstants(this, VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT),
|
||||||
_fragmentPushConstants(this, VK_SHADER_STAGE_FRAGMENT_BIT),
|
_fragmentPushConstants(this, VK_SHADER_STAGE_FRAGMENT_BIT),
|
||||||
_computePushConstants(this, VK_SHADER_STAGE_COMPUTE_BIT),
|
_computePushConstants(this, VK_SHADER_STAGE_COMPUTE_BIT),
|
||||||
_depthStencilState(this),
|
|
||||||
_stencilReferenceValueState(this),
|
|
||||||
_graphicsResourcesState(this),
|
|
||||||
_computeResourcesState(this),
|
|
||||||
_occlusionQueryState(this) {
|
_occlusionQueryState(this) {
|
||||||
|
|
||||||
_pDeviceFeatures = &_device->_enabledFeatures;
|
_pDeviceFeatures = &_device->_enabledFeatures;
|
||||||
|
@ -94,15 +94,15 @@ MVKCommandPool::MVKCommandPool(MVKDevice* device,
|
|||||||
const VkCommandPoolCreateInfo* pCreateInfo,
|
const VkCommandPoolCreateInfo* pCreateInfo,
|
||||||
bool usePooling) :
|
bool usePooling) :
|
||||||
MVKVulkanAPIDeviceObject(device),
|
MVKVulkanAPIDeviceObject(device),
|
||||||
_queueFamilyIndex(pCreateInfo->queueFamilyIndex),
|
|
||||||
_commandBufferPool(device, usePooling),
|
|
||||||
_commandEncodingPool(this),
|
|
||||||
|
|
||||||
// Initialize the command type pool member variables.
|
// Initialize the command type pool member variables.
|
||||||
# define MVK_CMD_TYPE_POOL_LAST(cmdType) _cmd ##cmdType ##Pool(usePooling)
|
# define MVK_CMD_TYPE_POOL_LAST(cmdType) _cmd ##cmdType ##Pool(usePooling)
|
||||||
# define MVK_CMD_TYPE_POOL(cmdType) MVK_CMD_TYPE_POOL_LAST(cmdType),
|
# define MVK_CMD_TYPE_POOL(cmdType) MVK_CMD_TYPE_POOL_LAST(cmdType),
|
||||||
# include "MVKCommandTypePools.def"
|
# include "MVKCommandTypePools.def"
|
||||||
|
,
|
||||||
|
_commandBufferPool(device, usePooling),
|
||||||
|
_commandEncodingPool(this),
|
||||||
|
_queueFamilyIndex(pCreateInfo->queueFamilyIndex)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
MVKCommandPool::~MVKCommandPool() {
|
MVKCommandPool::~MVKCommandPool() {
|
||||||
|
@ -58,7 +58,7 @@ public:
|
|||||||
id<MTLBuffer> mtlBuffer,
|
id<MTLBuffer> mtlBuffer,
|
||||||
NSUInteger offset,
|
NSUInteger offset,
|
||||||
NSUInteger length,
|
NSUInteger length,
|
||||||
uint64_t poolIndex) : _pool(pool), _mtlBuffer(mtlBuffer), _offset(offset), _length(length), _poolIndex(poolIndex) {}
|
uint64_t poolIndex) : _mtlBuffer(mtlBuffer), _offset(offset), _length(length), _pool(pool), _poolIndex(poolIndex) {}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
friend class MVKMTLBufferAllocationPool;
|
friend class MVKMTLBufferAllocationPool;
|
||||||
|
@ -71,6 +71,11 @@ typedef struct MVKPipelineBarrier {
|
|||||||
Image,
|
Image,
|
||||||
} MVKPipelineBarrierType;
|
} MVKPipelineBarrierType;
|
||||||
|
|
||||||
|
MVKPipelineBarrierType type = None;
|
||||||
|
VkAccessFlags srcAccessMask = 0;
|
||||||
|
VkAccessFlags dstAccessMask = 0;
|
||||||
|
uint8_t srcQueueFamilyIndex = 0;
|
||||||
|
uint8_t dstQueueFamilyIndex = 0;
|
||||||
union { MVKBuffer* mvkBuffer = nullptr; MVKImage* mvkImage; MVKResource* mvkResource; };
|
union { MVKBuffer* mvkBuffer = nullptr; MVKImage* mvkImage; MVKResource* mvkResource; };
|
||||||
union {
|
union {
|
||||||
struct {
|
struct {
|
||||||
@ -86,12 +91,6 @@ typedef struct MVKPipelineBarrier {
|
|||||||
uint8_t levelCount;
|
uint8_t levelCount;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
VkAccessFlags srcAccessMask = 0;
|
|
||||||
VkAccessFlags dstAccessMask = 0;
|
|
||||||
uint8_t srcQueueFamilyIndex = 0;
|
|
||||||
uint8_t dstQueueFamilyIndex = 0;
|
|
||||||
|
|
||||||
MVKPipelineBarrierType type = None;
|
|
||||||
|
|
||||||
bool isMemoryBarrier() { return type == Memory; }
|
bool isMemoryBarrier() { return type == Memory; }
|
||||||
bool isBufferBarrier() { return type == Buffer; }
|
bool isBufferBarrier() { return type == Buffer; }
|
||||||
@ -118,15 +117,15 @@ typedef struct MVKPipelineBarrier {
|
|||||||
type(Image),
|
type(Image),
|
||||||
srcAccessMask(vkBarrier.srcAccessMask),
|
srcAccessMask(vkBarrier.srcAccessMask),
|
||||||
dstAccessMask(vkBarrier.dstAccessMask),
|
dstAccessMask(vkBarrier.dstAccessMask),
|
||||||
newLayout(vkBarrier.newLayout),
|
|
||||||
srcQueueFamilyIndex(vkBarrier.srcQueueFamilyIndex),
|
srcQueueFamilyIndex(vkBarrier.srcQueueFamilyIndex),
|
||||||
dstQueueFamilyIndex(vkBarrier.dstQueueFamilyIndex),
|
dstQueueFamilyIndex(vkBarrier.dstQueueFamilyIndex),
|
||||||
mvkImage((MVKImage*)vkBarrier.image),
|
mvkImage((MVKImage*)vkBarrier.image),
|
||||||
|
newLayout(vkBarrier.newLayout),
|
||||||
aspectMask(vkBarrier.subresourceRange.aspectMask),
|
aspectMask(vkBarrier.subresourceRange.aspectMask),
|
||||||
baseMipLevel(vkBarrier.subresourceRange.baseMipLevel),
|
|
||||||
levelCount(vkBarrier.subresourceRange.levelCount),
|
|
||||||
baseArrayLayer(vkBarrier.subresourceRange.baseArrayLayer),
|
baseArrayLayer(vkBarrier.subresourceRange.baseArrayLayer),
|
||||||
layerCount(vkBarrier.subresourceRange.layerCount)
|
layerCount(vkBarrier.subresourceRange.layerCount),
|
||||||
|
baseMipLevel(vkBarrier.subresourceRange.baseMipLevel),
|
||||||
|
levelCount(vkBarrier.subresourceRange.levelCount)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
} MVKPipelineBarrier;
|
} MVKPipelineBarrier;
|
||||||
|
@ -602,9 +602,9 @@ MVKDescriptorSetLayoutBinding::MVKDescriptorSetLayoutBinding(const MVKDescriptor
|
|||||||
_layout(binding._layout),
|
_layout(binding._layout),
|
||||||
_info(binding._info),
|
_info(binding._info),
|
||||||
_flags(binding._flags),
|
_flags(binding._flags),
|
||||||
_descriptorIndex(binding._descriptorIndex),
|
|
||||||
_immutableSamplers(binding._immutableSamplers),
|
_immutableSamplers(binding._immutableSamplers),
|
||||||
_mtlResourceIndexOffsets(binding._mtlResourceIndexOffsets) {
|
_mtlResourceIndexOffsets(binding._mtlResourceIndexOffsets),
|
||||||
|
_descriptorIndex(binding._descriptorIndex) {
|
||||||
|
|
||||||
for (uint32_t i = kMVKShaderStageVertex; i < kMVKShaderStageCount; i++) {
|
for (uint32_t i = kMVKShaderStageVertex; i < kMVKShaderStageCount; i++) {
|
||||||
_applyToStage[i] = binding._applyToStage[i];
|
_applyToStage[i] = binding._applyToStage[i];
|
||||||
|
@ -712,6 +712,7 @@ MVKDescriptorPool::MVKDescriptorPool(MVKDevice* device, const VkDescriptorPoolCr
|
|||||||
MVKVulkanAPIDeviceObject(device),
|
MVKVulkanAPIDeviceObject(device),
|
||||||
_descriptorSets(pCreateInfo->maxSets, MVKDescriptorSet(this)),
|
_descriptorSets(pCreateInfo->maxSets, MVKDescriptorSet(this)),
|
||||||
_descriptorSetAvailablility(pCreateInfo->maxSets, true),
|
_descriptorSetAvailablility(pCreateInfo->maxSets, true),
|
||||||
|
_inlineBlockMTLBufferAllocator(device, device->_pMetalFeatures->dynamicMTLBufferSize, true),
|
||||||
_uniformBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, poolDescriptors)),
|
_uniformBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, poolDescriptors)),
|
||||||
_storageBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, poolDescriptors)),
|
_storageBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, poolDescriptors)),
|
||||||
_uniformBufferDynamicDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC, poolDescriptors)),
|
_uniformBufferDynamicDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC, poolDescriptors)),
|
||||||
@ -724,7 +725,6 @@ MVKDescriptorPool::MVKDescriptorPool(MVKDevice* device, const VkDescriptorPoolCr
|
|||||||
_combinedImageSamplerDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, poolDescriptors)),
|
_combinedImageSamplerDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, poolDescriptors)),
|
||||||
_uniformTexelBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER, poolDescriptors)),
|
_uniformTexelBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER, poolDescriptors)),
|
||||||
_storageTexelBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, poolDescriptors)),
|
_storageTexelBufferDescriptors(getPoolSize(pCreateInfo, VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, poolDescriptors)),
|
||||||
_inlineBlockMTLBufferAllocator(device, device->_pMetalFeatures->dynamicMTLBufferSize, true),
|
|
||||||
_hasPooledDescriptors(poolDescriptors) {
|
_hasPooledDescriptors(poolDescriptors) {
|
||||||
initMetalArgumentBuffer(pCreateInfo);
|
initMetalArgumentBuffer(pCreateInfo);
|
||||||
}
|
}
|
||||||
|
@ -3997,10 +3997,10 @@ MVKDevice::MVKDevice(MVKPhysicalDevice* physicalDevice, const VkDeviceCreateInfo
|
|||||||
_enabledInterlockFeatures(),
|
_enabledInterlockFeatures(),
|
||||||
_enabledHostQryResetFeatures(),
|
_enabledHostQryResetFeatures(),
|
||||||
_enabledSamplerYcbcrConversionFeatures(),
|
_enabledSamplerYcbcrConversionFeatures(),
|
||||||
|
_enabledPrivateDataFeatures(),
|
||||||
_enabledScalarLayoutFeatures(),
|
_enabledScalarLayoutFeatures(),
|
||||||
_enabledTexelBuffAlignFeatures(),
|
_enabledTexelBuffAlignFeatures(),
|
||||||
_enabledVtxAttrDivFeatures(),
|
_enabledVtxAttrDivFeatures(),
|
||||||
_enabledPrivateDataFeatures(),
|
|
||||||
_enabledPortabilityFeatures(),
|
_enabledPortabilityFeatures(),
|
||||||
_enabledImagelessFramebufferFeatures(),
|
_enabledImagelessFramebufferFeatures(),
|
||||||
_enabledDynamicRenderingFeatures(),
|
_enabledDynamicRenderingFeatures(),
|
||||||
|
@ -205,8 +205,8 @@ void MVKPipeline::addMTLArgumentEncoders(MVKMTLFunction& mvkMTLFunc,
|
|||||||
MVKPipeline::MVKPipeline(MVKDevice* device, MVKPipelineCache* pipelineCache, MVKPipelineLayout* layout, MVKPipeline* parent) :
|
MVKPipeline::MVKPipeline(MVKDevice* device, MVKPipelineCache* pipelineCache, MVKPipelineLayout* layout, MVKPipeline* parent) :
|
||||||
MVKVulkanAPIDeviceObject(device),
|
MVKVulkanAPIDeviceObject(device),
|
||||||
_pipelineCache(pipelineCache),
|
_pipelineCache(pipelineCache),
|
||||||
_fullImageViewSwizzle(mvkConfig().fullImageViewSwizzle),
|
_descriptorSetCount(layout->getDescriptorSetCount()),
|
||||||
_descriptorSetCount(layout->getDescriptorSetCount()) {
|
_fullImageViewSwizzle(mvkConfig().fullImageViewSwizzle) {
|
||||||
|
|
||||||
// Establish descriptor counts and push constants use.
|
// Establish descriptor counts and push constants use.
|
||||||
for (uint32_t stage = kMVKShaderStageVertex; stage < kMVKShaderStageCount; stage++) {
|
for (uint32_t stage = kMVKShaderStageVertex; stage < kMVKShaderStageCount; stage++) {
|
||||||
|
@ -241,12 +241,12 @@ void MVKSwapchain::setHDRMetadataEXT(const VkHdrMetadataEXT& metadata) {
|
|||||||
MVKSwapchain::MVKSwapchain(MVKDevice* device,
|
MVKSwapchain::MVKSwapchain(MVKDevice* device,
|
||||||
const VkSwapchainCreateInfoKHR* pCreateInfo) :
|
const VkSwapchainCreateInfoKHR* pCreateInfo) :
|
||||||
MVKVulkanAPIDeviceObject(device),
|
MVKVulkanAPIDeviceObject(device),
|
||||||
_surfaceLost(false),
|
|
||||||
_currentAcquisitionID(0),
|
|
||||||
_layerObserver(nil),
|
|
||||||
_currentPerfLogFrameCount(0),
|
|
||||||
_lastFrameTime(0),
|
|
||||||
_licenseWatermark(nil),
|
_licenseWatermark(nil),
|
||||||
|
_currentAcquisitionID(0),
|
||||||
|
_lastFrameTime(0),
|
||||||
|
_currentPerfLogFrameCount(0),
|
||||||
|
_surfaceLost(false),
|
||||||
|
_layerObserver(nil),
|
||||||
_presentHistoryCount(0),
|
_presentHistoryCount(0),
|
||||||
_presentHistoryIndex(0),
|
_presentHistoryIndex(0),
|
||||||
_presentHistoryHeadIndex(0) {
|
_presentHistoryHeadIndex(0) {
|
||||||
|
@ -101,8 +101,8 @@ private:
|
|||||||
|
|
||||||
std::mutex _lock;
|
std::mutex _lock;
|
||||||
std::condition_variable _blocker;
|
std::condition_variable _blocker;
|
||||||
uint32_t _reservationCount;
|
|
||||||
bool _shouldWaitAll;
|
bool _shouldWaitAll;
|
||||||
|
uint32_t _reservationCount;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -90,10 +90,11 @@ MVKExtension::MVKExtension(VkExtensionProperties* pProperties, bool enableForPla
|
|||||||
#pragma mark -
|
#pragma mark -
|
||||||
#pragma mark MVKExtensionList
|
#pragma mark MVKExtensionList
|
||||||
|
|
||||||
MVKExtensionList::MVKExtensionList(MVKVulkanAPIObject* apiObject, bool enableForPlatform) : _apiObject(apiObject),
|
MVKExtensionList::MVKExtensionList(MVKVulkanAPIObject* apiObject, bool enableForPlatform) :
|
||||||
#define MVK_EXTENSION_LAST(var, EXT, type, macos, ios) vk_ ##var(&kVkExtProps_ ##EXT, enableForPlatform)
|
#define MVK_EXTENSION_LAST(var, EXT, type, macos, ios) vk_ ##var(&kVkExtProps_ ##EXT, enableForPlatform)
|
||||||
#define MVK_EXTENSION(var, EXT, type, macos, ios) MVK_EXTENSION_LAST(var, EXT, type, macos, ios),
|
#define MVK_EXTENSION(var, EXT, type, macos, ios) MVK_EXTENSION_LAST(var, EXT, type, macos, ios),
|
||||||
#include "MVKExtensions.def"
|
#include "MVKExtensions.def"
|
||||||
|
, _apiObject(apiObject)
|
||||||
{
|
{
|
||||||
initCount();
|
initCount();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user