Question

I copied the exact (working) colladaLoader code from three.js on github, and put it on disk and sorted the dependancies. but instead of the monster.dae, I get a "Uncaught TypeError: Cannot set property 'convertUpAxis' of undefined" However the example works from the three.js github site.

No clues on the web at all. What does that mean?

Was it helpful?

Solution

I think you might need to give us some more info.

On the Collada example The only code that references convertUpAxis is Line 33.

var loader = new THREE.ColladaLoader();
loader.options.convertUpAxis = true;

As such, this suggests to me that the THREE.ColladaLoader instance either failed to create the instance or that the prototype isn't available in the first place. Either of these make it sound like you're missing a dependency.

Just a random guess on my part (I've never been a THREE.js expert) but are you perhaps using the Three.js file from the src folder instead of the build folder? The src version is just a stub with a requestAnimationFrame shim in it. The one from the build folder, however, includes all of the submodules like the COLLADA loader that you need. Double check!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top