Attempting to apply a Texture Atlas texture map to an exported OBJ mesh
redeyedrobot
Posts: 2
I have no idea what I am doing and ergo no idea what is really going wrong - I'm hoping someone just recognizes this as a common problem and knows what to do to fix it:
I'm creating a Texture Atlas from a model, then exporting that model as an OBJ, then loading that OBJ into Tabletop Simulator and attempting to apply the Texture Atlas PNG as a diffuse map.
After being applied, it looks like what is shown in the attachment.
Does anyone understand what is happening and/or how to fix it?
Screenshot from 2024-09-18 00-54-54.png
1920 x 1080 - 2M
Comments
Can you get a UV view of the exported OBJ? It looks as if it is still using the base UVs.
when you say "im creating a texture atlas from a model" what does that mean?
I am using the term Texture Atlas to describe a single image that is used as texture map for multiple different objects. You have one object shown.
How does one "create a texture atlas from a model" ? A texture is an image, a model is a model...
I mean, clearly your UV does not match your texture map.
DS has the ability to create a texture atlas. You simply select all the surfaces you want atlased, how you want the tiles laid out, texture size, etc. and it creates a new UV and generates the maps for you.
exporting you need to make sure that UV is selected in surfaces too
I have made to mistake of just exporting without checking and after closing D|S that UV is gone and may not be generated the same next attempt (though of course you also get a new atlassed texture too another go) just saving the scene is insufficient
Oh, never noticed that option inside daz. I suppose this is useful, though wonder if the default Single UDIM uv option to g9 combined with texture transfer might be better, since it already puts things into relatively optimised position.
It's not really about optimized position. I got familiar with texture atlas when I found out that I had no ability to apply textures to individual surfaces on a crowd agent in Houdini, so I had to re-export all my figures atlased. It's also about optimizing texture size. A G8 figure has 7-8 different surfaces that need maps, plus however many the clothes, hair etc. use, and those can really add up, especially if they're all 4K. With an atlas, you can cram all of those into a single set of maps, and for a background character you might even want to further reduce resolution.
If you successfully created atlas texture, the UV set on all figure's surface would be auto-set as sort of "Atals xxx", then export to OBJ with options of Write Surface + Mat Lib. Then at least you can have diffuse map assigned after importing into that simulator.
Well, I don't have Tabletop Simulator but most of the time I use atlas maps in Faceform Wrap and Blender, there's been no issue at all. So you can always firstly import OBJ into Blender to check if it works well. If it does, it should work well in other 3D app.
If the issue still persists, you better ask for the support from Tabletop Simulator.
*smiles very, very stupidly*
...I have no idea what a UV is. (:
But! Even just knowing that the UV is wrong, though I don't know that is, is still very helpful as a starting point to figuring out what I am even doing. Thanks!
A UV map tells the program which pixels of a texture map should be applied to which polygons on the mesh. In DS, you can click the dropdown menu at the top of your viewport that probably says "Perspective View" and select UV view instead to see the UVs of whichever surface(s) are currently selected.
OMG
OMG THIS WORKED
All I had to do was make the Texture Atlas first AND THEN do the OBJ export. I was doing it the other way around because my model looked weird after making the Texture Atlas.
THANK YOU!
...I need to learn more about these things. x.x
Oh, that was great ! Yea, order of the steps is important in most of the cases.
UV is actually UVW but since it's a 2D image not an obj the W is usually dropped
it's the 2D equivalent of XYZ, the co-ordinates of a 3D object in space onn a 3D chart (a box with an XYZ axis with values along the 3 front sides mirrored on the other 3 for the points/vertices that make up the model)
a UV graph is a regular flat square showing the obj unwrapped like an Easter Egg or Christmas Santa chocolate wrapper or a dress pattern, it doesn't have co-ordinates as such, it really is more of a grid of squares equivalent to the faces of the obj with the bits of the picture appearing on the obj where the squares match which is entirely arbitrary depending on how it is unwrapped.
This is why you need to export the obj after atlassing, it writes the UV co-ordinates in the obj file which you can actually see in notepad ++ as a huge list of paired numbers alomg with the sets of 3 XYZ co-ordinates
if you watch cosplay garment creation videos you can get an idea how UV mapping works, they wrap the person in cling wrap then use masking tape creating a template they can then draw where the cuts (unwrapping guides) will be, then cut it off along those lines with a scissors, lay it the most optimal way on the fabric, pin and cut it out, that fabric layout is the equivalent to your texture UV square
I hope this made it simpler not more complicated to understand
my personal introduction to UV mapping was in fact having it described as a clothing pattern, as a sewer it immediately made sense and fortunately the first time back in 2009 I ever saw one it was called a U,V,W, template
otherwise I might of thought what the F does Ultraviolet have to do with modeling