Ejemplo n.º 1
0
 public SerializedLayoutCategory(LayoutInfo info)
 {
     AABB              = new AABBLayout(info);
     AABBi             = new AABBiLayout(info);
     AnimationCurveTpl = new AnimationCurveTplLayout(info);
     ColorRGBA32       = new ColorRGBA32Layout(info);
     ColorRGBAf        = new ColorRGBAfLayout(info);
     Gradient          = new GradientLayout(info);
     GUIStyle          = new GUIStyleLayout(info);
     LayerMask         = new LayerMaskLayout(info);
     Matrix4x4f        = new Matrix4x4fLayout(info);
     Quaternionf       = new QuaternionfLayout(info);
     Rectf             = new RectfLayout(info);
     RectOffset        = new RectOffsetLayout(info);
     Vector2f          = new Vector2fLayout(info);
     Vector2i          = new Vector2iLayout(info);
     Vector3f          = new Vector3fLayout(info);
     Vector3i          = new Vector3iLayout(info);
     Vector4f          = new Vector4fLayout(info);
 }
Ejemplo n.º 2
0
        public YAMLNode ExportYAML(IExportContainer container)
        {
            YAMLMappingNode  node   = new YAMLMappingNode();
            Matrix4x4fLayout layout = container.ExportLayout.Serialized.Matrix4x4f;

            node.Add(layout.E00Name, E00);
            node.Add(layout.E01Name, E01);
            node.Add(layout.E02Name, E02);
            node.Add(layout.E03Name, E03);
            node.Add(layout.E10Name, E10);
            node.Add(layout.E11Name, E11);
            node.Add(layout.E12Name, E12);
            node.Add(layout.E13Name, E13);
            node.Add(layout.E20Name, E20);
            node.Add(layout.E21Name, E21);
            node.Add(layout.E22Name, E22);
            node.Add(layout.E23Name, E23);
            node.Add(layout.E30Name, E30);
            node.Add(layout.E31Name, E31);
            node.Add(layout.E32Name, E32);
            node.Add(layout.E33Name, E33);
            return(node);
        }
Ejemplo n.º 3
0
        private static void GenerateEngineStruct(TypeTreeContext context, SerializableType origin, string name)
        {
            switch (origin.Name)
            {
            case SerializableType.Vector2Name:
                Vector2fLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Vector2IntName:
                Vector2iLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Vector3Name:
                Vector3fLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Vector3IntName:
                Vector3iLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Vector4Name:
                Vector4fLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.RectName:
                RectfLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.BoundsName:
                AABBLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.BoundsIntName:
                AABBiLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.QuaternionName:
                QuaternionfLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Matrix4x4Name:
                Matrix4x4fLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.ColorName:
                ColorRGBAfLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.Color32Name:
                ColorRGBA32Layout.GenerateTypeTree(context, name);
                break;

            case SerializableType.LayerMaskName:
                LayerMaskLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.AnimationCurveName:
                AnimationCurveTplLayout.GenerateTypeTree(context, name, SingleLayout.GenerateTypeTree);
                break;

            case SerializableType.GradientName:
                GradientLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.RectOffsetName:
                RectOffsetLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.GUIStyleName:
                GUIStyleLayout.GenerateTypeTree(context, name);
                break;

            case SerializableType.PropertyNameName:
                PropertyNameLayout.GenerateTypeTree(context, name);
                break;

            default:
                throw new Exception($"Unknown engine struct {origin.Name}");
            }
        }