AO viewport shading

Having just aquired my copy of 3ds max (don’t worry - I am sticking with blender :yes:). I was watching a tutorial and the guys viewport seemed to have some sort of AO shading - is this possible in blender?

this will be hard to get into blender. thats soem complex coding.

Would it be hard? how about a GLSL AO shader?

Wouldn’t be too difficult to get an SSAO shader running in the viewport I don’t think. However, Blender uses some pretty archaic OpenGL for the viewport, so ideally that would get sorted out before fancy new features start getting added.

I know Jason Wilkins have suggested this as his gsoc proposal. We’ll see this tomorrow when the projects are announced.

Wow, that is one of my biggest wishes: a better view port. Unfortunately he is not proposing to do anything with how materials are viewed, because that seems like a mess sometimes. Things like AO, shadows, and procedural texture would be awsome! I think this would be the next logical step of development after cycles.

I think this would be the next logical step of development after cycles

Why? Cycles already has an interactive viewport, so trying to emulate lighting or textures badly in OpenGL seems pointless. (SS)AO in the viewport(as demonstrated in the 3dsmax video) isn’t a big deal, but I also don’t think it’s very useful for modeling, and the quality is questionable anyway.
However for sculpting a cavity shader should be added.

I’d much rather see Blenders viewport brought up to scratch in order to handle large polygon counts.

The sculpting speeds at the moment are really hit-and-miss in terms of whether or not you’ll get even close to workable frame rates.

ScreenSpace AO would probably look just fine while keeping the framerate high.

The sculpting speeds at the moment are really hit-and-miss in terms of whether or not you’ll get even close to workable frame rates.

You can work more or less comfortable up to 10+ million polygons, given the following settings:

  • Make sure to have VBOs active in OpenGL settings
  • Use Solid Mode
  • Don’t sculpt a very low-poly base mesh with many levels of multires. Apply a few levels of multires if necessary. This can improve sculpt performance in some cases.
  • If you are using a NVIDIA Fermi or newer GPU (GTX4xx,GTX5xx, possibly affects GTX680 too) make sure to disable “double sided” under Object Data->Normals (double sided lighting is not hardware accelerated on these cards anymore)

Performance does improve when you enable all those settings, true, but its obvious to me that sculpting speeds can vary a lot from one build to another and one model to another, 10 mil on one model, 7 mil on the next. and I remember some older builds that I could easily get to 14 mil w/out issues.

I think I’d rather see improved performance over eye candy.

Maybe its just me but I also see a huge performance increase when I just apply the multiresolution modifiers

Rendered draw mode isn’t fast enough a lot of the time. Also, viewport renders can be useful to quickly generate animatics and such. Unless the blender devs want to add something like Maya Hardware, we need a decent viewport renderer. (and IMO, improving the existing GLSL draw mode for the “OpenGL Render” option is a better idea than trying to add a new OpenGL renderer anyway)

to see AO in the viewport you would have to bake the AO to a texture
tutorial here:

example here:

I was actually thinking more about shadows, because being able to see those would be really useful in lighting and things. Being able to set up lighting in the viewport would be very nice. The cycles render view is not fast enough and does not give all of the things in the 3d view. (highlighting selected objects, transformation tools, edit mode, ect…)

I know this is slightly unrelated, but the texture and material view seems like a huge mess sometimes.

AO would be nice, but it is really not essential. I guess I was thinking about shadows.

shadows are already possible using GLSL… (could be improved though)

Only spotlight works with shadows but its easy enough to set up a basic lighting using GLSL, with experience that’s all you need, if that.

Being able to set up lighting in the viewport would be very nice. The cycles render view is not fast enough and does not give all of the things in the 3d view. (highlighting selected objects, transformation tools, edit mode, ect…)

I can’t think of a really good way to properly reproduce lighting in OpenGL. Maybe with VPLs like in Mitsuba. I don’t think the viewport rendering in cycles is too slow, not on my PC anyway. If you need selection, just have different viewport to move objects around.

Have you tried the harmony build, you can get sun shadows with that. I’ve been quite impressed with the performance of it as well. It’s probably possible for someone to implement one of the glsl filters that gives ssao in the game engine, to run fully on the viewport.

I dont really think I would use this function much though. Its fine using the ssao filters just in the game engine, I feel that it would be a bit of a novelty feature. Theres many other things I would like to have implemented before this sort of feature, but thats just me.

It would be amazing to have an OpenGL preview like the one in Mitsuba available in Blender. I’ve gotten better near-real time results from Mitsuba preview than I have from BI even.

SSAO is a decent effect in games, but honestly don’t see much of it’s use in the veiwport. It’s a really odd shader that doesn’t always look all that good.