Exemplo n.º 1
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            output *= (double)longitudeCurve.Evaluate((float)data.longitude);
            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 2
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            output = Math.Abs(output);
            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 3
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            output *= (double)deformityCurve.Evaluate((float)data.vertHeight);
            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 4
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output  = (MN.GetOutput(applyTo) + 1) * 0.5;
            var output1 = MN.GetOutput(firstNoise);
            var output2 = MN.GetOutput(secondNoise);

            output = Utils.LerpD(output1, output2, output);

            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 5
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            if (output < min)
            {
                output = min;
            }
            if (output > max)
            {
                output = max;
            }
            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 6
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            if (applyFrom != null)
            {
                output *= MN.GetOutput(applyFrom);
            }
            else
            {
                output *= valueToMult;
            }

            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 7
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output  = (MN.GetOutput(applyTo) + 1) * 0.5;     //2
            var output1 = MN.GetOutput(firstNoise);              //0
            var output2 = MN.GetOutput(secondNoise);             //1

            if (falloff > 0.0)
            {
                if (output < (min - falloff))
                {
                    MN.SetOutput(applyTo, output1);
                    return;
                }
                if (output < (min + falloff))
                {
                    var lc  = (min - falloff);
                    var uc  = (min + falloff);
                    var t   = Utils.MapCubicCurve((output - lc) / (uc - lc));
                    var ret = Utils.LerpD(output1,
                                          output2, t);
                    MN.SetOutput(applyTo, ret);
                    return;
                }
                if (output < (max - falloff))
                {
                    MN.SetOutput(applyTo, output2);
                    return;
                }
                if (output < (max + falloff))
                {
                    var lc  = (max - falloff);
                    var uc  = (max + falloff);
                    var t   = Utils.MapCubicCurve((output - lc) / (uc - lc));
                    var ret = Utils.LerpD(output2,
                                          output1, t);
                    MN.SetOutput(applyTo, ret);
                    return;
                }
                MN.SetOutput(applyTo, output1);
                return;
            }
            if (output < min || output > max)
            {
                MN.SetOutput(applyTo, output1);
                return;
            }
        }
Exemplo n.º 8
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            if (applyFrom != null)
            {
                var sign = (output < 0 ? -1 : 1);
                var from = MN.GetOutput(applyFrom);
                output = Math.Abs(Math.Pow(output, from)) * sign;
            }
            else
            {
                var sign = (output < 0 ? -1 : 1);
                output = Math.Abs(Math.Pow(output, power)) * sign;
            }

            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 9
0
        public override void Output(MN_Operator_OutputData data)
        {
            var output = MN.GetOutput(applyTo);

            if (applyFrom != null)
            {
                var from = MN.GetOutput(applyFrom);
                if (output < from)
                {
                    output = from;
                }
            }
            else
            {
                if (output > max)
                {
                    output = max;
                }
            }

            MN.SetOutput(applyTo, output);
        }
Exemplo n.º 10
0
 public virtual void Output(MN_Operator_OutputData data)
 {
 }