public override void ForEachWithin(IntRectangle rectangle, EnumerateItemDelegate <T> func) { rectangle = IntRectangle.FromPoints( IntVectorMath.MinMax(rectangle.LeftTopFront - Offset, IntVector.Zero, SizeVector), IntVectorMath.MinMax(rectangle.RightBottomBack - Offset, IntVector.Zero, SizeVector) ); base.ForEachWithin(rectangle, (block, coords) => func(block, coords + Offset)); }
public override IEnumerable <T> GetAllWithin(IntRectangle rectangle) { rectangle = IntRectangle.FromPoints( IntVectorMath.MinMax(rectangle.LeftTopFront - Offset, IntVector.Zero, SizeVector), IntVectorMath.MinMax(rectangle.RightBottomBack - Offset, IntVector.Zero, SizeVector) ); return(base.GetAllWithin(rectangle)); }