# glTF missing geometry R3F

**URL:** https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787
**Category:** Questions
**Tags:** loaders, react-three-fiber
**Created:** [April 30, 2020, 1:10pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787 "2020-04-30T13:10:31Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![mzucc](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@mzucc](https://discourse.threejs.org/u/mzucc)
#### Post date: [April 30, 2020, 1:10pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/1 "2020-04-30T13:10:31Z")

</div>

Hey,

Just wondering if anybody can help me. I’m using Next.js and React Three Fiber to display some custom models. I’ve tried exporting the model with a variety of different settings using different softwares. When I import the models into my scene they have no geometry. I am wondering if this is a loader issue or an export issue?

When I log the object to the console, there is no geometry node, compared to a `.glb` I found online that seems to be working in the same scene:

My object:

 ![Screenshot 2020-04-30 at 14.38.53](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/2X/d/d93f49052a5f32807e78e3e098ff3340d8144ab5.png)

Parrot:

 ![Screenshot 2020-04-30 at 14.39.21](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/2X/a/af2e433a1bf1f00422a252c1d4ac98cd6ce5f1e5.png)

These are the versions I am using:  
“next”: “9.2.1”,  
“react”: “16.12.0”,  
“three”: “0.112.1”  
“react-three-fiber”: “4.0.12”

---

<div class="post-metadata">

### Author: ![Mugen87](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/mugen87/32/5645_2.png) [@Mugen87](https://discourse.threejs.org/u/Mugen87)
#### Post date: [April 30, 2020, 1:15pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/2 "2020-04-30T13:15:52Z")

</div>

Are you able to load your `glTF` assets in viewers like:

[https://sandbox.babylonjs.com/](https://sandbox.babylonjs.com/)  
[https://gltf-viewer.donmccurdy.com/](https://gltf-viewer.donmccurdy.com/)

---

<div class="post-metadata">

### Author: ![mzucc](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@mzucc](https://discourse.threejs.org/u/mzucc)
#### Post date: [April 30, 2020, 1:37pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/3 "2020-04-30T13:37:07Z")

</div>

Hey, thanks for your quick reply. I am indeed able to load them in viewers without any hassles

---

<div class="post-metadata">

### Author: ![Mugen87](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/mugen87/32/5645_2.png) [@Mugen87](https://discourse.threejs.org/u/Mugen87)
#### Post date: [April 30, 2020, 1:49pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/4 "2020-04-30T13:49:51Z")

</div>

The second viewer in the list uses `three.js`. So there seems to be a problem with your app. Any chances to share a live example that demonstrates the issue?

---

<div class="post-metadata">

### Author: ![mzucc](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@mzucc](https://discourse.threejs.org/u/mzucc)
#### Post date: [April 30, 2020, 1:54pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/5 "2020-04-30T13:54:32Z")

</div>

Thank you and of course. In the meantime in the question I uploaded two screenshots comparing my model to the R3F glTF parrot, where my model (along with some others I tried) don’t have any geometry node

---

<div class="post-metadata">

### Author: ![mzucc](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@mzucc](https://discourse.threejs.org/u/mzucc)
#### Post date: [April 30, 2020, 2:16pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/6 "2020-04-30T14:16:27Z")

</div>

Hey this is the rough codesandbox [https://codesandbox.io/s/silly-mendeleev-0sus4?file=/pages/birds.js](https://codesandbox.io/s/silly-mendeleev-0sus4?file=/pages/birds.js)  
Birds is the page copied from the example and using the parrot object, custom is just a super simple export of a sphere `.glb`

---

<div class="post-metadata">

### Author: ![drcmda](https://avatars.discourse-cdn.com/v4/letter/d/91b2a8/32.png) [@drcmda](https://discourse.threejs.org/u/drcmda)
#### Post date: [April 30, 2020, 3:13pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/7 "2020-04-30T15:13:30Z")

</div>

that’s not how it works. the example was using gltfjsx ([https://github.com/react-spring/gltfjsx](https://github.com/react-spring/gltfjsx)). it extracts the scene-graph and it’s specific to the model. sphere.gtlf has another graph, it doesn’t fit.

all you need is this:

```auto
const { scene } = useLoader(GLTFLoader, url)
return <primitive object={scene} dispose={null} />

```

which is shorthand for (well, plus it uses suspense so you can manage async assets):

```auto
const [model, set] = useState()
useEffect(() => new GLTFLoader().load(url, set), [url])
return model ? <primitive object={model.scene} dispose={null} /> : null

```

you can look into gltfjsx if it interests you, it most certainly has advantages. but nothing in r3f should distract you from how threejs works. when in doubt, always do it like it’s written in the threejs docs.

PS. here’s a super simple sandbox that you can use to play around: [https://codesandbox.io/s/r3f-drei-stats-8p4ph](https://codesandbox.io/s/r3f-drei-stats-8p4ph)

---

<div class="post-metadata">

### Author: ![mzucc](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@mzucc](https://discourse.threejs.org/u/mzucc)
#### Post date: [April 30, 2020, 4:00pm UTC](https://discourse.threejs.org/t/gltf-missing-geometry-r3f/14787/8 "2020-04-30T16:00:31Z")

</div>

Ah, thank you so much for that!!  
if I didn’t walk away from these forums feeling stupid I wouldn’t be learning 🙂

Thanks again!
