Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regarding obj textures #186

Open
eeshashetty opened this issue Oct 19, 2021 · 3 comments
Open

Regarding obj textures #186

eeshashetty opened this issue Oct 19, 2021 · 3 comments

Comments

@eeshashetty
Copy link

Hi, the code works perfectly well and I'm getting really accurate outputs!

My issue is with the .mat file and the texture file.

  1. How do I use face_color, face_texture, tri, etc on the 3D obj?
  2. The 3D obj renders with the texture on Meshlab but on blender only the mesh. Why is it so?
  3. Is there a way to extract the texture separately as a png file from the obj? Either from meshlab/blender or a python package?

Thanks!

@yuripourre
Copy link

yuripourre commented Oct 20, 2021

@eeshashetty

  1. If I am not mistaken the produced obj uses vertex color instead of a texture. This is not really a .obj standard and it's not supported by mostly obj loaders (and I believe) including blender.
  2. Same as 1
  3. If you know how to code shouldn't be hard to extract a texture from the vertices' colors

Edit: You would have to place each vertex into an image, calculate neighbors and then interpolate the colors.

@eeshashetty
Copy link
Author

Thanks for your response!

Yes, the output is vertex colors and not a texture file. And yes that’s where I am facing an issue, because its not a standard obj format.

If someone knows how to convert this into a texture file via a script please share here. I tried googling, but haven't been able to find any good links that lead to a proper solution for this issue yet.

@JeongDongBaek
Copy link

@eeshashetty
hi, Is the problem solved by any chance?
I am facing the same problem.
I want to be rendered in Unity finally, but the shader that renders the vertex color doesn't work. Did you find a way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants