Added option to use full volume or only non zero voxels