• EON Studio File Formats Working with Viewports The Resources Group Use of Light in a Scene Generate a Foreground User Interface
  • Developer Articles / Beginner Basics

    Use of Light in a Scene

    Adding Light to Applications

    Typically, light is added to models within the modeling software, however it is also possible to add additional lights inside EON Studio to better enhance and improve application appearance. Light nodes are available to provide a way to better illuminate objects in applications. Using light node settings, a wide variety of lighting effects can be added to better illuminate the scene or objects within the application. These lighting effects will vary in appearance by the textures and materials that are applied to meshes.

    Light Illumination Types

    When working with 3D applications, you must understand several different types of light and the effect that each of these light options creates on the surface of rendered 3D objects. The terms we use to describe the lighting in applications are derived from the effects that light produces on objects and the complex mathematical calculations needed to re-create these effects. These exact types of light do not actually exist in nature. The terms provide a way for us to define the light options. Remember that these options are not actually “light sources” –they are colors applied to the material of an object to make it appear “lit” in different ways. In OpenGL, the common light types include the following options:
    • Ambient light:
    • Diffuse light:
    • Specular light
    • Emissive light
    The following sections describe each type of light.

    Ambient Light

    The term ambient light is used to describe the color bouncing around the scene. Technically, ambient light is the average volume of light created by the emission of light from all of the light sources surrounding (or located inside of) the lit area. As an example, when the sun’s rays enter a room through a window, they directly hit some surfaces and then are reflected and scattered in different directions. This reflection and scattering has the impact of brightening the whole room. However, ambient light alone cannot accurately represent an object in 3D space because all points are evenly lit by the same color—making an object appear to be two dimensional. Three-dimensional objects appear to be “flat” on the screen when lit by only ambient light.

    Diffuse Light

    Diffuse Light is the light that has a specific position in space and comes from a single direction. It represents the directional light cast by a light source. Think of this light as the beam from a flashlight held slightly above the object. The diffuse color is typically the base color of the object that fills in the polygons of the mesh. Typically, you use ambient light and diffuse light together to create object at look more realistic. Together, these two lighting methods form the basis for making an object appear to be three-dimensional.

    Specular Light

    Specular light, sometimes referred to as specular highlight or specular reflection, provides the shininess of an object. Specular light is often white or light gray, and it is the “bright spot” on a curved surface. For example, if you create an illustration of a balloon to give it a round appearance. That spot is the result of specular light. The specular highlight is layered on the ambient light and diffuse light to enhance the object’s 3D appearance. Specular light, like diffuse light, is a directional light—meaning that it comes from one particular direction. However, unlike diffuse light, specular light reflects off the surface in a sharp, uniform way. The appearance of specular light is driven by the angle between the viewer and the light source. From the viewer’s standpoint, specular light creates a highlighted area on the object’s surface. The intensity of the specular light depends on the material the object is made of and the strength of the light source.

    Emissive Light

    Emissive Light is different from the other lighting effects because it is the type of light emitted by the object, whereas the other three light types are used to describe a light source. The emissive light component is responsible for the ability of the object’s material to reflect or absorb light. When applied to an object’s material, emissive light simulates the light that is reflected off the object. If you apply no other light sources, an object that has only the emissive light component applied will look the same as an object with only ambient light applied—it will appear flat or two-dimensional even though it is really three-dimensional. However, the way in which diffuse or specular light interacts with the surface of an object with only emissive light applied to it is different. If, for example, a sphere has a white specular light, the resulting sphere will appear to have a yellowish surface. If the sphere did not have the green emissive color, it would have appeared red, but the light source color merges with the object’s color (emissive color) to produce the yellowish surface. The specular light will appear white at the center of the object, but as it spreads from the center, it also merges with the green and red colors to create shades of yellow.

    Light Sources

    There are several types of light sources used in EON Studio based on the direction and area the light illuminates. The following are the types of light sources available:
    • Ambient: This light source appears to illuminate all objects with equal intensity in all directions similar to direct sunlight.
    • Directional: This type of light is linked to a Frame node but appears to illuminate all objects with equal intensity in one direction as if it were an infinite distance from the scene. Directional lighting is the best choice for maximum rendering speed and is commonly used to simulate sunlight.
    • Parallel Point: Parallel point light sources also radiates light in all directions, however when parallel light strikes a flat surface, it illuminates the surface with an even intensity. Parallel point light source rendering performance is nearly as high as directional light sources.
    • Point: Point light source radiates light in all directions but it will require the calculation of a new lighting vector for each facet or normal it illuminates. Point lights are computationally more demanding than other light sources but it does produce more realistic lighting effects. Point lights are the best choice when visual fidelity is the primary concern.
    • Spot: A spotlight source emits a cone of light and only illuminates objects inside this cone. There are two angle values used with spot lights: umbra and penumbra. The umbra and penumbra define the variation of light intensity as a function of an angle. The umbra defines an inner “core” cone within which the light is a full intensity. The penumbra cone surrounds the umbra cone and is less intense, with an illumination cone gradually decreasing in the interval between the umbra angle (where light is at full intensity) and the penumbra angle (where there is no light).

    Color, Position and Orientation

    There are several properties that can be adjusted to change light. The first is the light color which can be defined by RGB values on the Light node’s color tab. You can enter color values by RGB values or you may choose a color from the Color Selection window. You can also adjust the position and orientation of light as determined by the light node’s parent Frame by adjusting the Translation/Rotation tab. The following table shows which light sources are affected by modifying the position and/or orientation values of their parent Frame nodes.
    Light Source Type Position Orientation
    Ambient No No
    Directional Yes Yes
    Parallel Point Yes No
    Point Yes No
    Spot Yes Yes

    Attenuation

    The amount of light that falls on real-world objects diminishes noticeably as the local light source moves away from the object. This effect is replicated in EON Studio by adjusting the Attenuation setting in the Light node property bar. The attenuation range value specifies the distance from the light source. Light intensity set at zero means no objects are illuminated by the light source. Attenuation is applicable only to spot light sources. The following are the three range values or coefficients which define how light intensity decreases in proportion to the distance from the light source. When adjusting the attenuation by small coefficient values such as 0.01 a considerable effect on light intensity occurs. The following are the coefficients of attenuation:
    • Constant Value Changed: Light intensity decreases when the constant factor increases. The light intensity is constant in relation to the distance to the light source.
    • Linear Value Changed: When the linear value is increased, the light intensity decreases faster in relation to the distance from the light source.
    • Quadratic Value Changed: The Quadratic values give the curves a steeper slope than linear values and decreases light intensity faster in relation to the distance of the light source compared to linear values. A higher quadratic value decreases light intensity faster than a lower value.
    To customize lighting applications, you can combine different coefficient values for certain circumstances and applications.

    Default Lights

    There are two light sources used in EON Studio. The first is the Keylight Frame containing a Light2 node. This frame is set to a Directional light to produce lighting effects similar to a lamp pointing straight ahead. The KeyLight Frame follows the movement of the simulations camera because it is placed under the Camera Frame node in the default simulation tree. The second is the use of the Light2 Node to create a variety of additional light sources. The Light2 Node provides the capability to create a variety of lights and appearances of objects based on light type, color, sources, etc.

    Light2 Node

    The Light2 node is typically inserted under a parent Frame node or another moveable parent so its effect can be seen. You can place light nodes at different locations in the scene by creating Frame nodes to parent Light2 nodes. Objects can be affected by 8 light sources simultaneously at maximum. The Light2 node also supports lighting cookies to create what is called gobo lights.
    Copyright 2017 EON Reality Inc. | All Rights Reserved

    Log in with your credentials

    or    

    Forgot your details?

    Create Account

    Skip to toolbar