Skip to content
Snippets Groups Projects
Commit 3173c0e0 authored by Rémi Cresson's avatar Rémi Cresson
Browse files

REFAC: use pixel constructor instead of SetSize()

parent d7654b17
Branches
Tags
No related merge requests found
......@@ -157,8 +157,7 @@ public:
FloatVectorImageType::PixelType NullPixel(FloatVectorImageType::Pointer & img)
{
const unsigned int nBands = img->GetNumberOfComponentsPerPixel();
FloatVectorImageType::PixelType pix;
pix.SetSize(nBands);
FloatVectorImageType::PixelType pix(nBands);
pix.Fill(0);
return pix;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment