So I saw Pior's cool video cap on Mudbox' litspheres here:
http://www.vimeo.com/7916648 ..it's a pretty intuitive concept but I hadn't seen this type of shader in action yet, nor did I know it was part of Mudbox and Z (was still working with Mud1 until recently).
My friend Charles Hollemeersch wrote a slim viewport shader for Max that does the same thing, it's only got 2 image inputs (normalmap + litsphere) and works for highpoly stuff as well as normal mapped lowpolies. Oh, and it's named Matballz. Download below.
Anyway, I think it'd be nice to have a thread where people can share their litspheres/matcaps (ideally with a preview image, similar to the PS brushes thread). Here's a couple I've been making.
>
Download Max shader + ballz
Quick now, post your own!
Replies
Thanks for sharing!
http://www.webreference.com/3d/lesson91/3.html
Also a suggestion. This kind of stuff works even better when coupled ith some kind of edge detection feature (fake AO/dirt in the cracks + eventually bright on the edges). Any chance your friend could add that? Since you have access to the screen normals ...
Well if not it's always doable as a post process pass in photoshop thanks to crazybump so no big deal. But it would be neat :P
Neox yup in mud its all relative to a main directional light.
Done aaaaand done. Congratulations, you won a new mac keyboard with the limited edition testicle skin.
Anyhow, really nice shader, thanks. I just love how I can preview my normalmap on flat surfaces with this shader, while actually modeling.
Edit: btw I didn't know the math would be this simple... translate the normals to worldspace, change the range and use that as sample coordinates, lol. I gotta rebuild this myself with nodes, see what it looks like in UDK or something.
you can easily crop away the second sphere if you don't want to use it for cavity masking
Pior, I'm not an expert obviously but it sounds like getting this sort of buffer info from Max isn't trivial.. Max' own viewport AO does work on top of this but it's only based on scene geometry (sample below). Generating detail AO like you say from the normals is probably tricky to get to work in realtime, so adding it in 2D may give you better results for now.
It's because you need to compare a pixel with bordering pixels, something that can only be done when sampling from UV's, which is obviously not the way to go.
In Zbrush they do everything on CPU plus they can work with vertices instead of pixels, resulting in a lot more possibilities that aren't possible with HLSL shaders.
Seems too shiny.
And a skin shader which is just a mix of some other matcaps I liked.
^ click for 512x ^
bwaha. I never had those! All I got as a binder were these:
matball:
litSphere.fx
i made spheres!
http://s000.tinyupload.com/?file_id=00375114690131554924
edit: the plasticballs look really good
dx9 material and the fx goes in the fx slot then the images in the image slots, and then drag the material onto the mesh ... kinda should work
edit: a shaderfx node for that shader was ueber awesome
also this:
http://www.pixelcg.com/blog/?p=165
now i want more of them spherers, those are interesting
that would be the way to go if you want to use it in udk.
This new version also supports alpha transparency and has a global opacity slider, although that stuff is kinda limited. Note that depth sorting in Max can lead to weird results, ie. transparent objects will completely occlude other objects if those are newer. You should also disable hardware shading and enable backface culling on transparent objects for useful results. Download link's in the first post.
but that would require geometry shaders i guess
it`s realtime so it won`t be able to render in scanline
What you could do is use mental ray.
have a standard material -> put a Environment Probe/Gray Ball material in there and just load the lightsphere map in there . then it wont show in realtime but you can render it as highres as you want
Btw great realtime shader !!
I made it so that you can set a size upto 7000 in width and height and it will save your viewport out to an image
I`ll probably adjust this one later on with some more options (maybe animation)
http://leslievdb.dommel.be/Tools-GrabViewport.rar
anyway mine just enlarges the entire viewport and saves the dib data to an image
just remembered that i made these a while back for testing in zbrush
http://rapidshare.com/files/324493404/orbz.rar.html
Just scroll up the page a bit ivaj.:)
(from what i know is retransformating the normals from tangent space to camera space so that the normal vector points to the correspondending pixel in the spheremap)
i tried to acomplish this in shaderfx but found no node supporting 3x3 matrixes and therefore im stuck
i was suggesting that since im to dumb to make it on my own