Search Unity

Curvature map?

Discussion in 'Shaders' started by SympaK, Jan 18, 2017.

  1. SympaK

    SympaK

    Joined:
    Apr 14, 2010
    Posts:
    134
    Excuse me, but where is the slot for the curvature map? Possibile that Unity doesn't have one?
     
  2. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    Lots of context here.
     
    jitterhorse and Martin_H like this.
  3. Invertex

    Invertex

    Joined:
    Nov 7, 2013
    Posts:
    1,550
    What purpose are you using the curvature map for? The Standard Shader is not a subsurface scattering shader, so there's not really a need for a curvature map input, nor is it a material layering shader so curvature has no use for affecting layering. Otherwise a curvature map is usually used in external software to help generate textures for the object.

    If you want to utilize curvature map for SSS, then download a skin shader, I would recommend the pre-integrated skin shader.
     
    Martin_H and SympaK like this.
  4. SympaK

    SympaK

    Joined:
    Apr 14, 2010
    Posts:
    134
    Thanks
    I would like to use it for cavities and the like. If it exists, for something it may be useful for sure. Anyway, thanks.
     
    Last edited: Jan 19, 2017
  5. Invertex

    Invertex

    Joined:
    Nov 7, 2013
    Posts:
    1,550
    That's something you would bake into your diffuse and specular textures, or into an ambient occlusion map for the standard shader (this isn't regular AO, it is actually affected by direct lighting, so cavities become darker than rest of surface when not directly lit).

    What is the effect you are trying to achieve? If you can explain what you are trying to make that would enable us to help you better!
     
  6. SympaK

    SympaK

    Joined:
    Apr 14, 2010
    Posts:
    134
    I think that your previous reply has covered the question already. Though, I still wonder why Unity doesn't use this kind of map directly.

    What?
     
  7. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,343
    He meant there was a lack of context in your question as "curvature map" can mean and be used for many things. For example it can be used for skin shading and other faked subsurface scattering, dynamic wear and scratches, and a hand full of non-photorealistic rendering techniques just to name a few.

    Curiously your mentioned use case of "for cavities" is generally done with a, well, cavity map which is significantly different than a curvature map unless I'm misunderstanding what you want.

    Really it would be most useful to know what other engine or 3D program you're coming from that you've used curvature maps for so that we have context.

    Again, since we don't know exactly what you're attempting or wanting we can't really answer this. However I can say that Unity tends to be very careful with the features it includes with the built in shaders. Any extra feature they add to the base shaders means a more complex shader (slower to render), and more shader variants to compile (longer to open the editor, and potentially larger apps).

    If it's a feature you want or need you can write your own shaders or get ones that do what you want from the asset store.
     
    sadicus, Martin_H and hippocoder like this.
  8. SympaK

    SympaK

    Joined:
    Apr 14, 2010
    Posts:
    134
    Hi bg. I always stayed with Unity so far, albeit I know about other engines though (and infact, I'm staying an willing to stay with Unity 'cause I find other engines very outdated and cumbersome as for ease of usability and learning curve). I use programs such as DDO to bake textures, among which there are also curvature maps. So, being that they are usable to embetter a character, I just wondered why Unity doesn't have a slot for it, whilst "some other engines" have. And, obviously I wasn't aware that Unity had some workabout to "simulate" what this kind of map would do. Anyway, that's all.
     
  9. Invertex

    Invertex

    Joined:
    Nov 7, 2013
    Posts:
    1,550
    The point of curvature maps in a program like DDO is exactly like you said.. to bake maps. You on longer need the curvature map because you've already baked maps using it, or else there would be no point in baking the maps. This is the workflow for 99% of games. If a curvature map is going to be used in a game, it will be for some very specific shading effect that is unique to that game generally, in which case you're going to be creating a custom shader for that effect regardless.

    So I think you were just confused thinking that because you used the curvature map in DDO, that you're supposed to also use it in your game. The answer is no. It's just a "helper" map when creating assets.
     
    SympaK likes this.
  10. SympaK

    SympaK

    Joined:
    Apr 14, 2010
    Posts:
    134
    Ok, thanks.
    Anyway, if I hadn't asked it, I think that nobody except who knows the argument indeep had had been aware of all this, and probably had asked the argument many times more. I guess that you might add this thread into some highlighted repository, or at least a complete answer in some FAQs on the shaders/maps argument.