mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 12:32:52 +00:00
Silence several Vulkan related warnings that showed up in Xcode
This commit is contained in:
parent
3c199c794e
commit
6199baff3a
@ -1549,7 +1549,6 @@ static bool vulkan_context_init_gpu(gfx_ctx_vulkan_data_t *vk)
|
||||
|
||||
static bool vulkan_context_init_device(gfx_ctx_vulkan_data_t *vk)
|
||||
{
|
||||
bool use_device_ext;
|
||||
uint32_t queue_count;
|
||||
unsigned i;
|
||||
static const float one = 1.0f;
|
||||
@ -1733,7 +1732,7 @@ static bool vulkan_context_init_device(gfx_ctx_vulkan_data_t *vk)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!(use_device_ext = vulkan_find_device_extensions(vk->context.gpu,
|
||||
if (!(vulkan_find_device_extensions(vk->context.gpu,
|
||||
enabled_device_extensions, &enabled_device_extension_count,
|
||||
device_extensions, ARRAY_SIZE(device_extensions),
|
||||
optional_device_extensions,
|
||||
|
@ -1857,8 +1857,6 @@ static void vulkan_set_viewport(void *data, unsigned viewport_width,
|
||||
bool video_scale_integer = settings->bools.video_scale_integer;
|
||||
unsigned aspect_ratio_idx = settings->uints.video_aspect_ratio_idx;
|
||||
vk_t *vk = (vk_t*)data;
|
||||
unsigned width = vk->video_width;
|
||||
unsigned height = vk->video_height;
|
||||
|
||||
if (vk->ctx_driver->translate_aspect)
|
||||
device_aspect = vk->ctx_driver->translate_aspect(
|
||||
@ -3346,7 +3344,7 @@ static bool vulkan_read_viewport(void *data, uint8_t *buffer, bool is_idle)
|
||||
&& (staging->memory != VK_NULL_HANDLE))
|
||||
VULKAN_SYNC_TEXTURE_TO_CPU(vk->context->device, staging->memory);
|
||||
|
||||
ctx->in_stride = staging->stride;
|
||||
ctx->in_stride = (int)staging->stride;
|
||||
ctx->out_stride = -(int)vk->vp.width * 3;
|
||||
scaler_ctx_scale_direct(ctx, buffer, src);
|
||||
|
||||
|
@ -59,14 +59,13 @@ CocoaView *cocoaview_get(void);
|
||||
|
||||
static uint32_t cocoa_vk_gfx_ctx_get_flags(void *data)
|
||||
{
|
||||
uint32_t flags = 0;
|
||||
cocoa_vk_ctx_data_t *cocoa_ctx = (cocoa_vk_ctx_data_t*)data;
|
||||
|
||||
#if defined(HAVE_SLANG) && defined(HAVE_SPIRV_CROSS)
|
||||
uint32_t flags = 0;
|
||||
BIT32_SET(flags, GFX_CTX_FLAGS_SHADERS_SLANG);
|
||||
#endif
|
||||
|
||||
return flags;
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
static void cocoa_vk_gfx_ctx_set_flags(void *data, uint32_t flags) { }
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* RetroArch - A frontend for libretro.
|
||||
/* RetroArch - A frontend for libretro.
|
||||
* Copyright (C) 2016-2017 - Hans-Kristian Arntzen
|
||||
*
|
||||
* RetroArch is free software: you can redistribute it and/or modify it under the terms
|
||||
@ -357,7 +357,7 @@ static void vulkan_font_render_msg(
|
||||
float color[4];
|
||||
int drop_x, drop_y;
|
||||
bool full_screen;
|
||||
unsigned max_glyphs;
|
||||
size_t max_glyphs;
|
||||
unsigned width, height;
|
||||
enum text_alignment text_align;
|
||||
float x, y, scale, drop_mod, drop_alpha;
|
||||
|
@ -1434,12 +1434,14 @@ bool vulkan_filter_chain::init_feedback()
|
||||
|
||||
bool vulkan_filter_chain::init_alias()
|
||||
{
|
||||
unsigned i, j;
|
||||
int i;
|
||||
|
||||
common.texture_semantic_map.clear();
|
||||
common.texture_semantic_uniform_map.clear();
|
||||
|
||||
for (i = 0; i < passes.size(); i++)
|
||||
{
|
||||
unsigned j;
|
||||
const std::string name = passes[i]->get_name();
|
||||
if (name.empty())
|
||||
continue;
|
||||
@ -1469,7 +1471,7 @@ bool vulkan_filter_chain::init_alias()
|
||||
|
||||
for (i = 0; i < common.luts.size(); i++)
|
||||
{
|
||||
j = &common.luts[i] - common.luts.data();
|
||||
unsigned j = &common.luts[i] - common.luts.data();
|
||||
if (!slang_set_unique_map(
|
||||
common.texture_semantic_map,
|
||||
common.luts[i]->get_id(),
|
||||
@ -1922,7 +1924,7 @@ bool Pass::init_pipeline_layout()
|
||||
}
|
||||
}
|
||||
|
||||
set_layout_info.bindingCount = bindings.size();
|
||||
set_layout_info.bindingCount = (uint32_t)bindings.size();
|
||||
set_layout_info.pBindings = bindings.data();
|
||||
|
||||
if (vkCreateDescriptorSetLayout(device,
|
||||
@ -1950,14 +1952,14 @@ bool Pass::init_pipeline_layout()
|
||||
}
|
||||
|
||||
push.stages = push_range.stageFlags;
|
||||
push_range.size = reflection.push_constant_size;
|
||||
push_range.size = (uint32_t)reflection.push_constant_size;
|
||||
|
||||
if (vkCreatePipelineLayout(device,
|
||||
&layout_info, NULL, &pipeline_layout) != VK_SUCCESS)
|
||||
return false;
|
||||
|
||||
pool_info.maxSets = num_sync_indices;
|
||||
pool_info.poolSizeCount = desc_counts.size();
|
||||
pool_info.poolSizeCount = (uint32_t)desc_counts.size();
|
||||
pool_info.pPoolSizes = desc_counts.data();
|
||||
if (vkCreateDescriptorPool(device, &pool_info, nullptr, &pool) != VK_SUCCESS)
|
||||
return false;
|
||||
@ -2600,7 +2602,7 @@ void Pass::build_commands(
|
||||
if (push.stages != 0)
|
||||
{
|
||||
vkCmdPushConstants(cmd, pipeline_layout,
|
||||
push.stages, 0, reflection.push_constant_size,
|
||||
push.stages, 0, (uint32_t)reflection.push_constant_size,
|
||||
push.buffer.data());
|
||||
}
|
||||
|
||||
@ -2965,7 +2967,7 @@ vulkan_filter_chain_t *vulkan_filter_chain_create_from_preset(
|
||||
itr->id);
|
||||
goto error;
|
||||
}
|
||||
chain->add_parameter(i, itr - shader->parameters, meta_param.id);
|
||||
chain->add_parameter(i, (unsigned)(itr - shader->parameters), meta_param.id);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user