Direct3D ShaderX: Vertex and Pixel Shader Tips and Tricks

( 1 )

Overview

Vertex and pixel shader programming allows graphics and game developers to create photorealistic graphics on the personal computer for the first time. And with DirectX, programmers have access to an assembly language interface to the transformation and lighting hardware (vertex shaders) and the pixel pipeline (pixel shaders). Direct3D ShaderX begins with an introduction to vertex and pixel shader programming and moves on to a wide array of specialized shader tricks contributed by 27 experts in game and graphics ...
See more details below
Available through our Marketplace sellers.
Other sellers (Multimedia Set)
  • All (13) from $1.99   
  • New (1) from $50.00   
  • Used (12) from $1.99   
Close
Sort by
Page 1 of 1
Showing All
Note: Marketplace items are not eligible for any BN.com coupons and promotions
$50.00
Seller since 2014

Feedback rating:

(139)

Condition:

New — never opened or used in original packaging.

Like New — packaging may have been opened. A "Like New" item is suitable to give as a gift.

Very Good — may have minor signs of wear on packaging but item works perfectly and has no damage.

Good — item is in good condition but packaging may have signs of shelf wear/aging or torn packaging. All specific defects should be noted in the Comments section associated with each item.

Acceptable — item is in working order but may show signs of wear such as scratches or torn packaging. All specific defects should be noted in the Comments section associated with each item.

Used — An item that has been opened and may show signs of wear. All specific defects should be noted in the Comments section associated with each item.

Refurbished — A used item that has been renewed or updated and verified to be in proper working condition. Not necessarily completed by the original manufacturer.

New
Brand new.

Ships from: acton, MA

Usually ships in 1-2 business days

  • Standard, 48 States
  • Standard (AK, HI)
Page 1 of 1
Showing All
Close
Sort by
Sending request ...

Overview

Vertex and pixel shader programming allows graphics and game developers to create photorealistic graphics on the personal computer for the first time. And with DirectX, programmers have access to an assembly language interface to the transformation and lighting hardware (vertex shaders) and the pixel pipeline (pixel shaders). Direct3D ShaderX begins with an introduction to vertex and pixel shader programming and moves on to a wide array of specialized shader tricks contributed by 27 experts in game and graphics programming. These range from character animation and lighting to photorealistic faces and non-photorealistic rendering. Special effects shaders are also presented, including those for such effects as bubbles, rippling water, animated grass, and particle flows.
Read More Show Less

Editorial Reviews

From Barnes & Noble
The Barnes & Noble Review
If you want to get to the cutting edge of game or computer graphics programming, and stay there, you need to understand programmable shading. No lie: This stuff’s challenging. But if you’re comfortable with C++, Direct3D ShaderX: Vertex and Pixel Shader Tips and Tricks will get you the rest of the way.

First, a little background. As Wolfgang F. Engel notes at the very beginning of this book, PC graphics are a whole lot faster since 3dfx introduced its breakthrough Voodoo cards back in ’95 -- but they haven’t gotten as much better as they should have. One big reason: Conventional PC graphics accelerators have been “fixed function” -- their graphics algorithms are hard-coded into silicon. (It’s one reason PC computer graphics tend to look alike.)

While PC game designers have struggled with the inflexibility of these video systems, the rest of the world hasn’t stood still. Take a look at Toy Story or Monsters, Inc., and you’ll see photorealistic graphics of breathtaking quality. Pixar’s RenderMan software made them possible. RenderMan is thoroughly programmable and can evolve as new rendering techniques arrive. Wouldn’t it be wonderful if the same flexibility were available in cheap PC hardware and in Windows?

Well, finally, it is. In addition to the Direct 3D fixed-function Transform & Lighting (T&L) pipeline that graphics designers have used for years, DirectX 8 (and beyond) offer vertex shaders, allowing you to evade the pipeline and write programs that execute directly on your graphics hardware. Recent boards like the nVIDIA GeForce3/4TI and ATI RADEON 8x00 not only support vertex shaders, but also provide hardware support for pixel shaders, small programs that execute on individual pixels to control color, lighting, and texture.

If you’ve got the gear and the programming chops, all you need is this book, and you’re in business. Engel (whose previous titles include Beginning Direct3D Game Programming) starts with the fundamentals: what it takes to start programming both vertex and pixel shaders in Windows environments, including techniques for lighting, transformations, texture mapping and effects, and per-pixel lighting. (Yes, this stuff can be done with OpenGL, too, but that’s a different book.)

Engel helps you build your skills incrementally. For example, he starts with a simple example program, then evolves it to incorporate a Bézier patch class with a diffuse, specular reflection model and a point light source. Section I ends with a thorough introduction to a powerful new shader development tool, Shader Studio, written by its developer, John Schwab. (You’ll find Release 1.0 on CD-ROM.)

In the book’s remaining 33 chapters, Engel gathers more than two dozen 3D graphics pros to show you all that can be done with vertex and pixel shaders. They’re an impressive crowd: both game designers and the engineers who are implementing programmable shaders for ATI, nVIDIA, et al. Folks like ATI’s Jason Mitchell, who worked with Microsoft in Redmond to help define the very pixel shader features introduced in this book.

There’s a full section on vertex shader tricks, including vertex decompression, shadow volume extrusion, lighting a single-surface object, and using Perlin Noise, Ken Perlin’s classic technique for producing natural appearing textures on computer generated surfaces.

Next, Engel’s team moves on to pixel shader tricks -- and this is the real heart of the book. You’ll find case studies and code that demonstrate how to blend textures for terrain; emulate geometry with shaders; create smooth lighting effects; and build more accurate environment-mapped reflections and refractions by adjusting for object distance. Kenneth Hurley, now at nVIDIA but with 17 years of game development experience at the likes of Activision, EA, and Intel, shows how to use vertex and pixel shaders to create photorealistic faces. There are chapters on rendering animated grass, texture perturbations, ocean water, rippling water, crystal and candy, particle flows, and much more.

A shorter section focuses on using 3D textures with shaders, and finally, you’ll find three full chapters on incorporating shaders in the design of advanced game engines.

These days, it’s not easy to set yourself above the pack as a game programmer, but with this book’s techniques, you will. (Bill Camarda)

Bill Camarda is a consultant, writer, and web/multimedia content developer. His 15 books include Special Edition Using Word 2000 and Upgrading & Fixing Networks For Dummies®, Second Edition.

Read More Show Less

Product Details

  • ISBN-13: 9781556220418
  • Publisher: Wordware Publishing, Inc.
  • Publication date: 6/25/1996
  • Series: Wordware Game Developer's Library
  • Edition description: BK&CD-ROM
  • Pages: 494
  • Product dimensions: 7.58 (w) x 9.30 (h) x 1.51 (d)

Table of Contents

Foreword xvi
Acknowledgments xvii
Part 1 Introduction to Shader Programming
Fundamentals of Vertex Shaders 4
What You Need to Know/Equipment 5
Vertex Shaders in the Pipeline 5
Why Use Vertex Shaders? 7
Vertex Shader Tools 8
Vertex Shader Architecture 16
High-Level View of Vertex Shader Programming 18
What Happens Next? 35
Programming Vertex Shaders 38
RacorX 38
RacorX2 49
RacorX3 53
RacorX4 59
RacorX5 66
What Happens Next? 70
Fundamentals of Pixel Shaders 72
Why Use Pixel Shaders? 72
Pixel Shaders in the Pipeline 74
Pixel Shader Tools 79
Pixel Shader Architecture 81
High-Level View of Pixel Shader Programming 84
Summary 121
What Happens Next? 122
Programming Pixel Shaders 125
RacorX6 125
RacorX7 137
RacorX8 140
RacorX9 144
Further Reading 147
Basic Shader Development with Shader Studio 149
Introduction 149
What You Should Know 149
Create a Vertex Shader 152
Create a Pixel Shader 159
Shaders Reference 160
Assets 169
Further Info 169
Part 2 Vertex Shader Tricks
Vertex Decompression in a Shader 172
Introduction 172
Vertex Compression Overview 172
Vertex Shader Data Types 173
Compressed Vertex Stream Declaration Example 174
Basic Compression 174
Advanced Compression 180
Conclusion 187
Shadow Volume Extrusion Using a Vertex Shader 188
Introduction 188
Creating Shadow Volumes 189
Effect File Code 191
Using Shadow Volumes with Character Animation 192
Character Animation with Direct3D Vertex Shaders 195
Introduction 195
Tweening 195
Skinning 197
Animating Tangent Space for Per-Pixel Lighting 202
Summary 208
Lighting a Single-Surface Object 209
Vertex Shader Code 211
Enhanced Lighting for Thin Objects 213
About the Demo 214
Optimizing Software Vertex Shaders 215
Introduction to Pentium 4 Processor Architecture 216
Introduction to the Streaming SIMD Extensions 217
Optimal Data Arrangement for SSE Instruction Usage 218
How the Vertex Shader Compiler Works 220
A Detailed Example 224
Compendium of Vertex Shader Tricks 228
Introduction 228
Periodic Time 228
One-Shot Effect 229
Random Numbers 229
Flow Control 230
Cross Products 230
Examples 230
Summary 231
Perlin Noise and Returning Results from Shader Programs 232
Limitations of Shaders 232
Perlin Noise and Fractional Brownian Motion 234
Final Thoughts 251
Part 3 Pixel Shader Tricks
Blending Textures for Terrain 256
Image Processing with 1.4 Pixel Shaders in Direct3D 258
Introduction 258
Simple Transfer Functions 259
Filter Kernels 261
Edge Detection 262
Mathematical Morphology 265
Conclusion 268
Hardware Support 269
Sample Application 269
Hallo World--Font Smoothing with Pixel Shaders 270
Emulating Geometry with Shaders--Imposters 273
Smooth Lighting with ps.1.4 277
Per-Pixel Fresnel Term 281
Introduction 281
Fresnel Effects 281
Effect Code 283
Diffuse Cube Mapping 287
Introduction 287
Using Diffuse Cube Maps 287
Generating Dynamic Diffuse Cube Maps 288
Accurate Reflections and Refractions by Adjusting for Object Distance 290
Introduction 290
The Artifacts of Environment Mapping 290
UV Flipping Technique to Avoid Repetition 295
Photorealistic Faces with Vertex and Pixel Shaders 296
Introduction 296
Software 296
Resources 297
3D Model 297
A Word About Optimizations 302
Full Head Mapping 309
What's Next? 312
Environment Mapping for Eyes 315
Facial Animation 317
Conclusion 317
Non-Photorealistic Rendering with Pixel and Vertex Shaders 319
Introduction 319
Rendering Outlines 319
Cartoon Lighting Model 322
Hatching 324
Gooch Lighting 326
Image Space Techniques 328
Conclusion 333
Animated Grass with Pixel and Vertex Shaders 334
Introduction 334
Waving the Grass 334
Lighting the Grass 334
Texture Perturbation Effects 337
Introduction 337
Wispy Clouds 337
Perturbation-Based Fire 342
Plasma Glass 344
Summary 346
Rendering Ocean Water 347
Introduction 347
Sinusoidal Perturbation in a Vertex Shader 348
CMEMBM Pixel Shader with Fresnel Term 350
Ocean Water Shader Source Code 352
Sample Applications 356
Rippling Reflective and Refractive Water 357
Introduction 357
Generating Reflection and Refraction Maps 358
Vertex Shader 358
Pixel Shader 360
Conclusion 362
Crystal/Candy Shader 363
Introduction 363
Setup 363
Vertex Shader 364
Pixel Shader 365
Summary 368
Bubble Shader 369
Introduction 369
Setup 369
Vertex Shader 370
Pixel Shader 372
Summary 375
Per-Pixel Strand-Based Anisotropic Lighting 376
Introduction 376
Strand-Based Illumination 376
Per-Pixel Strand-Based Illumination 378
Summary 382
A Non-Integer Power Function on the Pixel Shader 383
Overview 383
Traditional Techniques 384
Mathematical Details 387
Power Function on the Pixel Shader 391
Applications 396
Summary 402
Bump Mapped BRDF Rendering 405
Introduction 405
Bidirectional Reflectance Distribution Functions 406
Decomposing the Function 407
Reconstruction 407
Adding the Bumps 410
Conclusion 412
Real-Time Simulation and Rendering of Particle Flows 414
Motivation 414
Ingredients 415
How Does a Single Particle Move? 416
Basic Texture Advection: How Do a Bunch of Particles Move? 417
Inflow: Where are the Particles Born? 421
How Can Particles Drop Out? 423
Implementation 423
Summary 425
Part 4 Using 3D Textures with Shaders
3D Textures and Pixel Shaders 428
Introduction 428
3D Textures 428
Application 435
Truly Volumetric Effects 438
The Role of Volume Visualization 438
Basic Volume Graphics 439
Animation of Volume Graphics 441
High-Quality but Fast Volume Rendering 444
Where to Go from Here 446
Acknowledgments 447
Part 5 Engine Design with Shaders
First Thoughts on Designing a Shader-Driven Game Engine 450
Bump Mapping 450
Real-time Lighting 450
Use Detail Textures 451
Use Anisotropic Filtering 451
Split Up Rendering into Independent Passes 451
Use_x2 452
Visualization with the Krass Game Engine 453
Introduction 453
General Structure of the Krass Engine 453
Developmental History of the Rendering Component 454
Previous Drawbacks of Hardware Development 455
Current Drawbacks 455
Ordering Effects in the Krass Engine 456
Application of the IMG Concept for Terrain Rendering 457
Particle Rendering to Exemplify a Specialized Effect Shader 460
Summary 461
Designing a Vertex Shader-Driven 3D Engine for the Quake III Format 463
Quake III Arena Shaders 463
Vertex Program Setup in the Viewer 464
Vertex Shader Effects 467
Rendering Process 471
Summary 472
Glossary 474
About the Authors 481
Index 487
Read More Show Less

Customer Reviews

Average Rating 5
( 1 )
Rating Distribution

5 Star

(1)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing 1 Customer Reviews
  • Anonymous

    Posted July 10, 2002

    The best book I have ever read on DirectX 8.1

    I have read just about every presentation, white paper, and web page there is on vertex and pixel shaders. Now I am kicking myself for having not just waited for this book to come out. It fills in all the gaps, and is full of tricks I never would have thought of on my own.

    Was this review helpful? Yes  No   Report this review
Sort by: Showing 1 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)