summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar lat9nq2023-07-18 19:31:35 -0400
committerGravatar lat9nq2023-07-18 19:31:35 -0400
commit71b3b2a2f0f0ec5d0a0061d3d7ea42a1f63ae1de (patch)
tree023ef7def25a0bf79ae1556fa9fc0178bf980d2b /src
parentMerge pull request #11109 from Morph1984/net (diff)
downloadyuzu-71b3b2a2f0f0ec5d0a0061d3d7ea42a1f63ae1de.tar.gz
yuzu-71b3b2a2f0f0ec5d0a0061d3d7ea42a1f63ae1de.tar.xz
yuzu-71b3b2a2f0f0ec5d0a0061d3d7ea42a1f63ae1de.zip
general: Silence -Wshadow{,-uncaptured-local} warnings
These occur in the latest commits in LLVM Clang.
Diffstat (limited to 'src')
-rw-r--r--src/common/demangle.cpp2
-rw-r--r--src/common/detached_tasks.cpp4
-rw-r--r--src/core/hle/kernel/k_thread.cpp4
-rw-r--r--src/core/hle/kernel/kernel.cpp6
-rw-r--r--src/video_core/renderer_base.cpp4
-rw-r--r--src/video_core/renderer_opengl/gl_graphics_pipeline.cpp15
-rw-r--r--src/video_core/renderer_opengl/gl_shader_cache.cpp8
-rw-r--r--src/video_core/renderer_vulkan/vk_buffer_cache.cpp37
-rw-r--r--src/video_core/renderer_vulkan/vk_pipeline_cache.cpp12
-rw-r--r--src/video_core/renderer_vulkan/vk_query_cache.cpp11
-rw-r--r--src/video_core/renderer_vulkan/vk_texture_cache.cpp6
-rw-r--r--src/web_service/announce_room_json.cpp10
12 files changed, 61 insertions, 58 deletions
diff --git a/src/common/demangle.cpp b/src/common/demangle.cpp
index 3310faf86..6e117cb41 100644
--- a/src/common/demangle.cpp
+++ b/src/common/demangle.cpp
@@ -23,7 +23,7 @@ std::string DemangleSymbol(const std::string& mangled) {
23 SCOPE_EXIT({ std::free(demangled); }); 23 SCOPE_EXIT({ std::free(demangled); });
24 24
25 if (is_itanium(mangled)) { 25 if (is_itanium(mangled)) {
26 demangled = llvm::itaniumDemangle(mangled.c_str(), nullptr, nullptr, nullptr); 26 demangled = llvm::itaniumDemangle(mangled.c_str());
27 } 27 }
28 28
29 if (!demangled) { 29 if (!demangled) {
diff --git a/src/common/detached_tasks.cpp b/src/common/detached_tasks.cpp
index da64848da..f2ed795cc 100644
--- a/src/common/detached_tasks.cpp
+++ b/src/common/detached_tasks.cpp
@@ -30,8 +30,8 @@ DetachedTasks::~DetachedTasks() {
30void DetachedTasks::AddTask(std::function<void()> task) { 30void DetachedTasks::AddTask(std::function<void()> task) {
31 std::unique_lock lock{instance->mutex}; 31 std::unique_lock lock{instance->mutex};
32 ++instance->count; 32 ++instance->count;
33 std::thread([task{std::move(task)}]() { 33 std::thread([task_{std::move(task)}]() {
34 task(); 34 task_();
35 std::unique_lock thread_lock{instance->mutex}; 35 std::unique_lock thread_lock{instance->mutex};
36 --instance->count; 36 --instance->count;
37 std::notify_all_at_thread_exit(instance->cv, std::move(thread_lock)); 37 std::notify_all_at_thread_exit(instance->cv, std::move(thread_lock));
diff --git a/src/core/hle/kernel/k_thread.cpp b/src/core/hle/kernel/k_thread.cpp
index adb6ec581..d88909889 100644
--- a/src/core/hle/kernel/k_thread.cpp
+++ b/src/core/hle/kernel/k_thread.cpp
@@ -302,12 +302,12 @@ Result KThread::InitializeServiceThread(Core::System& system, KThread* thread,
302 std::function<void()>&& func, s32 prio, s32 virt_core, 302 std::function<void()>&& func, s32 prio, s32 virt_core,
303 KProcess* owner) { 303 KProcess* owner) {
304 system.Kernel().GlobalSchedulerContext().AddThread(thread); 304 system.Kernel().GlobalSchedulerContext().AddThread(thread);
305 std::function<void()> func2{[&system, func{std::move(func)}] { 305 std::function<void()> func2{[&system, func_{std::move(func)}] {
306 // Similar to UserModeThreadStarter. 306 // Similar to UserModeThreadStarter.
307 system.Kernel().CurrentScheduler()->OnThreadStart(); 307 system.Kernel().CurrentScheduler()->OnThreadStart();
308 308
309 // Run the guest function. 309 // Run the guest function.
310 func(); 310 func_();
311 311
312 // Exit. 312 // Exit.
313 Svc::ExitThread(system); 313 Svc::ExitThread(system);
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp
index f33600ca5..ebe7582c6 100644
--- a/src/core/hle/kernel/kernel.cpp
+++ b/src/core/hle/kernel/kernel.cpp
@@ -1089,15 +1089,15 @@ static std::jthread RunHostThreadFunc(KernelCore& kernel, KProcess* process,
1089 KThread::Register(kernel, thread); 1089 KThread::Register(kernel, thread);
1090 1090
1091 return std::jthread( 1091 return std::jthread(
1092 [&kernel, thread, thread_name{std::move(thread_name)}, func{std::move(func)}] { 1092 [&kernel, thread, thread_name_{std::move(thread_name)}, func_{std::move(func)}] {
1093 // Set the thread name. 1093 // Set the thread name.
1094 Common::SetCurrentThreadName(thread_name.c_str()); 1094 Common::SetCurrentThreadName(thread_name_.c_str());
1095 1095
1096 // Set the thread as current. 1096 // Set the thread as current.
1097 kernel.RegisterHostThread(thread); 1097 kernel.RegisterHostThread(thread);
1098 1098
1099 // Run the callback. 1099 // Run the callback.
1100 func(); 1100 func_();
1101 1101
1102 // Close the thread. 1102 // Close the thread.
1103 // This will free the process if it is the last reference. 1103 // This will free the process if it is the last reference.
diff --git a/src/video_core/renderer_base.cpp b/src/video_core/renderer_base.cpp
index 2d3f58201..4002fa72b 100644
--- a/src/video_core/renderer_base.cpp
+++ b/src/video_core/renderer_base.cpp
@@ -38,8 +38,8 @@ void RendererBase::RequestScreenshot(void* data, std::function<void(bool)> callb
38 LOG_ERROR(Render, "A screenshot is already requested or in progress, ignoring the request"); 38 LOG_ERROR(Render, "A screenshot is already requested or in progress, ignoring the request");
39 return; 39 return;
40 } 40 }
41 auto async_callback{[callback = std::move(callback)](bool invert_y) { 41 auto async_callback{[callback_ = std::move(callback)](bool invert_y) {
42 std::thread t{callback, invert_y}; 42 std::thread t{callback_, invert_y};
43 t.detach(); 43 t.detach();
44 }}; 44 }};
45 renderer_settings.screenshot_bits = data; 45 renderer_settings.screenshot_bits = data;
diff --git a/src/video_core/renderer_opengl/gl_graphics_pipeline.cpp b/src/video_core/renderer_opengl/gl_graphics_pipeline.cpp
index 23a48c6fe..71f720c63 100644
--- a/src/video_core/renderer_opengl/gl_graphics_pipeline.cpp
+++ b/src/video_core/renderer_opengl/gl_graphics_pipeline.cpp
@@ -231,24 +231,25 @@ GraphicsPipeline::GraphicsPipeline(const Device& device, TextureCache& texture_c
231 } 231 }
232 const bool in_parallel = thread_worker != nullptr; 232 const bool in_parallel = thread_worker != nullptr;
233 const auto backend = device.GetShaderBackend(); 233 const auto backend = device.GetShaderBackend();
234 auto func{[this, sources = std::move(sources), sources_spirv = std::move(sources_spirv), 234 auto func{[this, sources_ = std::move(sources), sources_spirv_ = std::move(sources_spirv),
235 shader_notify, backend, in_parallel, 235 shader_notify, backend, in_parallel,
236 force_context_flush](ShaderContext::Context*) mutable { 236 force_context_flush](ShaderContext::Context*) mutable {
237 for (size_t stage = 0; stage < 5; ++stage) { 237 for (size_t stage = 0; stage < 5; ++stage) {
238 switch (backend) { 238 switch (backend) {
239 case Settings::ShaderBackend::GLSL: 239 case Settings::ShaderBackend::GLSL:
240 if (!sources[stage].empty()) { 240 if (!sources_[stage].empty()) {
241 source_programs[stage] = CreateProgram(sources[stage], Stage(stage)); 241 source_programs[stage] = CreateProgram(sources_[stage], Stage(stage));
242 } 242 }
243 break; 243 break;
244 case Settings::ShaderBackend::GLASM: 244 case Settings::ShaderBackend::GLASM:
245 if (!sources[stage].empty()) { 245 if (!sources_[stage].empty()) {
246 assembly_programs[stage] = CompileProgram(sources[stage], AssemblyStage(stage)); 246 assembly_programs[stage] =
247 CompileProgram(sources_[stage], AssemblyStage(stage));
247 } 248 }
248 break; 249 break;
249 case Settings::ShaderBackend::SPIRV: 250 case Settings::ShaderBackend::SPIRV:
250 if (!sources_spirv[stage].empty()) { 251 if (!sources_spirv_[stage].empty()) {
251 source_programs[stage] = CreateProgram(sources_spirv[stage], Stage(stage)); 252 source_programs[stage] = CreateProgram(sources_spirv_[stage], Stage(stage));
252 } 253 }
253 break; 254 break;
254 } 255 }
diff --git a/src/video_core/renderer_opengl/gl_shader_cache.cpp b/src/video_core/renderer_opengl/gl_shader_cache.cpp
index 0329ed820..7e1d7f92e 100644
--- a/src/video_core/renderer_opengl/gl_shader_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_cache.cpp
@@ -288,9 +288,9 @@ void ShaderCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading,
288 const auto load_compute{[&](std::ifstream& file, FileEnvironment env) { 288 const auto load_compute{[&](std::ifstream& file, FileEnvironment env) {
289 ComputePipelineKey key; 289 ComputePipelineKey key;
290 file.read(reinterpret_cast<char*>(&key), sizeof(key)); 290 file.read(reinterpret_cast<char*>(&key), sizeof(key));
291 queue_work([this, key, env = std::move(env), &state, &callback](Context* ctx) mutable { 291 queue_work([this, key, env_ = std::move(env), &state, &callback](Context* ctx) mutable {
292 ctx->pools.ReleaseContents(); 292 ctx->pools.ReleaseContents();
293 auto pipeline{CreateComputePipeline(ctx->pools, key, env, true)}; 293 auto pipeline{CreateComputePipeline(ctx->pools, key, env_, true)};
294 std::scoped_lock lock{state.mutex}; 294 std::scoped_lock lock{state.mutex};
295 if (pipeline) { 295 if (pipeline) {
296 compute_cache.emplace(key, std::move(pipeline)); 296 compute_cache.emplace(key, std::move(pipeline));
@@ -305,9 +305,9 @@ void ShaderCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading,
305 const auto load_graphics{[&](std::ifstream& file, std::vector<FileEnvironment> envs) { 305 const auto load_graphics{[&](std::ifstream& file, std::vector<FileEnvironment> envs) {
306 GraphicsPipelineKey key; 306 GraphicsPipelineKey key;
307 file.read(reinterpret_cast<char*>(&key), sizeof(key)); 307 file.read(reinterpret_cast<char*>(&key), sizeof(key));
308 queue_work([this, key, envs = std::move(envs), &state, &callback](Context* ctx) mutable { 308 queue_work([this, key, envs_ = std::move(envs), &state, &callback](Context* ctx) mutable {
309 boost::container::static_vector<Shader::Environment*, 5> env_ptrs; 309 boost::container::static_vector<Shader::Environment*, 5> env_ptrs;
310 for (auto& env : envs) { 310 for (auto& env : envs_) {
311 env_ptrs.push_back(&env); 311 env_ptrs.push_back(&env);
312 } 312 }
313 ctx->pools.ReleaseContents(); 313 ctx->pools.ReleaseContents();
diff --git a/src/video_core/renderer_vulkan/vk_buffer_cache.cpp b/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
index 51df18ec3..818b6d3e3 100644
--- a/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
@@ -80,8 +80,8 @@ Buffer::Buffer(BufferCacheRuntime&, VideoCommon::NullBufferParams null_params)
80Buffer::Buffer(BufferCacheRuntime& runtime, VideoCore::RasterizerInterface& rasterizer_, 80Buffer::Buffer(BufferCacheRuntime& runtime, VideoCore::RasterizerInterface& rasterizer_,
81 VAddr cpu_addr_, u64 size_bytes_) 81 VAddr cpu_addr_, u64 size_bytes_)
82 : VideoCommon::BufferBase<VideoCore::RasterizerInterface>(rasterizer_, cpu_addr_, size_bytes_), 82 : VideoCommon::BufferBase<VideoCore::RasterizerInterface>(rasterizer_, cpu_addr_, size_bytes_),
83 device{&runtime.device}, buffer{ 83 device{&runtime.device},
84 CreateBuffer(*device, runtime.memory_allocator, SizeBytes())} { 84 buffer{CreateBuffer(*device, runtime.memory_allocator, SizeBytes())} {
85 if (runtime.device.HasDebuggingToolAttached()) { 85 if (runtime.device.HasDebuggingToolAttached()) {
86 buffer.SetObjectNameEXT(fmt::format("Buffer 0x{:x}", CpuAddr()).c_str()); 86 buffer.SetObjectNameEXT(fmt::format("Buffer 0x{:x}", CpuAddr()).c_str());
87 } 87 }
@@ -206,8 +206,8 @@ public:
206 const size_t sub_first_offset = static_cast<size_t>(first % 4) * GetQuadsNum(num_indices); 206 const size_t sub_first_offset = static_cast<size_t>(first % 4) * GetQuadsNum(num_indices);
207 const size_t offset = 207 const size_t offset =
208 (sub_first_offset + GetQuadsNum(first)) * 6ULL * BytesPerIndex(index_type); 208 (sub_first_offset + GetQuadsNum(first)) * 6ULL * BytesPerIndex(index_type);
209 scheduler.Record([buffer = *buffer, index_type_, offset](vk::CommandBuffer cmdbuf) { 209 scheduler.Record([buffer_ = *buffer, index_type_, offset](vk::CommandBuffer cmdbuf) {
210 cmdbuf.BindIndexBuffer(buffer, offset, index_type_); 210 cmdbuf.BindIndexBuffer(buffer_, offset, index_type_);
211 }); 211 });
212 } 212 }
213 213
@@ -528,17 +528,18 @@ void BufferCacheRuntime::BindVertexBuffers(VideoCommon::HostBindings<Buffer>& bi
528 buffer_handles.push_back(handle); 528 buffer_handles.push_back(handle);
529 } 529 }
530 if (device.IsExtExtendedDynamicStateSupported()) { 530 if (device.IsExtExtendedDynamicStateSupported()) {
531 scheduler.Record([bindings = std::move(bindings), 531 scheduler.Record([bindings_ = std::move(bindings),
532 buffer_handles = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) { 532 buffer_handles_ = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) {
533 cmdbuf.BindVertexBuffers2EXT( 533 cmdbuf.BindVertexBuffers2EXT(bindings_.min_index,
534 bindings.min_index, bindings.max_index - bindings.min_index, buffer_handles.data(), 534 bindings_.max_index - bindings_.min_index,
535 bindings.offsets.data(), bindings.sizes.data(), bindings.strides.data()); 535 buffer_handles_.data(), bindings_.offsets.data(),
536 bindings_.sizes.data(), bindings_.strides.data());
536 }); 537 });
537 } else { 538 } else {
538 scheduler.Record([bindings = std::move(bindings), 539 scheduler.Record([bindings_ = std::move(bindings),
539 buffer_handles = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) { 540 buffer_handles_ = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) {
540 cmdbuf.BindVertexBuffers(bindings.min_index, bindings.max_index - bindings.min_index, 541 cmdbuf.BindVertexBuffers(bindings_.min_index, bindings_.max_index - bindings_.min_index,
541 buffer_handles.data(), bindings.offsets.data()); 542 buffer_handles_.data(), bindings_.offsets.data());
542 }); 543 });
543 } 544 }
544} 545}
@@ -573,11 +574,11 @@ void BufferCacheRuntime::BindTransformFeedbackBuffers(VideoCommon::HostBindings<
573 for (u32 index = 0; index < bindings.buffers.size(); ++index) { 574 for (u32 index = 0; index < bindings.buffers.size(); ++index) {
574 buffer_handles.push_back(bindings.buffers[index]->Handle()); 575 buffer_handles.push_back(bindings.buffers[index]->Handle());
575 } 576 }
576 scheduler.Record([bindings = std::move(bindings), 577 scheduler.Record([bindings_ = std::move(bindings),
577 buffer_handles = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) { 578 buffer_handles_ = std::move(buffer_handles)](vk::CommandBuffer cmdbuf) {
578 cmdbuf.BindTransformFeedbackBuffersEXT(0, static_cast<u32>(buffer_handles.size()), 579 cmdbuf.BindTransformFeedbackBuffersEXT(0, static_cast<u32>(buffer_handles_.size()),
579 buffer_handles.data(), bindings.offsets.data(), 580 buffer_handles_.data(), bindings_.offsets.data(),
580 bindings.sizes.data()); 581 bindings_.sizes.data());
581 }); 582 });
582} 583}
583 584
diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
index d600c4e61..4f84d8497 100644
--- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
@@ -469,9 +469,9 @@ void PipelineCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading
469 ComputePipelineCacheKey key; 469 ComputePipelineCacheKey key;
470 file.read(reinterpret_cast<char*>(&key), sizeof(key)); 470 file.read(reinterpret_cast<char*>(&key), sizeof(key));
471 471
472 workers.QueueWork([this, key, env = std::move(env), &state, &callback]() mutable { 472 workers.QueueWork([this, key, env_ = std::move(env), &state, &callback]() mutable {
473 ShaderPools pools; 473 ShaderPools pools;
474 auto pipeline{CreateComputePipeline(pools, key, env, state.statistics.get(), false)}; 474 auto pipeline{CreateComputePipeline(pools, key, env_, state.statistics.get(), false)};
475 std::scoped_lock lock{state.mutex}; 475 std::scoped_lock lock{state.mutex};
476 if (pipeline) { 476 if (pipeline) {
477 compute_cache.emplace(key, std::move(pipeline)); 477 compute_cache.emplace(key, std::move(pipeline));
@@ -500,10 +500,10 @@ void PipelineCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading
500 (key.state.dynamic_vertex_input != 0) != dynamic_features.has_dynamic_vertex_input) { 500 (key.state.dynamic_vertex_input != 0) != dynamic_features.has_dynamic_vertex_input) {
501 return; 501 return;
502 } 502 }
503 workers.QueueWork([this, key, envs = std::move(envs), &state, &callback]() mutable { 503 workers.QueueWork([this, key, envs_ = std::move(envs), &state, &callback]() mutable {
504 ShaderPools pools; 504 ShaderPools pools;
505 boost::container::static_vector<Shader::Environment*, 5> env_ptrs; 505 boost::container::static_vector<Shader::Environment*, 5> env_ptrs;
506 for (auto& env : envs) { 506 for (auto& env : envs_) {
507 env_ptrs.push_back(&env); 507 env_ptrs.push_back(&env);
508 } 508 }
509 auto pipeline{CreateGraphicsPipeline(pools, key, MakeSpan(env_ptrs), 509 auto pipeline{CreateGraphicsPipeline(pools, key, MakeSpan(env_ptrs),
@@ -702,8 +702,8 @@ std::unique_ptr<ComputePipeline> PipelineCache::CreateComputePipeline(
702 if (!pipeline || pipeline_cache_filename.empty()) { 702 if (!pipeline || pipeline_cache_filename.empty()) {
703 return pipeline; 703 return pipeline;
704 } 704 }
705 serialization_thread.QueueWork([this, key, env = std::move(env)] { 705 serialization_thread.QueueWork([this, key, env_ = std::move(env)] {
706 SerializePipeline(key, std::array<const GenericEnvironment*, 1>{&env}, 706 SerializePipeline(key, std::array<const GenericEnvironment*, 1>{&env_},
707 pipeline_cache_filename, CACHE_VERSION); 707 pipeline_cache_filename, CACHE_VERSION);
708 }); 708 });
709 return pipeline; 709 return pipeline;
diff --git a/src/video_core/renderer_vulkan/vk_query_cache.cpp b/src/video_core/renderer_vulkan/vk_query_cache.cpp
index d67490449..29e0b797b 100644
--- a/src/video_core/renderer_vulkan/vk_query_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_query_cache.cpp
@@ -98,10 +98,10 @@ HostCounter::HostCounter(QueryCache& cache_, std::shared_ptr<HostCounter> depend
98 : HostCounterBase{std::move(dependency_)}, cache{cache_}, type{type_}, 98 : HostCounterBase{std::move(dependency_)}, cache{cache_}, type{type_},
99 query{cache_.AllocateQuery(type_)}, tick{cache_.GetScheduler().CurrentTick()} { 99 query{cache_.AllocateQuery(type_)}, tick{cache_.GetScheduler().CurrentTick()} {
100 const vk::Device* logical = &cache.GetDevice().GetLogical(); 100 const vk::Device* logical = &cache.GetDevice().GetLogical();
101 cache.GetScheduler().Record([logical, query = query](vk::CommandBuffer cmdbuf) { 101 cache.GetScheduler().Record([logical, query_ = query](vk::CommandBuffer cmdbuf) {
102 const bool use_precise = Settings::IsGPULevelHigh(); 102 const bool use_precise = Settings::IsGPULevelHigh();
103 logical->ResetQueryPool(query.first, query.second, 1); 103 logical->ResetQueryPool(query_.first, query_.second, 1);
104 cmdbuf.BeginQuery(query.first, query.second, 104 cmdbuf.BeginQuery(query_.first, query_.second,
105 use_precise ? VK_QUERY_CONTROL_PRECISE_BIT : 0); 105 use_precise ? VK_QUERY_CONTROL_PRECISE_BIT : 0);
106 }); 106 });
107} 107}
@@ -111,8 +111,9 @@ HostCounter::~HostCounter() {
111} 111}
112 112
113void HostCounter::EndQuery() { 113void HostCounter::EndQuery() {
114 cache.GetScheduler().Record( 114 cache.GetScheduler().Record([query_ = query](vk::CommandBuffer cmdbuf) {
115 [query = query](vk::CommandBuffer cmdbuf) { cmdbuf.EndQuery(query.first, query.second); }); 115 cmdbuf.EndQuery(query_.first, query_.second);
116 });
116} 117}
117 118
118u64 HostCounter::BlockingQuery(bool async) const { 119u64 HostCounter::BlockingQuery(bool async) const {
diff --git a/src/video_core/renderer_vulkan/vk_texture_cache.cpp b/src/video_core/renderer_vulkan/vk_texture_cache.cpp
index 3aac3cfab..bf6ad6c79 100644
--- a/src/video_core/renderer_vulkan/vk_texture_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_texture_cache.cpp
@@ -1412,7 +1412,7 @@ void Image::DownloadMemory(std::span<VkBuffer> buffers_span, std::span<VkDeviceS
1412 } 1412 }
1413 scheduler->RequestOutsideRenderPassOperationContext(); 1413 scheduler->RequestOutsideRenderPassOperationContext();
1414 scheduler->Record([buffers = std::move(buffers_vector), image = *original_image, 1414 scheduler->Record([buffers = std::move(buffers_vector), image = *original_image,
1415 aspect_mask = aspect_mask, vk_copies](vk::CommandBuffer cmdbuf) { 1415 aspect_mask_ = aspect_mask, vk_copies](vk::CommandBuffer cmdbuf) {
1416 const VkImageMemoryBarrier read_barrier{ 1416 const VkImageMemoryBarrier read_barrier{
1417 .sType = VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, 1417 .sType = VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER,
1418 .pNext = nullptr, 1418 .pNext = nullptr,
@@ -1424,7 +1424,7 @@ void Image::DownloadMemory(std::span<VkBuffer> buffers_span, std::span<VkDeviceS
1424 .dstQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED, 1424 .dstQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED,
1425 .image = image, 1425 .image = image,
1426 .subresourceRange{ 1426 .subresourceRange{
1427 .aspectMask = aspect_mask, 1427 .aspectMask = aspect_mask_,
1428 .baseMipLevel = 0, 1428 .baseMipLevel = 0,
1429 .levelCount = VK_REMAINING_MIP_LEVELS, 1429 .levelCount = VK_REMAINING_MIP_LEVELS,
1430 .baseArrayLayer = 0, 1430 .baseArrayLayer = 0,
@@ -1456,7 +1456,7 @@ void Image::DownloadMemory(std::span<VkBuffer> buffers_span, std::span<VkDeviceS
1456 .dstQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED, 1456 .dstQueueFamilyIndex = VK_QUEUE_FAMILY_IGNORED,
1457 .image = image, 1457 .image = image,
1458 .subresourceRange{ 1458 .subresourceRange{
1459 .aspectMask = aspect_mask, 1459 .aspectMask = aspect_mask_,
1460 .baseMipLevel = 0, 1460 .baseMipLevel = 0,
1461 .levelCount = VK_REMAINING_MIP_LEVELS, 1461 .levelCount = VK_REMAINING_MIP_LEVELS,
1462 .baseArrayLayer = 0, 1462 .baseArrayLayer = 0,
diff --git a/src/web_service/announce_room_json.cpp b/src/web_service/announce_room_json.cpp
index 4c3195efd..f1020a5b8 100644
--- a/src/web_service/announce_room_json.cpp
+++ b/src/web_service/announce_room_json.cpp
@@ -135,11 +135,11 @@ void RoomJson::Delete() {
135 LOG_ERROR(WebService, "Room must be registered to be deleted"); 135 LOG_ERROR(WebService, "Room must be registered to be deleted");
136 return; 136 return;
137 } 137 }
138 Common::DetachedTasks::AddTask( 138 Common::DetachedTasks::AddTask([host_{this->host}, username_{this->username},
139 [host{this->host}, username{this->username}, token{this->token}, room_id{this->room_id}]() { 139 token_{this->token}, room_id_{this->room_id}]() {
140 // create a new client here because the this->client might be destroyed. 140 // create a new client here because the this->client might be destroyed.
141 Client{host, username, token}.DeleteJson(fmt::format("/lobby/{}", room_id), "", false); 141 Client{host_, username_, token_}.DeleteJson(fmt::format("/lobby/{}", room_id_), "", false);
142 }); 142 });
143} 143}
144 144
145} // namespace WebService 145} // namespace WebService