Skip to content

Commit

Permalink
Fix shadowed variable in spdl/src/libspdl/core/detail/nvjpeg/decoding…
Browse files Browse the repository at this point in the history
….cpp

Differential Revision: D64398711

Pull Request resolved: #248
  • Loading branch information
r-barnes authored Oct 17, 2024
1 parent 3a88ac9 commit f99030d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/libspdl/core/detail/nvjpeg/decoding.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ std::tuple<CUDABufferPtr, SizeMeta> get_output(
std::optional<size_t> batch_size = std::nullopt) {
auto [num_channels, interleaved] = get_shape(out_fmt);

auto buffer = [&](const size_t ch, bool interleaved) {
auto buffer = [&](const size_t ch, bool interleaved_2) {
return batch_size
? (interleaved
? (interleaved_2
? cuda_buffer({*batch_size, height, width, ch}, cuda_config)
: cuda_buffer({*batch_size, ch, height, width}, cuda_config))
: (interleaved ? cuda_buffer({height, width, ch}, cuda_config)
: cuda_buffer({ch, height, width}, cuda_config));
: (interleaved_2 ? cuda_buffer({height, width, ch}, cuda_config)
: cuda_buffer({ch, height, width}, cuda_config));
}(num_channels, interleaved);

return {
Expand Down

0 comments on commit f99030d

Please sign in to comment.