예제 #1
0
        public MDLNoiseTexture(float input, string name, Vector2i textureDimensions, MDLTextureChannelEncoding channelEncoding, MDLNoiseTextureType type)
        {
            // two different `init*` would share the same C# signature
            switch (type)
            {
            case MDLNoiseTextureType.Vector:
                Handle = InitVectorNoiseWithSmoothness(input, name, textureDimensions, channelEncoding);
                break;

            case MDLNoiseTextureType.Cellular:
                Handle = InitCellularNoiseWithFrequency(input, name, textureDimensions, channelEncoding);
                break;

            default:
                throw new ArgumentException("type");
            }
        }
예제 #2
0
 public MDLNoiseTexture(float input, string name, Vector2i textureDimensions, MDLTextureChannelEncoding channelEncoding) : this(input, name, textureDimensions, channelEncoding, MDLNoiseTextureType.Vector)
 {
 }