Read more
Informationen zum Autor Andreas Anyuru is a Senior Member of Technical Staff at ST-Ericsson, specializing in Web Technologies. He is experienced in developing web graphics and has worked with implementation and optimization of WebGL and many other web technologies for Linux-based mobile platforms. Wrox Professional guides are written by working developers to address everyday needs. They provide examples, practical solutions, and expert education in new technologies, all designed to help programmers do a better job. Klappentext Everything you need to know about developing hardware-accelerated 3D graphics with WebGL!As the newest technology for creating 3D graphics on the web, in both games, applications, and on regular websites, WebGL gives web developers the capability to produce eye-popping graphics. This book teaches you how to use WebGL to create stunning cross-platform apps. The book features several detailed examples that show you how to develop 3D graphics with WebGL, including explanations of code snippets that help you understand the why behind the how.You will also develop a stronger understanding of WebGL development from coverage that:*Provides a comprehensive overview of WebGL and shows how it relates to other graphics-related technologies*Addresses important topics such as the WebGL graphics pipeline, 3D transformations, texturing and lighting*Teaches you how to write vertex shaders and fragment shaders for WebGL*Includes a lot of useful guidelines, tips, and tricks for WebGL performance optimizationsProfessional WebGL Programming is the first book on the market to delve into this fascinating topic and it puts you on your way to mastering the possibilities that exist with WebGL. Zusammenfassung Everything you need to know about developing hardware-accelerated 3D graphics with WebGL! As the newest technology for creating 3D graphics on the web, in both games, applications, and on regular websites, WebGL gives web developers the capability to produce eye-popping graphics. Inhaltsverzeichnis Introduction xxl CHAPTER 1: INTRODUCING WEBGL 1 The Basics of WebGL 1 So Why Is WebGL So Great? 2 Designing a Graphics API 3 An Immediate-Mode API 3 A Retained-Mode API 4 An Overview of Graphics Hardware 4 GPU 5 FrameBuffer 5 Texture Memory 7 Video Controller 7 Understanding the WebGL Graphics Pipeline 7 Vertex Shader 8 Primitive Assembly 12 Rasterization 14 Fragment Shader 14 Per Fragment Operations 17 Comparing WebGL to Other Graphics Technologies 19 OpenGL 19 OpenGL ES 2.0 21 Direct3D 23 HTML5 Canvas 24 Scalable Vector Graphics 28 VRML and X3D 30 Linear Algebra for 3D Graphics 31 Coordinate System 31 Points or Vertices 31 Vectors 32 Dot Product or Scalar Product 33 Cross Product 34 Homogeneous Coordinates 35 Matrices 35 Affine Transformations 38 Summary 44 CHAPTER 2: CREATING BASIC WEBGL EXAMPLES 45 Drawing a Triangle 46 Creating the WebGL Context 49 Creating the Vertex Shader and the Fragment Shader 51 Compiling the Shaders 52 Creating the Program Object and Linking the Shaders 53 Setting Up the Buffers 54 Drawing the Scene 56 Understanding the WebGL Coding Style 57 Debugging Your WebGL Application 58 Using Chrome Developer Tools 58 Using Firebug 65 WebGL Error Handling and Error Codes 67 WebGL Inspector 70 Troubleshooting WebGL 76 Using the DOM API to Load Your Shaders 78 Putting It Together in a Slightly More Advanced Example 80 Experimenting with Code 83 Summary 84 CHAPTER 3: DRAWING 85 WebGL Drawing Primitives and Drawing Methods 86 ...