Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learning Windows 8 Game Development

You're reading from   Learning Windows 8 Game Development Windows 8 brings touchscreens to the tablet and PC. This book will show you how to develop games for both by following clear, hands-on examples. Takes your C++ skills into exciting areas of 3D development.

Arrow left icon
Product type Paperback
Published in Oct 2013
Publisher Packt
ISBN-13 9781849697446
Length 244 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Michael Quandt Michael Quandt
Author Profile Icon Michael Quandt
Michael Quandt
Arrow right icon
View More author details
Toc

DirectXMath

Although this topic is too big for the scope of this appendix, we'll work through the basics so that you understand how to get started.

Note

For more information on DirectXMath, visit: http://msdn.microsoft.com/en-us/library/windows/desktop/ee415574.

All the points (and vertices) are represented by using an array of three floats called a Vector, which represents the x, y, and z axes. In DirectXMath this is represented by the DirectX::XMFLOAT3 structure.

Note

For simplicity I'll avoid using the DirectX namespace in front of all the references, but, don't forget that all of DirectXMath sits within that namespace—so be sure to ensure you reference it in some way.

Most operations on this data are done by first converting the XMFLOAT3 to an XMVECTOR, which represents the SIMD (Single Instruction, Multiple Data) units on the CPU. Two simple functions provide you with a way to get information in and out of XMVECTOR, shown as follows:

XMFLOAT3 start = XMFLOAT3(1, 1...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime