public NoiseSeedSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> generator, INoise3D positiveXAxisNoise, INoise3D negativeXAxisNoise, INoise3D positiveYAxisNoise, INoise3D negativeYAxisNoise, INoise3D positiveZAxisNoise, INoise3D negativeZAxisNoise) { Contracts.Requires.That(generator != null); Contracts.Requires.That(positiveXAxisNoise != null); Contracts.Requires.That(negativeXAxisNoise != null); Contracts.Requires.That(positiveYAxisNoise != null); Contracts.Requires.That(negativeYAxisNoise != null); Contracts.Requires.That(positiveZAxisNoise != null); Contracts.Requires.That(negativeZAxisNoise != null); this.generator = generator; this.positiveXNoise = positiveXAxisNoise; this.negativeXNoise = negativeXAxisNoise; this.positiveYNoise = positiveYAxisNoise; this.negativeYNoise = negativeYAxisNoise; this.positiveZNoise = positiveZAxisNoise; this.negativeZNoise = negativeZAxisNoise; }
public NoiseSeedSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> generator, INoise3D xAxisNoise, INoise3D yAxisNoise, INoise3D zAxisNoise) : this(generator, xAxisNoise, xAxisNoise, yAxisNoise, yAxisNoise, zAxisNoise, zAxisNoise) { }
public SeedRangeSurfaceGenerator(float min, float max, ISurfaceValueGenerator<TVoxel, TSurfaceData, TValue> generator) { Contracts.Requires.That(min <= max); Contracts.Requires.That(generator != null); this.min = min; this.max = max; this.generator = generator; }
public AxisSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> xAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> yAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> zAxisGenerator) : this(xAxisGenerator, xAxisGenerator, yAxisGenerator, yAxisGenerator, zAxisGenerator, zAxisGenerator) { Contracts.Requires.That(xAxisGenerator != null); Contracts.Requires.That(yAxisGenerator != null); Contracts.Requires.That(zAxisGenerator != null); }
public SeedSwitchSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> defaultGenerator, params ISeedThreshold <TVoxel, TSurfaceData, TValue>[] generators) { Contracts.Requires.That(defaultGenerator != null); Contracts.Requires.That(generators.AllAndSelfNotNull()); this.defaultGenerator = defaultGenerator; this.generators = generators; }
public TerrainMaterialProperties( bool isSolid, ISurfaceValueGenerator <TerrainVoxel, TSurfaceData, Color> colorer, ISurfaceValueGenerator <TerrainVoxel, TSurfaceData, Vector2> texturer) { Contracts.Requires.That(colorer != null); Contracts.Requires.That(texturer != null); this.IsSolid = isSolid; this.Colorer = colorer; this.Texturer = texturer; }
public AreaThresholdSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> aboveThresholdGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> belowThresholdGenerator, float threshold) { Contracts.Requires.That(aboveThresholdGenerator != null); Contracts.Requires.That(belowThresholdGenerator != null); Contracts.Requires.That(threshold >= 0); this.aboveThresholdGenerator = aboveThresholdGenerator; this.belowThresholdGenerator = belowThresholdGenerator; this.threshold = threshold; }
public FlatQuadContourer( IContourDeterminer <TVoxel> contourDeterminer, ISurfaceValueGenerator <TVoxel, TSurfaceData, Vector3> positioner, ISurfaceValueGenerator <TVoxel, TSurfaceData, Color> colorer, ISurfaceValueGenerator <TVoxel, TSurfaceData, Vector2> texturer) { Contracts.Requires.That(contourDeterminer != null); Contracts.Requires.That(positioner != null); Contracts.Requires.That(colorer != null); Contracts.Requires.That(texturer != null); this.contourDeterminer = contourDeterminer; this.positioner = positioner; this.colorer = colorer; this.texturer = texturer; }
// TODO Steven - this constructor should probably be a static factory method... public NoiseSeedSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> generator, IFactory <int, INoise3D> noiseFactory, INoiseDistorter3D noiseDistorter) : this( generator, new DistortedNoise3D(noiseFactory.Create(0), noiseDistorter), new DistortedNoise3D(noiseFactory.Create(1), noiseDistorter), new DistortedNoise3D(noiseFactory.Create(2), noiseDistorter), new DistortedNoise3D(noiseFactory.Create(3), noiseDistorter), new DistortedNoise3D(noiseFactory.Create(4), noiseDistorter), new DistortedNoise3D(noiseFactory.Create(5), noiseDistorter)) { Contracts.Requires.That(generator != null); Contracts.Requires.That(noiseFactory != null); Contracts.Requires.That(noiseDistorter != null); }
public AxisSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> positiveXAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> negativeXAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> positiveYAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> negativeYAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> positiveZAxisGenerator, ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> negativeZAxisGenerator) { Contracts.Requires.That(positiveXAxisGenerator != null); Contracts.Requires.That(negativeXAxisGenerator != null); Contracts.Requires.That(positiveYAxisGenerator != null); Contracts.Requires.That(negativeYAxisGenerator != null); Contracts.Requires.That(positiveZAxisGenerator != null); Contracts.Requires.That(negativeZAxisGenerator != null); this.positiveXAxisGenerator = positiveXAxisGenerator; this.negativeXAxisGenerator = negativeXAxisGenerator; this.positiveYAxisGenerator = positiveYAxisGenerator; this.negativeYAxisGenerator = negativeYAxisGenerator; this.positiveZAxisGenerator = positiveZAxisGenerator; this.negativeZAxisGenerator = negativeZAxisGenerator; }
public TextureSurfaceWriter(ISurfaceValueGenerator <TVoxel, TSurfaceData, Vector2> generator) { Contracts.Requires.That(generator != null); this.generator = generator; }
public ColorSurfaceWriter(ISurfaceValueGenerator <TVoxel, TSurfaceData, Color> generator) { Contracts.Requires.That(generator != null); this.generator = generator; }
public NoiseSeedSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> generator, INoise3D noise) : this(generator, noise, noise, noise) { }
public SeedSwitchSurfaceGenerator( ISurfaceValueGenerator <TVoxel, TSurfaceData, TValue> defaultGenerator, IEnumerable <ISeedThreshold <TVoxel, TSurfaceData, TValue> > generators) : this(defaultGenerator, generators.ToArray()) { }