Commit 085971d3 authored by Morten Ofstad's avatar Morten Ofstad
Browse files

Only the dimension 0 size/offset of the copy should be multiplied by the number of components.

parent d811b386
Pipeline #70377 passed with stages
in 21 minutes and 14 seconds
......@@ -561,14 +561,11 @@ static bool RequestSubsetProcessPage(VolumeDataPageImpl* page, const VolumeDataC
// Multiply sizes and offsets by number of components since BlockCopy is not component-aware
if(chunk.layer->GetComponents() > 1)
{
for (int32_t dimension = 0; dimension < DataBlock::Dimensionality_Max; dimension++)
{
sourceSize [dimension] *= int(chunk.layer->GetComponents());
sourceOffset[dimension] *= int(chunk.layer->GetComponents());
targetSize [dimension] *= int(chunk.layer->GetComponents());
targetOffset[dimension] *= int(chunk.layer->GetComponents());
overlapSize [dimension] *= int(chunk.layer->GetComponents());
}
sourceSize [0] *= int(chunk.layer->GetComponents());
sourceOffset[0] *= int(chunk.layer->GetComponents());
targetSize [0] *= int(chunk.layer->GetComponents());
targetOffset[0] *= int(chunk.layer->GetComponents());
overlapSize [0] *= int(chunk.layer->GetComponents());
}
void *source = page->GetRawBufferInternal();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment