Blender 3.0 OpenSubdiv development

It is definitely not a UI thing. This will require quite a few tricky things to do, so I decided to postpone it until the GPU acceleration part is done.

2 Likes

The way it works in Maya just for general fyi is the object property is not true subdivision. It is display only. Yes it renders. But to add proper subdivision you do so by adding a Subdivision Proxy. This is a node hook up. So in effect not an object property. And having a modifier in Blender is akin to this as I see it.

Also I think modifiers are superior. Better would be a Use Nodes for all modifiers and allow the same flexible workflow as materials.

The modifier is not going to be removed when the subdivision properties are part of the Mesh datablock. This was mentioned already in various threads (maybe you don’t know about that).

2 Likes

No I did not know that.

But it was not the intent of my comment.

It is the nature of the difference between the two in Maya and considering it is the likely reason people are asking for it. Just as it exists in Maya. But in Maya it is not the same thing at all.

So then it begs the question is how is this going to work?

And then considering the time spent do implement it, what is the trade off?

Do we really need it as an object property and as a Modifier?

If the reason is to have it “like in other apps” then I say no.

I say that mostly because the Maya implementation is not true subdivision in Object properties.

Disclaimer. I am a Maya user for many years and I see a ton of things would want in Blender. So that is not a fanboy comment. Just saying.

More if an FYI than anything. For the purpose of evaluation of user request.

@KWD It looks like you did not make a new build with the crash fixes.

If that would still be possible it would make testing with more files/rigs a lot more feasible. :+1:

If you’d prefer to wait with releasing a new build untill some performance improvements are in I can understand that as well and will wait (im)patiently. :wink:

The idea behind making subdivision settings as part of the Mesh datablock is to simplify and streamline some areas like normals, and I/O (Alembic and USD have native subdivision primitive). Although it is mostly a rendering thing, it should also work for scattering hair or snapping to the right location. A task was created on the developer website to follow development and discuss design. So it is like in Maya in the sense that you don’t have to add a modifier, but it should behave like it. We do not look forward copying what other software are doing.

Buildbot is working on it now, should take ~1h.

4 Likes

Thanks Kevin! :+1:

If you’re referring to me, that wasn’t my intent. I personally look forward to having unambiguous speedup caused by subdivision always happening last, as well as getting rid of this extra check when iterating through objects (“does object have subsurf? if yes then…”)

@KWD ok thanks !

1 Like

Alright new builds are available:

Linux
MacOS ARM
MacOS Intel
Windows

Change Log:

  • Fix crash when going into/opening a file in pose mode
  • Fix crash when adding a modifier after a subdivision modifier
  • Added an evaluator cache, which fixes most of the bad performance
  • Partial fix for drawing outline overlay in X-Ray mode, all edges are included so it looks like wireframe, I need to figure this out
  • Wireframes take factor into account (when smooth shading is used)
12 Likes

I have not followed everything very closely. So I was not trying to single anyone out.

Just a general comment.

1 Like

Thanks for the great work!
Just found another bottleneck:
Adding UV Maps decreases performances. To reproduce it, jut add a UV Map with default blank coordinates, by simply clicking the + button in the UV Maps panel. There is already a slight decrease in Blender 3.0, but it get really more noticeable with the subdiv branch. Since it’s quite common to use two UV Maps, would be quite interesting if this bottleneck can be solved.

Using the soldier test case I sent you earlier:

[Char 1 - Soldier]
Blender 3.0, subdiv level 1

  • One UVMap: 29 fps
  • Two UVMaps: 27 fps (-2)
  • Three UVMaps: 25 fps (-4)

Subdiv branch, subdiv level 1

  • One UVMap: 60 fps
  • Two UVMaps: 45 fps (-15)
  • Three UVMaps: 33 fps (-27)
11 Likes

I don’t think anyone is or should be insinuating like “Here look here, 3DS or Maya have this. Make it like they did it. If they can do it why can’t you?”

I don’t think that was the intent in those past recent comments. If you guys can develop a way of delivering the same performance as those companies through a different way or similar tech design. That’s awesome. Honestly I would love nothing more than to see that.

That’s coming from a person who is in industry and I use Maya and Blender, but Maya… not by direct choice. (if I could put Maya away and never touch it again I would. It has many over looked short comings over the years and Autodesk doesn’t care)

I use Blender in tandem with Maya (blender as a filtering / touch up suite for my models for what Maya lacks in like smoothing groups / weighted normal control) but the subdiv modelling performance is very poor. Borderline unusable in practical applications for medium to high advanced assets.

I guess what I am saying is, no one is saying copy them. Do it your guys way for sure. But if that fails, there is no shame in seeing how they do it and implementing it yourselves cause in my opinion Blender has giants like Maya and 3ds bested in so many ways, but this is blenders like… Last major weakness in my opinion. This is what stops me from being a full fledged no looking back Blender fanatic.

Keep up the great work, and I can’t wait to see blender with full functioning Subd that is on par with the current industry standard.

3 Likes

Thanks for pointing those things out. It saved me a lot of typing…lol

Because I tried to say basically the same thing with less words.

So here again concisely what I mean. And I hope it is not misinterpreted. And it certainly is not meant to spark debate.

I was sending a general message to development and others in general that if - and it just so happens it usually is - it was a request that came from a Maya user such as myself, that putting subdivision in Maya at the object level is nothing more than a preview with some features. But it is not the same as adding a Subvidision Proxi which contains all of the features including the ability to apply on export which you can not do with it added to the object properties.

So that perhaps when asking for a Subsurf at the Object level “Because Maya has it” it is not understood that Maya actually dies not have this feature. It is just a preview of the effect.

So…

In effect a Developer is being asked to spend time doing something for the wrong reason.

Do we really need to add true subdivision at the object level?

I say it is not worth it. This is coming from a person who actually uses Maya, enjoys using Maya, would love to see features from Maya in Blender.

But not this. I see no practical advantage. I don’t even like that it is a preview only in Maya.

But… That is all just FYI and my opinion.

Please don’t debate anything other than is this feature really necessary or not. And what are the advantages?

If your answer is “well Maya has it and I find it useful”, understand Maya does not actually have this. That is all.

1 Like

Alright quick little status update.

No more crashes! I could open every rig i’ve collected over the years (including some really old ones) and they all open and work just fine. :+1:

The performance is most notable with lighter rigs. Take the “min” rig from Glass Half for example. She becomes a pleasure to pose with a few subdiv levels in the subdiv branch.

If you take Rain v2 instead the performance increases are almost negligible. I think(?) its because the rig is quite taxing in and of itself. If I set the framerate really high and animate some simple movements with subdiv off I get around 30fps. If I turn on subdiv by hand for some geometry it dips below 20fps on my system.

I feel this is a combination of a more taxing rig to begin with and slightly higher res meshes overall. Its disappointing but I don’t know if its realistic to expect it to do better?

I also tried it with the Jim rig (paid): https://www.youtube.com/watch?v=CI3lmEGpnHM It was pretty much the same story. I even went so far as to delete all uv maps and shape keys from the geo and it did not make much (if any) of a difference.

4 Likes

If I simply open this file and try to pose, I got a message in the console: “Cannot evaluate subdivision on the GPU, falling back to the regular draw code.” Do you also have such a message? It would appear that there are some drivers turning off subdivision in the viewport.

I do get the same message! I was unaware of it.

With that said I did delete the drivers from the subdiv modifiers so I could test it properly. There is a control in the cloudrig ui but it turns on other modifiers as well. So to get a somewhat clear comparision between subdiv turned on and off I just set the values by hand.

I gotta say I am surprised of the message. Why should drivers controlling the subdivision surface modifier have any effect on gpu acceleration if the modifier is last in the stack? :sweat_smile: It is very common for rigs to have subdiv levels set through drivers (or viewport visibility).

1 Like

Well, we do not do subdivision (CPU or GPU) if the modifier is disabled. Then I would expect with GPU acceleration that people will disable less often the subsurf modifier.

That is the intention yes. :slight_smile: I was just confused by the error message. Its more of a notification that the modifiers vp display is turned of then that something is wrong.

Just for clarity I quickly repeated my test from yesterday. I removed all drivers controlling viewport visibility from subsurf modifiers and set them to be shown. Animated a simple loop with the hips moving in a circular fashion.

Latest subdiv branch: 8-9fps

Blender 3.0 alpha from 2021-07-13: 5-6fps

Thats with 1 level of subdivision. Like I said before, perhaps this is the best we can expect, I honestly don’t know. But this is what im getting currently with Rain v2. :man_shrugging:

For completeness sake. If I turn off subdivision surfaces with my tweaked testfile (so all subsurf modifiers on, visible and set to 1) and use simplify to force the level to 0 for all subsurf modifiers im looking at ~30 fps.

So it looks like opensubdiv, even accelerated, is currently still really taxing.

If it helps here is my system info generated from blender:

system-info.txt (25.3 KB)

I noticed that this new implementation uses more CPU power than 2.79, is that normal?

How are things going @KWD? :slightly_smiling_face:

Would love to get a little update, even if its a one liner. Lets keep this thread alive and visible. :+1: