Beispiel #1
0
        public YAMLNode ExportYAML(IExportContainer container)
        {
            YAMLMappingNode node = new YAMLMappingNode();

            node.AddSerializedVersion(ToSerializedVersion(container.ExportVersion));
            node.Add(HeightsName, Heights.ExportYAML(true));
            if (HasShifts(container.ExportVersion))
            {
                node.Add(ShiftsName, Shifts.ExportYAML(container));
            }

            node.Add(PrecomputedErrorName, PrecomputedError.ExportYAML());
            node.Add(MinMaxPatchHeightsName, MinMaxPatchHeights.ExportYAML());
            if (HasDefaultPhysicMaterial(container.ExportVersion))
            {
                node.Add(DefaultPhysicMaterialName, DefaultPhysicMaterial.ExportYAML(container));
            }

            node.Add(WidthName, Width);
            node.Add(HeightName, Height);
            if (HasThickness(container.ExportVersion))
            {
                node.Add(ThicknessName, Thickness);
            }

            node.Add(LevelsName, Levels);
            node.Add(ScaleName, Scale.ExportYAML(container));
            return(node);
        }
Beispiel #2
0
        public YAMLNode ExportYAML(IExportContainer container)
        {
#warning TODO: values acording to read version (current 2017.3.0f3)
            YAMLMappingNode node = new YAMLMappingNode();
            node.AddSerializedVersion(GetSerializedVersion(container.Version));
            node.Add("m_Heights", Heights.ExportYAML(true));
            node.Add("m_PrecomputedError", PrecomputedError.ExportYAML());
            node.Add("m_MinMaxPatchHeights", MinMaxPatchHeights.ExportYAML());
            node.Add("m_Width", Width);
            node.Add("m_Height", Height);
            node.Add("m_Thickness", Thickness);
            node.Add("m_Levels", Levels);
            node.Add("m_Scale", Scale.ExportYAML(container));
            return(node);
        }
Beispiel #3
0
        public YAMLNode ExportYAML(IExportContainer container)
        {
            YAMLMappingNode node = new YAMLMappingNode();

            node.AddSerializedVersion(GetSerializedVersion(container.ExportVersion));
            node.Add(HeightsName, Heights.ExportYAML(true));
            node.Add(PrecomputedErrorName, PrecomputedError.ExportYAML());
            node.Add(MinMaxPatchHeightsName, MinMaxPatchHeights.ExportYAML());
            node.Add(WidthName, Width);
            node.Add(HeightName, Height);
            node.Add(ThicknessName, Thickness);
            node.Add(LevelsName, Levels);
            node.Add(ScaleName, Scale.ExportYAML(container));
            return(node);
        }