Book Image

Learning LibGDX Game Development- Second Edition

Book Image

Learning LibGDX Game Development- Second Edition

Overview of this book

Table of Contents (21 chapters)
Learning LibGDX Game Development Second Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Light sources


Light clusters from the sun fall on an object, which reflect and reach our eye. This is how we see things. OpenGL ES allows us to create four types of light sources:

  • Ambient light: This is not exactly a light source, but light reflected from other objects, thereby limiting the light intensity when compared with directional lights.

  • Directional light: This comes from a faraway source. Light from sun is a perfect example of directional light.

  • Point light: This is the light from a point source such as a bulb.

  • Spotlight: This is similar to point light; however, it has a direction in which it shines. A flashlight/torch is a perfect example of a spotlight.