# How to render the STL file with smoother effect?

**URL:** <https://discourse.threejs.org/t/how-to-render-the-stl-file-with-smoother-effect/60488>\
**Category:** Questions\
**Tags:** textures, shaders, geometry\
**Created:** [January 19, 2024, 5:50am UTC](https://discourse.threejs.org/t/how-to-render-the-stl-file-with-smoother-effect/60488 "2024-01-19T05:50:16Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nevermore](https://avatars.discourse-cdn.com/v4/letter/n/a587f6/32.png) [@Nevermore](https://discourse.threejs.org/u/Nevermore)\
**Post date:** [January 19, 2024, 5:50am UTC](https://discourse.threejs.org/t/how-to-render-the-stl-file-with-smoother-effect/60488/1 "2024-01-19T05:50:16Z")

</div>

Hi everyone,  
I am a newbie to learn three.js. I am rendering a STL file as the image shows.

 ![image](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/3X/9/7/97794f47fc3cad03e15a804ed5776273e40f93ab.jpeg)  
But I see a better effect with a smoother mesh. How can I get the effect that we can’t see the line from stl mesh grid. Thank you.

---

<div class="post-metadata">

**Author:** ![manthrax](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/manthrax/32/2596_2.png) [@manthrax](https://discourse.threejs.org/u/manthrax)\
**Post date:** [January 19, 2024, 10:25pm UTC](https://discourse.threejs.org/t/how-to-render-the-stl-file-with-smoother-effect/60488/2 "2024-01-19T22:25:35Z")

</div>

You could try:

```javascript
geometry.setAttribute('normal',null)
geometry = BufferGeometryUtils.mergeVertices(geometry);
geometry.computeVertexNormals();
mesh.geometry = geometry;
``
https://threejs.org/docs/#examples/en/utils/BufferGeometryUtils.mergeVertices
```
