Will Timmins' Procedural Shaders

Oso3DOso3D Posts: 14,345

So my initial free pack is here: http://www.sharecg.com/v/83593/view/7/Material-and-Shader/Will-Timmins-Procedural-Shaders

And I'm working on a much-improved version (some with top coat, lots of presets to make life easier, etc.)

 

I thought I'd start a thread for any questions people might have about the shaders.

 

 

The format of the shaders is a little confusing (one thing I'll improve).

The Base shaders are the root shaders that the other presets use. The terms after 'Base' are what the noise affects.

So, for example, WTP Base Bump means that there are noise parameters for Bump. WTP Base BumpCutout means that there are noise parameters for Bump and Cutout Opacity.

Ideally, use the simplest shader that covers what you are interested in, because each extra set of parameters slows down the render slightly.

 

With the second set I'm working on, it will be more explicit, with a subfolder of 'base shaders' and then subfolders for things like Ground, Skin, Skydome, etc. Also new shaders like WTP Emission and WTP Refraction.

 

Random thoughts:

With Base Color, you can generate very subtle variations in color that can make something look more realistic. The key is to use colors that are VERY similar; maybe one color is slightly less saturated and lighter. The Skin presets do this, so that there is a slightly uneven look to it.

For some reason, Bump scale is 100x the scale of other noise. So if your color is set to 10/10/10 tiling, and you want bump that matches it, bump tiling should be .1/.1/.1. Remember higher tiling means smaller details.

Bump noise can replace Roughness. It's interesting to reflect on the fact that's what Roughness essentially _is_. If you make a mirror shader, then have bump noise with a reasonably high tiling, it looks like you've increased Roughness. (Mind you, there's not much reason to DO this, but it's neat)

If you have a surface you like but want to add noise to it, copy the surface, apply the WTP shader, then paste the surface on top. You have thus created a noise version of your original surface. For example, if you want to turn a tapestry into a moth-eaten tapestry, you can copy the surface, apply WTP Base Cutout, paste the surface back, and then adjust Cutout parameters.

Channels for noise parameters uses the convention of: regular channel, secondary channel. So WTP Base Color uses 'Base Color' like normal, and then has Secondary Base Color for a second color. The noise generates a pattern between the first and second channels. The primary channel retains mapping! So in the tapestry example, if the tapestry also has a Cutout Opacity Map, the map is preserved in the primary channel and then combines that with the Secondary Cutout Opacity.

 

Any questions?

 

«13456

Comments

  • JimbowJimbow Posts: 556

    Thanks for the detailed explanation, Will.

  • srieschsriesch Posts: 4,213

    Just out of curiosity, any plans for a similar 3DL set?

  • Oso3DOso3D Posts: 14,345

    I've thought about it. There's less 'need' and a lot more competition... might try it at some point.

    One possible upside is that Displacement noise might work a lot better in 3DL, which is intriguing.

     

  • kaotkblisskaotkbliss Posts: 2,889

    I ended up using your first set of shaders on the hyperian bar. I wasn't quite sure how the base and top worked so I ended up using the base on the actual mesh, then added a geoshell and used the top on that. Worked fine and looked great although every time I use a geoshell it slows the rnder down considerably. Did I do this correctly, or should I have done it differently?

    Anyways, I plan on adding this set to my collection as well :) Great job!

  • Oso3DOso3D Posts: 14,345

    With geoshells you have the ability to make one surface (the rust spots) radically different than the other (metal). In particular, you can make the rust spots more rough and give it its own mottled appearance.

    However, you could probably swing it with ColorBump, if the metal is pretty simple. Just not completely sure if the bumpy pits would be rough enough to look like rust.

    With ColorBump, Color should have thresholds that are close together. This makes the transition more distinct between regular metal surface and rust color (orange, I'd assume).

    With Bump, you want something like Bump Upper Threshold .5, Bump Lower Threshold 0. This basically 'flattens' about half of the surface.

    You then want the parameters to match, with Bump tiling 1/100 of Color tiling. So, say, Base Color Tiling 10/10/10, Bump Tiling .1/.1/.1.

     

    Oh, a note about tiling; it's based on universal coordinates. You can otherwise flatten or pull the pattern by setting tiling differently. For example, 10/2/10 would make the texture pulled vertically. However, if you rotate the object, the pattern remains oriented based on the world grid.

    This can be a bug or feature, depending on what you want...

     

  • grinch2901grinch2901 Posts: 1,217

    So my initial free pack is here: http://www.sharecg.com/v/83593/view/7/Material-and-Shader/Will-Timmins-Procedural-Shaders

    And I'm working on a much-improved version (some with top coat, lots of presets to make life easier, etc.)

    I've used your freebie set and got some nice effects but wasn't able to achive the sorts of things I've seen you do with them. This was clearly operator error on my pary and I appreciate the clarification on your naming conventions.  Big help. Will go back and do some more experiments.

    I'm also really curious what sort of effects you are able to acheive in your updated set, if you care to share a preview or two. 

  • Oso3DOso3D Posts: 14,345

    Sure, and yeah, I really have to write better tutorials. Among other things, I think I need to list all the presets and have comments on using each, how to tweak each.

    New set should be organized a lot better, and have more options you can start with.

    Oh, another tip: it's VERY USEFUL to type in the noise you are working with in the surface tab, so you can see relevant parameters. For example, if you are using WTP Base Cutout, typing 'cutout' in the surface tab will show you Cutout Opacity, Secondary Cutout Opacity, Cutout Tiling, Cutout Levels, Cutout Billowing Appearance, and the thresholds. This can be even more handy if there are more than one noise types, so you can distinguish one from the other, or look at 'tiling' to match up tiling.

    As for changes from WTP > WTP2, one biggie is having some shaders with Top Coat. See, the Uber Iray shader does some fancy code stuff such that if you don't use something, it drops it from what the renderer sees. So if Top Coat Weight is 0, all the top coat code goes away.

    I didn't realize that, so when I sucked in the Uber Iray, it was missing some stuff. Oops.

    Now, granted, not having top coat is faster, which is handy if you aren't using it.

    Also adding WTP Refraction (for cool translucent options) and Emission. Now, you can do, say, stars with cutout, but it can be slower than an object with dots that glow.

     

    The skin effects I'm getting with WTP2 are a lot better, partly because of more experience, and also opening up Top Coat.

    Another addition is opening access to Rotation. I had hidden that mainly to not overwhelm users, but with brushed steel and wood, it seemed worth adding as options.

    So there's WTP Base ColorBump (noise pattern Base Color and Bump), but also WTP Base ColorBump Top (adds Top Coat) and WTP Base ColorBump TopRot (and then Rotation).

    There are certain materials that make a lot of use of Top Coat, so this will help users handle them.

     

    Here's an example. The wood has been oriented a bit with Rotation, the bark as well. I toyed with using a WTP shader for the fire, but this is a case where using maps was just obviously better.

    The crystal uses WTP Emission, though it probably wasn't worth bothering. However, I'm REALLY happy with the WTP Star preset.

     

    WTP2 Campfire.png
    1748 x 1080 - 3M
  • Yes. Please do a 3DL version. Some of us can't use IRay because of the limitations of our machines. 

  • Oso3DOso3D Posts: 14,345

    I've managed to make some decent clothing/leather shaders (some in previous image), but it's hard to beat a really good 'weave' bump map.

    Here's more clothing, some metals, and a cloud preset that turned out very nicely. I attempted to use the same cloud preset with the campfire image but it just wouldn't work right; I suspect I need to use emission or something.

    The lower front bits use a bronze preset I'm very happy with.

     

    WTP2 Golden Hills.png
    1920 x 960 - 3M
  • Oso3DOso3D Posts: 14,345

    I've been working a lot on organic and nature stuff, because those are the most challenging, but WTP Base Bump is a great way to add some subtle wear/unevenness to lots and lots of metal or stone stuff you may have already.

    Repeating, if you want to add noise pattern to an existing surface, copy the surface, apply the shader, then paste your stuff back. So if you have, say, a giant robot, you can create bump noise to make it 'dinged up.' (Or you can do rust spots with a geoshell layer)

    Here's the Brushed Aluminum golem that convinced me to add rotation. The pattern on its head is rotated to bullseye around the hole. The other bits are also moved a little, although you run into problems if multiple parts share a surface. For example, the right and left limbs share materials, so I couldn't adjust the pattern on each side differently. Ah well.

    Due to updated shaders, I was able to copy in Mec4D's Aluminum shader, and then add the brushed Bump noise.

     

    Aluminum Golem.png
    1080 x 1080 - 6M
  • Oso3DOso3D Posts: 14,345
    edited August 2016

    Here's my best effort with skin so far. The freckles are on a geoshell, giving people the option to have tightly defined freckles, more diffuse spots, change scale, etc. You could make a scattering of ColorBump moles, then lots of lighter freckles, and so on.

    For subtle lips, I found it only necessary to tweak SSS reflectance and transmitted color a little, and to adjust gloss/top coat.

    The overall approach to skin, btw, is informed by various discussions. Basically, all regular non-metal objects should have glossy color/top coat color of pure white, and a total weight of 1. Roughness should govern, basically, how much you see highlights.

    My approach is to use a very high roughness Glossy with a lot of weight (.9), and then a little bit of Top Coat (weight .1) with a roughness around .3. If I want sweatier/glossier skin, I can just change the weights to 'lean' toward more the shiny top coat.

    For lips, I did this plus I made the roughness around .2 and upped the Glossy reflectivity. So, generally more lustrous moist-looking lips.

     

    Another thing I need to experiment with is using makeup. I have Skin Overlay, and I can use the maps to create, say, blush and eyeshadow geoshells to give more variation to the character's skin.

    For fingernails, I like using car paint as nail polish, but for 'real nails' I created a skin preset based on the regular skin preset, just without bump and slightly less saturated coloring, and more shine.

    Oh, I did end up using a bump map for the floorboards and for the clothing. I have some decent clothing presets, but there are a number of cases where you really should just use a map. Same with eyes and hair. Everything else, though...

     

    WTP2 Fair Maiden.png
    1748 x 1080 - 2M
    Post edited by Oso3D on
  • Oso3DOso3D Posts: 14,345

    Added lip color from the Kyokyo skin on a geoshell, and cheek blush from Skin Builder mask.

     

    WTP2 Kyokyo.png
    1080 x 1080 - 1M
  • grinch2901grinch2901 Posts: 1,217
    edited August 2016

    Will, Is that last one also a procedurally generated skin? No textures other than the geoshell stuff?  If so that's really good!  The added color really helps "sell" it.  I'd love to see the older woman updated with that added touch.

    Post edited by grinch2901 on
  • Oso3DOso3D Posts: 14,345
    The skin is procedural with lip color and blush added on top on geoshells, yes. The freckles are added with a second geoshell. The Kyokyo skin has a useful lip mask. For lip/blush, it's at about 30% opacity so it blends nicely.
  • Oso3DOso3D Posts: 14,345

    Here's another. Eyeshadow and lip masks. Hair and eyes are mapped, everything else is WTP.

     

    WTP2 Brandon.png
    1080 x 1080 - 2M
  • Oso3DOso3D Posts: 14,345

    Here's previous character in closeup with makeup. Not sure the procedural holds up to stuff this close, but not bad...

     

    WTP2 Fair Maiden Closeup.png
    1748 x 1080 - 3M
  • Oso3DOso3D Posts: 14,345

    Another tip (and this is useful even if you don't use my shaders):

    If you want to combine my Bump noise with some of the original bump of the surface, I recommend using Photoshop or http://cpetry.github.io/NormalMap-Online/ to convert the original Bump map into a Normal map, and then just plug that in.

    For one thing, Normal maps often look better than Bump anyway (which is where the 'even if you don't use my shaders' comes in).

    Ideally, things like floorboards and rock walls 'should' be modeled as highly defined models. But almost all the content you are likely to encounter will be relying on texture maps to give surfaces critical definition.

     

  • Oso3DOso3D Posts: 14,345

    It's often useful to set colors to very different shades so you can work out the pattern you want, then change them to subtly different shades. Unless, of course, you want a vivid pattern.

    For similar reasons, if you have something like stars, where the threshold is very low (to get just little pinpricks), you might want to set the threshold at .5 or something so you can see roughly how the pattern is distributed, then once you have it as you want, drop the threshold until it looks right. Stars, for example, reduce one channel to juuuust the peaks, so you get a bunch of blank space and then little dots. But it can take some dialing to make sure the scale is right.

    If the object looks weirdly faceted despite being a good model, and you are using Bump noise, set Bump to 0 and see if it goes away. If it does, then try setting Bump to a very low number and adjust until it looks right. You also might want to change the tiling (scale) to lower numbers.

    If the tiling is imbalanced so the pattern 'stretches,' but it doesn't look right, try swapping some numbers around. Like, for example, I have some wood textures that are elongated along the Y dimension. I was confused why it looked weird on floorboards until I went... duh, I'm looking at the 'top' of the pattern. I swapped Y and X tiling and it looked perfect.

    Try changing scale up and down to make sure you have the effect you want. You're going to have to change tiling when going between different models, because their inherent scale will differ. For example, something that looks great on a sphere primitive will probably need tiling about 4x on a human figure.

     

  • Oso3DOso3D Posts: 14,345

    In this image, I use normals for the stone wall and floorboards, as mentioned earlier.

    Otherwise everything is procedural.

    The Alien Statue makes use of my new Refractions noise shader.

    In the upper right you can see the problem with material zones; the beams and rafters are all one surface zone, so the vertical orientation of the shader looks good on beams, not good on rafters. Mind you, you can go into the geometry editor, select all the polygons of the rafters and create a new surface.

    WTP2 Hall of Relics.png
    1748 x 1080 - 3M
  • JimbowJimbow Posts: 556

    Is there a voronoi noise function? If you had that option, you could mimic skin cells and leather really nicely (not that your skin's bad, but I think you know what I mean...).

  • Oso3DOso3D Posts: 14,345

    There's a Worley noise function, which I'm thinking of doing to capture certain effects that are difficult. For one thing, I think I might be able to pull off Iris shaders if I have something that will actually follow a UV map (Worley brick applies to UV map, Perlin brick does not).

    There's a 3DL brick for Voronoi, but alas, not for Iray (at least, that I can see -- the functionality of the brickyard in DS is godawful. There's no search filter. !!)

    I had originally made elaborate codey shaders that would let you blend Perlin 1, Perlin 2, and Worley, and then apply it to a bunch of different things. But something broke when I transferred to a new computer... and, frankly, the shaders were sluggish.

     

    Anyway, so I finally got around to doing dark skin. I was nervous that I wouldn't be able to pull it off well, but either because of how dark skin works or because I had worked out most of the kinks already, it wasn't hard at all, and I'm very pleased with the results. I'm astonished at how well the nails came out.

    Again, only eyes and hair have maps.

     

     

    WTP2 Tamara.png
    1080 x 1080 - 1M
  • JimbowJimbow Posts: 556

    Looks good.

  • grinch2901grinch2901 Posts: 1,217

    This skin is really good across the board, Will. As you've said, for close ups nothing beats a good texture but for characters a little further from the camera the ability to use something that isnt texture based yet doesnt look like a manequin would be a real benefit for those struggling to render Iray with 2GB cards.  I could see myself using that a lot.  And I agree, the nails on your last render look really good.

  • Oso3DOso3D Posts: 14,345
    edited August 2016

    Even if you only use procedurals for architecture, that can SERIOUSLY thin out the glut of textures.

    There are some wonderful environments that have dozens and dozens of high quality textures. Add in a bunch of characters... yeek!

    I adore Winter Hall, for example, but I find it impossible to render in Iray on my machine. Just too much stuff.

     

    Post edited by Oso3D on
  • Oso3DOso3D Posts: 14,345

    The light skin seemed a bit overly pink for some models, so worked on a more pale look. Also age spots.

     

    WTP2 Old Man.png
    1080 x 1080 - 1M
  • SaphirewildSaphirewild Posts: 5,747

    Wow I think your shaders are looking great Will!! I do wish you would make some for 3Delight in the future though, like Tramp said IRay is taxing on my computer as well.

  • Oso3DOso3D Posts: 14,345
    Well, one of the upsides of this approach is that it can drastically reduce memory required so a scene can fit on much lower end cards. I tentatively plan on a third set of WTP (with Worley noise), and then maybe a 3dl set.
  • SaphirewildSaphirewild Posts: 5,747

    I will be looking forward to the 3DL ones for sure

  • Oso3DOso3D Posts: 14,345
    edited August 2016

    What's nice is that I THINK I'll be able to do noise Displacement in 3DL, which should make for some odd objects.

    The problem I run into is that I'd love to have, say, the code for UberSurface and make noise with that. But... I can't. So it'd have to be based on Daz core shader. Mmm.

     

    Post edited by Oso3D on
  • vwranglervwrangler Posts: 4,262

    What's nice is that I THINK I'll be able to do noise Displacement in 3DL, which should make for some odd objects.

    The problem I run into is that I'd love to have, say, the code for UberSurface and make noise with that. But... I can't. So it'd have to be based on Daz core shader. Mmm.

     

    So actually having Ubersurface itself doesn't help with that? It's a Studio default shader, so it's in every copy. (Although in a slightly weird location - Shader Presets/omnifreaker/Ubersurface, according to my content library.) And I *think*, though I will not swear, that Ubersurface is a Shader Mixer shader (hence being located in Shader Presets instead of Shaders -- which is not the way anyone would normally think of it), so you might be able to see how things connect to each other.

Sign In or Register to comment.