Browse Source

Merge remote-tracking branch 'origin/gltf2_metadata_export' into gltf2_metadata_export

Bengt Rosenberger 3 years ago
parent
commit
f20071d740
1 changed files with 17 additions and 0 deletions
  1. 17 0
      code/AssetLib/glTF2/glTF2Asset.h

+ 17 - 0
code/AssetLib/glTF2/glTF2Asset.h

@@ -395,6 +395,23 @@ struct Extras {
     }
 };
 
+//! Represents metadata in an glTF2 object
+struct Extras {
+    std::vector<CustomExtension> mValues;
+
+    inline bool HasExtras() const {
+        return mValues.size() != 0;
+    }
+
+    Extras() = default;
+    ~Extras() = default;
+
+    Extras(const Extras &other) :
+            mValues(other.mValues) {
+        // empty
+    }
+};
+
 //! Base class for all glTF top-level objects
 struct Object {
     int index; //!< The index of this object within its property container