Skip to content

Commit

Permalink
fix(utils::pipeline_layout): fix range tracking
Browse files Browse the repository at this point in the history
  • Loading branch information
clshortfuse committed Dec 9, 2024
1 parent 77a39a2 commit 9c33602
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/utils/pipeline_layout.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ static void OnInitPipelineLayout(

PipelineLayoutData& layout_data = data.pipeline_layout_data[layout.handle];
layout_data.params.assign(params, params + param_count);
layout_data.ranges.resize(param_count);

for (uint32_t i = 0; i < param_count; ++i) {
const auto& param = params[i];
if (param.type == reshade::api::pipeline_layout_param_type::descriptor_table) {
layout_data.ranges[i].assign(
auto& range = layout_data.ranges.emplace_back(
param.descriptor_table.ranges,
param.descriptor_table.ranges + param.descriptor_table.count);
layout_data.params[i].descriptor_table.ranges = layout_data.ranges[i].data();
layout_data.params[i] = param;
layout_data.params[i].descriptor_table.ranges = range.data();
}
}
}
Expand Down

0 comments on commit 9c33602

Please sign in to comment.