check for void material to avoid out of bounds