Interactive Computer Graphics with WebG... | WHSmith Books
Interactive Computer Graphics with WebGL, Global Edition (7th edition)

Interactive Computer Graphics with WebGL, Global Edition (7th edition)

By: Edward Angel (author), Dave Shreiner (author)Paperback

Up to 2 WeeksUsually despatched within 2 weeks

£55.09 RRP £57.99  You save £2.90 (5%) With FREE Saver Delivery

Description

This book is suitable for undergraduate students in computer science and engineering, for students in other disciplines who have good programming skills, and for professionals. Computer animation and graphics are now prevalent in everyday life from the computer screen, to the movie screen, to the smart phone screen. The growing excitement about WebGL applications and their ability to integrate HTML5, inspired the authors to exclusively use WebGL in the Seventh Edition of Interactive Computer Graphics with WebGL. Thisis the only introduction to computer graphics text for undergraduates that fully integrates WebGL and emphasizes application-based programming. The top-down, programming-oriented approach allows for coverage of engaging 3D material early in the course so students immediately begin to create their own 3D graphics. Teaching and Learning ExperienceThis program will provide a better teaching and learning experience-for you and your students. It will help:Engage Students Immediately with 3D Material: A top-down, programming-oriented approach allows for coverage of engaging 3D material early in the course so students immediately begin to create their own graphics. Introduce Computer Graphics Programming with WebGL and JavaScript: WebGL is not only fully shader-based-each application must provide at least a vertex shader and a fragment shader-but also a version that works within the latest web browsers.

Contents

CHAPTER 1 GRAPHICS SYSTEMS AND MODELS 11.1 Applications of Computer Graphics 21.1.1 Display of Information 21.1.2 Design 31.1.3 Simulation and Animation 31.1.4 User Interfaces 41.2 A Graphics System 51.2.1 Pixels and the Framebuffer 51.2.2 The CPU and the GPU 61.2.3 Output Devices 71.2.4 Input Devices 91.3 Images: Physical and Synthetic 101.3.1 Objects and Viewers 101.3.2 Light and Images 121.3.3 Imaging Models 131.4 Imaging Systems 151.4.1 The Pinhole Camera 151.4.2 The Human Visual System 171.5 The Synthetic-Camera Model 181.6 The Programmer's Interface 201.6.1 The Pen-Plotter Model 211.6.2 Three-Dimensional APIs 231.6.3 A Sequence of Images 261.6.4 The Modeling-Rendering Paradigm 271.7 Graphics Architectures 281.7.1 Display Processors 291.7.2 Pipeline Architectures 291.7.3 The Graphics Pipeline 301.7.4 Vertex Processing 311.7.5 Clipping and Primitive Assembly 311.7.6 Rasterization 321.7.7 Fragment Processing 321.8 Programmable Pipelines 321.9 Performance Characteristics 331.10 OpenGL Versions and WebGL 34Summary and Notes 36Suggested Readings 36Exercises 37 CHAPTER 2 GRAPHICS PROGRAMMING 392.1 The Sierpinski Gasket 392.2 Programming Two-Dimensional Applications 422.3 The WebGL Application Programming Interface 472.3.1 Graphics Functions 472.3.2 The Graphics Pipeline and State Machines 492.3.3 OpenGL and WebGL 502.3.4 The WebGL Interface 502.3.5 Coordinate Systems 512.4 Primitives and Attributes 532.4.1 Polygon Basics 552.4.2 Polygons in WebGL 562.4.3 Approximating a Sphere 572.4.4 Triangulation 582.4.5 Text 592.4.6 Curved Objects 602.4.7 Attributes 612.5 Color 622.5.1 RGB Color 642.5.2 Indexed Color 662.5.3 Setting of Color Attributes 672.6 Viewing 682.6.1 The Orthographic View 682.6.2 Two-Dimensional Viewing 712.7 Control Functions 712.7.1 Interaction with the Window System 722.7.2 Aspect Ratio and Viewports 732.7.3 Application Organization 742.8 The Gasket Program 752.8.1 Sending Data to the GPU 782.8.2 Rendering the Points 782.8.3 The Vertex Shader 792.8.4 The Fragment Shader 802.8.5 Combining the Parts 802.8.6 The initShaders Function 812.8.7 The init Function 822.8.8 Reading the Shaders from the Application 832.9 Polygons and Recursion 832.10 The Three-Dimensional Gasket 862.10.1 Use of Three-Dimensional Points 862.10.2 Naming Conventions 882.10.3 Use of Polygons in Three Dimensions 882.10.4 Hidden-Surface Removal 91Summary and Notes 93Suggested Readings 94Exercises 95 CHAPTER 3 INTERACTION AND ANIMATION 993.1 Animation 993.1.1 The Rotating Square 1003.1.2 The Display Process 1023.1.3 Double Buffering 1033.1.4 Using a Timer 1043.1.5 Using setAnimFrame 1053.2 Interaction 1063.3 Input Devices 1073.4 Physical Input Devices 1083.4.1 Keyboard Codes 1083.4.2 The Light Pen 1093.4.3 The Mouse and the Trackball 1093.4.4 Data Tablets,Touch Pads, and Touch Screens 1103.4.5 The Joystick 1113.4.6 Multidimensional Input Devices 1113.4.7 Logical Devices 1123.4.8 Input Modes 1133.5 Clients and Servers 1153.6 Programming Event-Driven Input 1163.6.1 Events and Event Listeners 1173.6.2 Adding a Button 1173.6.3 Menus 1193.6.4 Using Keycodes 1203.6.5 Sliders 1213.7 Position Input 1223.8 Window Events 1233.9 Picking 1253.10 Building Models Interactively 1263.11 Design of Interactive Programs 130Summary and Notes 130Suggested Readings 131Exercises 132 CHAPTER 4 GEOMETRIC OBJECTS AND TRANSFORMATIONS 1354.1 Scalars, Points, and Vectors 1364.1.1 Geometric Objects 1364.1.2 Coordinate-Free Geometry 1384.1.3 The Mathematical View: Vector and Affine Spaces 1384.1.4 The Computer Science View 1394.1.5 Geometric ADTs 1404.1.6 Lines 1414.1.7 Affine Sums 1414.1.8 Convexity 1424.1.9 Dot and Cross Products 1424.1.10 Planes 1434.2 Three-Dimensional Primitives 1454.3 Coordinate Systems and Frames 1464.3.1 Representations and N-Tuples 1484.3.2 Change of Coordinate Systems 1494.3.3 Example: Change of Representation 1514.3.4 Homogeneous Coordinates 1534.3.5 Example: Change in Frames 1554.3.6 Working with Representations 1574.4 Frames in WebGL 1594.5 Matrix and Vector Types 1634.5.1 Row versus Column Major Matrix Representations 1654.6 Modeling a Colored Cube 1654.6.1 Modeling the Faces 1664.6.2 Inward- and Outward-Pointing Faces 1674.6.3 Data Structures for Object Representation 1674.6.4 The Colored Cube 1684.6.5 Color Interpolation 1704.6.6 Displaying the Cube 1704.6.7 Drawing with Elements 1714.7 Affine Transformations 1724.8 Translation, Rotation, and Scaling 1754.8.1 Translation 1754.8.2 Rotation 1764.8.3 Scaling 1774.9 Transformations in Homogeneous Coordinates 1794.9.1 Translation 1794.9.2 Scaling 1814.9.3 Rotation 1814.9.4 Shear 1834.10 Concatenation of Transformations 1844.10.1 Rotation About a Fixed Point 1854.10.2 General Rotation 1864.10.3 The Instance Transformation 1874.10.4 Rotation About an Arbitrary Axis 1884.11 Transformation Matrices in WebGL 1914.11.1 Current Transformation Matrices 1924.11.2 Basic Matrix Functions 1934.11.3 Rotation, Translation, and Scaling 1944.11.4 Rotation About a Fixed Point 1954.11.5 Order of Transformations 1954.12 Spinning of the Cube 1964.12.1 Uniform Matrices 1984.13 Interfaces to Three-Dimensional Applications 2004.13.1 Using Areas of the Screen 2014.13.2 A Virtual Trackball 2014.13.3 Smooth Rotations 2044.13.4 Incremental Rotation 2054.14 Quaternions 2064.14.1 Complex Numbers and Quaternions 2064.14.2 Quaternions and Rotation 2074.14.3 Quaternions and Gimbal Lock 209Summary and Notes 210Suggested Readings 211Exercises 211 CHAPTER 5 VIEWING 2155.1 Classical and Computer Viewing 2155.1.1 Classical Viewing 2175.1.2 Orthographic Projections 2175.1.3 Axonometric Projections 2185.1.4 Oblique Projections 2205.1.5 Perspective Viewing 2215.2 Viewing with a Computer 2225.3 Positioning of the Camera 2245.3.1 Positioning of the Camera Frame 2245.3.2 Two Viewing APIs 2295.3.3 The Look-At Function 2325.3.4 Other Viewing APIs 2335.4 Parallel Projections 2345.4.1 Orthogonal Projections 2345.4.2 Parallel Viewing with WebGL 2355.4.3 Projection Normalization 2365.4.4 Orthogonal Projection Matrices 2375.4.5 Oblique Projections 2395.4.6 An Interactive Viewer 2425.5 Perspective Projections 2445.5.1 Simple Perspective Projections 2455.6 Perspective Projections with WebGL 2485.6.1 Perspective Functions 2495.7 Perspective Projection Matrices 2505.7.1 Perspective Normalization 2505.7.2 WebGL Perspective Transformations 2545.7.3 Perspective Example 2565.8 Hidden-Surface Removal 2565.8.1 Culling 2585.9 Displaying Meshes 2595.9.1 Displaying Meshes as Surfaces 2625.9.2 Polygon Offset 2645.9.3 Walking through a Scene 2655.10 Projections and Shadows 2655.10.1 Projected Shadows 2665.11 Shadow Maps 270Summary and Notes 271Suggested Readings 272Exercises 272 CHAPTER 6 LIGHTING AND SHADING 2756.1 Light and Matter 2766.2 Light Sources 2796.2.1 Color Sources 2806.2.2 Ambient Light 2806.2.3 Point Sources 2816.2.4 Spotlights 2826.2.5 Distant Light Sources 2826.3 The Phong Reflection Model 2836.3.1 Ambient Reflection 2856.3.2 Diffuse Reflection 2856.3.3 Specular Reflection 2866.3.4 The Modified Phong Model 2886.4 Computation of Vectors 2896.4.1 Normal Vectors 2896.4.2 Angle of Reflection 2926.5 Polygonal Shading 2936.5.1 Flat Shading 2936.5.2 Smooth and Gouraud Shading 2946.5.3 Phong Shading 2966.6 Approximation of a Sphere by Recursive Subdivision 2976.7 Specifying Lighting Parameters 2996.7.1 Light Sources 2996.7.2 Materials 3016.8 Implementing a Lighting Model 3016.8.1 Applying the Lighting Model in the Application 3026.8.2 Efficiency 3046.8.3 Lighting in the Vertex Shader 3056.9 Shading of the Sphere Model 3106.10 Per-Fragment Lighting 3116.11 Nonphotorealistic Shading 3136.12 Global Illumination 314Summary and Notes 315Suggested Readings 316Exercises 316 CHAPTER 7 DISCRETE TECHNIQUES 3197.1 Buffers 3207.2 Digital Images 3217.3 Mapping Methods 3257.4 Two-Dimensional Texture Mapping 3277.5 Texture Mapping in WebGL 3337.5.1 Texture Objects 3347.5.2 The Texture Image Array 3357.5.3 Texture Coordinates and Samplers 3367.5.4 Texture Sampling 3417.5.5 Working with Texture Coordinates 3447.5.6 Multitexturing 3457.6 Texture Generation 3487.7 Environment Maps 3497.8 Reflection Map Example 3537.9 Bump Mapping 3577.9.1 Finding Bump Maps 3587.9.2 Bump Map Example 3617.10 Blending Techniques 3657.10.1 Opacity and Blending 3667.10.2 Image Blending 3677.10.3 Blending in WebGL 3677.10.4 Antialiasing Revisited 3697.10.5 Back-to-Front and Front-to-Back Rendering 3717.10.6 Scene Antialiasing and Multisampling 3717.10.7 Image Processing 3727.10.8 Other Multipass Methods 3747.11 GPGPU 3747.12 Framebuffer Objects 3787.13 Buffer Ping-Ponging 3847.14 Picking 387Summary and Notes 392Suggested Readings 393Exercises 394 CHAPTER 8 FROM GEOMETRY TO PIXELS 3978.1 Basic Implementation Strategies 3988.2 Four Major Tasks 4008.2.1 Modeling 4008.2.2 Geometry Processing 4018.2.3 Rasterization 4028.2.4 Fragment Processing 4038.3 Clipping 4038.4 Line-Segment Clipping 4048.4.1 Cohen-Sutherland Clipping 4048.4.2 Liang-Barsky Clipping 4078.5 Polygon Clipping 4088.6 Clipping of Other Primitives 4108.6.1 Bounding Boxes and Volumes 4108.6.2 Curves, Surfaces, and Text 4128.6.3 Clipping in the Framebuffer 4138.7 Clipping in Three Dimensions 4138.8 Rasterization 4168.9 Bresenham's Algorithm 4188.10 Polygon Rasterization 4208.10.1 Inside-Outside Testing 4218.10.2 WebGL and Concave Polygons 4228.10.3 Fill and Sort 4238.10.4 Flood Fill 4238.10.5 Singularities 4248.11 Hidden-Surface Removal 4248.11.1 Object-Space and Image-Space Approaches 4248.11.2 Sorting and Hidden-Surface Removal 4268.11.3 Scan Line Algorithms 4268.11.4 Back-Face Removal 4278.11.5 The z-Buffer Algorithm 4298.11.6 Scan Conversion with the z-Buffer 4318.11.7 Depth Sort and the Painter's Algorithm 4328.12 Antialiasing 4358.13 Display Considerations 4378.13.1 Color Systems 4378.13.2 The Color Matrix 4418.13.3 Gamma Correction 4418.13.4 Dithering and Halftoning 442Summary and Notes 443Suggested Readings 445Exercises 445 CHAPTER 9 MODELING AND HIERARCHY 4499.1 Symbols and Instances 4509.2 Hierarchical Models 4519.3 A Robot Arm 4539.4 Trees and Traversal 4569.4.1 A Stack-Based Traversal 4579.5 Use of Tree Data Structures 4609.6 Animation 4649.7 Graphical Objects 4659.7.1 Methods, Attributes, and Messages 4669.7.2 A Cube Object 4679.7.3 Objects and Hierarchy 4689.7.4 Geometric and Nongeometric Objects 4699.8 Scene Graphs 4709.9 Implementing Scene Graphs 4729.10 Other Tree Structures 4749.10.1 CSG Trees 4749.10.2 BSP Trees 4759.10.3 Quadtrees and Octrees 478Summary and Notes 479Suggested Readings 480Exercises 480 CHAPTER 10 PROCEDURAL METHODS 48310.1 Algorithmic Models 48310.2 Physically Based Models and Particle Systems 48510.3 Newtonian Particles 48610.3.1 Independent Particles 48810.3.2 Spring Forces 48810.3.3 Attractive and Repulsive Forces 49010.4 Solving Particle Systems 49110.5 Constraints 49410.5.1 Collisions 49410.5.2 Soft Constraints 49610.6 A Simple Particle System 49710.6.1 Displaying the Particles 49810.6.2 Updating Particle Positions 49810.6.3 Collisions 49910.6.4 Forces 50010.6.5 Flocking 50010.7 Agent-Based Models 50110.8 Language-Based Models 50310.9 Recursive Methods and Fractals 50710.9.1 Rulers and Length 50810.9.2 Fractal Dimension 50910.9.3 Midpoint Division and Brownian Motion 51010.9.4 Fractal Mountains 51110.9.5 The Mandelbrot Set 51210.9.6 Mandelbrot Fragment Shader 51610.10 Procedural Noise 517Summary and Notes 521Suggested Readings 521Exercises 522 CHAPTER 11 CURVES AND SURFACES 52511.1 Representation of Curves and Surfaces 52511.1.1 Explicit Representation 52511.1.2 Implicit Representations 52711.1.3 Parametric Form 52811.1.4 Parametric Polynomial Curves 52911.1.5 Parametric Polynomial Surfaces 53011.2 Design Criteria 53011.3 Parametric Cubic Polynomial Curves 53211.4 Interpolation 53311.4.1 Blending Functions 53411.4.2 The Cubic Interpolating Patch 53611.5 Hermite Curves and Surfaces 53811.5.1 The Hermite Form 53811.5.2 Geometric and Parametric Continuity 54011.6 Be zier Curves and Surfaces 54111.6.1 Be zier Curves 54211.6.2 Be zier Surface Patches 54411.7 Cubic B-Splines 54511.7.1 The Cubic B-Spline Curve 54511.7.2 B-Splines and Basis 54811.7.3 Spline Surfaces 54911.8 General B-Splines 55011.8.1 Recursively Defined B-Splines 55111.8.2 Uniform Splines 55211.8.3 Nonuniform B-Splines 55211.8.4 NURBS 55311.8.5 Catmull-Rom Splines 55411.9 Rendering Curves and Surfaces 55511.9.1 Polynomial Evaluation Methods 55611.9.2 Recursive Subdivision of Be zier Polynomials 55711.9.3 Rendering Other Polynomial Curves by Subdivision 56011.9.4 Subdivision of Be zier Surfaces 56111.10 The Utah Teapot 56211.11 Algebraic Surfaces 56511.11.1 Quadrics 56511.11.2 Rendering of Surfaces by Ray Casting 56611.12 Subdivision Curves and Surfaces 56711.12.1 Mesh Subdivision 56811.13 Mesh Generation from Data 57111.13.1 Height Fields Revisited 57111.13.2 Delaunay Triangulation 57111.13.3 Point Clouds 57511.14 Graphics API support for Curves and Surfaces 57611.14.1 Tessellation Shading 57611.14.2 Geometry Shading 577Summary and Notes 577Suggested Readings 578Exercises 578 CHAPTER 12 ADVANCED RENDERING 58112.1 Going Beyond Pipeline Rendering 58112.2 Ray Tracing 58212.3 Building a Simple Ray Tracer 58612.3.1 Recursive Ray Tracing 58612.3.2 Calculating Intersections 58812.3.3 Ray-Tracing Variations 59012.4 The Rendering Equation 59112.5 Radiosity 59312.5.1 The Radiosity Equation 59412.5.2 Solving the Radiosity Equation 59512.5.3 Computing Form Factors 59712.5.4 Carrying Out Radiosity 59912.6 Global Illumination and Path Tracing 60012.7 RenderMan 60212.8 Parallel Rendering 60312.8.1 Sort-Middle Rendering 60512.8.2 Sort-Last Rendering 60612.8.3 Sort-First Rendering 61012.9 Hardware GPU Implementations 61112.10 Implicit Functions and Contour Maps 61212.10.1 Marching Squares 61312.10.2 Marching Triangles 61712.11 Volume Rendering 61812.11.1 Volumetric Data Sets 61812.11.2 Visualization of Implicit Functions 61912.12 Isosurfaces and Marching Cubes 62112.13 Marching Tetrahedra 62412.14 Mesh Simplification 62512.15 Direct Volume Rendering 62512.15.1 Assignment of Color and Opacity 62612.15.2 Splatting 62712.15.3 Volume Ray Tracing 62812.15.4 Texture Mapping of Volumes 62912.16 Image-Based Rendering 63012.16.1 A Simple Example 630Summary and Notes 632Suggested Readings 633Exercises 634 APPENDIX A INITIALIZING SHADERS 637A.1 Shaders in the HTML file 637A.2 Reading Shaders from Source Files 640APPENDIX B SPACES 643B.1 Scalars 643B.2 Vector Spaces 644B.3 Affine Spaces 646B.4 Euclidean Spaces 647B.5 Projections 648B.6 Gram-Schmidt Orthogonalization 649Suggested Readings 650Exercises 650APPENDIX C MATRICES 651C.1 Definitions 651C.2 Matrix Operations 652C.3 Row and Column Matrices 653C.4 Rank 654C.5 Change of Representation 655C.6 The Cross Product 657C.7 Eigenvalues and Eigenvectors 657C.8 Vector and Matrix Classes 659Suggested Readings 659Exercises 660APPENDIX D SAMPLING AND ALIASING 661D.1 Sampling Theory 661D.2 Reconstruction 666D.3 Quantization 668References 669

Product Details

  • ISBN13: 9781292019345
  • Format: Paperback
  • Number Of Pages: 752
  • ID: 9781292019345
  • weight: 1154
  • ISBN10: 1292019344
  • edition: 7th edition

Delivery Information

  • Saver Delivery: Yes
  • 1st Class Delivery: Yes
  • Courier Delivery: Yes
  • Store Delivery: Yes

Prices are for internet purchases only. Prices and availability in WHSmith Stores may vary significantly

Close