Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
C++ Game Animation Programming
C++ Game Animation Programming

C++ Game Animation Programming: Learn modern animation techniques from theory to implementation using C++, OpenGL, and Vulkan , Second Edition

Arrow left icon
Profile Icon Michael Dunsky Profile Icon Gabor Szauer
Arrow right icon
$19.99 per month
Full star icon Full star icon Full star icon Full star icon Half star icon 4.6 (12 Ratings)
Paperback Dec 2023 480 pages 2nd Edition
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m
Arrow left icon
Profile Icon Michael Dunsky Profile Icon Gabor Szauer
Arrow right icon
$19.99 per month
Full star icon Full star icon Full star icon Full star icon Half star icon 4.6 (12 Ratings)
Paperback Dec 2023 480 pages 2nd Edition
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m
eBook
$35.98 $39.99
Paperback
$49.99
Subscription
Free Trial
Renews at $19.99p/m

What do you get with a Packt Subscription?

Free for first 7 days. $19.99 p/m after that. Cancel any time!
Product feature icon Unlimited ad-free access to the largest independent learning library in tech. Access this title and thousands more!
Product feature icon 50+ new titles added per month, including many first-to-market concepts and exclusive early access to books as they are being written.
Product feature icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Product feature icon Thousands of reference materials covering every tech concept you need to stay up to date.
Subscribe now
View plans & pricing
Table of content icon View table of contents Preview book icon Preview Book

C++ Game Animation Programming

1

Creating the Game Window

This is the start of your journey into the world of game character animation programming. In this book, you will open a window into a virtual world, enabling the user to take control and move around in it. The window will utilize hardware-accelerated graphics rendering to show detailed characters that have been loaded from a simple file on your system. You will be introduced to character animation, starting with basic steps such as how to show a single, static pose, and you will move on to more advanced topics such as Inverse Kinematics. By the end, the application will have a large crowd of animated people, who are the inhabitants of your virtual world. In addition, the window will have fancy UI elements that you can use to control the animations of the characters, and you will learn how to debug the application if you encounter any trouble, both on the CPU and the GPU. I hope you enjoy the ride – it will take you to various wonderful locations, steep hills, long roads, and nice cities. Buckle up!

To begin, welcome to Chapter 1! The first step might be the most important as it sets the foundation for all the other chapters in this book. Without a window to your virtual world, you won’t be able to see your creations. But it’s not as hard as you might expect, and the right tools can solve this quickly and easily.

As we are using open source software and platform-independent libraries in this book, you should be able to compile and run the code “out of the box” on Windows and Linux. You will find a detailed list of the required software and libraries in the Technical requirements section.

To that end, in this chapter, we will cover the following topics:

  • Creating your first window
  • Adding support for OpenGL or Vulkan to the window
  • Event handling in GLFW
  • The mouse and keyboard input for the game window
Left arrow icon Right arrow icon
Download code icon Download Code

Key benefits

  • Learn how to create a game skeleton with keyboard and mouse controls along with modern graphics
  • Gain insights into model loading, character animations, inverse kinematics, and debugging techniques
  • Master the art of creating animated characters and controlling their various aspects
  • Purchase of the print or Kindle book includes a free PDF eBook

Description

If you‘re fascinated by the complexities of animating video game characters and are curious about the transformation of model files into 3D avatars and NPCs that can explore virtual worlds, then this book is for you. In this new edition, you’ll find expanded content on high-performance graphics and modern animation techniques, along with improved workflows and enhanced guidance on using OpenGL and Vulkan. You’ll learn everything you need to know about game animation, from a simple graphical window to a large crowd of smoothly animated characters. First, you’ll learn how to use modern high-performance graphics, dig into the details of how virtual characters are stored, and load the models and animations into a minimalistic game-like application. Then, you’ll get an overview of the components of an animation system, how to play the animations and combine them, and how to blend from one animation into another. You’ll also get an introduction to topics that will make your programming life easier, such as debugging your code or stripping down the graphical output. By the end of this book, you’ll have gained deep insights into all the parts of game animation programming and how they work together, revealing the magic that brings life to the virtual worlds on your screen.

Who is this book for?

This book is for curious C++ developers, game programmers, game designers, and character animators, either pursuing this as a hobby or profession, who have always wanted to look behind the curtain and see how character animation in games works. The book assumes basic C++ and math knowledge, and you should be able to read code and math formulas to get the most out of this book.

What you will learn

  • Create simple OpenGL and Vulkan applications and work with shaders
  • Explore the glTF file format, including its design and data structures
  • Design an animation system with poses, clips, and skinned meshes
  • Find out how vectors, matrices, quaternions, and splines are used in game development
  • Discover and implement ways to seamlessly blend character animations
  • Implement inverse kinematics for your characters using CCD and FABRIK solvers
  • Understand how to render large, animated crowds efficiently
  • Identify and resolve performance issues

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Dec 01, 2023
Length: 480 pages
Edition : 2nd
Language : English
ISBN-13 : 9781803246529
Languages :
Concepts :
Tools :

What do you get with a Packt Subscription?

Free for first 7 days. $19.99 p/m after that. Cancel any time!
Product feature icon Unlimited ad-free access to the largest independent learning library in tech. Access this title and thousands more!
Product feature icon 50+ new titles added per month, including many first-to-market concepts and exclusive early access to books as they are being written.
Product feature icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Product feature icon Thousands of reference materials covering every tech concept you need to stay up to date.
Subscribe now
View plans & pricing

Product Details

Publication date : Dec 01, 2023
Length: 480 pages
Edition : 2nd
Language : English
ISBN-13 : 9781803246529
Languages :
Concepts :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just $5 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just $5 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total $99.96 $111.97 $12.01 saved
C++ Game Animation Programming
$49.99
Building Low Latency Applications with C++
$44.99
Mastering Graphics Programming with Vulkan
$44.99
Total $99.96$111.97 $12.01 saved Stars icon

Table of Contents

21 Chapters
Part 1:Building a Graphics Renderer Chevron down icon Chevron up icon
Chapter 1: Creating the Game Window Chevron down icon Chevron up icon
Chapter 2: Building an OpenGL 4 Renderer Chevron down icon Chevron up icon
Chapter 3: Building a Vulkan Renderer Chevron down icon Chevron up icon
Chapter 4: Working with Shaders Chevron down icon Chevron up icon
Chapter 5: Adding Dear ImGui to Show Valuable Information Chevron down icon Chevron up icon
Part 2: Mathematics Roundup Chevron down icon Chevron up icon
Chapter 6: Understanding Vector and Matrix Chevron down icon Chevron up icon
Chapter 7: A Primer on Quaternions and Splines Chevron down icon Chevron up icon
Part 3: Working with Models and Animations Chevron down icon Chevron up icon
Chapter 8: Loading Models in the glTF Format Chevron down icon Chevron up icon
Chapter 9: The Model Skeleton and Skin Chevron down icon Chevron up icon
Chapter 10: About Poses, Frames, and Clips Chevron down icon Chevron up icon
Chapter 11: Blending between Animations Chevron down icon Chevron up icon
Part 4: Advancing Your Code to the Next Level Chevron down icon Chevron up icon
Chapter 12: Cleaning Up the User Interface Chevron down icon Chevron up icon
Chapter 13: Implementing Inverse Kinematics Chevron down icon Chevron up icon
Chapter 14: Creating Instanced Crowds Chevron down icon Chevron up icon
Chapter 15: Measuring Performance and Optimizing the Code Chevron down icon Chevron up icon
Index Chevron down icon Chevron up icon
Other Books You May Enjoy Chevron down icon Chevron up icon

Customer reviews

Top Reviews
Rating distribution
Full star icon Full star icon Full star icon Full star icon Half star icon 4.6
(12 Ratings)
5 star 83.3%
4 star 8.3%
3 star 0%
2 star 0%
1 star 8.3%
Filter icon Filter
Top Reviews

Filter reviews by




Salim Pamukcu Feb 06, 2024
Full star icon Full star icon Full star icon Full star icon Full star icon 5
good book with clear instruction, a lot of useful, realistic applications. good author, detailed.
Feefo Verified review Feefo
CireWire Dec 05, 2023
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Since I'm working in the game industry, I thought this book was a great resource to have next to me while I worked on my projects.It is very in-depth with examples, code snippets, and a github repository to make sure you get the most out of this resource.The math behind the theories are just as beautiful. Vectors, Matrices, Splines, everything needed to make sure you succeed in this skill are in this book.For anyone interested in learning more about C++ animation techniques or want to level up your established skillset, I highly recommend this book!
Amazon Verified review Amazon
Zach Peterson Dec 01, 2023
Full star icon Full star icon Full star icon Full star icon Full star icon 5
I've been a game engine developer for 3 years now, and yet I've never worked on an animation system before. Reading this book has been a really great insight on everything animation, from the math involved to writing an efficient animation system in Vulkan. The entire process is easy to follow, which was a pleasant surprise for learning a new field. And I bet you'll learn a lot more than animation with the last few chapters of the book on optimization.
Amazon Verified review Amazon
Kirito Dec 28, 2023
Full star icon Full star icon Full star icon Full star icon Full star icon 5
If this book sounds scary, it could be. A good level of understanding of how C++ works and a decent working knowledge on math will help you understand the concepts quicker.That being said, I believe how this book is taught, works with learners of all styles whether they are a beginner or an advanced user.It's not easy to cover such complex topics in a condensed form, but for the size of this book, I think it does it well and conveys the concepts of OpenGL, Vulkan, C++, how the GPU runs, and how Animation works in the background.From someone who is an Unreal and Unity developer, this, I believe, would help you better PoC (Proof of Concept) animation a lot easier in engines like those. Especially in Unreal Engine as it uses C++.The provided abundant snippets and concise content brings the users learning experience to be focused and direct. A good amount of practice for a beginner and an extensible modular approach for the more advanced user, this book would be a great addition to your arsenal as a game developer of all degrees interested in Animation.
Amazon Verified review Amazon
Lifegood Dec 02, 2023
Full star icon Full star icon Full star icon Full star icon Full star icon 5
The book gives many insights into the basics of creating graphics for the game but delves into the mathematical aspects of it. Matrix and Vectors are the essential parts of creating animations. The information about animation and modeling is great and a good starting point if you want to get into it. A plus is that gives you information on optimized C++ too. So overall, great book
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is included in a Packt subscription? Chevron down icon Chevron up icon

A subscription provides you with full access to view all Packt and licnesed content online, this includes exclusive access to Early Access titles. Depending on the tier chosen you can also earn credits and discounts to use for owning content

How can I cancel my subscription? Chevron down icon Chevron up icon

To cancel your subscription with us simply go to the account page - found in the top right of the page or at https://subscription.packtpub.com/my-account/subscription - From here you will see the ‘cancel subscription’ button in the grey box with your subscription information in.

What are credits? Chevron down icon Chevron up icon

Credits can be earned from reading 40 section of any title within the payment cycle - a month starting from the day of subscription payment. You also earn a Credit every month if you subscribe to our annual or 18 month plans. Credits can be used to buy books DRM free, the same way that you would pay for a book. Your credits can be found in the subscription homepage - subscription.packtpub.com - clicking on ‘the my’ library dropdown and selecting ‘credits’.

What happens if an Early Access Course is cancelled? Chevron down icon Chevron up icon

Projects are rarely cancelled, but sometimes it's unavoidable. If an Early Access course is cancelled or excessively delayed, you can exchange your purchase for another course. For further details, please contact us here.

Where can I send feedback about an Early Access title? Chevron down icon Chevron up icon

If you have any feedback about the product you're reading, or Early Access in general, then please fill out a contact form here and we'll make sure the feedback gets to the right team. 

Can I download the code files for Early Access titles? Chevron down icon Chevron up icon

We try to ensure that all books in Early Access have code available to use, download, and fork on GitHub. This helps us be more agile in the development of the book, and helps keep the often changing code base of new versions and new technologies as up to date as possible. Unfortunately, however, there will be rare cases when it is not possible for us to have downloadable code samples available until publication.

When we publish the book, the code files will also be available to download from the Packt website.

How accurate is the publication date? Chevron down icon Chevron up icon

The publication date is as accurate as we can be at any point in the project. Unfortunately, delays can happen. Often those delays are out of our control, such as changes to the technology code base or delays in the tech release. We do our best to give you an accurate estimate of the publication date at any given time, and as more chapters are delivered, the more accurate the delivery date will become.

How will I know when new chapters are ready? Chevron down icon Chevron up icon

We'll let you know every time there has been an update to a course that you've bought in Early Access. You'll get an email to let you know there has been a new chapter, or a change to a previous chapter. The new chapters are automatically added to your account, so you can also check back there any time you're ready and download or read them online.

I am a Packt subscriber, do I get Early Access? Chevron down icon Chevron up icon

Yes, all Early Access content is fully available through your subscription. You will need to have a paid for or active trial subscription in order to access all titles.

How is Early Access delivered? Chevron down icon Chevron up icon

Early Access is currently only available as a PDF or through our online reader. As we make changes or add new chapters, the files in your Packt account will be updated so you can download them again or view them online immediately.

How do I buy Early Access content? Chevron down icon Chevron up icon

Early Access is a way of us getting our content to you quicker, but the method of buying the Early Access course is still the same. Just find the course you want to buy, go through the check-out steps, and you’ll get a confirmation email from us with information and a link to the relevant Early Access courses.

What is Early Access? Chevron down icon Chevron up icon

Keeping up to date with the latest technology is difficult; new versions, new frameworks, new techniques. This feature gives you a head-start to our content, as it's being created. With Early Access you'll receive each chapter as it's written, and get regular updates throughout the product's development, as well as the final course as soon as it's ready.We created Early Access as a means of giving you the information you need, as soon as it's available. As we go through the process of developing a course, 99% of it can be ready but we can't publish until that last 1% falls in to place. Early Access helps to unlock the potential of our content early, to help you start your learning when you need it most. You not only get access to every chapter as it's delivered, edited, and updated, but you'll also get the finalized, DRM-free product to download in any format you want when it's published. As a member of Packt, you'll also be eligible for our exclusive offers, including a free course every day, and discounts on new and popular titles.