VK: Updated headers. Cleanup.
This commit is contained in:
parent
eed8edb364
commit
32f1760690
16
3rdparty/khronos/vulkan/vk_platform.h
vendored
16
3rdparty/khronos/vulkan/vk_platform.h
vendored
@ -2,7 +2,7 @@
|
||||
// File: vk_platform.h
|
||||
//
|
||||
/*
|
||||
** Copyright (c) 2014-2015 The Khronos Group Inc.
|
||||
** Copyright (c) 2014-2017 The Khronos Group Inc.
|
||||
**
|
||||
** Licensed under the Apache License, Version 2.0 (the "License");
|
||||
** you may not use this file except in compliance with the License.
|
||||
@ -51,13 +51,13 @@ extern "C"
|
||||
#define VKAPI_ATTR
|
||||
#define VKAPI_CALL __stdcall
|
||||
#define VKAPI_PTR VKAPI_CALL
|
||||
#elif defined(__ANDROID__) && defined(__ARM_EABI__) && !defined(__ARM_ARCH_7A__)
|
||||
// Android does not support Vulkan in native code using the "armeabi" ABI.
|
||||
#error "Vulkan requires the 'armeabi-v7a' or 'armeabi-v7a-hard' ABI on 32-bit ARM CPUs"
|
||||
#elif defined(__ANDROID__) && defined(__ARM_ARCH_7A__)
|
||||
// On Android/ARMv7a, Vulkan functions use the armeabi-v7a-hard calling
|
||||
// convention, even if the application's native code is compiled with the
|
||||
// armeabi-v7a calling convention.
|
||||
#elif defined(__ANDROID__) && defined(__ARM_ARCH) && __ARM_ARCH < 7
|
||||
#error "Vulkan isn't supported for the 'armeabi' NDK ABI"
|
||||
#elif defined(__ANDROID__) && defined(__ARM_ARCH) && __ARM_ARCH >= 7 && defined(__ARM_32BIT_STATE)
|
||||
// On Android 32-bit ARM targets, Vulkan functions use the "hardfloat"
|
||||
// calling convention, i.e. float parameters are passed in registers. This
|
||||
// is true even if the rest of the application passes floats on the stack,
|
||||
// as it does by default when compiling for the armeabi-v7a NDK ABI.
|
||||
#define VKAPI_ATTR __attribute__((pcs("aapcs-vfp")))
|
||||
#define VKAPI_CALL
|
||||
#define VKAPI_PTR VKAPI_ATTR
|
||||
|
1936
3rdparty/khronos/vulkan/vulkan.h
vendored
1936
3rdparty/khronos/vulkan/vulkan.h
vendored
File diff suppressed because it is too large
Load Diff
@ -961,6 +961,8 @@ VK_IMPORT_INSTANCE
|
||||
g_caps.vendorId = uint16_t(m_deviceProperties.vendorID);
|
||||
g_caps.deviceId = uint16_t(m_deviceProperties.deviceID);
|
||||
|
||||
g_caps.limits.maxTextureSize = m_deviceProperties.limits.maxImageDimension2D;
|
||||
g_caps.limits.maxFBAttachments = uint8_t(bx::uint32_min(m_deviceProperties.limits.maxFragmentOutputAttachments, BGFX_CONFIG_MAX_FRAME_BUFFER_ATTACHMENTS) );
|
||||
|
||||
{
|
||||
// VkFormatProperties fp;
|
||||
@ -1171,7 +1173,7 @@ VK_IMPORT_DEVICE
|
||||
|
||||
m_backBufferDepthStencilFormat =
|
||||
VK_FORMAT_D32_SFLOAT_S8_UINT
|
||||
// VK_FORMAT_D24_UNORM_S8_UINT
|
||||
// VK_FORMAT_D24_UNORM_S8_UINT
|
||||
;
|
||||
|
||||
{
|
||||
@ -3506,11 +3508,11 @@ VK_DESTROY
|
||||
const void* code = reader.getDataPtr();
|
||||
bx::skip(&reader, shaderSize+1);
|
||||
|
||||
m_code = alloc( ( (shaderSize+3)/4)*4);
|
||||
m_code = alloc( ( ( (shaderSize+3)/4)*4) );
|
||||
bx::memSet(m_code->data, 0, m_code->size);
|
||||
bx::memCopy(m_code->data
|
||||
, code
|
||||
, shaderSize+1
|
||||
, shaderSize
|
||||
);
|
||||
#else
|
||||
#include "../examples/runtime/shaders/spv/vert.spv.h"
|
||||
@ -3535,7 +3537,12 @@ VK_DESTROY
|
||||
smci.flags = 0;
|
||||
smci.codeSize = m_code->size;
|
||||
smci.pCode = (const uint32_t*)m_code->data;
|
||||
VK_CHECK(vkCreateShaderModule(s_renderVK->m_device, &smci, s_renderVK->m_allocatorCb, &m_module) );
|
||||
VK_CHECK(vkCreateShaderModule(
|
||||
s_renderVK->m_device
|
||||
, &smci
|
||||
, s_renderVK->m_allocatorCb
|
||||
, &m_module
|
||||
) );
|
||||
|
||||
bx::memSet(m_attrMask, 0, sizeof(m_attrMask) );
|
||||
m_attrMask[Attrib::Position] = UINT16_MAX;
|
||||
|
Loading…
Reference in New Issue
Block a user