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

Non-deterministic UVAtlas parameterization #84

Open
sterlinglaird opened this issue Nov 4, 2022 · 4 comments
Open

Non-deterministic UVAtlas parameterization #84

sterlinglaird opened this issue Nov 4, 2022 · 4 comments
Assignees

Comments

@sterlinglaird
Copy link

I'm trying to generate repeatable UV atlases but the parameterization seems to be different every time.
Specifically, calling UVAtlasCreate() with the same inputs produces different output vertex, index, and remap buffers.

Is this expected? Or is there some other way I can ensure reproducible results?

@walbourn
Copy link
Member

walbourn commented Nov 4, 2022

The library makes use of rand for some decisions.

@sterlinglaird
Copy link
Author

@walbourn Thanks for the quick reply.
To confirm then, there is no way to force reproducible results via providing a fixed seed or otherwise?

@walbourn walbourn reopened this Nov 4, 2022
@walbourn
Copy link
Member

walbourn commented Nov 4, 2022

I modified the library from the original use of the C rand function in favor of the C++ <random> header. I currently make use of std::random_device in both isochartengine and UVAtlasRepacker.

It sounds like this is a request to add the ability to provide a specific seed as part of the API.

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

Not being able to reproduce a parameterization is a bit problematic in some cases, so having an API to provide a specific seed would be pretty useful for me and likely others. Thanks.

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

No branches or pull requests

2 participants