Cracks in Texture of OBJ

Jan 31, 2014 at 12:49 AM
I am importing an OBJ model with a texture that references an image. The edges of the different pieces in the image show up as cracks in the viewer. Is this something I can fix in the helixtoolkit code or is it a problem in the .NET code? (The model looks fine in MeshLab)

Feb 2, 2014 at 12:11 PM
It's a nice effect! :-) But I guess you don't want it to look like that..
What does the textures look like? Examine the edges in a image editor.
Could it be a problem with the ImageBrush? Are texture coordinates clamped in [0,1]?
Feb 19, 2014 at 3:40 PM
The texture coordinates are clamped in [0,1]. As I mentioned the model and texture display fine in MeshLab. Can you point me to the code that causes a triangle to get rendered to the viewport? Is that even in the HelixToolkit code?

Feb 19, 2014 at 8:56 PM
The importer creates a MeshGeometry3D with positions and texture coordinates. The material is created from an ImageBrush.
I guess the problem is with the material since this is only a problem on the edges. Can you post the texture image?
You could also try changing the TileMode of the ImageBrush (my wild guess).
Feb 20, 2014 at 5:54 PM
I have to get permission to share the texture file. While I'm waiting for that, I've shared an obj/mtl pair in another thread that also doesn't display correctly in the Helix viewer. I'm not sure that it's the exact same issue, but it is evidence that the viewer has problems with image textures.

Also, my colleague who knows more about 3D than I do thinks that the trouble crops up only where the UV map has a discontinuity, i.e., you have triangles that are adjacent in the mesh, but map to portions of the texture image that aren't adjacent to each other.

Finally, I have tried all of the different TileModes (I assume you mean in the CreateTextureBrush method?) and it didn't make any difference.

Thanks for your help.
Feb 20, 2014 at 8:53 PM
Ok, the link in the other thread should be a good start. I have added issue
Feb 20, 2014 at 8:57 PM

Great. Thanks.

Feb 27, 2014 at 9:06 PM
I don't mean to hijack this thread, but just wanted to say I am getting a similar problem with what are the seems I guess.

Loads fine in MeshLab, but not in Helix...

Feb 27, 2014 at 11:04 PM
Thanks for all the input regarding the OBJ importer, rogad.
I will look into the OBJ importer when refactoring it to the new PCL library (#10023). This should include a test suite of OBJ models, also including models with ´texture cracks´.
Feb 27, 2014 at 11:20 PM
No problem :)

I've been doing a fair bit of work with my models so I am starting to understand better how OBJ files work. So I just drop my observations in here when I think they are useful.
May 28, 2014 at 4:08 PM
Hello, I am experiencing similar issues with the rendering of obj textures and was wondering if any one has code fix or modifications that they are willing to share?
Feb 16, 2015 at 12:34 PM
Same problem here,

.. well its almost a year later is there a solution ?? thx

Feb 16, 2015 at 1:56 PM
Edited Feb 16, 2015 at 1:57 PM
Same problem here.
I doubt any one takes much notice of this discussion now that the project has moved. Could try asking on stack exchange?
Best we could do was reduce the visual impact of helix3D's faulty texture rendering by adding additional meshes for hair, moving seams out of view etc. Not very satisfactory.
I attempted to hack the code but didn't come up with a fix.
Please post here if you have more luck!
Feb 16, 2015 at 2:01 PM
... found an image - using a black and white checker grid texture to find areas of corruption