Taira2032 wrote:...
(part 1)
Then, recently i found
this tool, and its pretty neat for merging meshes ..
Now, the newly merged meshes of course produce one render group and one texture.
...
Ok, I can always splat a grid of numbers on the diffuse map and just edit and fix and mix and match in photoshop until it fits.
...
...
(part 2)
So.. is there a way to see how a texture (the diffuse maps) is mapped on a mesh?. ..
...
I tried exporting those UV map thingies but I think that concerns the meshes rather than what goes where on the texture.
...
XNAaraL wrote:...
True, it would be much easier if you was actually showing what you trying to do
![Idea :idea:](./images/smilies/icon_idea.gif)
(show me the goal ... not your "presumed" way).
...
Since you haven't describe what your goal is, I have to use my crystal ball and guess it (something I hate very much).
But first a few notes:
I have never used Zareef's tool. So I don't know if it makes his job good or bad.
I know that this tools allow to merge meshes, but "merging meshes" is a completely useless function in my opinion. That is why this option is not available in XPS. Merging models has an advantage (all parts can be loaded at once), but merging meshes has no advantage, only disadvantages. So why would anyone want to do it? Confused.
--- A merged mesh dont needs less memory than two meshes
--- A merged mesh will not be rendered faster than two meshes
--- Tell me just one advantage. I don't know of any advantage
--- Merged meshes of course can only have one render group (shader). That's a disadvantage
However, if the function to merge meshes is well done, then the UV map and textures shouldn't be a problem. Such a function (albeit useless) is easy to implement.
Part 1
Suppose you have a model that contains two meshes. The eyebrows and the eyelashes:
![Image](https://nsa40.casimages.com/img/2020/05/16/200516104400516568.jpg)
Each mesh has his own uv-map (part of the vertex description) and a texture (image):
eyelash
eyebrow
Now we merge both parts (both meshes have textures with a resolution 512x512 pixel)
+++ The x (u) coordinate from the first mesh (eyelash) will be divided by 2 (u = x
1 / 2.0)
+++ The x (u) coordinate from the second mesh (eyebrow) will be divided by 2 and added by 0.5 (u = x
2 / 2.0 + 0.5)
+++ The textures from both meshes a combined (first texture left ... second texture on the right side) x = x
1 ; x = x
2 / image
2x_resolution * image
1x_resolution + image
1x_resolution
Result (resolution 512x1024
![Image](https://nsa40.casimages.com/img/2020/05/16/200516104359697418.jpg)
+++ Textures should be powers of two because many older graphical cards still require it. The reason for that restriction was so that they could perform some optimizations to the texture mapping operations. Most modern graphic cards don't have this restriction either.
+++ So we rescale the texture:
Ok, there is no needs to splat a grid of numbers on the diffuse map and just edit and fix and mix and match in photoshop until it fits.
If the tool works good, there is nothing to do:
Part 2
"So.. is there a way to see how a texture (the diffuse maps) is mapped on a mesh?."
Yes.
"
Modify-->Save UV Face Layout"
...
"I tried exporting those UV map thingies but I think that concerns the meshes rather than what goes where on the texture."
Wrong.
Blender 3D: Noob to Pro/UV Map Basics - Wikibooks, open books
UV mapping is a technique used to "wrap" a 2D image texture onto a 3D mesh. "U" and "V" are the names of the axes of a plane, since "X", "Y" and "Z" are used for the coordinates in the 3D space.
UV mapping
UV mapping is the 3D modelling process of projecting a 2D image to a 3D model's surface for texture mapping. The letters "U" and "V" denote the axes of the 2D texture because "X", "Y", and "Z" are already used to denote the axes of the 3D object in model space, while "W" (in addition to XYZ) is used in calculating quaternion rotations, a common operation in computer graphics.
Textures
In order to map a texture to the triangle we need to tell each vertex of the triangle which part of the texture it corresponds to. Each vertex should thus have a texture coordinate associated with them that specifies what part of the texture image to sample from.
Texture coordinates range from 0 to 1 in the x and y axis (remember that we use 2D texture images). Retrieving the texture color using texture coordinates is called sampling.
In OpenGL, texture coordinates start at (0,0) for the lower left corner of a texture image to (1,1) for the upper right corner of a texture image.
In DirectX (XPS use DirectX) texture coordinates start at (0,0) for the upper left corner of a texture image to (1,1) for the lower right corner of a texture image.
![Image](https://nsa40.casimages.com/img/2020/05/16/200516010121261841.jpg)