From d9c437291135255422c71918cd0cab8a735848af Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Thu, 17 Mar 2022 22:12:20 +0200 Subject: [PATCH] Mostly cosmetic changes --- source/backends/vulkan/program_backend.h | 3 --- source/core/module.cpp | 2 +- source/core/program.cpp | 6 ++---- source/materials/rendermethod.cpp | 2 +- source/render/scene.h | 2 -- 5 files changed, 4 insertions(+), 11 deletions(-) diff --git a/source/backends/vulkan/program_backend.h b/source/backends/vulkan/program_backend.h index 16cf7b27..4f9d9c47 100644 --- a/source/backends/vulkan/program_backend.h +++ b/source/backends/vulkan/program_backend.h @@ -17,9 +17,6 @@ class VulkanProgram: public NonCopyable friend class VulkanPipelineState; protected: - struct TransientData - { }; - Device &device; unsigned n_stages = 0; unsigned stage_flags = 0; diff --git a/source/core/module.cpp b/source/core/module.cpp index f42a0da7..5475e434 100644 --- a/source/core/module.cpp +++ b/source/core/module.cpp @@ -313,7 +313,7 @@ SpirVModule *SpirVModule::specialize(const map &spec_values) const unsigned func_id = *(op+2); new_code.push_back(func_id); - unsigned i=3; + unsigned i = 3; while(i > block_uniform_names(1); - unsigned n_descriptor_sets = 0; for(const SpirVModule::Variable &v: mod.get_variables()) { if((v.storage==SpirVModule::UNIFORM || v.storage==SpirVModule::PUSH_CONSTANT) && v.struct_type) @@ -94,7 +93,7 @@ void Program::collect_uniforms(const SpirVModule &mod) info.bind_point = v.binding | (v.descriptor_set<<20); else info.bind_point = ReflectData::DEFAULT_BLOCK; - n_descriptor_sets = max(n_descriptor_sets, v.descriptor_set+1); + reflect_data.n_descriptor_sets = max(reflect_data.n_descriptor_sets, v.descriptor_set+1); } string prefix; @@ -113,7 +112,7 @@ void Program::collect_uniforms(const SpirVModule &mod) info.location = v.location; if(v.binding>=0) info.binding = v.binding | (v.descriptor_set<<20); - n_descriptor_sets = max(n_descriptor_sets, v.descriptor_set+1); + reflect_data.n_descriptor_sets = max(reflect_data.n_descriptor_sets, v.descriptor_set+1); info.array_size = max(v.array_size, 1U); info.type = v.type; } @@ -141,7 +140,6 @@ void Program::collect_uniforms(const SpirVModule &mod) block.update_layout_hash(); } - reflect_data.n_descriptor_sets = n_descriptor_sets; reflect_data.update_layout_hash(); } diff --git a/source/materials/rendermethod.cpp b/source/materials/rendermethod.cpp index 66424856..78b937d0 100644 --- a/source/materials/rendermethod.cpp +++ b/source/materials/rendermethod.cpp @@ -154,7 +154,7 @@ void RenderMethod::Loader::init_actions() add("blend", &Loader::blend); add("blend", &Loader::blend_factors); add("face_cull", &RenderMethod::face_cull); - add("shader", &Loader::shader); + add("shader", &Loader::shader); add("image_based_lighting", &RenderMethod::image_based_lighting); add("instancing", &RenderMethod::instancing); add("material", &Loader::material_inline); diff --git a/source/render/scene.h b/source/render/scene.h index 512b020b..e6115ae5 100644 --- a/source/render/scene.h +++ b/source/render/scene.h @@ -60,8 +60,6 @@ public: }; protected: - mutable Matrix culling_matrix; - Scene() = default; public: virtual ~Scene() = default; -- 2.43.0