# Is there an existing function to parse an OBJ file by section and name?

**URL:** <https://forum.babylonjs.com/t/is-there-an-existing-function-to-parse-an-obj-file-by-section-and-name/15960>\
**Category:** Questions\
**Created:** [November 23, 2020, 2:45pm UTC](https://forum.babylonjs.com/t/is-there-an-existing-function-to-parse-an-obj-file-by-section-and-name/15960 "2020-11-23T14:45:22Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Carlos.Mendieta](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carlos.mendieta/32/124_2.png) [@Carlos.Mendieta](https://forum.babylonjs.com/u/Carlos.Mendieta)\
**Post date:** [November 23, 2020, 2:45pm UTC](https://forum.babylonjs.com/t/is-there-an-existing-function-to-parse-an-obj-file-by-section-and-name/15960/1 "2020-11-23T14:45:22Z")

</div>

Hello, I was looking for an existing function where I could provide a layer name and get in return an array of uv map coordinates.

For example:

> function GetUVMapFromOBJLayer(OBJ\_filename, layer\_name) {  
> return all UV map coordinates for the layer named;  
> }

thank you,  
Carlos

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [November 23, 2020, 4:01pm UTC](https://forum.babylonjs.com/t/is-there-an-existing-function-to-parse-an-obj-file-by-section-and-name/15960/2 "2020-11-23T16:01:33Z")

</div>

I think the easiest would be to load/import the obj into babylon and then get access to the mesh vertices data.

There is a bit of remapping/swizzling happening and it would be safer this way.

---

<div class="post-metadata">

**Author:** ![Carlos.Mendieta](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carlos.mendieta/32/124_2.png) [@Carlos.Mendieta](https://forum.babylonjs.com/u/Carlos.Mendieta)\
**Post date:** [November 23, 2020, 4:07pm UTC](https://forum.babylonjs.com/t/is-there-an-existing-function-to-parse-an-obj-file-by-section-and-name/15960/3 "2020-11-23T16:07:35Z")

</div>

swizzling ahaha… thanks 🙂 will look into it.
