Nav apraksta
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

MotionBlurEditor.cs 1.2KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using UnityEngine.Rendering.Universal;
  2. namespace UnityEditor.Rendering.Universal
  3. {
  4. [CustomEditor(typeof(MotionBlur))]
  5. sealed class MotionBlurEditor : VolumeComponentEditor
  6. {
  7. SerializedDataParameter m_Mode;
  8. SerializedDataParameter m_Quality;
  9. SerializedDataParameter m_Intensity;
  10. SerializedDataParameter m_Clamp;
  11. public override void OnEnable()
  12. {
  13. var o = new PropertyFetcher<MotionBlur>(serializedObject);
  14. m_Mode = Unpack(o.Find(x => x.mode));
  15. m_Quality = Unpack(o.Find(x => x.quality));
  16. m_Intensity = Unpack(o.Find(x => x.intensity));
  17. m_Clamp = Unpack(o.Find(x => x.clamp));
  18. }
  19. public override void OnInspectorGUI()
  20. {
  21. //PropertyField(m_Mode);
  22. //if (m_Mode.value.intValue == (int)MotionBlurMode.CameraOnly)
  23. //{
  24. PropertyField(m_Mode);
  25. PropertyField(m_Quality);
  26. PropertyField(m_Intensity);
  27. PropertyField(m_Clamp);
  28. //}
  29. //else
  30. //{
  31. // EditorGUILayout.HelpBox("Object motion blur is not supported on the Universal Render Pipeline yet.", MessageType.Info);
  32. //}
  33. }
  34. }
  35. }