예제 #1
0
        void Start()
        {
            if (adjustHue)
            {
                adjustHue.value = HSVRange.GetHue(targetMaterial);
                adjustHue.onValueChanged.AddListener(hue => {
                    HSVRange.SetHue(targetMaterial, hue);
                });
            }

            if (adjustSaturation)
            {
                adjustSaturation.value = HSVRange.GetSaturation(targetMaterial);
                adjustSaturation.onValueChanged.AddListener(saturation => {
                    HSVRange.SetSaturation(targetMaterial, saturation);
                });
            }

            if (adjustValue)
            {
                adjustValue.value = HSVRange.GetValue(targetMaterial);
                adjustValue.onValueChanged.AddListener(value => {
                    HSVRange.SetValue(targetMaterial, value);
                });
            }

            if (adjustAlpha)
            {
                adjustAlpha.value = HSVRange.GetAlpha(targetMaterial);
                adjustAlpha.onValueChanged.AddListener(alpha => {
                    HSVRange.SetAlpha(targetMaterial, alpha);
                });
            }
        }
예제 #2
0
 public void SetAlpha(float alpha)
 {
     HSVRange.SetAlpha(targetMaterial, alpha);
 }
예제 #3
0
 public void SetValue(float value)
 {
     HSVRange.SetValue(targetMaterial, value);
 }
예제 #4
0
 public void SetSaturation(float saturation)
 {
     HSVRange.SetSaturation(targetMaterial, saturation);
 }
예제 #5
0
 public void SetHue(float hue)
 {
     HSVRange.SetHue(targetMaterial, hue);
 }