GPGPU Programming for Games and Science (Anglais) Relié – 1 octobre 2014
|Neuf à partir de||Occasion à partir de|
- Choisissez parmi 17 000 points de collecte en France
- Les membres du programme Amazon Premium bénéficient de livraison gratuites illimitées
- Trouvez votre point de collecte et ajoutez-le à votre carnet d’adresses
- Sélectionnez cette adresse lors de votre commande
Les clients ayant acheté cet article ont également acheté
Descriptions du produit
Présentation de l'éditeur
An In-Depth, Practical Guide to GPGPU Programming Using Direct3D 11
GPGPU Programming for Games and Science demonstrates how to achieve the following requirements to tackle practical problems in computer science and software engineering:
- Quality source code that is easily maintained, reusable, and readable
The book primarily addresses programming on a graphics processing unit (GPU) while covering some material also relevant to programming on a central processing unit (CPU). It discusses many concepts of general purpose GPU (GPGPU) programming and presents practical examples in game programming and scientific programming.
The author first describes numerical issues that arise when computing with floating-point arithmetic, including making trade-offs among robustness, accuracy, and speed. He then shows how single instruction multiple data (SIMD) extensions work on CPUs since GPUs also use SIMD.
The core of the book focuses on the GPU from the perspective of Direct3D 11 (D3D11) and the High Level Shading Language (HLSL). This chapter covers drawing 3D objects; vertex, geometry, pixel, and compute shaders; input and output resources for shaders; copying data between CPU and GPU; configuring two or more GPUs to act as one; and IEEE floating-point support on a GPU.
The book goes on to explore practical matters of programming a GPU, including code sharing among applications and performing basic tasks on the GPU. Focusing on mathematics, it next discusses vector and matrix algebra, rotations and quaternions, and coordinate systems. The final chapter gives several sample GPGPU applications on relatively advanced topics.
Available on a supporting website, the author’s fully featured Geometric Tools Engine for computing and graphics saves you from having to write a large amount of infrastructure code necessary for even the simplest of applications involving shader programming. The engine provides robust and accurate source code with SIMD when appropriate and GPU versions of algorithms when possible.
Aucun appareil Kindle n'est requis. Téléchargez l'une des applis Kindle gratuites et commencez à lire les livres Kindle sur votre smartphone, tablette ou ordinateur.
Pour obtenir l'appli gratuite, saisissez votre numéro de téléphone mobile.
Détails sur le produit
Commentaires en ligne
Commentaires client les plus utiles sur Amazon.com (beta)
Chapter 1 is a brief overview of the subject matter.
Chapter 2 deals primarily with finite binary encodings of the reals, with emphasis on the IEEE 754 floating-point standard. Much of this material could have been pared down or omitted. Even "Numerical Recipes in C", a book entirely about numerical methods, spends only a few pages on such low-level technicalities.
Chapter 3 is a discussion of SIMD computing. It covers some useful techniques for avoiding branching, and places a heavy emphasis on polynomial approximations of common arithmetic and trigonometric functions. Eberly takes a principled approach using the Chebyshev equioscillation theorem (in particular, the Remez algorithm for computing minimax approximations). The second half of the chapter is somewhat redundant due to the presence of intrinsics in HLSL for all of the described functions.
Chapter 4 is the first practical chapter in the book. It introduces the 3D graphics pipeline, with a brief discussion of coordinate spaces, projection, and rasterization. A few trivial shaders are decompiled and analyzed, but this chapter is mostly a laundry list of the steps required to do useful work with Direct X 11. Everything you would expect to see is here: devices, contexts, swap chains, buffers, textures, states, shaders, and techniques for copying from CPU to GPU and vice-versa. A few, mostly trivial, examples are scattered throughout, but very little of this material is motivated.
We're now halfway through the book, page-wise, and we haven't seen any practical compute shaders yet. A bit curious for a book with "GPGPU" in the title.
Chapter 5 is a grab-bag of OOD, debugging, performance, and testing advice. There are a few useful tidbits here.
Chapter 6 is yet another 90-page chapter with hardly any content relevant to GPGPU. We get coverage of the geometric and algebraic properties of vectors, matrices, and rotations, and a quite thorough discussion of coordinate space conventions, but it's hard to see how any of this relates to work one might be interested in doing on the GPU that isn't directly related to 3D rendering.
Chapter 7 redeems the book somewhat. It contains a survey of GPGPU implementations of various problems in collision detection, physical system simulation, image processing, and level set extraction. These are all well-illustrated and lucidly explained.
So, now for the verdict.
I can't imagine an audience that will find this book indispensible. Chapters 2, 3, 5, and 6 could be condensed to about 20 pages total while retaining most of their value. The content of Chapter 4 is better covered in a book expressly on DX11 and HLSL, such as Varcholik's. The actual GPGPU examples are worth studying on their own, but comprise so little of the book's contents. The GPU Gems and GPU Pro series have roughly the same proportion of GPGPU content in each volume, and the techniques are generally self-contained and lavishly illustrated.
A final note: Eberly's codebase (GTEngine) is currently implemented only in DirectX, and thus is of limited utility to non-Windows users. By the time it is ported to OpenGL and GLSL, it will probably have undergone architectural shifts (as did every version of Eberly's Wild Magic / Geometric Tools codebase when he was writing his 3DGEA and 3DGED texts). Nevertheless, it does make for interesting reading.
I’m a tough critic. I’m also an unpaid one: I spent a few hours with this book, but certainly did not read it cover to cover (though I hope to find the time to do so with this one for topics I know nothing about).
This book is tangentially related to computer graphics, but I mention it here anyway. Unlike most books about GPGPU programming, this one does not use CUDA, but rather uses DirectX’s DirectCompute. I can’t fairly assess this book, as I still haven’t taken on GPGPU.
While the book is ostensibly about GPU programming, computer graphics sneaks in here and there, and that I can comment on. Chapter 4, called “GPU Computing”, is the heart of the book. However, it spends the first part talking about vertex, pixel, and geometry shaders, rasterization, perspective projection, etc. Presenting this architecture is meant as an example of how parallelism is used within the GPU. However, this intent seems to get a bit sidetracked, with the transformation matrix stack taking up the first 8 pages. While important, this set of transforms is not all that related to parallelism beyond “SIMD can be used to evaluate dot products”. For most general GPGPU problems you won’t need to know about rendering matrices. 8 pages is not enough to teach the subject, and in an intermediate text this area could have been left out as a given.
Chapter 6, “Linear and Affine Algebra”, is an 84 page standalone chapter on this topic. It starts out talking about template classes for this area, then plows through the theory in this field. While an important area for some applications, this chapter sticks out as fairly unrelated to the rest of the chapters. The author clearly loves the topic, but this much coverage (a fifth of the book) does not serve the reader well for the topic at hand. I was strongly reminded of the quote, “In writing, you must kill all your darlings”. You have to be willing to edit out irrelevant pieces, no matter how sound and how much you love them. The author notes in the introduction, “I doubt I could write a book without mathematics, so I included chapter 6 about vector and matrix algebra.” The nature of the physical book market is “make it thick” so that it looks definitive. Putting tangential content into a book does the customer who is paying and spending time to learn about GPGPU programming a disservice. I don’t blame the author in particular, nor even the publisher. Most technical books have no real editors assigned to them, “real” in the sense of someone asking hard questions such as, “can this section of the book be trimmed back?” We have to self-edit, and we all have our blind spots.
Overall I’m a bit apprehensive about truly reading this book to learn about GPGPU programming. I had hoped that it would be a solid guide, but its organization concerns me. It seems to go a few different directions, not having a clear “here’s what I’m going to cover and here’s what you’re going to learn” feel to it. A lot of time is spent with groundwork such as floating point rounding rules, basic SIMD, etc. – it’s not until 123 pages in that the GPU is mentioned. The book feels more like a collection of articles about various elements having to do with performing computations efficiently on various forms of hardware. That said, Chapter 7, “Sample Applications”, does offer a fairly wide range of computational tasks mapped to the GPU. It’s a chapter I’ll probably come back to if I need to implement these algorithms. The author is a well-respected veteran and I trust his code to be correct. He’s done wonderful work over the years in growing his Geometric Tools site – it’s a fantastic free resource (at one point I even tried to find external grants to support his work on the site - no luck there. A MacArthur Fellowship sent his way would be great). What might have made more sense is a focused, stripped down book, half of chapter 4 and all of chapter 7, offered for $10 as an ebook treatise.
GPUs are used for both rendering and computation. Term GPGPU denotes general purpose computation on GPU and that was what I expected from the book. Unfortunately, going through the TOC I realized that something is wrong with the title. Namely, book has 429 pages and only 1/5 of it is devoted to the GPGPU topic!