Fresnel Reflections

What we refer to in CG by the term “Fresnel Effect” or “Fresnel Reflections”, is the way Specular Reflection intensity changes according to light \ surface incident angle, and it is a basic optical property surfaces.

Specular reflection intensity changes according to light incident angle, and behaves almost like a perfect mirror at grazing view angle.
The reason we call this natural reflection behavior “Fresnel Effect” or “Fresnel Reflection” is that the equations describing the how reflection intensity changes according to incident angle were invented by the French Physicist Augustin-Jean Fresnel, and in early CG days, not all systems knew how to calculate natural reflections or reflections at all for that matter. So in CG we ended up treating this as something special, when in fact it’s not special in nature, it was just special in the early days of ray-tracing.

When rendering Fresnel Reflections, the reflection intensity isn’t determined by a linear blending percent like mixing a layer.
It’s determined by a factor called “Refractive Index” or “Index Of Refraction” i.e. IOR.
The IOR value is derived from the physical material’s density, which is the key factor determining both reflection intensity and refraction amount.

Examples of some physical IOR values*:
Air (vacuum): 1.0
Water: 1.33
Glass: 1.52
Diamond: 2.417
* Physical values differ between different measurements and samples of materials so you might see differences between different data sources.

FResnel_Off

This ball is rendered without “Fresnel Reflections”.
Its Specular reflection is blended consistently at 50% over the diffuse color (reflection), not affected by the light/view incident angle.
The result looks wrong for a natural material. It may look like a dielectric material (non metal) that’s coated with a silvery coating, but it can’t look correctly like glossy plastic or glass.

FResnel_On

This ball is rendered with “Fresnel Reflections”.
The reflections look natural for a dielectric material (non metal), because they are dim at perpendicular incident angle and intense at grazing view angle, hence seen mostly at the sides of the ball accentuating its contour.

Theoretically Specular Reflection for all types of materials should be calculated using what we refer to in CG by the term “Complex Fresnel”, that is reflection equations that take into account both the Refractive Index (IOR) and Extinction Coefficient for 3 primary colors (spectrum wave lengths).
*Complex fresnel component values for different materials can be found on https://refractiveindex.info/.
In practice, for Dielectric materials (non metals), most common production rendering systems use what we refer to in CG by the term “Simple Fresnel” or “Simple IOR”, that is calculating the reflection for all 3 primary colors using a single Refractive Index value, which is the Refractive index of the Green primary color.
This method has proven itself to be very efficient for rendering non-metallic surfaces (dielectric materials).
Rendering metallic reflection using complex IOR produces the most realistic color and reflection* for metals.
*In metallic surfaces the color is the reflection color itself and not a separate Diffuse component.
Some rendering systems like Arnold 5 for example have implemented a general form* of Complex IOR into their physical surface shader, Complex IOR reflection can also be rendered via OSL shaders that can be found on the web (or written..).
*I’m using the term ‘general form’ because these implementations don’t include input for Complex IOR values but just a general metallic reflection curve, that interpolates manual color selection.
Popular useful cheats for mimicking metallic reflection without complex IOR are to set a very high (non physical) simple IOR value, like 15 to 30 which forces the Fresnel reflection to become more metal-like, or turn Fresnel reflection completely off, turning the specular reflection into a perfect mirror reflection, or create a custom reflection/angle curve/ramp that produces the effect of the metallic reflection color and intensity changing by incident angle, see example here.

In many popular production renderers, the physical surface shader uses a single IOR parameter. Some rendering systems allow using 2 different IOR parameters, one for calculating reflections and the other for calculating Refraction.
* physically correct dielectric materials should be defined with the same IOR value for both reflections and refraction. using different IOR values for reflection and refraction allows useful cheats like creating transparent a material that is modeled without any thickness or defining a transparent glass that has silver reflective coating like sunglasses sometimes have.

Notes:

  1. IOR lists on the web, that display only simple IOR values like this list, are not valid for metals, and produce wrong results.
    *Using simple IOR values for dielectric materials however is very efficient.
  2. There are parts in the CG industry where in daily slang language, the term “Fresnel” is used to refer to any shading effect that is view-angle dependent,
    Usually referring to the shading properties appearing at the “sides” or contours of the model.
  3. There are some CG systems that use the term Fresnel to refer to a simple linear or non-linear incident angle blending effect, that should actually be called “Facing ratio” or “Perpendicular-Parallel” blending (falloff).
    This is wrong because IOR based Fresnel reflection intensity produces a specific physical Reflection intensity/view angle function curve, and not just a linear or simple power function.
    See example in UE4’s Fresnel node.

Related:

  1. V-Ray Next’s new metallic material option.
  2. Creating a rich metallic shader in UE4.
  3. Complex Fresnel Texture for Cycles.
Advertisements

IES Lighting in CG

IES stands for Illuminating Engineering Society, it is the organization responsible for creating and maintaining industrial standards for design and manufacturing of artificial light sources.

In 3D rendering, an IES file or “photo-metric file” is a text file containing a physical description of a light source’s beam spread , pattern and intensity, allowing for faithful depiction of the light source in 3D renders.
Most modern 3D rendering software support IES lights, that is allow loading IES files into the software and lighting the 3D scene using the light source described in the IES file.

Lighting manufacturers make measurements of their light fixture model’s physical light output and create IES files available for download on their websites.
This allows architects, lighting designers, and interior designers to download the files and realistically visualize the light sources effect on their projects.

CG artists use IES lights to add realistic spotlight beam patterns to their renderings and animations, such that can’t be created using regular simple 3D light sources.

Examples of IES lights rendered with V-Ray for 3ds max:

IES

Related:
IES Spotlights for Blender & Cycles

Sprite Sheet – Storing animation frames in one texture

Runner_Atlas

An efficient way to store 2D animation for games is to layout all the frames withing one texture called a ‘Sprite Sheet’ or ‘Texture Atlas’.
This saves resources by avoiding multiple texture loading operations and only animating the UVs of the shader to display the needed image at each frame.
Sprite Sheets are also used to pack various states of game graphics and textures for multiple objects in one file.

Creating Sprite-Sheets:
Sprite Sheets can be created manually using any image editing software,
For an automated process and more control, a specialized software like Texture Packer can be used.
And it can also be done automatically in Adobe Animate (Flash).
* There are many more solutions / scripts that will do that you can find on the web…