LuxCore icon indicating copy to clipboard operation
LuxCore copied to clipboard

real adaptive subdivision

Open bestman8 opened this issue 4 years ago • 17 comments

adaptive subdivision more like cycles has. i think it will help a lot with displacement.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

bestman8 avatar Feb 14 '21 16:02 bestman8

LuxCore already has adaptive subdiv, what do you miss about it?

juangea avatar Feb 14 '21 17:02 juangea

i mean more like cycles adaptive subdivision so it is not the hole mesh but the parts closest to the camera

bestman8 avatar Feb 15 '21 13:02 bestman8

You will have to describe in more detail how this feature should work, and illustrate it with images. Or supply an example .blend file showcasing the Cycles subdivision.

Theverat avatar Feb 16 '21 11:02 Theverat

this is just a plane with adaptive subdivisions on it afbeelding here is a image of how cycles does it luxcore subdivides the whole object but with cycles it depends on where the camera/viewer is and will subdivide the objects according to that

bestman8 avatar Feb 16 '21 12:02 bestman8

a few probably better images afbeelding afbeelding

bestman8 avatar Feb 16 '21 12:02 bestman8

here is that file so you can see it your self.zip go in camera view maybe move the plane so it updates and then move out camera view to see it from above like in the last images.

bestman8 avatar Feb 16 '21 12:02 bestman8

Very interesting, do you have the same example but with the LuxCore result?

juangea avatar Feb 16 '21 14:02 juangea

i dont because i dont know how to visualize it with lux but there should the entire mesh be even

bestman8 avatar Feb 16 '21 14:02 bestman8

Actually, it is already supported:

viewscale

It is just adaptive simplification (i.e. you first uniformly subdivide and than adaptive simplify): https://forums.luxcorerender.org/viewtopic.php?f=5&t=1523

Dade916 avatar Feb 16 '21 16:02 Dade916

ah! it was the arlequin node what I was looking for to see the result :)

Dade is that the same that happens with adaptive subdivision?

I ask this becauseif subdivision is not adaptive you have to generate billions of polygons to simplify them afterwards, not sure it that's what is expected by adaptive subdivision or of a progressive subdivision would be more efficient avoiding the need to generate super big amount of geometry before.

Maybe everything happens under the hood and while we generate it in two steps the engine is just avoiding to generate the geometry that will be useless :)

juangea avatar Feb 16 '21 17:02 juangea

In my opinion, Subdiv + Simplify is a very poor substitute for real adaptive subdivision. The difference in memory requirement and compute time is immense. So I would also welcome "true adaptive subdivision" for single meshes in LuxCore.

Also, it might make sense to combine adaptive subdivision with displacement into one step, so the adaptiveness can better match the requirements of the displacement. For example, it could subdivide further in areas where the displacement texture has fine high-frequency detail, and subdivide not at all in areas where the displacement texture is uniform.

Theverat avatar Feb 16 '21 17:02 Theverat

so should i rename it to real adaptive subdivision?

bestman8 avatar Feb 16 '21 17:02 bestman8

The subdivision is done by Pixer's OpenSubdiv.

Dade916 avatar Feb 16 '21 19:02 Dade916

Mmmh then may be easy to implement true adaptive subdivision since it’s part of the Pixar OpenSubDiv library :)

https://graphics.pixar.com/opensubdiv/docs/subdivision_surfaces.html

41D37E36-5799-4A05-8C05-C3ADA8A88051

juangea avatar Feb 16 '21 20:02 juangea

@juangea, the links is for "Curvature-adaptive tessellation of B-spline surface" (see the label): it is for tessellation of parametric surfaces, it is quite different topic from the one asked by Bestman8.

Dade916 avatar Feb 17 '21 15:02 Dade916

Yeah, you are right, I just looked into it with more detail :)

juangea avatar Feb 17 '21 18:02 juangea

View Dependent Adaptive Subdivision / Tessellation would be awesome. Especially if it takes the distance of the camera into account. Found one paper about it, there are several different ones out there. This is just for example.

http://hhoppe.com/proj/vdrpm/

And if you want to get even more fancy, there's subdivision that takes features into account.

"Feature-adaptive GPU rendering of Catmull-Clark subdivision surfaces" (Theres a paper out there).

mambobanda avatar Feb 22 '21 15:02 mambobanda