| 11 | |
| 12 | namespace CesiumGltf { |
| 13 | std::string convertPropertyTypeToString(PropertyType type) { |
| 14 | switch (type) { |
| 15 | case PropertyType::Scalar: |
| 16 | return ClassProperty::Type::SCALAR; |
| 17 | case PropertyType::Vec2: |
| 18 | return ClassProperty::Type::VEC2; |
| 19 | case PropertyType::Vec3: |
| 20 | return ClassProperty::Type::VEC3; |
| 21 | case PropertyType::Vec4: |
| 22 | return ClassProperty::Type::VEC4; |
| 23 | case PropertyType::Mat2: |
| 24 | return ClassProperty::Type::MAT2; |
| 25 | case PropertyType::Mat3: |
| 26 | return ClassProperty::Type::MAT3; |
| 27 | case PropertyType::Mat4: |
| 28 | return ClassProperty::Type::MAT4; |
| 29 | case PropertyType::Boolean: |
| 30 | return ClassProperty::Type::BOOLEAN; |
| 31 | case PropertyType::Enum: |
| 32 | return ClassProperty::Type::ENUM; |
| 33 | case PropertyType::String: |
| 34 | return ClassProperty::Type::STRING; |
| 35 | default: |
| 36 | return "INVALID"; |
| 37 | } |
| 38 | } |
| 39 | |
| 40 | PropertyType convertStringToPropertyType(const std::string& str) { |
| 41 | if (str == ClassProperty::Type::SCALAR) { |
no outgoing calls