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

Why the number of vertices is increased? #73

Closed
Armen-J opened this issue Nov 29, 2021 · 5 comments
Closed

Why the number of vertices is increased? #73

Armen-J opened this issue Nov 29, 2021 · 5 comments
Assignees
Labels
tools Applies to uvatlastool

Comments

@Armen-J
Copy link

Armen-J commented Nov 29, 2021

When running the ".\uvatlastool.exe -wf average.obj", the number of vertices in the resulting file is increased. How can I keep it the exact same?

@walbourn
Copy link
Member

If you are getting additional vertices it's coming from the Clean needed to break bow-ties. If the model contains non-convex surfaces, it can get stuck in an infinite loop.

@Armen-J
Copy link
Author

Armen-J commented Nov 30, 2021

But another thing is that in the new .obj file even the coordinates of previous vertices are changed! And there is no way to figure out the mapping!
Let's say in the original file there are 1000 vertices and in the file created by uvatlastool there are 1050, is there any way to map between the original 1000 and their corresponding vertices in the new file?

@walbourn
Copy link
Member

walbourn commented Nov 30, 2021

The remapping information is available via the API. Sounds like I might need to add a new uvatlastool option to write out that remapping as a text file as well.

@walbourn walbourn reopened this Nov 30, 2021
@walbourn walbourn added tools Applies to uvatlastool and removed question labels Nov 30, 2021
@Armen-J
Copy link
Author

Armen-J commented Nov 30, 2021

That would be great!
Could you direct me to the file and function that provides the remapping?

@walbourn walbourn self-assigned this Nov 4, 2022
@walbourn walbourn pinned this issue Nov 4, 2022
@walbourn
Copy link
Member

walbourn commented Nov 5, 2022

Added in this commit 4a16541 a new -m option that writes out a text file of the form:

newIndex,oldIndex

That tells you for each index in the output mesh, what vertex in the original mesh did it come from.

@walbourn walbourn closed this as completed Nov 5, 2022
@walbourn walbourn unpinned this issue Nov 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tools Applies to uvatlastool
Projects
None yet
Development

No branches or pull requests

2 participants