|
@@ -43,6 +43,12 @@ module BABYLON {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * Gets or sets the id of the morph Target
|
|
|
+ */
|
|
|
+ @serialize()
|
|
|
+ public id: string;
|
|
|
+
|
|
|
private _animationPropertiesOverride: Nullable<AnimationPropertiesOverride> = null;
|
|
|
|
|
|
/**
|
|
@@ -169,6 +175,9 @@ module BABYLON {
|
|
|
serializationObject.influence = this.influence;
|
|
|
|
|
|
serializationObject.positions = Array.prototype.slice.call(this.getPositions());
|
|
|
+ if (this.id != null) {
|
|
|
+ serializationObject.id = this.id;
|
|
|
+ }
|
|
|
if (this.hasNormals) {
|
|
|
serializationObject.normals = Array.prototype.slice.call(this.getNormals());
|
|
|
}
|
|
@@ -182,6 +191,14 @@ module BABYLON {
|
|
|
return serializationObject;
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * Returns the string "MorphTarget"
|
|
|
+ * @returns "MorphTarget"
|
|
|
+ */
|
|
|
+ public getClassName(): string {
|
|
|
+ return "MorphTarget";
|
|
|
+ }
|
|
|
+
|
|
|
// Statics
|
|
|
|
|
|
/**
|
|
@@ -194,6 +211,9 @@ module BABYLON {
|
|
|
|
|
|
result.setPositions(serializationObject.positions);
|
|
|
|
|
|
+ if (serializationObject.id != null) {
|
|
|
+ result.id = serializationObject.id;
|
|
|
+ }
|
|
|
if (serializationObject.normals) {
|
|
|
result.setNormals(serializationObject.normals);
|
|
|
}
|