Game Development with SlimDX

Game Development with SlimDX
eBook: $20.99
Formats: PDF, PacktLib, ePub and Mobi formats
save 15%!
Print + free eBook + free PacktLib access to the book: $55.98    Print cover: $34.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Table of Contents
Sample Chapters
  • Harness the power of DirectInput and XInput to detect and respond to user input from keyboard, mouse, and joysticks/gamepads while adding the allimportant interactivity to your games
  • Make the most of Direct2D, DirectSound, XAudio2, and Direct3D to make your game worlds come to life on the screen
  • A practical guide packed with example code and quick instructions on game development with SlimDX

Book Details

Language : English
Paperback : 150 pages [ 235mm x 191mm ]
Release Date : December 2013
ISBN : 1782167382
ISBN 13 : 9781782167389
Author(s) : Michael Fontanini
Topics and Technologies : All Books, Open Source

Table of Contents

Chapter 1: Getting Started
Chapter 2: Responding to Player Inputs
Chapter 3: Rendering 2D Graphics
Chapter 4: Adding Sound
Chapter 5: Rendering Simple 3D Graphics
Chapter 6: Where to Go from Here
  • Chapter 1: Getting Started
    • Setting up Visual Studio 2013 Express
    • Setting up SlimDX
    • Creating a framework
    • The GameWindow class
      • The constructor
      • The IDisposable interface
  • The GameLoop method
  • Testing our game window
  • Summary
    • Chapter 2: Responding to Player Inputs
      • DirectInput versus XInput
      • Mouse and keyboard input
        • The constructor
        • Initializing DirectInput
        • The Update() method
        • The IDisposable interface
        • Updating the GameWindow class
      • Using joysticks with DirectInput
        • Enumerating devices
      • Getting input from the joystick
      • Using joysticks with XInput
      • Summary
      • Chapter 3: Rendering 2D Graphics
        • Creating a Direct2D game window class
          • The constructor
          • Creating our rectangle
          • Drawing our rectangle
          • Cleanup
        • Rendering bitmaps
          • Initialization
          • Rendering the game world
          • Rendering the player character
          • Rendering debug information
          • Finishing the rendering code
          • Handling user input
          • Animating the player character
          • Running the game
        • Entities
          • Component-based entities
        • Summary
        • Chapter 4: Adding Sound
          • DirectSound versus XAudio2
          • The basics of sound
          • Stereo sound
          • DirectSound
            • Volume control
            • Frequency control
            • Pan control
          • XAudio2
            • Volume control
            • Frequency control
            • Pan control
          • Summary
          • Chapter 5: Rendering Simple 3D Graphics
            • The Direct3D graphics rendering pipeline
              • Input assembler
              • Vertex shader
              • Rasterizer
              • Pixel shader
              • Output merger
            • Shaders
            • Rendering a triangle
              • Initializing Direct3D
              • Initializing the shaders
              • Initializing the scene
              • Rendering the scene
            • Rendering a cube
              • Initializing the depth stencil
              • Initializing the constant buffers
              • Initializing the scene
              • Updating the scene
              • Rendering the scene
            • Summary
            • Chapter 6: Where to Go from Here
              • Culling and clipping
              • Collision detection
              • Artificial Intelligence
              • Physics
              • Multithreaded programming
              • Game design
                • Game difficulty
                • Manipulating the player's emotions
              • Further reading
                • Websites
                • Books
              • Summary

              Michael Fontanini

              Michael Fontanini has a passion for video games and computers, loves animals, and is a very friendly yet timid person. He first got into computer programming when he was just a kid, and was given a toy made by VTech, called the PreComputer 1000. It had a programming mode in it, which was a very basic form of the language BASIC. Out of curiosity, he played around with it, and became fascinated with his new ability to make a computer do whatever he wanted. He soon discovered QBasic (QuickBasic) on a Windows PC (a DOS version of the language BASIC that came with old versions of Windows) and started messing up with that. From there, he eventually moved on to Visual Basic, and then C++ and C#.

              As he grew older, his passion for video games grew, and eventually, he realized he could combine these two passions and make video games. Nintendo's, The Legend of Zelda series, has been one of his favorite game franchises and a great source of inspiration. Creating virtual worlds in computers also fascinated him. So, he has spent countless hours playing with game programming and level creation recreationally, and has learned a lot along the way. He aspires to become a successful indie game developer.

              He was held back by some anxiety issues and hasn't been very successful in life, but the book Game Development with SlimDX, Packt Publishing, was a great opportunity, so he pursued it. Michael enjoyed this new journey and is proud of his work. He is always there for his friends and family. Having been a bit of a loner growing up, he learned the hard way how precious good friends and family are. He is thankful for all that he has.

              Sorry, we don't have any reviews for this title yet.

              Code Downloads

              Download the code and support files for this book.

              Submit Errata

              Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.

              Sample chapters

              You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

              Frequently bought together

              Game Development with SlimDX +    Cassandra Administration [Video] =
              50% Off
              the second eBook
              Price for both: $20.99

              Buy both these recommended eBooks together and get 50% off the cheapest eBook.

              What you will learn from this book

              • Handle user input from the mouse, keyboard, and gamepad using both DirectInput and XInput
              • Draw 2D graphics using Direct2D
              • Create a 2D tilebased game world with animated characters
              • Add sound effects and music to your game using both DirectSound and XAudio2
              • Set up a Direct3D application
              • Render basic 3D graphics
              • Texture your basic 3D objects

              In Detail

              Video games have been around for quite some time, but SlimDX has become a big thing in game development in recent years. It is a free open source framework that lets you bring your own virtual world to life using the power of DirectX.

              This tutorial gives you a good head start into the world of game development with SlimDX. You will learn everything you need to know to start making your own 2D and 3D games.

              This book takes you through some of the most important areas of game design, such as handling user input, 2D graphics, and adding sound and music to your games. You will learn the advanced topic of 3D graphics, which will get you started on making your own games. It will guide you fully in working with 2D game worlds and animated 2D characters by developing a 2D tilebased game world with a goofy, animated robot character for the player to control, and other demos.

              By learning the basics of creating 3D graphics, you will be comfortable building 3D worlds in your own game.


              An easytofollow guide on SlimDX game development with practical exercises in each chapter. Stepbystep instructions and example code put each topic into action in a working demo.

              Who this book is for

              If you are a game designer or game developer with a passion for video games and a desire to create your own from scratch, this is the book for you. You will need basic programming experience in C#(C Sharp) to get the most out of this book.

              Code Download and Errata
              Packt Anytime, Anywhere
              Register Books
              Print Upgrades
              eBook Downloads
              Video Support
              Contact Us
              Awards Voting Nominations Previous Winners
              Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
              Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software