TerrainDemo.CDLOD.Node.GetBoundingBox C# (CSharp) Method

GetBoundingBox() private method

private GetBoundingBox ( Vector3 &terrainOffset, float patchScale, float heightScale, Microsoft.Xna.Framework.BoundingBox &boundingBox ) : void
terrainOffset Vector3
patchScale float
heightScale float
boundingBox Microsoft.Xna.Framework.BoundingBox
return void
        void GetBoundingBox(ref Vector3 terrainOffset, float patchScale, float heightScale, out BoundingBox boundingBox)
        {
            boundingBox = new BoundingBox();

            boundingBox.Min.X = x * patchScale + terrainOffset.X;
            boundingBox.Min.Y = minHeight * heightScale + terrainOffset.Y;
            boundingBox.Min.Z = y * patchScale + terrainOffset.Z;

            boundingBox.Max.X = (x + size) * patchScale + terrainOffset.X;
            boundingBox.Max.Y = maxHeight * heightScale + terrainOffset.Y;
            boundingBox.Max.Z = (y + size) * patchScale + terrainOffset.Z;
        }