rastapasta/react-native-gl-model-view

How can I change texture of a static model(.obj)?

Nero9Chan opened this issue · 0 comments

Hello, I would like to ask how can I change texture of a static model. I have tried to load a texture by using state to store texture uri. At the first time of render, everything works fine. However, when I change the texture uri through state, nothing happens after re-rendering. That model still uses the old texture. The stranger thing is that if I change the rotate angle and re-render model view, the model view will use the new rotate angle. I am sure my new texture has no problem since I have tried to render the model view using the new texture and it works fine. Therefore, I would like to ask how to change texture of a static model or how to reload the model view with new texture.

Thank you!