spacer

OpenGL Shading Language

This document describes a programming language that is a companion to OpenGL 2.0 and higher, called The OpenGL Shading Language. The OpenGL Shading Language is part of the core OpenGL 4.4 specification.

spacer Download the OpenGL Shading Language Specification

  • GLSL Reference Pages
  • OpenGL 4.4 & GLSL Quick Reference Guide
  • OpenGL 4.3 & GLSL Quick Reference Guide
  • OpenGL 4.2 & GLSL Quick Reference Guide
  • OpenGL 4.1 & GLSL Quick Reference Guide
  • OpenGL 3.2 & GLSL

The recent trend in graphics hardware has been to replace fixed functionality with programmability in areas that have grown exceedingly complex (e.g., vertex processing and fragment processing). The OpenGL Shading Language has been designed to allow application programmers to express the processing that occurs at those programmable points of the OpenGL pipeline. Independently compilable units that are written in this language are called shaders. A program is a set of shaders that are compiled and linked together.

The aim of this document is to thoroughly specify the programming language. The OpenGL entry points that are used to manipulate and communicate with programs and shaders are defined separately from this language specification.

The OpenGL Shading Language is based on ANSI C and many of the features have been retained except when they conflict with performance or ease of implementation. C has been extended with vector and matrix types (with hardware based qualifiers) to make it more concise for the typical operations carried out in 3D graphics. Some mechanisms from C++ have also been borrowed, such as overloading functions based on argument types, and ability to declare variables where they are first needed instead of at the beginning of blocks.


Column Header

Documentation

  • About OpenGL 4.5
  • OpenGL Shading Language
  • About OpenGL Extensions
  • OpenGL Registry
  • Spec Feedback Form
  • Newest Reference Pages
  • OpenGL 4 Reference Pages
  • OpenGL 3.3 Reference Pages
  • OpenGL 2.1 Reference Pages
  • OS/Platform Implementations
  • OpenGL Books
  • OpenGL 4.5 & GLSL 4.5 Quick Reference Card
  • OpenGL 4.4 & GLSL 4.4 Quick Reference Card
  • OpenGL 4.3 & GLSL 4.3 Quick Reference Card
  • OpenGL 4.2 & GLSL 4.2 Quick Reference Card
  • OpenGL 3.2 & GLSL 1.5 Quick Reference Card
Column Footer

gipoco.com is neither affiliated with the authors of this page nor responsible for its contents. This is a safe-cache copy of the original web site.