1 / 30

From Turing Machine to Global Illumination

From Turing Machine to Global Illumination. Outline. My first computer (CASIO fx3600) Turning machine and von Neumann architecture GPU pipeline Local and global illumination Shadow and reflection through texture Programmable GPUs. Calculator vs. Computer.

salley
Télécharger la présentation

From Turing Machine to Global Illumination

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. From Turing Machine to Global Illumination

  2. Outline • My first computer (CASIO fx3600) • Turning machine and von Neumann architecture • GPU pipeline • Local and global illumination • Shadow and reflection through texture • Programmable GPUs

  3. Calculator vs. Computer • What is the difference between a calculator and a computer? • Doesn’t a compute-r just “compute”? • The Casio fx3600p calculated can be programmed (38 steps allowed).

  4. Turing Machine • Can be adapted to simulates the logic of any computer that could possibly be constructed. • von Neumann architecture implements a universal Turing machine. • Look them up at Wikipedia!

  5. Outline • My first computer (CASIO fx3600) • Turning machine and von Neumann architecture • GPU pipeline • Local and global illumination • Shadow and reflection through texture • Programmable GPUs

  6. Simplified View • The Data Flow: 3D Polygons (+Colors, Lights, Normals, Texture Coordinates…etc.) • 2D Polygons • 2D Pixels (I.e., Output Images) Transform (& Lighting) Rasterization

  7. Outline • My first computer (CASIO fx3600) • Turning machine and von Neumann architecture • GPU pipeline • Local and global illumination • Shadow and reflection through texture • Programmable GPUs

  8. Global Effects shadow multiple reflection translucent surface

  9. Local vs. Global

  10. How Does GPU Draw This?

  11. Quiz • Q1: A straightforward GPU pipeline give us local illumination only. Why? • Q2: What typical effects are missing? Hint: How is an object drawn? Do they consider the relationship with other objects? Shadow, reflection, and refraction…

  12. With Shadows Without Shadows • Wait but I’ve seen shadow and reflection in games before…

  13. Outline • My first computer (CASIO fx3600) • Turning machine and von Neumann architecture • GPU pipeline • Local and global illumination • Shadow and reflection through texture • Programmable GPUs

  14. Transform (& Lighting) Rasterization Textures Adding “Memory” to the GPU Computation • Modern GPUs allow: • The usage of multiple textures. • Rendering algorithms that use multiple passes.

  15. Faked Global Illumination • Shadow, Reflection, BRDF…etc. • In theory, real global illumination is not possible in current graphics pipeline: • Conceptually a loop of individual polygons. • No interaction between polygons. • Can this be changed by multi-pass rendering?

  16. Case Study: Shadow Map • Using two textures: color and depth • Relatively straightforward design using pixel (fragment) shaders on GPUs.

  17. Eye’s View Light’s View Depth/Shadow Map Image Source: Cass Everitt et al., “Hardware Shadow Mapping” NVIDIA SDK White Paper

  18. Basic Steps of Shadow Maps • Render the scene from the light’s point of view, • Use the light’s depth buffer as a texture (shadow map), • Projectively texture the shadow map onto the scene, • Use “texture color” (comparison result) in fragment shading.

  19. Outline • My first computer (CASIO fx3600) • Turning machine and von Neumann architecture • GPU pipeline • Local and global illumination • Shadow and reflection through texture • Programmable GPUs

  20. PC Graphics Architecture • Two buses on PC: System Bus (CPU-Memory) and Peripheral I/O Bus. • Before AGP: narrow path (I/O Bus) between main memory and graphics memory (for frame buffer, Z buffer, texture, vertex data…etc.) • AGP and PCI-e speed up the link between host PC and graphics processor (GPU)

  21. Source: http://www.karbosguide.com/hardware/module2d03a.htm

  22. NVIDIA Geforce 6800

  23. NVIDIA Geforce 8800

  24. NVIDIA Fermi (Geforce 400 and 500 Series) From NVIDIA Fermi Architecture Whitepaper http://www.nvidia.com/content/PDF/fermi_white_papers/NVIDIA_Fermi_Compute_Architecture_Whitepaper.pdf

  25. How to Program a GPU? • Writing a 3D graphics application program • Typically in DirectX or OpenGL • Still CPU programming in C/C++ • The APIs and drivers do the dirty work for you. • Writing GPU shaders • Typically in GLSL or Cg • Still drawing 3D objects • Working like plug-in’s to the 3D rendering pipeline

  26. GPGPU • General-purpose GPU computing • No longer restricted to graphics applications. • To utilize the abundant “GFLOPs” in GPU. • Could be implemented in GPU shaders • By clever transformation of problem domains. • Textures to store the data structures • However, shaders could not perform memory writes with calculated addresses (a.k.a. scatter operations)

  27. GPU as a Parallel Computing Platform • Treating GPUs as parallel machinery • Not quite the same as shared-memory multi-processor. • A special kind of memory hierarchy. • NVIDIA CUDA • Widely adopted in real-world applications • OpenCL • For non-NV GPUs and multi-core CPUs

  28. Branch Divergence on GPU Warp … if x1 – x0 > y1 – y0: xMajorIteration() else: yMajorIteration() … ½ performance for each branch!

More Related