コード例 #1
0
ファイル: IntentBuilder.cs プロジェクト: jaredb7/vixen
 public static IIntent CreateDiscreteIntent(Color color, double startIntensity, double endIntensity, TimeSpan duration)
 {
     var startingValue = new DiscreteValue(color, startIntensity);
     var endValue = new DiscreteValue(color, endIntensity);
     IIntent intent = new DiscreteLightingIntent(startingValue, endValue, duration);
     return intent;
 }
コード例 #2
0
ファイル: MaskFillModule.cs プロジェクト: jaredb7/vixen
 public override DiscreteValue CombineDiscreteIntensity(DiscreteValue highLayerValue, DiscreteValue lowLayerValue)
 {
     if (highLayerValue.Intensity > 0)
     {
         return highLayerValue;
     }
     return lowLayerValue;
 }
コード例 #3
0
ファイル: MaskFillModule.cs プロジェクト: jeffu231/vixen
        public override DiscreteValue CombineDiscreteIntensity(DiscreteValue highLayerValue, DiscreteValue lowLayerValue)
        {
            if (highLayerValue.Intensity > 0 || !_data.ExcludeZeroValues)
            {
                return highLayerValue;
            }

            return lowLayerValue;
        }
コード例 #4
0
 public override DiscreteValue CombineDiscreteIntensity(DiscreteValue highLayerValue, DiscreteValue lowLayerValue)
 {
     double intensity = lowLayerValue.Intensity * (1 - highLayerValue.Intensity);
     highLayerValue.Intensity = Math.Max(intensity, highLayerValue.Intensity);
     return highLayerValue;
 }
コード例 #5
0
ファイル: IntentBuilder.cs プロジェクト: jaredb7/vixen
 public static IIntent CreateDiscreteIntent(Color color, double intensity, TimeSpan duration)
 {
     DiscreteValue discreteValue = new DiscreteValue(color, intensity);
     IIntent intent = new DiscreteLightingIntent(discreteValue, discreteValue, duration);
     return intent;
 }
コード例 #6
0
ファイル: IntentBuilder.cs プロジェクト: jaredb7/vixen
        private static DiscreteValue[] InitializeDiscreteValues(Color c, int number)
        {
            var discreteValues = new DiscreteValue[number];
            for (int i = 0; i < discreteValues.Length; i++)
            {
                discreteValues[i] = new DiscreteValue(c, 0);
            }

            return discreteValues;
        }
コード例 #7
0
 public DiscreteValue(DiscreteValue dv)
 {
     _color     = dv.Color;
     _intensity = dv.Intensity;
 }
コード例 #8
0
ファイル: IntensityOverlay.cs プロジェクト: jaredb7/vixen
 public override DiscreteValue CombineDiscreteIntensity(DiscreteValue highLayerValue, DiscreteValue lowLayerValue)
 {
     lowLayerValue.Intensity = lowLayerValue.Intensity * highLayerValue.Intensity;
     return lowLayerValue;
 }