SlideShare une entreprise Scribd logo
1  sur  29
CS 354
Interaction &
Project 2
Mark Kilgard
University of Texas
March 29, 2012
CS 354                                2



         Today’s material
        In-class quiz
            On compression lecture
        Lecture topic
          Project 2
          Interaction
CS 354                            3



         My Office Hours
        Tuesday, before class
            Painter (PAI) 5.35
            8:45 a.m. to 9:15
        Thursday, after class
            ACE 6.302
            11:00 a.m. to 12


        Randy’s office hours
            Monday & Wednesday
            11 a.m. to 12:00
            Painter (PAI) 5.33
CS 354                                         4



         Last time, this time
        Last lecture, we discussed
          Project 2 on Programmable Shaders
          Compression for Computer Graphics
        This lecture
            Project 2 discussion
                 Get started now
            Interaction
CS 354                                                                       5

                                 On a sheet of paper
         Daily Quiz              • Write your EID, name, and date
                                 • Write #1, #2, #3, #4 followed by its answer

        True or False: A                  True or False: Run-
         hardware texture                   length encoding works
         compression scheme                 well for digital
         must be capable of                 photographs.
         random access
         decompression.                    If the surface normals in
                                            a mesh are each stored
        True or False: Floating            as an index into a set of
         point values are required          256 quantized normals
         to have at least 23 bits           rather than as three 32-
         devoted to the mantissa            bit floating point
         and 8 bits for the                 numbers, what
         exponent.                          compression ratio is
                                            achieved over the
                                            floating-point
                                            representation?
CS 354                                                                   6



         Project 2
        Project is NOW available
            PDF + code to use
        Requirements
          Mostly writing GLSL shaders
          Small amount of C/C++ code
                 Convert height map to normal map
                 Implement NormalMap::computeNormal method
        Intermediate milestone
            Monday, April 2nd
                 Submit snapshots and GLSL code for first two shaders
        Complete project
            Due Friday, April 6th
                 All 9 shaders
                 Embellish for additional credit
CS 354                                                7



         By April 2
        Have these first two shaders tasks
         implemented

                                Task 1: apply decal




          Task 0: roll torus
CS 354                                                  8

         Procedurally Generating a
         Torus from a 2D Grid




         2D grid over (s,t)∈[0,1]
                                    Tessellated torus
CS 354                                                                               9

         GLSL Standard Library Routines
         You’ll Need for Project 2
        texture2D—accesses a 2D texture through a sampler2D and a 2-component
         texture coordinate set (s,t)
        textureCube—access a cube map with a samplerCube and a 3-component
         texture coordinate set (s,t,r)
        normalize—normalizes a vector
        cross—computes a cross product of 2 vectors
        dot—computes a dot (inner) product of 2 vectors
        max—compute the maximum of two values
        reflect—compute a reflection vector given an incident vector and a normal
         vector
        vec3—constructor for 3-component vector from scalars
        mat3—constructor for 3x3 matrix from column vectors
        *—matrix-by-vector or vector-by-matrix multiplication
        sin—sine trigonometric function
        cos—cosine trigonometric function
        pow—raise a number to a power, exponentiation (hint: specular)
CS 354                                                10

         Interaction with
         Computer Graphics
      Graphics isn’t just about pretty pictures
      It’s also about interacting with pictures


                                    SketchPad
                                    1963
                                    Ivan Sutherland
CS 354                                                  11



         Event Models
        Polling
          “while loop” reads events & processes them
          Good for events arriving at a regular rate
          Appropriate when events aren’t “digital”
                May require sampling analog signals
        Event-driven
          Structured to avoid “busy waiting”
          Callback-driven programming
                GLUT’s event loop is callback-driven
CS 354                                                                             12

         Physical Events vs.
         Logical Events
        Physical events                       Logical events
            Real-world input                      Examples
            Examples                                   Key press delivered to
                                                         a particular window the
                 Key presses
                                                         mouse cusor is in
                 Physical link layer for               Byte stream from a
                  networking
                                                         network socket
                 Charged-coupled                       Mouse clicked on an
                  device (CCD) captures
                                                         object in a 3D scene
                  image
            May require signal
                                                   Higher-level
             processing to make
             into a digital event
                 Prone to noise
CS 354                                                           13



         Routing Events
      What entity is interested in an event?
      How is the event routed to the interested
       entity?
      Example: window system events
          Mouse events generated by mouse
          Button clicks and movement must go to the
           correct window region
                Window regions arranged hierarchically
            Two or more events may be connected
                The press & release of a mouse must be paired
CS 354                                                           14



         Model-View-Controller
        Software architecture approach
            Separates concerns

                                   Model
             updates                                  modifies
                               Data and logic


                 View                               Controller
                                   modifies
          Interface / display                      User input


                       user responds to view with input
CS 354                                                          15



         Interactivity
        Interaction Latency
            Time from visual display to user action to
             displayed response to user interaction
                 Low latency provides illusion of continuous
                  interaction
        Graphics device display frames
            Roughly 60 frames/second provides
             continuous interaction
               Roughly 16.6 milliseconds
               Display devices tuned to this
CS 354                                                                               16



         Frame Buffering
        Problem with just one framebuffer
          Updating the buffer you are displaying results in flicker and
           tearing
          One solution
                 Timing framebuffer updates to not be updating pixels about to be
                  scanned out
                      Known as “racing the beam”
        Solution: Two buffers
            One to display NOW
            One to render NOW so to display NEXT
            Ping-pong between the two buffers
            Alternatively, copy “draw” buffer to “display” buffer every frame
            Either approach needs synchornization
CS 354                                                17



         Synchronized Buffer Swaps
        Stall generate next frame until displaying
         the last frame
                          16.6 milliseconds
CS 354                                                      18



         Unsynchronized Buffers Swaps
        More frame rendered and lower latency to display
          But tearing artifacts on displays
          And some frames rendered but never displayed
                Wasted work
                                    16.6 milliseconds




                     tearing artifacts
CS 354                                                   19



         Triple Buffering
        Expensive Compromise
          Needs more memory, now 3 buffers
          Renders frames that may never be displayed
          But avoids tearing while minimizing latency


                                  16.6 milliseconds
CS 354                                         20



         Complex Interactions
      Dragging objects
      Cut-and-paste
      Pop-up and pull-down menus
      Selecting an object within a 3D scene
CS 354                                            21

         State Machines to Managed
         Complex Interactions
        Think of on-screen “button”
            You can click with the mouse
            How does it really logically work?
CS 354                                      22



         Manipulators and Choosers



                            Open Inventor
CS 354                                                         23



         Intuitive Interactions
        Make computer behave in a way that’s natural to
         humans
            NOT the other way around
        Good rules of thumb
            Hint what the result of an interaction will be
                 Locate highlight buttons
                 Change cursor shape based on its position
          Provide immediate and continuous display of state
          Show mercy, people make mistakes, be able to undo
          Make manipulation as direct as possible
        Examples
          Dragging and dropping objects
          Pointing to indicate interest
CS 354                                                                               24



         Back Projection
        User clicks on screen…
        Question: What object got “clicked”?
          Known as “picking” in 3D applications
          Basic operation in 3D applications
        Process
            Window system maps click to (x,y) in a particular window
                 Delivers the event to application selecting events on the window
            Applications gets (x,y) in window space
                 Walk through scene graph
                 Invert viewport, projection, and modelview transforms
                      Back project point to object space ray
                 Intersect the ray with each object in scene graph
                      Does the ray intersect the object?
                      What intersected object is the closest?
                 Return the nearest object intersecting the ray as a “hit”
CS 354                                                                                               25



         Conceptual Vertex Transformation
   glVertex*
               object-space coordinates      Modelview      eye-space coordinates         User-defined
      API           (xo,yo,zo,wo)             matrix            (xe,ye,ze,we)              clip planes
  commands
                                                                  (xe,ye,ze,we)

                                             clipped eye-space coordinates
                                                     (xe,ye,ze,we)

                          clip-space                                 clipped clip-space
     Projection          coordinates         View-frustum                coordinates      Perspective
       matrix            (xc,yc,zc,wc)        clip planes               (xc,yc,zc,wc)      division


                  normalized device coordinates (NDC)
                                   (xn,yn,zn,1/wc)

                                                         window-space
                  Viewport + Depth Range                  coordinates            to primitive
                      transformation                        (xw,yw,zw,1/wc)      rasterization
CS 354                                                                                               26



         Reversed Vertex Transformation
   glVertex*
               object-space coordinates      Modelview      eye-space coordinates         User-defined
      API           (xo,yo,zo,wo)             matrix            (xe,ye,ze,we)              clip planes
  commands
                                                                  (xe,ye,ze,we)

                                             clipped eye-space coordinates
                                                     (xe,ye,ze,we)

                          clip-space                                 clipped clip-space
     Projection          coordinates         View-frustum                coordinates      Perspective
       matrix            (xc,yc,zc,wc)        clip planes               (xc,yc,zc,wc)      division


                  normalized device coordinates (NDC)
                                   (xn,yn,zn,1/wc)
                                                                                    (x,y) mouse event
                                                         window-space
                  Viewport + Depth Range                  coordinates            to primitive
                      transformation                        (xw,yw,zw,1/wc)      rasterization
CS 354                                         27

         New Current
         Interaction Paradigms
        Multi-touch screens
            Phones, tablets… work surfaces?




                 Perceptive Pixel
CS 354                                               28



         Where next?
        Visual, tactile, gestures, speech, highly
         responsive, emotionally aware
            Minority Report interface…
CS 354                                                      29



         Next Class
        Next lecture
            Procedural methods
            Making shape, appearance, and animation from
             programs—instead of data
        Project 2
            Start learning GLSL and doing project
            Due Friday, April 6th
            Incremental deadline on April 2nd
                 First two tasks

Contenu connexe

Tendances

CS 354 Programmable Shading
CS 354 Programmable ShadingCS 354 Programmable Shading
CS 354 Programmable ShadingMark Kilgard
 
CS 354 Vector Graphics & Path Rendering
CS 354 Vector Graphics & Path RenderingCS 354 Vector Graphics & Path Rendering
CS 354 Vector Graphics & Path RenderingMark Kilgard
 
CS 354 Surfaces, Programmable Tessellation, and NPR Graphics
CS 354 Surfaces, Programmable Tessellation, and NPR GraphicsCS 354 Surfaces, Programmable Tessellation, and NPR Graphics
CS 354 Surfaces, Programmable Tessellation, and NPR GraphicsMark Kilgard
 
CS 354 More Graphics Pipeline
CS 354 More Graphics PipelineCS 354 More Graphics Pipeline
CS 354 More Graphics PipelineMark Kilgard
 
CS 354 Acceleration Structures
CS 354 Acceleration StructuresCS 354 Acceleration Structures
CS 354 Acceleration StructuresMark Kilgard
 
CS 354 Texture Mapping
CS 354 Texture MappingCS 354 Texture Mapping
CS 354 Texture MappingMark Kilgard
 
Shadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareShadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareMark Kilgard
 
CS 354 Introduction
CS 354 IntroductionCS 354 Introduction
CS 354 IntroductionMark Kilgard
 
CS 354 Understanding Color
CS 354 Understanding ColorCS 354 Understanding Color
CS 354 Understanding ColorMark Kilgard
 
Real-time Shadowing Techniques: Shadow Volumes
Real-time Shadowing Techniques: Shadow VolumesReal-time Shadowing Techniques: Shadow Volumes
Real-time Shadowing Techniques: Shadow VolumesMark Kilgard
 
CS 354 Pixel Updating
CS 354 Pixel UpdatingCS 354 Pixel Updating
CS 354 Pixel UpdatingMark Kilgard
 
CS 354 Blending, Compositing, Anti-aliasing
CS 354 Blending, Compositing, Anti-aliasingCS 354 Blending, Compositing, Anti-aliasing
CS 354 Blending, Compositing, Anti-aliasingMark Kilgard
 
An Introduction to NV_path_rendering
An Introduction to NV_path_renderingAn Introduction to NV_path_rendering
An Introduction to NV_path_renderingMark Kilgard
 
CS 354 Viewing Stuff
CS 354 Viewing StuffCS 354 Viewing Stuff
CS 354 Viewing StuffMark Kilgard
 
Clustered defered and forward shading
Clustered defered and forward shadingClustered defered and forward shading
Clustered defered and forward shadingWuBinbo
 
CS 354 Transformation, Clipping, and Culling
CS 354 Transformation, Clipping, and CullingCS 354 Transformation, Clipping, and Culling
CS 354 Transformation, Clipping, and CullingMark Kilgard
 
A Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyA Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyIOSR Journals
 
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated Rendering
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated RenderingPractical and Robust Stenciled Shadow Volumes for Hardware-Accelerated Rendering
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated RenderingMark Kilgard
 
Mesh Generation and Topological Data Analysis
Mesh Generation and Topological Data AnalysisMesh Generation and Topological Data Analysis
Mesh Generation and Topological Data AnalysisDon Sheehy
 

Tendances (20)

CS 354 Programmable Shading
CS 354 Programmable ShadingCS 354 Programmable Shading
CS 354 Programmable Shading
 
CS 354 Vector Graphics & Path Rendering
CS 354 Vector Graphics & Path RenderingCS 354 Vector Graphics & Path Rendering
CS 354 Vector Graphics & Path Rendering
 
CS 354 Typography
CS 354 TypographyCS 354 Typography
CS 354 Typography
 
CS 354 Surfaces, Programmable Tessellation, and NPR Graphics
CS 354 Surfaces, Programmable Tessellation, and NPR GraphicsCS 354 Surfaces, Programmable Tessellation, and NPR Graphics
CS 354 Surfaces, Programmable Tessellation, and NPR Graphics
 
CS 354 More Graphics Pipeline
CS 354 More Graphics PipelineCS 354 More Graphics Pipeline
CS 354 More Graphics Pipeline
 
CS 354 Acceleration Structures
CS 354 Acceleration StructuresCS 354 Acceleration Structures
CS 354 Acceleration Structures
 
CS 354 Texture Mapping
CS 354 Texture MappingCS 354 Texture Mapping
CS 354 Texture Mapping
 
Shadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL HardwareShadow Mapping with Today's OpenGL Hardware
Shadow Mapping with Today's OpenGL Hardware
 
CS 354 Introduction
CS 354 IntroductionCS 354 Introduction
CS 354 Introduction
 
CS 354 Understanding Color
CS 354 Understanding ColorCS 354 Understanding Color
CS 354 Understanding Color
 
Real-time Shadowing Techniques: Shadow Volumes
Real-time Shadowing Techniques: Shadow VolumesReal-time Shadowing Techniques: Shadow Volumes
Real-time Shadowing Techniques: Shadow Volumes
 
CS 354 Pixel Updating
CS 354 Pixel UpdatingCS 354 Pixel Updating
CS 354 Pixel Updating
 
CS 354 Blending, Compositing, Anti-aliasing
CS 354 Blending, Compositing, Anti-aliasingCS 354 Blending, Compositing, Anti-aliasing
CS 354 Blending, Compositing, Anti-aliasing
 
An Introduction to NV_path_rendering
An Introduction to NV_path_renderingAn Introduction to NV_path_rendering
An Introduction to NV_path_rendering
 
CS 354 Viewing Stuff
CS 354 Viewing StuffCS 354 Viewing Stuff
CS 354 Viewing Stuff
 
Clustered defered and forward shading
Clustered defered and forward shadingClustered defered and forward shading
Clustered defered and forward shading
 
CS 354 Transformation, Clipping, and Culling
CS 354 Transformation, Clipping, and CullingCS 354 Transformation, Clipping, and Culling
CS 354 Transformation, Clipping, and Culling
 
A Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder PiracyA Video Watermarking Scheme to Hinder Camcorder Piracy
A Video Watermarking Scheme to Hinder Camcorder Piracy
 
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated Rendering
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated RenderingPractical and Robust Stenciled Shadow Volumes for Hardware-Accelerated Rendering
Practical and Robust Stenciled Shadow Volumes for Hardware-Accelerated Rendering
 
Mesh Generation and Topological Data Analysis
Mesh Generation and Topological Data AnalysisMesh Generation and Topological Data Analysis
Mesh Generation and Topological Data Analysis
 

Similaire à CS 354 Interaction

Modern OpenGL scientific visualization
Modern OpenGL scientific visualizationModern OpenGL scientific visualization
Modern OpenGL scientific visualizationNicolas Rougier
 
Patchwork3 D Datasheet January 2009
Patchwork3 D Datasheet January 2009Patchwork3 D Datasheet January 2009
Patchwork3 D Datasheet January 2009CAM3DRT
 
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...Roberto Casadei
 
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...Johan Andersson
 
[AI07] Revolutionizing Image Processing with Cognitive Toolkit
[AI07] Revolutionizing Image Processing with Cognitive Toolkit[AI07] Revolutionizing Image Processing with Cognitive Toolkit
[AI07] Revolutionizing Image Processing with Cognitive Toolkitde:code 2017
 
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)Peter Löwe
 
Neo4j GraphDay Seattle- Sept19- graphs are ai
Neo4j GraphDay Seattle- Sept19-  graphs are aiNeo4j GraphDay Seattle- Sept19-  graphs are ai
Neo4j GraphDay Seattle- Sept19- graphs are aiNeo4j
 
Azure Digital Twins.pdf
Azure Digital Twins.pdfAzure Digital Twins.pdf
Azure Digital Twins.pdfTomasz Kopacz
 
11.secure compressed image transmission using self organizing feature maps
11.secure compressed image transmission using self organizing feature maps11.secure compressed image transmission using self organizing feature maps
11.secure compressed image transmission using self organizing feature mapsAlexander Decker
 
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...I MT
 
2011 3D Technology Trends
2011 3D Technology Trends2011 3D Technology Trends
2011 3D Technology TrendsJens Hupkau
 
Introduction to Deep Learning and Tensorflow
Introduction to Deep Learning and TensorflowIntroduction to Deep Learning and Tensorflow
Introduction to Deep Learning and TensorflowOswald Campesato
 
Deep learning and streaming in Apache Spark 2.2 by Matei Zaharia
Deep learning and streaming in Apache Spark 2.2 by Matei ZahariaDeep learning and streaming in Apache Spark 2.2 by Matei Zaharia
Deep learning and streaming in Apache Spark 2.2 by Matei ZahariaGoDataDriven
 
How to Create 3D Mashups by Integrating GIS, CAD, and BIM
How to Create 3D Mashups by Integrating GIS, CAD, and BIMHow to Create 3D Mashups by Integrating GIS, CAD, and BIM
How to Create 3D Mashups by Integrating GIS, CAD, and BIMSafe Software
 
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 20072009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007Marc Smith
 
Android Malware 2020 (CCCS-CIC-AndMal-2020)
Android Malware 2020 (CCCS-CIC-AndMal-2020)Android Malware 2020 (CCCS-CIC-AndMal-2020)
Android Malware 2020 (CCCS-CIC-AndMal-2020)Indraneel Dabhade
 
Marek Suplata Projects
Marek Suplata ProjectsMarek Suplata Projects
Marek Suplata Projectsguest14f12f
 
Cloud Graphical Rendering: A New Paradigm
Cloud Graphical Rendering:  A New ParadigmCloud Graphical Rendering:  A New Paradigm
Cloud Graphical Rendering: A New ParadigmJoel Isaacson
 
Chi2011 Case Study: Interactive, Dynamic Sparklines
Chi2011 Case Study: Interactive, Dynamic SparklinesChi2011 Case Study: Interactive, Dynamic Sparklines
Chi2011 Case Study: Interactive, Dynamic SparklinesLeo Frishberg
 

Similaire à CS 354 Interaction (20)

Modern OpenGL scientific visualization
Modern OpenGL scientific visualizationModern OpenGL scientific visualization
Modern OpenGL scientific visualization
 
Patchwork3 D Datasheet January 2009
Patchwork3 D Datasheet January 2009Patchwork3 D Datasheet January 2009
Patchwork3 D Datasheet January 2009
 
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...
Pulverisation in Cyber-Physical Systems: Engineering the Self-Organising Logi...
 
pydataPointCloud.pptx
pydataPointCloud.pptxpydataPointCloud.pptx
pydataPointCloud.pptx
 
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
 
[AI07] Revolutionizing Image Processing with Cognitive Toolkit
[AI07] Revolutionizing Image Processing with Cognitive Toolkit[AI07] Revolutionizing Image Processing with Cognitive Toolkit
[AI07] Revolutionizing Image Processing with Cognitive Toolkit
 
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)
Scientific 3D Printing (GFZ GeoInformatics Kollquium April 2012)
 
Neo4j GraphDay Seattle- Sept19- graphs are ai
Neo4j GraphDay Seattle- Sept19-  graphs are aiNeo4j GraphDay Seattle- Sept19-  graphs are ai
Neo4j GraphDay Seattle- Sept19- graphs are ai
 
Azure Digital Twins.pdf
Azure Digital Twins.pdfAzure Digital Twins.pdf
Azure Digital Twins.pdf
 
11.secure compressed image transmission using self organizing feature maps
11.secure compressed image transmission using self organizing feature maps11.secure compressed image transmission using self organizing feature maps
11.secure compressed image transmission using self organizing feature maps
 
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...
Colloque IMT -04/04/2019- L'IA au cœur des mutations industrielles - L'IA pou...
 
2011 3D Technology Trends
2011 3D Technology Trends2011 3D Technology Trends
2011 3D Technology Trends
 
Introduction to Deep Learning and Tensorflow
Introduction to Deep Learning and TensorflowIntroduction to Deep Learning and Tensorflow
Introduction to Deep Learning and Tensorflow
 
Deep learning and streaming in Apache Spark 2.2 by Matei Zaharia
Deep learning and streaming in Apache Spark 2.2 by Matei ZahariaDeep learning and streaming in Apache Spark 2.2 by Matei Zaharia
Deep learning and streaming in Apache Spark 2.2 by Matei Zaharia
 
How to Create 3D Mashups by Integrating GIS, CAD, and BIM
How to Create 3D Mashups by Integrating GIS, CAD, and BIMHow to Create 3D Mashups by Integrating GIS, CAD, and BIM
How to Create 3D Mashups by Integrating GIS, CAD, and BIM
 
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 20072009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007
 
Android Malware 2020 (CCCS-CIC-AndMal-2020)
Android Malware 2020 (CCCS-CIC-AndMal-2020)Android Malware 2020 (CCCS-CIC-AndMal-2020)
Android Malware 2020 (CCCS-CIC-AndMal-2020)
 
Marek Suplata Projects
Marek Suplata ProjectsMarek Suplata Projects
Marek Suplata Projects
 
Cloud Graphical Rendering: A New Paradigm
Cloud Graphical Rendering:  A New ParadigmCloud Graphical Rendering:  A New Paradigm
Cloud Graphical Rendering: A New Paradigm
 
Chi2011 Case Study: Interactive, Dynamic Sparklines
Chi2011 Case Study: Interactive, Dynamic SparklinesChi2011 Case Study: Interactive, Dynamic Sparklines
Chi2011 Case Study: Interactive, Dynamic Sparklines
 

Plus de Mark Kilgard

D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...Mark Kilgard
 
Computers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School StudentsComputers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School StudentsMark Kilgard
 
NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017Mark Kilgard
 
NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017Mark Kilgard
 
NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016Mark Kilgard
 
Virtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUsVirtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUsMark Kilgard
 
Migrating from OpenGL to Vulkan
Migrating from OpenGL to VulkanMigrating from OpenGL to Vulkan
Migrating from OpenGL to VulkanMark Kilgard
 
EXT_window_rectangles
EXT_window_rectanglesEXT_window_rectangles
EXT_window_rectanglesMark Kilgard
 
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...Mark Kilgard
 
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware PipelineAccelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware PipelineMark Kilgard
 
NV_path rendering Functional Improvements
NV_path rendering Functional ImprovementsNV_path rendering Functional Improvements
NV_path rendering Functional ImprovementsMark Kilgard
 
OpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUsOpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUsMark Kilgard
 
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path RenderingSIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path RenderingMark Kilgard
 
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and BeyondSIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and BeyondMark Kilgard
 
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...Mark Kilgard
 
GPU accelerated path rendering fastforward
GPU accelerated path rendering fastforwardGPU accelerated path rendering fastforward
GPU accelerated path rendering fastforwardMark Kilgard
 
GPU-accelerated Path Rendering
GPU-accelerated Path RenderingGPU-accelerated Path Rendering
GPU-accelerated Path RenderingMark Kilgard
 
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web RenderingSIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web RenderingMark Kilgard
 
SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012Mark Kilgard
 

Plus de Mark Kilgard (20)

D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...
 
Computers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School StudentsComputers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School Students
 
NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017
 
NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017
 
NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016
 
Virtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUsVirtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUs
 
Migrating from OpenGL to Vulkan
Migrating from OpenGL to VulkanMigrating from OpenGL to Vulkan
Migrating from OpenGL to Vulkan
 
EXT_window_rectangles
EXT_window_rectanglesEXT_window_rectangles
EXT_window_rectangles
 
OpenGL for 2015
OpenGL for 2015OpenGL for 2015
OpenGL for 2015
 
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
 
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware PipelineAccelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
 
NV_path rendering Functional Improvements
NV_path rendering Functional ImprovementsNV_path rendering Functional Improvements
NV_path rendering Functional Improvements
 
OpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUsOpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUs
 
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path RenderingSIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
 
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and BeyondSIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
 
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
 
GPU accelerated path rendering fastforward
GPU accelerated path rendering fastforwardGPU accelerated path rendering fastforward
GPU accelerated path rendering fastforward
 
GPU-accelerated Path Rendering
GPU-accelerated Path RenderingGPU-accelerated Path Rendering
GPU-accelerated Path Rendering
 
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web RenderingSIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
 
SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012
 

Dernier

08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 

Dernier (20)

08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 

CS 354 Interaction

  • 1. CS 354 Interaction & Project 2 Mark Kilgard University of Texas March 29, 2012
  • 2. CS 354 2 Today’s material  In-class quiz  On compression lecture  Lecture topic  Project 2  Interaction
  • 3. CS 354 3 My Office Hours  Tuesday, before class  Painter (PAI) 5.35  8:45 a.m. to 9:15  Thursday, after class  ACE 6.302  11:00 a.m. to 12  Randy’s office hours  Monday & Wednesday  11 a.m. to 12:00  Painter (PAI) 5.33
  • 4. CS 354 4 Last time, this time  Last lecture, we discussed  Project 2 on Programmable Shaders  Compression for Computer Graphics  This lecture  Project 2 discussion  Get started now  Interaction
  • 5. CS 354 5 On a sheet of paper Daily Quiz • Write your EID, name, and date • Write #1, #2, #3, #4 followed by its answer  True or False: A  True or False: Run- hardware texture length encoding works compression scheme well for digital must be capable of photographs. random access decompression.  If the surface normals in a mesh are each stored  True or False: Floating as an index into a set of point values are required 256 quantized normals to have at least 23 bits rather than as three 32- devoted to the mantissa bit floating point and 8 bits for the numbers, what exponent. compression ratio is achieved over the floating-point representation?
  • 6. CS 354 6 Project 2  Project is NOW available  PDF + code to use  Requirements  Mostly writing GLSL shaders  Small amount of C/C++ code  Convert height map to normal map  Implement NormalMap::computeNormal method  Intermediate milestone  Monday, April 2nd  Submit snapshots and GLSL code for first two shaders  Complete project  Due Friday, April 6th  All 9 shaders  Embellish for additional credit
  • 7. CS 354 7 By April 2  Have these first two shaders tasks implemented Task 1: apply decal Task 0: roll torus
  • 8. CS 354 8 Procedurally Generating a Torus from a 2D Grid 2D grid over (s,t)∈[0,1] Tessellated torus
  • 9. CS 354 9 GLSL Standard Library Routines You’ll Need for Project 2  texture2D—accesses a 2D texture through a sampler2D and a 2-component texture coordinate set (s,t)  textureCube—access a cube map with a samplerCube and a 3-component texture coordinate set (s,t,r)  normalize—normalizes a vector  cross—computes a cross product of 2 vectors  dot—computes a dot (inner) product of 2 vectors  max—compute the maximum of two values  reflect—compute a reflection vector given an incident vector and a normal vector  vec3—constructor for 3-component vector from scalars  mat3—constructor for 3x3 matrix from column vectors  *—matrix-by-vector or vector-by-matrix multiplication  sin—sine trigonometric function  cos—cosine trigonometric function  pow—raise a number to a power, exponentiation (hint: specular)
  • 10. CS 354 10 Interaction with Computer Graphics  Graphics isn’t just about pretty pictures  It’s also about interacting with pictures SketchPad 1963 Ivan Sutherland
  • 11. CS 354 11 Event Models  Polling  “while loop” reads events & processes them  Good for events arriving at a regular rate  Appropriate when events aren’t “digital”  May require sampling analog signals  Event-driven  Structured to avoid “busy waiting”  Callback-driven programming  GLUT’s event loop is callback-driven
  • 12. CS 354 12 Physical Events vs. Logical Events  Physical events  Logical events  Real-world input  Examples  Examples  Key press delivered to a particular window the  Key presses mouse cusor is in  Physical link layer for  Byte stream from a networking network socket  Charged-coupled  Mouse clicked on an device (CCD) captures object in a 3D scene image  May require signal  Higher-level processing to make into a digital event  Prone to noise
  • 13. CS 354 13 Routing Events  What entity is interested in an event?  How is the event routed to the interested entity?  Example: window system events  Mouse events generated by mouse  Button clicks and movement must go to the correct window region  Window regions arranged hierarchically  Two or more events may be connected  The press & release of a mouse must be paired
  • 14. CS 354 14 Model-View-Controller  Software architecture approach  Separates concerns Model updates modifies Data and logic View Controller modifies Interface / display User input user responds to view with input
  • 15. CS 354 15 Interactivity  Interaction Latency  Time from visual display to user action to displayed response to user interaction  Low latency provides illusion of continuous interaction  Graphics device display frames  Roughly 60 frames/second provides continuous interaction  Roughly 16.6 milliseconds  Display devices tuned to this
  • 16. CS 354 16 Frame Buffering  Problem with just one framebuffer  Updating the buffer you are displaying results in flicker and tearing  One solution  Timing framebuffer updates to not be updating pixels about to be scanned out  Known as “racing the beam”  Solution: Two buffers  One to display NOW  One to render NOW so to display NEXT  Ping-pong between the two buffers  Alternatively, copy “draw” buffer to “display” buffer every frame  Either approach needs synchornization
  • 17. CS 354 17 Synchronized Buffer Swaps  Stall generate next frame until displaying the last frame 16.6 milliseconds
  • 18. CS 354 18 Unsynchronized Buffers Swaps  More frame rendered and lower latency to display  But tearing artifacts on displays  And some frames rendered but never displayed  Wasted work 16.6 milliseconds tearing artifacts
  • 19. CS 354 19 Triple Buffering  Expensive Compromise  Needs more memory, now 3 buffers  Renders frames that may never be displayed  But avoids tearing while minimizing latency 16.6 milliseconds
  • 20. CS 354 20 Complex Interactions  Dragging objects  Cut-and-paste  Pop-up and pull-down menus  Selecting an object within a 3D scene
  • 21. CS 354 21 State Machines to Managed Complex Interactions  Think of on-screen “button”  You can click with the mouse  How does it really logically work?
  • 22. CS 354 22 Manipulators and Choosers Open Inventor
  • 23. CS 354 23 Intuitive Interactions  Make computer behave in a way that’s natural to humans  NOT the other way around  Good rules of thumb  Hint what the result of an interaction will be  Locate highlight buttons  Change cursor shape based on its position  Provide immediate and continuous display of state  Show mercy, people make mistakes, be able to undo  Make manipulation as direct as possible  Examples  Dragging and dropping objects  Pointing to indicate interest
  • 24. CS 354 24 Back Projection  User clicks on screen…  Question: What object got “clicked”?  Known as “picking” in 3D applications  Basic operation in 3D applications  Process  Window system maps click to (x,y) in a particular window  Delivers the event to application selecting events on the window  Applications gets (x,y) in window space  Walk through scene graph  Invert viewport, projection, and modelview transforms  Back project point to object space ray  Intersect the ray with each object in scene graph  Does the ray intersect the object?  What intersected object is the closest?  Return the nearest object intersecting the ray as a “hit”
  • 25. CS 354 25 Conceptual Vertex Transformation glVertex* object-space coordinates Modelview eye-space coordinates User-defined API (xo,yo,zo,wo) matrix (xe,ye,ze,we) clip planes commands (xe,ye,ze,we) clipped eye-space coordinates (xe,ye,ze,we) clip-space clipped clip-space Projection coordinates View-frustum coordinates Perspective matrix (xc,yc,zc,wc) clip planes (xc,yc,zc,wc) division normalized device coordinates (NDC) (xn,yn,zn,1/wc) window-space Viewport + Depth Range coordinates to primitive transformation (xw,yw,zw,1/wc) rasterization
  • 26. CS 354 26 Reversed Vertex Transformation glVertex* object-space coordinates Modelview eye-space coordinates User-defined API (xo,yo,zo,wo) matrix (xe,ye,ze,we) clip planes commands (xe,ye,ze,we) clipped eye-space coordinates (xe,ye,ze,we) clip-space clipped clip-space Projection coordinates View-frustum coordinates Perspective matrix (xc,yc,zc,wc) clip planes (xc,yc,zc,wc) division normalized device coordinates (NDC) (xn,yn,zn,1/wc) (x,y) mouse event window-space Viewport + Depth Range coordinates to primitive transformation (xw,yw,zw,1/wc) rasterization
  • 27. CS 354 27 New Current Interaction Paradigms  Multi-touch screens  Phones, tablets… work surfaces? Perceptive Pixel
  • 28. CS 354 28 Where next?  Visual, tactile, gestures, speech, highly responsive, emotionally aware  Minority Report interface…
  • 29. CS 354 29 Next Class  Next lecture  Procedural methods  Making shape, appearance, and animation from programs—instead of data  Project 2  Start learning GLSL and doing project  Due Friday, April 6th  Incremental deadline on April 2nd  First two tasks