Home Technical Talk

A few questions about PBR.

polycounter lvl 12
Offline / Send Message
Hayden Zammit polycounter lvl 12
Hey guys. Just wanted to ask a question someone could hopefully clear up for me in regards to PBR as I'm trying to wrap my head around it at the moment in cryengine.

I understand that with the Spec Gloss workflow you need to either have a spec map that is the right color for the material you are making, but what happens if you have a material and you can't find the exact number? Do you just guess as close as you can?

Also, with the albedo map, does the diffuse have to match any certain number. Like paint or wood for example, can they be any color, but do they have to have a certain value set?

thanks + sorry if I wasn't clear on anything.

Replies

  • JedTheKrampus
    Offline / Send Message
    JedTheKrampus polycounter lvl 8
    If you want to know the exact albedo value for something grab your camera and your handy Macbeth chart and go out for a shoot.

    x-ritefactor.png

    That will get you the most true-to-life results. If you don't have a Macbeth chart see if you can find calibrated scan data online somewhere and use that to inform your texture. If you can't find scans of anything, just guess! Most surfaces have albedo between 0.05 and 0.4. Some are much higher (like snow.) In some cases it is more important to match the noise profile of the albedo (especially for surfaces like rocks) than it is to match the median value. Gather lots of reference and try to get a result that's close to it.

    As for specularity, if you don't know what it is, guess 0.04. In most cases you'll be right. Water is 0.02, and skin is .028. Gems are .1 to .16 and metals are .6 to .95. As far as glossiness goes, you just have to do what your body tells you. That is, find a corresponding surface in the real world and touch it. Listen to the sound that the surface makes when you rub your finger on it and feel how rough the surface is. Then figure out what number that would correspond to and write it down in a notebook and use that as a baseline value for glossiness. You can get surprisingly believable results this way...
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    OK, I think that's making some sort of sense. Here's a texture I'm trying to re-create for a scene in Cryengine:

    aTQTj1c.png

    Here are the maps I'm using. Top left is gloss, top right is spec:

    tQBLNsX.png

    And here's my current result:

    hJMtd3W.png

    So am I basically doing this wrong here? If its ceramic tiles, then should the values for the white diamonds be much darker in the albedo? Should the spec be one solid value unlike what I have here?
  • tynew
    Offline / Send Message
    tynew polycounter lvl 9
    I believe if the white diamonds are the same material as the rest of the tiles? So in the albedo it would be white as you have, but in spec and gloss it would be the same value as the squares.

    The grout I'm also not sure that would be very reflective/glossy either as the real material itself is dry and concreteish.
  • billymcguffin
    Offline / Send Message
    billymcguffin polycounter lvl 11
    Like tynew said, the spec should be the same for the two different colors of tiles, and the grout should have really low gloss. I think the albedo should be a bit lighter perhaps, as having a dark albedo and bright spec causes it to look metallic.

    It looks pretty good as it is to me, though!
  • JedTheKrampus
    Offline / Send Message
    JedTheKrampus polycounter lvl 8
    Yeah that spec map is way off. You should have almost a uniform color of .04 converted to SRGB for that, with a cavity AO map multiplied on top (with reduced opacity) for specular micro-occlusion. (Unless the small tiles are made of gems but that doesn't seem to be the case from the reference.) The gloss also seems to be pretty uniform (maybe a little lower than what you have) although you should definitely texture it and the grout should be at a lower gloss. The albedo is on the right track although I think I would probably bump up the blacks a bit and add a layer of really subtle rough grey dust over the floor.
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    Alright, thanks a lot guys. It helps a lot for me to be able to post up images like this and have it corrected. Just reading the theory isn't doing it for me. Gonna read some more documentation and make the adjustments you said and I'll be back with some more updates soon.
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    Okay, here's a new attempt:

    DKwoUBv.png

    The result in cryengine:

    bOTDO4y.jpg

    Another angle:

    WkP5PSN.png

    So is that looking more correct? The 2nd shot doesn't look right in the crevices. Is that because there should simply be black for the gloss there?
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    Also, here's another shot in cryengine, with an environment probe added:

    Tpxj8Zs.png
  • tynew
    Offline / Send Message
    tynew polycounter lvl 9
    So is that looking more correct? The 2nd shot doesn't look right in the crevices. Is that because there should simply be black for the gloss there?
    I would think so. It looks a little strange with how reflective/glossy it looks in the sunlight. The values almost look as bright as the tiles, the grout should be pretty flat looking.
  • JedTheKrampus
    Offline / Send Message
    JedTheKrampus polycounter lvl 8
    If you look at some places in the grout lines it looks like you have some spots where you completely erased the grout exposing a tile layer underneath. Obviously this isn't how grout works. Ask yourself what would be under the grout if the grout were partially degraded, and then put that in those spots. You could fudge it a little by darkening those parts but don't go overboard.
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    Not sure what I'm doing wrong with that grout. I did a little test.

    here's what I did to the maps: I put a black line in both the albedo and the gloss map. I'm assuming this would get rid of all the brightness in that black line:

    jC1dxWT.png

    Here's the result those tweaks give me:

    6Lnf9Yj.png
  • loggie24
    Offline / Send Message
    loggie24 polycounter lvl 3
    Looks like a pretty low-res texture from that photo, so harder to tell. Black is the wrong value, go rather with a dark grey if you want to try and keep ita bit PBR accurate.

    Material setup in CE would be nice to see as well.
  • Fwap
    Offline / Send Message
    Fwap polycounter lvl 13
    I haven't used CE but i know sometimes in UE4 when importing grayscale maps ala Roughness/Gloss it sets it to srgb.
    Maybe something similar has happened in CE? if so make sure your grayscale maps have srgb turned off.
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    Fwap - I don't think its that. The Gloss map is stored in the alpha slot of the normal map for Ce3.

    Loggie - Here's the material setup:

    tTphtVz.png
  • loggie24
    Offline / Send Message
    loggie24 polycounter lvl 3
    Replied to your crydev post instead
  • JedTheKrampus
    Offline / Send Message
    JedTheKrampus polycounter lvl 8
    I think you should paint the grout lines black in the gloss channel and some kind of grey in the albedo. That should give the most believable results IMO.
  • Zezeri
    I would probably advise you to decrease the gloss a bit and increase the diffuse.
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    So I posted this on the Cryengine forums as well and got some good help. My gloss map was totally wrong it seems. I didn't fully understand how they were working.
    I think you should paint the grout lines black in the gloss channel and some kind of grey in the albedo. That should give the most believable results IMO.
    Thanks. I'll give that a try.
    I would probably advise you to decrease the gloss a bit and increase the diffuse.
    Yeah, that texture isn't final. I'll have a play with it some more.


    Here's the result I got after fixing up the gloss:

    NcPb5v4.png

    QlbTei3.png
  • JedTheKrampus
    Offline / Send Message
    JedTheKrampus polycounter lvl 8
    Looks good to me. :thumbup:
  • Hayden Zammit
    Offline / Send Message
    Hayden Zammit polycounter lvl 12
    JedTheKrampus - Yeah, I'm pretty happy with it. Still gonna do those tweaks like you suggested. Thanks for the help.
Sign In or Register to comment.