Ogre_glTF icon indicating copy to clipboard operation
Ogre_glTF copied to clipboard

Adapt texture loading code to Ogre 2.2

Open Ybalrid opened this issue 5 years ago • 1 comments

The current code that loads texture data is both messy and inefficient. There's 2 things that need fixing :

  1. we are loading textures before knowing what material the glTF will use. Thus, we don't know what purpose the textures we load. Some of theses textures differ between how glTF store them and how HLMS PBS need them (eg : metalic-roughness map has to be separated in 2 "one color" texture from the 1 "two color" texture).

  2. current texture loading code is inefficient and messy. It needs cleaning.

Original issue about that problem was #17. But instead of concentrating on fixing the code for Ogre 2.1, we should rewrite it for 2.2, while incorporating the necessary changes.

The Ogre 2.1 code path will still benefit from the change due to the updated texture loading logic, but it is by no mean necessary.

I'm closing issue #17 now, as it is irrelevant from now on.

Ybalrid avatar Dec 06 '18 04:12 Ybalrid