Exemple #1
0
        public void Clear(float x, float z)
        {
            float tx = (x - Position.X) / _width * Constants.terrainPieceTextureWidth * Constants.terrainHeightsPerChunk;
            float tz = (z - Position.Z) / _height * Constants.terrainPieceTextureWidth * Constants.terrainHeightsPerChunk;

            _texture.Clear(tx, tz, Constants.terrainPieceTextureWidth, Constants.terrainPieceTextureWidth);
        }
Exemple #2
0
 /// <summary>
 /// Clears the texture and sets all pixels to the default clear color.
 /// </summary>
 public void Clear()
 {
     _nativeTexture.Clear();
 }