3 ms·
> The glTF material model is essentially all you need for realistic rendering. If you assume the whole world is plastic, then yes! But the microfacet model is
by Jasper_ 6y ago
> The glTF material model is essentially all you need for realistic rendering.
If you assume the whole world is plastic, then yes! But the microfacet model is not the ultimate physical model, GGX-Smith and Epic/Disney PBR are compromises in a lot of cases, and you interact with hundreds of surfaces every day that can't be modeled accurately with it. Fuzzy or hairy surfaces are often modeled with a microfiber model! Epic's approximations (e.g. the split-sum approximation) can't easily handle anisotropic surfaces like brushed metal. And fleshy surfaces like skin, wax, paper, fruit pulp, etc. all require some form of subsurface scattering beyond the basic Lambertian diffuse.
> I always wondered how much performance you could gain by implementing that model directly in silicon and ditch GPU shaders instead.
Very little of the shader code that's being run is the microfacet BRDF stuff, and that's ALU so it's the fast bit! The expensive stuff is texture fetching for i.e. incident light, shadows, and that's all done by artists and graphics engineers above the BRDF layer. BRDF just tells you how to respond to incoming light, not where it is or where it comes from. And it makes you supply stuff like albedo color, normal direction, which are where shaders spend a lot of their time.
- donmccurdy 6y agoSome of these features (sheen, anisotropy, subsurface scattering) are being added to the format with changes like https://github.com/KhronosGroup/glTF/pull/1726 https://github.com/KhronosGroup/glTF/pull/1726. But realtime implementations can get a lot of mileage out of a simpler metal/rough PBR workflow, too.