MCPcopy
hub / github.com/mrdoob/three.js / clone

Method clone

src/core/Object3D.js:1581–1585  ·  view source on GitHub ↗

* Returns a new 3D object with copied values from this instance. * * @param {boolean} [recursive=true] - When set to `true`, descendants of the 3D object are also cloned. * @return {Object3D} A clone of this instance.

( recursive )

Source from the content-addressed store, hash-verified

1579 * @return {Object3D} A clone of this instance.
1580 */
1581 clone( recursive ) {
1582
1583 return new this.constructor().copy( this, recursive );
1584
1585 }
1586
1587 /**
1588 * Copies the values of the given 3D object to this instance.

Callers 2

constructorMethod · 0.45
copyMethod · 0.45

Calls 1

copyMethod · 0.45

Tested by

no test coverage detected