Book description
Build a 3D rendering engine from scratch while solving problems in a stepbystep way with the help of useful recipes
Key Features
 Learn to integrate modern rendering techniques into a single performant 3D rendering engine
 Leverage Vulkan to render 3D content, use AZDO in OpenGL applications, and understand modern realtime rendering methods
 Implement a physically based rendering pipeline from scratch in Vulkan and OpenGL
Book Description
OpenGL is a popular crosslanguage, crossplatform application programming interface (API) used for rendering 2D and 3D graphics, while Vulkan is a lowoverhead, crossplatform 3D graphics API that targets highperformance applications. 3D Graphics Rendering Cookbook helps you learn about modern graphics rendering algorithms and techniques using C++ programming along with OpenGL and Vulkan APIs.
The book begins by setting up a development environment and takes you through the steps involved in building a 3D rendering engine with the help of basic, yet selfcontained, recipes. Each recipe will enable you to incrementally add features to your codebase and show you how to integrate different 3D rendering techniques and algorithms into one large project. You'll also get to grips with core techniques such as physically based rendering, imagebased rendering, and CPU/GPU geometry culling, to name a few. As you advance, you'll explore common techniques and solutions that will help you to work with large datasets for 2D and 3D rendering. Finally, you'll discover how to apply optimization techniques to build performant and featurerich graphics applications.
By the end of this 3D rendering book, you'll have gained an improved understanding of best practices used in modern graphics APIs and be able to create fast and versatile 3D rendering frameworks.
What you will learn
 Improve the performance of legacy OpenGL applications
 Manage a substantial amount of content in realtime 3D rendering engines
 Discover how to debug and profile graphics applications
 Understand how to use the Approaching Zero Driver Overhead (AZDO) philosophy in OpenGL
 Integrate various rendering techniques into a single application
 Find out how to develop Vulkan applications
 Implement a physically based rendering pipeline from scratch
 Integrate a physics library with your rendering engine
Who this book is for
This book is for 3D graphics developers who are familiar with the mathematical fundamentals of 3D rendering and want to gain expertise in writing fast rendering engines with advanced techniques using C++ libraries and APIs. A solid understanding of C++ and basic linear algebra, as well as experience in creating custom 3D applications without using premade rendering engines is required.
Table of contents
 3D Graphics Rendering Cookbook
 Contributors
 About the authors
 About the reviewers
 Preface
 Chapter 1: Establishing a Build Environment
 Chapter 2: Using Essential Libraries

Chapter 3: Getting Started with OpenGL and Vulkan
 Technical requirements
 Intercepting OpenGL API calls
 Working with Direct State Access (DSA)
 Loading and compiling shaders in OpenGL
 Implementing programmable vertex pulling (PVP) in OpenGL
 Working with cube map textures
 Compiling Vulkan shaders at runtime
 Initializing Vulkan instances and graphical devices
 Initializing the Vulkan swap chain
 Setting up Vulkan's debugging capabilities
 Tracking and cleaning up Vulkan objects
 Using Vulkan command buffers
 Dealing with buffers in Vulkan
 Using texture data in Vulkan
 Using mesh geometry data in Vulkan
 Using Vulkan descriptor sets
 Initializing Vulkan shader modules
 Initializing the Vulkan pipeline
 Putting it all together into a Vulkan application

Chapter 4: Adding User Interaction and Productivity Tools
 Technical requirements
 Organizing Vulkan frame rendering code
 Organizing mesh rendering in Vulkan
 Implementing an immediate mode drawing canvas
 Rendering a Dear ImGui user interface with Vulkan
 Working with a 3D camera and basic user interaction
 Adding a framespersecond counter
 Adding camera animations and motion
 Integrating EasyProfiler and Optick into C++ applications
 Using cube map textures in Vulkan
 Rendering onscreen charts
 Putting it all together into a Vulkan application

Chapter 5: Working with Geometry Data
 Technical requirements
 Organizing the storage of mesh data
 Implementing a geometry conversion tool
 Indirect rendering in Vulkan
 Implementing an infinite grid GLSL shader
 Rendering multiple meshes with OpenGL
 Generating LODs using MeshOptimizer
 Integrating tessellation into the OpenGL graphics pipeline

Chapter 6: Physically Based Rendering Using the glTF2 Shading Model
 Technical requirements
 Simplifying Vulkan initialization and frame composition
 Initializing compute shaders in Vulkan
 Using descriptor indexing and texture arrays in Vulkan
 Using descriptor indexing in Vulkan to render an ImGui
 Generating textures in Vulkan using compute shaders
 Implementing computed meshes in Vulkan
 Precomputing BRDF LUTs
 Precomputing irradiance maps and diffuse convolution
 Implementing the glTF2 shading model

Chapter 7: Graphics Rendering Pipeline
 Technical requirements
 How not to do a scene graph
 Using dataoriented design for a scene graph
 Loading and saving a scene graph
 Implementing transformation trees
 Implementing a material system
 Importing materials from Assimp
 Implementing a scene conversion tool
 Managing Vulkan resources
 Refactoring Vulkan initialization and the main loop
 Working with rendering passes
 Unifying descriptor set creation routines
 Putting it all together into a Vulkan application

Chapter 8: ImageBased Techniques
 Technical requirements
 Implementing offscreen rendering in OpenGL
 Implementing fullscreen quad rendering
 Implementing shadow maps in OpenGL
 Implementing SSAO in OpenGL
 Implementing HDR rendering and tone mapping
 Implementing HDR light adaptation
 Writing postprocessing effects in Vulkan
 Implementing SSAO in Vulkan
 Implementing HDR rendering in Vulkan
 Chapter 9: Working with Scene Graphs

Chapter 10: Advanced Rendering Techniques and Optimizations
 Technical requirements
 Doing frustum culling on the CPU
 Doing frustum culling on the GPU with compute shaders
 Implementing orderindependent transparency
 Loading texture assets asynchronously
 Implementing projective shadows for directional lights
 Using GPU atomic counters in Vulkan
 Putting it all together into an OpenGL demo
 Why subscribe?
 Other Books You May Enjoy
Product information
 Title: 3D Graphics Rendering Cookbook
 Author(s):
 Release date: August 2021
 Publisher(s): Packt Publishing
 ISBN: 9781838986193
You might also like
book
RealTime 3D Rendering with DirectX® and HLSL: A Practical Guide to Graphics Programming
Get Started Quickly with DirectX 3D Programming: No 3D Experience Needed This stepbystep text demystifies modern …
book
OpenGL 4 Shading Language Cookbook  Third Edition
Over 70 recipes that cover advanced techniques for 3D programming such as lighting, shading, textures, particle …
book
Shading, Lighting, and Rendering with Blender EEVEE
Get to grips with new realtime animation techniques and tricks to improve your artistic and technical …
book
Mathematics for Game Programming and Computer Graphics
A comprehensive guide to learning fundamental 3D mathematical principles used in games and computer graphics by …