0
$\begingroup$

i have encountered a strange problem when exporting an .obj file. Some portions of info is missing entirely.

All i did was create a cube, add a texture, align the texture mapping to my liking, and exported as an obj file with normals enabled.

I had to use an online converter to convert the file into a text file because the platform i was working with 3D models on has no way to load obj files, let alone any file. The converted text seemed fine with no corruption.

What i mean by removing certain info is duplicate values, specifically for normals and texture coordinates. It appears to not include any values that are the same, but i need these values for the software i am using.

The export window had nothing about removing duplicate values, not even a checkbox to enable or disable it.

Is there a setting i am missing that i can’t see, or is there a bug in the program? Thank you for any help you can give me.

$\endgroup$
8
  • $\begingroup$ What version of Blender are you using? The reason I ask is that Blender 3.5 and 3.6 have two versions of the obj file exporter on the Export menu (legacy written in python and a new faster version in C++) so it might be worth trying both versions and comparing the results to see if there's any difference. If the legacy version is ok and the new version has your duplicates missing you should report it as a bug. $\endgroup$
    – John Eason
    Jul 24, 2023 at 9:16
  • $\begingroup$ I am using version 3.6 of blender. I have tried both new and legacy export options. I assume i should have 36 texture values, 3 for each triangle. The new version only gives me 4 of the texture values, while the legacy version gives me half of them. I believe i should have 12 normal values, both export options give me only half, removing the duplicate values. I could just copy and paste to double my normal values, but for the texture coords i’m not sure if that will work correctly. I will be working on trying the copy and paste part here soon. Where do i go to post a bug report? Thank you. $\endgroup$
    – XanCraft21
    Jul 26, 2023 at 0:44
  • $\begingroup$ Since it sounds as if you have a problem with both the old and new versions of the exporter I'd use Blender's Help > Report a Bug menu and give a full explanation saying that you've tried both the addon and built-in version of the exporter and explain the differences you've found. (There is a Report a Bug button on the addon's entry under the addon's Edit > Preferences > Addons entry, but that's just for the legacy version.) See this posting for further details about bug reporting. $\endgroup$
    – John Eason
    Jul 26, 2023 at 8:15
  • $\begingroup$ Thank you. I will get to that as soon as i can. $\endgroup$
    – XanCraft21
    Jul 26, 2023 at 18:55
  • $\begingroup$ I was just about to make a bug report, but i was thinking, am i doing something wrong and just wasted making a topic? I have another question before i make my bug report, how are the model indices designed to work like in the .obj file? There are 9 index values per triangle, are 3 for the triangle points, 3 for the normal values, and 3 for the texture coords? Thank you. $\endgroup$
    – XanCraft21
    Jul 27, 2023 at 19:53

1 Answer 1

1
$\begingroup$

I have figured out the problem, there are no bugs, it was just me misunderstanding some things. Yes the program is skipping duplicate values but for a reason, the use of index values or indices, one for the triangle points, texture coords, and normals for each vertices of each triangle. I was writing my own obj file reader using arrays in a program that can’t read files, and i had to iterate through the values using the indices to generate each triangle. One day i’ll make a guide on how i did this and link it here.

$\endgroup$
3
  • $\begingroup$ Would you be so kind and post your solution/workaround? "I solved it kthxbye" is one of the worst things you can do in the internet :( $\endgroup$
    – taiyo
    Jul 27, 2023 at 22:12
  • $\begingroup$ Yes. Please post an answer explaining your solution for the benefit of anyone who may come up against the same problem in future. $\endgroup$
    – John Eason
    Jul 27, 2023 at 22:46
  • 1
    $\begingroup$ There’s not really a good solution for this, nothing was wrong, i was just confused at how something worked. The skipped values is deliberate because the program includes an index value for each point. I think i wasted this post, i will be deleting it soon. But really the trick was i needed to learn how to use indices to generate triangles. But for now i will edit my answer. $\endgroup$
    – XanCraft21
    Jul 27, 2023 at 23:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .