Esempio n. 1
0
        /// <summary>
        /// Adds a property to a PLY file descriptor.
        /// </summary>
        /// <param name="plyFile"></param>
        /// <param name="words"></param>
        private static void AddProperty(PlyFile plyFile, string[] words)
        {
            var property = new PlyProperty();

            if (words[1] == "list")
            {
                property.CountExternal = GetPropertyType(words[2]);
                property.ExternalType  = GetPropertyType(words[3]);
                property.Name          = words[4];
                property.IsList        = true;
            }
            else
            {
                property.ExternalType = GetPropertyType(words[1]);
                property.Name         = words[2];
                property.IsList       = false;
            }

            // Add this property to the list of properties of the current element.
            plyFile.Elements[plyFile.Elements.Count - 1].Properties.Add(property);
        }
Esempio n. 2
-1
        /// <summary>
        /// Adds a property to a PLY file descriptor.
        /// </summary>
        /// <param name="plyFile"></param>
        /// <param name="words"></param>
        private static void AddProperty(PlyFile plyFile, string[] words)
        {
            var property = new PlyProperty();

            if (words[1] == "list")
            {
                property.CountExternal = GetPropertyType(words[2]);
                property.ExternalType = GetPropertyType(words[3]);
                property.Name = words[4];
                property.IsList = true;
            }
            else
            {
                property.ExternalType = GetPropertyType(words[1]);
                property.Name = words[2];
                property.IsList = false;
            }

            // Add this property to the list of properties of the current element.
            plyFile.Elements[plyFile.Elements.Count - 1].Properties.Add(property);
        }