Нет описания
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

123456789101112131415161718
  1. using UnityEditor;
  2. namespace Unity.Mathematics.Editor
  3. {
  4. [CustomPropertyDrawer(typeof(quaternion))]
  5. class QuaternionDrawer : PostNormalizedVectorDrawer
  6. {
  7. protected override SerializedProperty GetVectorProperty(SerializedProperty property)
  8. {
  9. return property.FindPropertyRelative("value");
  10. }
  11. protected override double4 Normalize(double4 value)
  12. {
  13. return math.normalizesafe(new quaternion((float4)value)).value;
  14. }
  15. }
  16. }