SharpGL learning notes (10) common light source types, creating light sources, sharpgl learning notes

Source: Internet
Author: User

SharpGL learning notes (10) common light source types, creating light sources, sharpgl learning notes

 

In OpenGL, different types of lights can be created by combining the characteristics of the light source, such as color, position, and direction.

Common lighting types include:

Directonal)

Positional)

Attenuation Light Source

Spotlight

 

Next we use the light source in 3dsmax to simulate the corresponding type of OpenGL light source, rendering for everyone to have a quick impression.

Note that all the light effects in the following picture enable the projection effect. However, in OpenGL, the projection is not an incidental effect of the light. We need to perform some additional work.

 

The oriented light source in OpengGL refers to the light source that is set in an infinite distance. when the light is shining on an object, its direction is parallel. This feature is just equivalent to the parallel light in 3dsmax.

 

The position of the positioning light source in OpenGL determines the impact on the scene. This feature is equivalent to a bulb in 3dsmax.

 

The attenuation light source in OpenGL. The so-called attenuation refers to the light intensity of an object that is farther away from the light. This property is equivalent to the light source with the attenuation option enabled in 3dsmax, such as the bulb.

There is an obvious depth of field effect of brightness, and in the perspective, 3dsmax also marks the position of the attenuation of the near and remote points.

 

OpenGL spotlight refers to limiting positioning to a cone, that is, the stage spotlight effect in real life. This kind of lighting is an effect of cone illumination.

The corresponding spotlight is also available in 3dsmax, as shown in.

 

 

 

Original article, from "blog garden, pig weneng's blog": http://www.cnblogs.com/hackpig/

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.