コード例 #1
0
 public override void OnValidate(PPData_Bloom _data)
 {
     base.OnValidate(_data);
     m_Material.SetFloat(ID_Threshold, _data.threshold);
     m_Material.SetFloat(ID_Intensity, _data.intensity);
     _mCoreBlur.OnValidate(_data.m_BlurParams);
 }
コード例 #2
0
 public override void OnValidate(PPData_DepthOfField _data)
 {
     base.OnValidate(_data);
     m_Material.SetFloat(ID_FocalStart, _data.m_DOFStart);
     m_Material.SetFloat(ID_FocalLerp, _data.m_DOFLerp);
     m_Material.EnableKeyword(KW_UseBlurDepth, _data.m_DepthBlurSample);
     m_Material.SetFloat(ID_BlurSize, _data.m_DepthBlurSize);
     _mCoreBlur.OnValidate(_data.m_BlurParams);
 }
コード例 #3
0
 public override void OnValidate(PPData_VolumetricLight _params)
 {
     base.OnValidate(_params);
     m_Material.SetFloat(ID_ColorStrength, _params.m_Strength);
     m_Material.SetInt(ID_MarchTimes, (int)_params.m_MarchTimes);
     m_Material.SetFloat(ID_MarchDistance, _params.m_Distance);
     m_Material.SetFloat(ID_LightPow, _params.m_Pow);
     m_Material.SetFloat(ID_LightStrength, _params.m_MarchStrength);
     m_Material.EnableKeyword(kW_DITHER, _params.m_Dither);
     m_CoreBlur.OnValidate(_params.m_BlurParam);
 }
コード例 #4
0
        public override void OnValidate(PPData_Outline _data)
        {
            base.OnValidate(_data);
            _mCoreBlur.OnValidate(_data.m_OutlineBlur);
            m_Material.SetColor(ID_EdgeColor, _data.m_Color);
            m_Material.SetFloat(ID_OutlineWidth, _data.m_Width);
            m_Material.EnableKeywords(KW_Convolution, (int)_data.m_Convolution);
            m_Material.EnableKeywords(KW_DetectType, (int)_data.m_DetectType);
            m_Material.SetFloat(ID_Strength, _data.m_Strength);
            m_Material.SetFloat(ID_Bias, _data.m_Bias);

            m_RenderMaterial.EnableKeyword(KW_DepthForward, _data.m_ZClip);
            if (_data.m_ZClip)
            {
                m_RenderMaterial.SetInt(ID_ZTest, (int)(_data.m_ZLesser ?CompareFunction.Less:CompareFunction.Greater));
                m_RenderMaterial.SetFloat(ID_DepthForwardAmount, _data.m_ZOffset);
            }
        }