PBR 3D Models

Started by
1 comment, last by そら 7 years, 11 months ago

What are the needed material properties of new high-end models for rendering?

While I currently read about PBR and inspect some shader code, I know each material must have a Fresnel R0 value and a roughness value (perhaps a roughness map..?).

In this shader the writer also declared a uniform as "vec3 u_colorMaterial". Why is this needed in addition to an albedo map?

Also, in this shader can you explain the next three textures:


Texture2D TexRoughness; //why is this a texture and not a uniform like the previous shader?
Texture2D TexMetallic;
Texture2D TexOcclusion;

By the way, are specular maps out of the game these days?

Is there a site on the web that offers free high-end models so I can do some testing?

Can I use Assimp to load these kind of models? I think it doesn't even load a "roughness" material property.

If anyone could shed some light on some of these questions that would be great

Advertisement

Most tools/engines are converging on two different workflows for specular maps.

In "traditional" game art, you usually had:

Specular Power: size/shape of the highlight

Specular Mask: intensity of the highlight.

These had lots of different names, such as gloss maps, spec-color maps, or just specular maps... but it usually boiled down to a power value and a mask value.

In PBR, the F0 ~= mask/spec-colour, and roughness/glossiness ~= power.

The two new workflows for authoring these values are the "spec/gloss" workflow and the "rougness/metalness" workflow.

Spec/gloss is very similar to the traditional workflow -- the monochrome gloss map controls the size/shape of the highlight, and the RGB specular map contains F0, which acts very similarly to a traditional RGB mask value. This workflow is easy for traditional game artists to understand due to the similarity. The main difference is that traditionally, artists put a lot of details into their masks/spec-colours, when they should now be putting detail into the power/roughness/gloss maps instead.

Metal/rough is different, but IMHO simpler and more intuitive -- the monochrome roughness map controls the size/shape of the highlight, but in a slightly different way (in some engines, it's inverted, so black = small highlights and white = large highlights), and the monochrome metalness map indirectly specifies the F0 value. If metalness is zero, then the F0 value is some hard-coded non-metal value, such as vec3(0.02, 0.02, 0.02), otherwise if metalness is one, F0 is the value stored in your material colour map. Moreover, metalness also affects your diffuse colour! If metalness is zero, the diffuse colour is the value stored in your material colour map, otherwise if metalness is one, the diffuse colour is black.

This is because pure metals should have bright RGB F0 values and black diffuse values, and non-metals should have monochrome, dark F0 values in approx the 2%-4% range, most of the time. So this workflow makes it harder for artist's to create "impossible" materials -- such as having bright a blue diffuse colour and bright red F0.

So with Spec/gloss, you'd have diffuse colour (RGB), specular colour (RGB) and glossiness (mono).

And with Metal/rough, you'd have material colour (RGB), metalness (mono) and roughness (mono).

complementing what Hodgman already said, you can find a nice guide to PBR in this Alegoritmic's two-part PBR Guide for free (targeted mainly for artists, but technical enough for programmers as well).

And in a couple of months Matt Pharr and others will release the Third Edition of the book Physically Based Rendering From Theory to Implementation.

Hope that helps!

"lots of shoulddas, coulddas, woulddas in the air, thinking about things they shouldda couldda wouldda donne, however all those shoulddas coulddas woulddas ran away when they saw the little did to come"

This topic is closed to new replies.

Advertisement