Working with Direct State Access (DSA)
Starting with version 4.5, OpenGL Core Profile allows us to modify the state of objects without enforcing the bind-to-edit model that was used in previous versions of OpenGL. Let's take a closer look at the new functions that provide a straightforward, object-oriented interface and do not affect the global state.
Getting ready
The OpenGL examples provided in this book use the DSA programming model, which you were exposed to in Chapter 2, Using Essential Libraries. If you are not familiar with DSA yet, it is recommended that you go through the source code for all the applications covered in Chapter 2, Using Essential Libraries, to get a solid grasp of this approach to small, self-contained examples.
All DSA functions can be separated into the following object families:
- Texture
- Framebuffer
- Buffer
- Transform feedback
- Vertex array
- Sampler
- Query
- Program
Let's go through a couple of these...