-
Notifications
You must be signed in to change notification settings - Fork 1
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
Use octee for normals and uvs seperatly #32
base: master
Are you sure you want to change the base?
Use octee for normals and uvs seperatly #32
Conversation
p.s the reason its a draft is because I cannot seem to get the terrain example to run, not quite sure why but it just hangs infinitly. Thought I'd post it here though for comments though while I work out why. |
Also one thing that will be cool is to run the benchmark to see how this PR performs against master, you can go to the gaiku-3d crate and run there
** I saw sometimes a difference of 2% between runs. |
Ah fixed :) Also can we get #31 merged so we can remove these lines in the texture |
Running benches now |
Here are the benches, mine are a lot slower than your as my mac is not that fast
Change here is relative to this PR, improved results here means master is faster
Seems to be slower :(, which is a shame because I like this implementation as it dosen't treat the uvs and normals as anything special just as another set of data to cache |
I am beginning to wonder if the benchmarks I made here are accurate. I cannot seem to get a consistent timing on my machine even when I run the same bench mark twice in a row with no changes it will have +-50% change |
I get usually single digit % diff between runs. |
This PR applies some of the features discussed in #27 namely using an octree for normals and uv coordinates and caching them in separate tables.
This is currently just during baking and it is converted to the same list of verts and normals as before during the
Meshify::build
step. But in future we could make obj like that exported in blender using the separate tables.This reduces the number of normals and uvs kept in memory during caching as most normals and uvs are duplicates