Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docs/components/collada-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ examples: []

The collada-model component loads a 3D model using a [COLLADA][wiki-collada] (.DAE) file.

> **DEPRECATED**: The `collada-model` component is deprecated. Consider
converting models with [COLLADA2GLTF][collada2gltf] and using `gltf-model`
instead.

[collada2gltf]: https://github.com/KhronosGroup/COLLADA2glTF

## Example

We can load a COLLADA model by pointing to an asset that specifies the `src` to a COLLADA file.
Expand Down
6 changes: 6 additions & 0 deletions docs/primitives/a-collada-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ source_code: src/extras/primitives/primitives/a-collada-model.js
The COLLADA model primitive displays a 3D COLLADA model created from a 3D
modeling program or downloaded from the web.

> **DEPRECATED**: The `collada-model` component is deprecated. Consider
converting models with [COLLADA2GLTF][collada2gltf] and using `gltf-model`
instead.

[collada2gltf]: https://github.com/KhronosGroup/COLLADA2glTF

## Example

```html
Expand Down
4 changes: 4 additions & 0 deletions src/components/collada-model.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
var registerComponent = require('../core/component').registerComponent;
var THREE = require('../lib/three');
var debug = require('../utils/debug');

var warn = debug('components:collada-model:warn');

module.exports.Component = registerComponent('collada-model', {
schema: {type: 'asset'},

init: function () {
this.model = null;
this.loader = new THREE.ColladaLoader();
warn('`collada-model` is deprecated. Consider using `gltf-model` instead.');
},

update: function () {
Expand Down