Skip to content
This repository was archived by the owner on Apr 27, 2018. It is now read-only.

Version 1.2 breaking change #4

Open
jgwinner opened this issue Nov 28, 2017 · 1 comment
Open

Version 1.2 breaking change #4

jgwinner opened this issue Nov 28, 2017 · 1 comment

Comments

@jgwinner
Copy link

In version 1.1, the loader is defined as:

THREE.GLTF2Loader = ( function () {

In version 1.2, the loader is defined as:

THREE.GLTFLoader = ( function () {

This is a huge breaking change. React-vr and react-vr-web both use THREE.GLTF2Loader, so gltf files now won't load in React VR at all. There is no workaround, other than to downgrade to 1.1.0. I'm also following up with React VR.

Was there a reason for this change?

Will the rename be permanent? Seems odd as GLTF2 files are more common now than GLTF1.

Also, I notice the GLTFSHADER seems to have disappeared; that seems drastic - did it move somewhere? What's it for?

Thank you,

== John ==

@donmccurdy
Copy link

Hi @jgwinner — note that this repo is a mirror of the GLTF(2)Loader file from the three.js repository — you're more likely to get answers promptly on issues/questions/bugs by posting there instead.

Was there a reason for this change? Will the rename be permanent?

three.js is deprecating glTF 1.0 support, and that loader has been renamed to THREE.LegacyGLTFLoader. Since glTF 2.0 is more common and preferred, we've renamed it GLTFLoader to indicate it's the default, and to hopefully avoid the need to rename with glTF 2.X, 3.X, etc. The name will remain GLTFLoader.

Also, I notice the GLTFSHADER seems to have disappeared; that seems drastic - did it move somewhere? What's it for?

glTF 1.0 had a mechanism for transmitting custom GLSL shaders with a model, which was visually flexible but prevented models from rendering in many native applications. glTF 2.0 replaced that with modern PBR materials, and will (later) support custom GLSL through a glTF extension called KHR_technique_webgl. That extension hasn't been finished, so we've removed the related code from the glTF 2.0 loader in the meantime.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants