O'Reilly logo

OpenGL Shading Language, Third Edition by Mike Weiblen, Hugh Malan, Barthold Lichtenbelt, John M. Kessenich, Dan Ginsburg, Bill Licea-Kane, Randi J. Rost

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5. Built-in Functions

This chapter provides the details of the functions that are defined as part of the OpenGL Shading Language. Feel free to skip ahead to the next chapter if you want to get down to the nitty-gritty of writing your own shaders. This chapter can be useful as a reference after you are well on your way to writing OpenGL shaders for your own application.

The OpenGL Shading Language defines an assortment of built-in convenience functions for scalar and vector operations. The reasons for providing built-in functions for the OpenGL Language include

• Making shaders simpler to develop and easier to understand and maintain.

• Exposing some necessary hardware functionality in a convenient way such as accessing a texture map. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required