C++

Total 40 Posts
This tag aggregates all tutorials on C++ programming techniques.

Basic Ad Hoc Collision Response

In this tutorial the equation of reflection off of any hypersurface, i.e. off a line in 2D and off a plane in 3D, is derived from the known observation that the angle of incidence equals the angle of reflection.

Streaming Music with XAudio2

In this tutorial we will learn how to implement an audio streaming technique using XAudio2 and the Windows Media Foundation's source reader in asynchronous mode.

XAudio2 and Submix Voices

In this short tutorial we will learn how to use XAudio2 and submix voices to collect source voices into sets and how to set the volume level of a submix voice.

Programming Patterns: An Event-Queue

In this tutorial we will learn how to use an event queue to unify all interactions between game characters, such as the player and NPCs, and application components, such as user input and audio.

XInput and Gamepads

In this tutorial we will look at how to add support for gamepads to our application using the XInput API. XInput replaces DirectInput from previous DirectX versions and greatly simplifies the task of working with game controllers, as long as they are XInput-compatible, i.e. X-Box-like controllers.

Polling Joysticks with DirectInput

This tutorial explains how to use DirectInput in DirectX 11 to acquire user input from joystick-like devices.

Raw Data

To facilitate deploying the game, or just working in a team, it would be nice to have a good file system structure in place. This isn't really a tutorial, but rather a reminder to myself. For now, we simply store the raw data files into the My Documents folder.