public void DisplayInEditor() { textureDetails.AttachToMaterial(areaMaterial); textureDetails.RefreshHeights(areaMaterial, areaNoiseDetails.minHeight, areaNoiseDetails.maxHeight); AreaNoise noiseArea = NoiseController.BuildNoiseArea(areaDetails.verticesPerLine, areaNoiseDetails, Vector2.zero); if (displayMode == DisplayMode.Noise) { DisplayMap(TextureController.GenerateFromNoise(noiseArea)); } else if (displayMode == DisplayMode.Mesh) { DisplayMesh(MeshController.BuildMesh(noiseArea.area, previevLOD, areaDetails)); } else if (displayMode == DisplayMode.Falloff) { DisplayMap(TextureController.GenerateFromNoise(new AreaNoise(FalloffController.GenerateFalloffArea(areaDetails.verticesPerLine), 0, 1))); } }
public void RequestMesh(AreaNoise noiseArea, AreaDetails areaSettings) { requested = true; ThreadHandler.RequestDetails(() => MeshController.BuildMesh(noiseArea.area, lod, areaSettings), OnMeshDetailsReceived); }