WebGL Gems
Author | : Greg Sidelnikov |
Publisher | : |
Total Pages | : 397 |
Release | : 2017-06 |
Genre | : |
ISBN | : 9781521399590 |
Download WebGL Gems Book in PDF, ePub and Kindle
WebGL Gems is a 3D graphics programming book for game developers who wish to learn how to make games in web browsers. Each of 32 "gems" contains detailed walkthrough with complete source code.Table of ContentsGem 1 - JavaScript Canvas Initializing 2D Context Ensuring Graphics Assets Are Fully Downloaded Loading Multiple Types Of Resources Simultaneously Initializing 3D ContextGem 2 - Initializing WebGLGem 3 - Simplified WebGL Pipeline In WebGL Browser Takes Care of Double Buffering Drawing Basic Primitives And Then There Were Attributes What Exactly Is Varying? From OpenGL to WebGLGem 4 - Clearing the Screen For JavaScript PuristsGem 5 - Matrix Principles Introduction to Matrices Common 3D Matrices Model View Projection Matrix Gradual Discovery Birth of the Matrix Matrix Multiplication Multiplication Order Who Is Moving? Who Is Staying? Shadow Casting Basic Representation Translation and Rotation Starfield Demo Simple Particle Engine The Star Class Clipping Planes Starfield Demo Results Matrix Structure Sequential Order Homogeneous Coordinates Row-Major and Column-Major Matrix Notations Default Camera Position Efficient Cross-Matrix Calculations Common Cross-Matrix Operations Multiplication Tangent Metamorphosis Into Camera's View Matrix Other Common Matrix Operations Local and World Coordinate System Rotation Matrix Rotation Around Z-axis Rotation Around X-axis Rotation Around Y-axis Translation Matrix Scale Matrix Using a 3D Matrix JavaScript Library Matrix Libraries And Where To Get One Matrix Library Examples Conclusion Gem 6 - Simple Shader Example Simple Fragment Shader Shaders In a String Initializing Shader Program Multiple Shader Programs Drawing a Point Gem 7 - Drawing a Point Creating Shader Program ManagerGem 8 - Loading Shaders From Files Initializing WebGL Shaders From FilesGem 9 - Loading Shaders From Files Loading Shaders Asynchronously Waiting for Shaders to Load Cache BustingGem 10 - Drawing in SpaceGem 11 - 3D Transformations Translating Scaling 3D Transformations The Four Transformations Viewport Transformation The Viewing Transformation The Modeling Transformation The Modelview Transformation The Projection Transformation The Viewport Transformation 3D Transformation Order Gem 12 - Draw TriangleGem 13 - Vector Class Vector Class Vector Representation Adding Vectors Subtracting Vectors Multiply Vectors Division Length Cross Product Dot Product Gem 14 - Vertex-Colored Triangle Binding To a Secondary Buffer Binding One Buffer At A Time One More Thing Gem 15 - Drawing Multiple TrianglesGem 16 - Controversial Texture Image Loader Appropriate Name Textures In Global Scope One More Thing Gem 17 - Texture-Mapped Triangle Creating Shader for Texture Mapping Gem 18 - Test Cube & Other Specimina Cube Primitives.jsGem 19 - Loading Model Data from PLY Before Moving Forward LoadPLY() Source Code Pseudo Code A Word Of Caution New Level Of Complexity Depth Test ConclusionGem 20 - Imitating First Person "walking" Camera in 3D World Strafing Default DirectionAnd other Gems 21-32Greg Sidelnikov is a Game Developer and tutorial author of several software literature publication since 2003. This volume, WebGL Gems is a special book for game developers who are looking to learn WebGL. The book includes major insights into WebGL graphics library as well as several sections about how to make 2D games in WebGL on JavaScript canvas.