GLSL Overview: Creating a Program
|
|
- Delphia Reeves
- 6 years ago
- Views:
Transcription
1 1. Create the OpenGL application GLSL Overview: Creating a Program Primarily concerned with drawing Preferred approach uses buffer objects All drawing done in terms of vertex arrays Programming style differs from that used in fixed pipeline programs 2. Create shader programs Must have a vertex and fragment shader; others optional These created as separate programs 3. Create an interface between the application and shaders The application executes on the server The others execute on the GPU Values need to be able to pass back and forth between the application and shaders Individual vertices will be sent to the vertex shader as they are processed in the vertex arrays The interface specifies what form the data will have when it is received by the vertex shader 4. The application and shaders are compiled and linked 1
2 GLSL Overview: Primitives These are a subset of what s available in the fixed pipeline They represent what can be rendered directly on a GPU 1. Points May render as multiple fragments If point size larger than one pixel and center of point maps to center of pixel, only that pixel rendered If maps to edge between two pixels, both rendered If maps to shared corner of four pixels, all four rendered Each fragment may be a different color gl PointCoord is a built-in variable available only in the fragment shader It holds the coord of the current fragment Available only when rendering points 2. Lines Simple lines Line strips Line loops Pixels rendered using diamond test: If line passes through the diamond contained within the square pixel, the pixel is rendered 3. Triangles For a more detailed explanation and examples, see 28v=vs.85%29.aspx Simple triangles Triangle strips Triangle fans 2
3 GLSL Overview: Vertex Array Objects (VAOs) - Creating Drawing in OpenGL 3+ uses vertex array objects Similar to vertex arrays in earlier versions of OpenGL except used with buffer objects Buffer objects stored on server side in GPU memory Vertex data can be interleaved or have arrays dedicated to specific types of vertex data Steps in using VAOs (cf texture object usage): 1. Generate a set of names void glgenvertexarrays(glsizei n, GLuint *arraynames) Creates n unused names stored in arraynames 2. Bind a name to a VAO void glbindvertexarray (GLuint array) Accomplishes 3 things: (a) When first called with a name, creates new VAO for that name and makes it the active VAO Allocates storage with default values (b) Subsequent calls activate the named VAO (c) If name is 0, VAO use discontinued Generates GL INVALID OPERATION error if array name invalid Only 1 tex object active at any time 3. Delete VAOs Use: void gldeletevertexarrays (GLsizei n, const GLuint *arraynames); Deletes first n objects stored in arraynames To determine if a texture has been bound, use: GLboolean glisvertexarray (GLuint arrayname); 3
4 GLSL Overview: Vertex Array Objects (VAOs) - Drawing (Basics) glenablevertexattribarray (GLuint index); VAOs must be enabled in order to be accessed index is an index into an array of VAOs and specifies which one is being enabled 0 index GL MAX V ERT EX AT T RIBS 1 gldrawarrays (GLenum mode, GLint first, GLsizei count); Starts with data element first, and use count successive elements from each enabled vertex array Modes: Modes GL POINTS GL LINES GL LINE STRIP GL LINE LOOP GL TRIANGLES GL TRIANGLE STRIP GL TRIANGLE FAN Uses a single buffer object (plus one for each add l enabled VAO) void gldrawelements (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices); Indexed version of gldrawarrays mode: GL POINTS, GL LINES,... type: GL UNSIGNED BYTE, GL UNSIGNED SHORT, GL UNSIGNED INT indices: Array of pointers (indices) into the data arrays 4
5 GLSL Overview: Vertex Array Objects (VAOs) - Drawing (Basics) (2) Vertex array components are accessed in the order listed in the indices array count: Specifies how many indices to use (always starting from indices[0]) Uses two buffer objects (plus one for each add l enabled VAO) 5
6 GLSL Overview: Buffer Objects Basic steps in using: 1. Generate a set of BO names void glgenbuffers(glsizei n, GLuint *buffers) Creates n unused names stored in buffers 0 is reserved buffer name 2. Bind a name to a BO void glbindbuffer (GLenum target, GLuint buffer) Accomplishes 3 things: (a) When first called with a name, creates new BO for that name and makes it the active BO Allocates storage with default values for target (b) Subsequent calls activate the named BO (c) If name is 0, BO use for that target discontinued Only 1 tex object of each target type active at any time 6
7 GLSL Overview: Buffer Objects (2) Target types: (a) GL ARRAY BUFFER Used for vertex array data Probably most frequently used target (b) GL COPY READ BUFFER Used to transfer data between buffers without affecting OpenGL state (c) GL COPY WRITE BUFFER Used to transfer data between buffers without affecting OpenGL state (d) GL DRAW INDIRECT BUFFER Used to store drawing parameters when using indirect drawing (later) (e) GL ELEMENT ARRAY BUFFER Used for indexed drawing (f) GL PIXEL PACK BUFFER Destination when reading image data (g) GL PIXEL UNPACK BUFFER Source for image data (h) GL TEXTURE BUFFER Holds texture data (i) GL TRANSFORM FEEDBACK BUFFER Stores transformed vertex data (j) GL UNIFORM FEEDBACK BUFFER Stores uniform data (later) 7
8 3. Populate BOs with data GLSL Overview: Buffer Objects (3) (a) void glbufferdata (GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage) target is a BO size bytes are allocated, which may result in resizing the BO data is the data to be stored in the BO usage indicates how the data will be used (see table p96): Indicates frequency and direction: STATIC : modified once and used many times DYNAMIC : modified many times and used many times STREAM : modified once and used a few times DRAW : data modified by application and used as a source for drawing and image specs READ : data modified by reading data from OpenGL and returned when queried by application COPY : data modified by reading data from OpenGL and used as a source for drawing and image specs (b) void glbuffersubdata (GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data) Works like glbufferdata except loads data at offset from BO start Allows you to load multiple data sets one after another in a BO Can t use glbufferdata for this because each load will resize the BO (c) void glclearbufferdata (GLenum target, GLenum internalformat, GLenum format, GLenum datatype, const GLvoid *data) Replaces data in target by data in data internalformat specifies how data is to be stored in the BO format and datatype describe the incoming data 8
9 GLSL Overview: Buffer Objects (4) (d) void glclearbuffersubdata (GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum datatype, const GLvoid *data) Works like glbuffersubdata as applied to glclearbufferdata (e) void glcopybuffersubdata (GLenum readtarget, GLenum writetarget, GLintptr readoffset, GLintptr writeoffset, GLsizeiptr size) Copies size bytes at position readoffset from readtarget to offset in writetarget Special tagets GL COPY READ BUFFER and GL COPY WRITE BUFFER exist so BOs can be bound to them Using these targets does not disturn OpenGL state (f) void glgetbuffersubdata (GLuint buffer) Transfers data from BO to application memory (g) void glinvalidatebufferdata (GLuint buffer, GLintptr offset,glsizeiptr size) Frees BO memory (h) void glinvalidatebuffersubdata (GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data) Sub buffer version of above 9
10 GLSL Overview: Interfacing BOs With the Application The OpenGL app needs to know where the BO is (in memory) This is achieved by mapping the BO: void *glmapbuffer (GLenum target, GLenum access) This call returns a pointer to target s address space (a BO) If the mapping fails, NULL returned access specifies how the app will access the data: GL READ ONLY GL WRITE ONLY GL READ WRITE Data is then transferred as discussed above The data doesn t become visible to the BO until the BO is unmapped ; void *glunmapbuffer (GLenum target) 10
CS 450: COMPUTER GRAPHICS REVIEW: STATE, ATTRIBUTES, AND OBJECTS SPRING 2015 DR. MICHAEL J. REALE
CS 450: COMPUTER GRAPHICS REVIEW: STATE, ATTRIBUTES, AND OBJECTS SPRING 2015 DR. MICHAEL J. REALE OPENGL STATE MACHINE OpenGL state system or state machine Has list of all current state values called state
More informationDrawing with OpenGL. Chapter 3. Chapter Objectives
Chapter 3 Drawing with OpenGL Chapter Objectives After reading this chapter, you will be able to: Identify all of the rendering primitives available in OpenGL. Initialize and populate data buffers for
More informationTutorial 1: Your First Triangle!
Tutorial 1: Your First Triangle! Summary For your first dabble in OpenGL, you are going to create the graphics programming equivalent of Hello World - outputting a single coloured triangle. It doesn t
More informationStarting out with OpenGL ES 3.0. Jon Kirkham, Senior Software Engineer, ARM
Starting out with OpenGL ES 3.0 Jon Kirkham, Senior Software Engineer, ARM Agenda Some foundational work Instanced geometry rendering Uniform Buffers Transform feedback ETC2 Texture formats Occlusion Queries
More informationLighting and Texturing
Lighting and Texturing Michael Tao Michael Tao Lighting and Texturing 1 / 1 Fixed Function OpenGL Lighting Need to enable lighting Need to configure lights Need to configure triangle material properties
More informationCS475/CS675 - Computer Graphics. OpenGL Drawing
CS475/CS675 - Computer Graphics OpenGL Drawing What is OpenGL? Open Graphics Library API to specify geometric objects in 2D/3D and to control how they are rendered into the framebuffer. A software interface
More informationCS 548: COMPUTER GRAPHICS PORTRAIT OF AN OPENGL PROGRAM SPRING 2015 DR. MICHAEL J. REALE
CS 548: COMPUTER GRAPHICS PORTRAIT OF AN OPENGL PROGRAM SPRING 2015 DR. MICHAEL J. REALE INTRODUCTION We re going to talk a little bit about the structure and logic of a basic, interactive OpenGL/GLUT
More informationApplying Textures. Lecture 27. Robb T. Koether. Hampden-Sydney College. Fri, Nov 3, 2017
Applying Textures Lecture 27 Robb T. Koether Hampden-Sydney College Fri, Nov 3, 2017 Robb T. Koether (Hampden-Sydney College) Applying Textures Fri, Nov 3, 2017 1 / 24 Outline 1 Applying Textures 2 Photographs
More informationCoding OpenGL ES 3.0 for Better Graphics Quality
Coding OpenGL ES 3.0 for Better Graphics Quality Part 2 Hugo Osornio Rick Tewell A P R 1 1 t h 2 0 1 4 TM External Use Agenda Exercise 1: Array Structure vs Vertex Buffer Objects vs Vertex Array Objects
More informationMali & OpenGL ES 3.0. Dave Shreiner Jon Kirkham ARM. Game Developers Conference 27 March 2013
Mali & OpenGL ES 3.0 Dave Shreiner Jon Kirkham ARM Game Developers Conference 27 March 2013 1 Agenda Some foundational work Instanced geometry rendering Transform feedback Occlusion Queries 2 What s New
More informationCSE 4431/ M Advanced Topics in 3D Computer Graphics. TA: Margarita Vinnikov
CSE 4431/5331.03M Advanced Topics in 3D Computer Graphics TA: Margarita Vinnikov mvinni@cse.yorku.ca Goals of any 3d application is speed. You should always limit the amount of polygons actually rendered
More informationCS 432 Interactive Computer Graphics
CS 432 Interactive Computer Graphics Lecture 2 Part 1 Primitives and Buffers Matt Burlick - Drexel University - CS 432 1 Rendering in OpenGL Ok, so now we want to actually draw stuff! OpenGL (like most
More informationVertex Buffer Objects
1 Vertex Buffer Objects This work is licensed under a Creative Commons Attribution-NonCommercial- NoDerivatives 4.0 International License Mike Bailey mjb@cs.oregonstate.edu VertexBuffers.pptx Vertex Buffer
More informationVertex Buffer Objects. Vertex Buffer Objects: The Big Idea
1 Vertex Buffer Objects This work is licensed under a Creative Commons Attribution-NonCommercial- NoDerivatives 4.0 International License Mike Bailey mjb@cs.oregonstate.edu VertexBuffers.pptx Vertex Buffer
More informationShaders. Introduction. OpenGL Grows via Extensions. OpenGL Extensions. OpenGL 2.0 Added Shaders. Shaders Enable Many New Effects
CSCI 420 Computer Graphics Lecture 4 Shaders Jernej Barbic University of Southern California Shading Languages GLSL Vertex Array Objects Vertex Shader Fragment Shader [Angel Ch. 1, 2, A] Introduction The
More informationTutorial 04. Harshavardhan Kode. September 14, 2015
Tutorial 04 Harshavardhan Kode September 14, 2015 1 About This tutorial an extension of the Tutorial 03. So you might see quite a lot similarities. The following things are new. A Plane is added underneath
More informationShaders. Slide credit to Prof. Zwicker
Shaders Slide credit to Prof. Zwicker 2 Today Shader programming 3 Complete model Blinn model with several light sources i diffuse specular ambient How is this implemented on the graphics processor (GPU)?
More informationGLSL: Creating GLSL Programs - Overview
GLSL: Creating GLSL Programs - Overview The steps used to incorporate shaders into an OpenGL program: 1. Create shader programs There must be at least a vertex and a fragment shader Each is a set of strings
More informationEECS 487: Interactive Computer Graphics
Integrating GLSL with OpenGL EECS 487: Interactive Computer Graphics Lecture 19: Integrating shaders with OpenGL program Vertex-array objects with shaders Miscellaneous shader related stuff Integrating
More informationComp 410/510 Computer Graphics Spring Programming with OpenGL Part 2: First Program
Comp 410/510 Computer Graphics Spring 2017 Programming with OpenGL Part 2: First Program Objectives Refine the first program Introduce a standard program structure - Initialization Program Structure Most
More informationInformation Coding / Computer Graphics, ISY, LiTH. OpenGL! ! where it fits!! what it contains!! how you work with it 11(40)
11(40) Information Coding / Computer Graphics, ISY, LiTH OpenGL where it fits what it contains how you work with it 11(40) OpenGL The cross-platform graphics library Open = Open specification Runs everywhere
More informationProgramming with OpenGL Shaders I. Adapted From: Ed Angel Professor of Emeritus of Computer Science University of New Mexico
Programming with OpenGL Shaders I Adapted From: Ed Angel Professor of Emeritus of Computer Science University of New Mexico Objectives Shader Programming Basics Simple Shaders Vertex shader Fragment shaders
More informationOpenGL pipeline Evolution and OpenGL Shading Language (GLSL) Part 2/3 Vertex and Fragment Shaders
OpenGL pipeline Evolution and OpenGL Shading Language (GLSL) Part 2/3 Vertex and Fragment Shaders Prateek Shrivastava CS12S008 shrvstv@cse.iitm.ac.in 1 GLSL Data types Scalar types: float, int, bool Vector
More informationCS 432 Interactive Computer Graphics
CS 432 Interactive Computer Graphics Lecture 2 Part 2 Introduction to Shaders Matt Burlick - Drexel University - CS 432 1 Shaders To understand shaders, let s look at the graphics pipeline again The job
More informationBuilding Models. Prof. George Wolberg Dept. of Computer Science City College of New York
Building Models Prof. George Wolberg Dept. of Computer Science City College of New York Objectives Introduce simple data structures for building polygonal models - Vertex lists - Edge lists Deprecated
More informationGraphics Programming. Computer Graphics, VT 2016 Lecture 2, Chapter 2. Fredrik Nysjö Centre for Image analysis Uppsala University
Graphics Programming Computer Graphics, VT 2016 Lecture 2, Chapter 2 Fredrik Nysjö Centre for Image analysis Uppsala University Graphics programming Typically deals with How to define a 3D scene with a
More informationRendering Objects. Need to transform all geometry then
Intro to OpenGL Rendering Objects Object has internal geometry (Model) Object relative to other objects (World) Object relative to camera (View) Object relative to screen (Projection) Need to transform
More informationProgramming with OpenGL Shaders I. Adapted From: Ed Angel Professor of Emeritus of Computer Science University of New Mexico
Programming with OpenGL Shaders I Adapted From: Ed Angel Professor of Emeritus of Computer Science University of New Mexico 0 Objectives Shader Basics Simple Shaders Vertex shader Fragment shaders 1 Vertex
More informationCS452/552; EE465/505. Image Processing Frame Buffer Objects
CS452/552; EE465/505 Image Processing Frame Buffer Objects 3-12 15 Outline! Image Processing: Examples! Render to Texture Read: Angel, Chapter 7, 7.10-7.13 Lab3 new due date: Friday, Mar. 13 th Project#1
More information3d Programming I. Dr Anton Gerdelan
3d Programming I Dr Anton Gerdelan gerdela@scss.tcd.ie 3d Programming 3d programming is very difficult 3d programming is very time consuming 3d Programming Practical knowledge of the latest, low-level
More informationComputer graphics Labs: OpenGL (2/2) Vertex Shaders and Fragment Shader
University of Liège Departement of Aerospace and Mechanical engineering Computer graphics Labs: OpenGL (2/2) Vertex Shaders and Fragment Shader Exercise 1: Introduction to shaders (Folder square in archive
More informationComp 410/510 Computer Graphics Spring Programming with OpenGL Part 3: Shaders
Comp 410/510 Computer Graphics Spring 2018 Programming with OpenGL Part 3: Shaders Objectives Basic shaders - Vertex shader - Fragment shader Programming shaders with GLSL Finish first program void init(void)
More informationIntroduction to OpenGL
Introduction to OpenGL 1995-2015 Josef Pelikán & Alexander Wilkie CGG MFF UK Praha pepca@cgg.mff.cuni.cz http://cgg.mff.cuni.cz/~pepca/ 1 / 31 Advances in Hardware 3D acceleration is a common feature in
More informationShading System Immediate-Mode API v2.2
Shading System Immediate-Mode API v2.2 William R. Mark and C. Philipp Schloter August 29, 2001 1 Introduction This document describes modifications to the OpenGL API to support the immediate-mode use of
More informationCSE 167: Introduction to Computer Graphics Lecture #7: GLSL. Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2016
CSE 167: Introduction to Computer Graphics Lecture #7: GLSL Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2016 Announcements Project 2 due Friday 4/22 at 2pm Midterm #1 on
More informationGraphics. Texture Mapping 고려대학교컴퓨터그래픽스연구실.
Graphics Texture Mapping 고려대학교컴퓨터그래픽스연구실 3D Rendering Pipeline 3D Primitives 3D Modeling Coordinates Model Transformation 3D World Coordinates Lighting 3D World Coordinates Viewing Transformation 3D Viewing
More informationHow OpenGL Works. Retained Mode. Immediate Mode. Introduction To OpenGL
How OpenGL Works Introduction To OpenGL OpenGL uses a series of matrices to control the position and way primitives are drawn OpenGL 1.x - 2.x allows these primitives to be drawn in two ways immediate
More information3 Meshes. Strips, Fans, Indexed Face Sets. Display Lists, Vertex Buffer Objects, Vertex Cache
3 Meshes Strips, Fans, Indexed Face Sets Display Lists, Vertex Buffer Objects, Vertex Cache Intro generate geometry triangles, lines, points glbegin(mode) starts primitive then stream of vertices with
More informationGet the most out of the new OpenGL ES 3.1 API. Hans-Kristian Arntzen Software Engineer
Get the most out of the new OpenGL ES 3.1 API Hans-Kristian Arntzen Software Engineer 1 Content Compute shaders introduction Shader storage buffer objects Shader image load/store Shared memory Atomics
More informationProgramming with OpenGL Part 3: Shaders. Ed Angel Professor of Emeritus of Computer Science University of New Mexico
Programming with OpenGL Part 3: Shaders Ed Angel Professor of Emeritus of Computer Science University of New Mexico 1 Objectives Simple Shaders - Vertex shader - Fragment shaders Programming shaders with
More informationBuilding Models. CS 537 Interactive Computer Graphics Prof. David E. Breen Department of Computer Science
Building Models CS 537 Interactive Computer Graphics Prof. David E. Breen Department of Computer Science 1 Objectives Introduce simple data structures for building polygonal models - Vertex lists - Edge
More informationAnnouncement. Homework 1 has been posted in dropbox and course website. Due: 1:15 pm, Monday, September 12
Announcement Homework 1 has been posted in dropbox and course website Due: 1:15 pm, Monday, September 12 Today s Agenda Primitives Programming with OpenGL OpenGL Primitives Polylines GL_POINTS GL_LINES
More informationAPI Background. Prof. George Wolberg Dept. of Computer Science City College of New York
API Background Prof. George Wolberg Dept. of Computer Science City College of New York Objectives Graphics API history OpenGL API OpenGL function format Immediate Mode vs Retained Mode Examples The Programmer
More informationCOMP371 COMPUTER GRAPHICS
COMP371 COMPUTER GRAPHICS SESSION 12 PROGRAMMABLE SHADERS Announcement Programming Assignment #2 deadline next week: Session #7 Review of project proposals 2 Lecture Overview GPU programming 3 GPU Pipeline
More informationOUTLINE. Learn the basic design of a graphics system Introduce pipeline architecture Examine software components for a graphics system
GRAPHICS PIPELINE 1 OUTLINE Learn the basic design of a graphics system Introduce pipeline architecture Examine software components for a graphics system 2 IMAGE FORMATION REVISITED Can we mimic the synthetic
More informationA Review of OpenGL Compute Shaders
1 A Review of OpenGL Compute Shaders This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License Mike Bailey mjb@cs.oregonstate.edu OpenglComputeShaders.pptx
More informationGDC 2014 Barthold Lichtenbelt OpenGL ARB chair
GDC 2014 Barthold Lichtenbelt OpenGL ARB chair Agenda OpenGL 4.4, news and updates - Barthold Lichtenbelt, NVIDIA Low Overhead Rendering with OpenGL - Cass Everitt, NVIDIA Copyright Khronos Group, 2010
More informationTutorial 12: Real-Time Lighting B
Tutorial 12: Real-Time Lighting B Summary The last tutorial taught you the basics of real time lighting, including using the normal of a surface to calculate the diffusion and specularity. Surfaces are
More informationlast time put back pipeline figure today will be very codey OpenGL API library of routines to control graphics calls to compile and load shaders
last time put back pipeline figure today will be very codey OpenGL API library of routines to control graphics calls to compile and load shaders calls to load vertex data to vertex buffers calls to load
More informationCS452/552; EE465/505. Review & Examples
CS452/552; EE465/505 Review & Examples 2-05 15 Outline Review and Examples:! Shaders, Buffers & Binding! Example: Draw 3 Triangles Vertex lists; gl.drawarrays( ) Edge lists: gl.drawelements( )! Example:
More informationOpenGL with Qt 5. Qt Developer Days, Berlin Presented by Sean Harmer. Produced by Klarälvdalens Datakonsult AB
Qt Developer Days, Berlin 2012 Presented by Sean Harmer Produced by Klarälvdalens Datakonsult AB Material based on Qt 5.0, created on November 9, 2012 QtQuick 2 and OpenGL The Future Module: 2/18 QtQuick
More informationCS770/870 Spring 2017 Open GL Shader Language GLSL
Preview CS770/870 Spring 2017 Open GL Shader Language GLSL Review traditional graphics pipeline CPU/GPU mixed pipeline issues Shaders GLSL graphics pipeline Based on material from Angel and Shreiner, Interactive
More informationCS770/870 Spring 2017 Open GL Shader Language GLSL
CS770/870 Spring 2017 Open GL Shader Language GLSL Based on material from Angel and Shreiner, Interactive Computer Graphics, 6 th Edition, Addison-Wesley, 2011 Bailey and Cunningham, Graphics Shaders 2
More informationProgramming with OpenGL Complete Programs Objectives Build a complete first program
Programming with OpenGL Complete Programs Objectives Build a complete first program Introduce shaders Introduce a standard program structure Simple viewing Two-dimensional viewing as a special case of
More informationCOURSE 17: STATE-OF-THE-ART IN SHADING HARDWARE1 CHAPTER 6: THE OPENGL SHADING LANGUAGE 2. Randi J. Rost 3Dlabs, Inc.
COURSE 17: STATE-OF-THE-ART IN SHADING HARDWARE1 CHAPTER 6: THE OPENGL SHADING LANGUAGE 2 Randi J. Rost 3Dlabs, Inc. SIGGRAPH 2002 Course Notes 05-August-2002 SIGGRAPH 2002 6-1 State of the Art in Shading
More informationWebGL A quick introduction. J. Madeira V. 0.2 September 2017
WebGL A quick introduction J. Madeira V. 0.2 September 2017 1 Interactive Computer Graphics Graphics library / package is intermediary between application and display hardware Application program maps
More informationComputação Gráfica. Computer Graphics Engenharia Informática (11569) 3º ano, 2º semestre. Chap. 4 Windows and Viewports
Computação Gráfica Computer Graphics Engenharia Informática (11569) 3º ano, 2º semestre Chap. 4 Windows and Viewports Outline : Basic definitions in 2D: Global coordinates (scene domain): continuous domain
More informationDave Shreiner, ARM March 2009
4 th Annual Dave Shreiner, ARM March 2009 Copyright Khronos Group, 2009 - Page 1 Motivation - What s OpenGL ES, and what can it do for me? Overview - Lingo decoder - Overview of the OpenGL ES Pipeline
More informationComputer Graphics (CS 543) Lecture 1 (Part 2): Introduction to OpenGL/GLUT (Part 1)
Computer Graphics (CS 543) Lecture 1 (Part 2): Introduction to OpenGL/GLUT (Part 1) Prof Emmanuel Agu Computer Science Dept. Worcester Polytechnic Institute (WPI) OpenGL/GLUT Installation OpenGL: Specific
More informationE.Order of Operations
Appendix E E.Order of Operations This book describes all the performed between initial specification of vertices and final writing of fragments into the framebuffer. The chapters of this book are arranged
More informationCS380: Computer Graphics Screen Space & World Space. Sung-Eui Yoon ( 윤성의 ) Course URL:
CS380: Computer Graphics Screen Space & World Space Sung-Eui Yoon ( 윤성의 ) Course URL: http://sglab.kaist.ac.kr/~sungeui/cg Class Objectives Understand different spaces and basic OpenGL commands Understand
More informationOpenGL Über Buffers Extension
1 of 70 OpenGL Über Buffers Extension Revision 0.29 Author Rob Mace Copyright 2002, 2003 ATI Technologies Inc. All rights reserved. This document is being distributed for the sole purpose of soliciting
More informationComputer Graphics CS 543 Lecture 4 (Part 2) Building 3D Models (Part 2)
Computer Graphics CS 543 Lecture 4 (Part 2) Building 3D Models (Part 2) Prof Emmanuel Agu Computer Science Dept. Worcester Polytechnic Institute (WPI) Modeling a Cube In 3D, declare vertices as (x,y,z)
More informationThe Projection Matrix
The Projection Matrix Lecture 8 Robb T. Koether Hampden-Sydney College Fri, Sep 11, 2015 Robb T. Koether (Hampden-Sydney College) The Projection Matrix Fri, Sep 11, 2015 1 / 43 Outline 1 Coordinate Systems
More informationObjectives. Programming with WebGL Part 1: Background. Retained vs. Immediate Mode Graphics. Early History of APIs. PHIGS and X.
Objectives Programming with WebGL Part 1: Background CS 432 Interactive Computer Graphics Prof. David E. Breen Department of Computer Science Development of the OpenGL API OpenGL Architecture - OpenGL
More informationProgramming with WebGL Part 1: Background. CS 432 Interactive Computer Graphics Prof. David E. Breen Department of Computer Science
Programming with WebGL Part 1: Background CS 432 Interactive Computer Graphics Prof. David E. Breen Department of Computer Science E. Angel and D. Shreiner: Interactive Computer Graphics 6E Addison-Wesley
More informationCS 432 Interactive Computer Graphics
CS 432 Interactive Computer Graphics Lecture 7 Part 2 Texture Mapping in OpenGL Matt Burlick - Drexel University - CS 432 1 Topics Texture Mapping in OpenGL Matt Burlick - Drexel University - CS 432 2
More informationIntroductory Seminar
EDAF80 Introduction to Computer Graphics Introductory Seminar OpenGL & C++ Michael Doggett 2017 C++ slides by Carl Johan Gribel, 2010-13 Today Lab info OpenGL C(++)rash course Labs overview 5 mandatory
More informationGeForce3 OpenGL Performance. John Spitzer
GeForce3 OpenGL Performance John Spitzer GeForce3 OpenGL Performance John Spitzer Manager, OpenGL Applications Engineering jspitzer@nvidia.com Possible Performance Bottlenecks They mirror the OpenGL pipeline
More informationBlis: Better Language for Image Stuff Project Proposal Programming Languages and Translators, Spring 2017
Blis: Better Language for Image Stuff Project Proposal Programming Languages and Translators, Spring 2017 Abbott, Connor (cwa2112) Pan, Wendy (wp2213) Qinami, Klint (kq2129) Vaccaro, Jason (jhv2111) [System
More informationCSE 167. Discussion 03 ft. Glynn 10/16/2017
CSE 167 Discussion 03 ft Glynn 10/16/2017 Announcements - Midterm next Tuesday(10/31) - Sample midterms are up - Project 1 late grading until this Friday - You will receive 75% of the points you ve earned
More informationCS179: GPU Programming
CS179: GPU Programming Lecture 4: Textures Original Slides by Luke Durant, Russel McClellan, Tamas Szalay Today Recap Textures What are textures? Traditional uses Alternative uses Recap Our data so far:
More information三維繪圖程式設計 3D Graphics Programming Design 第七章基礎材質張貼技術嘉大資工系盧天麒
三維繪圖程式設計 3D Graphics Programming Design 第七章基礎材質張貼技術嘉大資工系盧天麒 1 In this chapter, you will learn The basics of texture mapping Texture coordinates Texture objects and texture binding Texture specification
More informationOpenGL BOF Siggraph 2011
OpenGL BOF Siggraph 2011 OpenGL BOF Agenda OpenGL 4 update Barthold Lichtenbelt, NVIDIA OpenGL Shading Language Hints/Kinks Bill Licea-Kane, AMD Ecosystem update Jon Leech, Khronos Viewperf 12, a new beginning
More informationLecture 5 Vertex and Fragment Shaders-1. CITS3003 Graphics & Animation
Lecture 5 Vertex and Fragment Shaders-1 CITS3003 Graphics & Animation E. Angel and D. Shreiner: Interactive Computer Graphics 6E Addison-Wesley 2012 Objectives The rendering pipeline and the shaders Data
More informationInformation Coding / Computer Graphics, ISY, LiTH GLSL. OpenGL Shading Language. Language with syntax similar to C
GLSL OpenGL Shading Language Language with syntax similar to C Syntax somewhere between C och C++ No classes. Straight ans simple code. Remarkably understandable and obvious! Avoids most of the bad things
More informationCg 2.0. Mark Kilgard
Cg 2.0 Mark Kilgard What is Cg? Cg is a GPU shading language C/C++ like language Write vertex-, geometry-, and fragmentprocessing kernels that execute on massively parallel GPUs Productivity through a
More informationShader Programs. Lecture 30 Subsections 2.8.2, Robb T. Koether. Hampden-Sydney College. Wed, Nov 16, 2011
Shader Programs Lecture 30 Subsections 2.8.2, 2.8.3 Robb T. Koether Hampden-Sydney College Wed, Nov 16, 2011 Robb T. Koether (Hampden-Sydney College) Shader Programs Wed, Nov 16, 2011 1 / 43 Outline 1
More information2D graphics with WebGL
2D graphics with WebGL Some material contained here is adapted from the book s slides. September 7, 2015 (Dr. Mihail) 2D graphics September 7, 2015 1 / 22 Graphics Pipeline (Dr. Mihail) 2D graphics September
More information3D Camera for a Cellular Phone. Deborah Cohen & Dani Voitsechov Supervisor : Raja Giryes 2010/11
3D Camera for a Cellular Phone Deborah Cohen & Dani Voitsechov Supervisor : Raja Giryes 2010/11 1 Contents Why 3D? Project definition and goals Projective model of a structured light system Algorithm (3
More informationCS195V Week 6. Image Samplers and Atomic Operations
CS195V Week 6 Image Samplers and Atomic Operations Administrata Warp is due today! NBody should go out soon Due in three weeks instead of two Slightly larger in scope First week and a half we be spent
More informationGLSL Programming. Nicolas Holzschuch
GLSL Programming Nicolas Holzschuch GLSL programming C-like language structure: int i, j; i = 2; j = 0; j += i; Functions, loops, branches... Reading your first GSL shader is easy Differences with C New
More informationOpenGL Compute Shaders
1 OpenGL Compute Shaders Mike Bailey mjb@cs.oregonstate.edu compute.shader.pptx OpenGL Compute Shader the Basic Idea 2 A Shader Program, with only a Compute Shader in it Application Invokes the Compute
More informationOpenGL Status - November 2013 G-Truc Creation
OpenGL Status - November 2013 G-Truc Creation Vendor NVIDIA AMD Intel Windows Apple Release date 02/10/2013 08/11/2013 30/08/2013 22/10/2013 Drivers version 331.10 beta 13.11 beta 9.2 10.18.10.3325 MacOS
More informationCopyright Khronos Group 2012 Page 1. Teaching GL. Dave Shreiner Director, Graphics and GPU Computing, ARM 1 December 2012
Copyright Khronos Group 2012 Page 1 Teaching GL Dave Shreiner Director, Graphics and GPU Computing, ARM 1 December 2012 Copyright Khronos Group 2012 Page 2 Agenda Overview of OpenGL family of APIs Comparison
More informationCMSC427 Fall 2017 OpenGL Notes A: Starting with JOGL and OpenGL Objectives of notes Readings Computer Graphics Programming in OpenGL with Java
CMSC427 Fall 2017 OpenGL Notes A: Starting with JOGL and OpenGL Objectives of notes Show how to program full OpenGL in JOGL Start on shader programing Readings Computer Graphics Programming in OpenGL with
More informationMobile Application Programing: Android. OpenGL Operation
Mobile Application Programing: Android OpenGL Operation Activities Apps are composed of activities Activities are self-contained tasks made up of one screen-full of information Activities start one another
More informationHands-On Workshop: 3D Automotive Graphics on Connected Radios Using Rayleigh and OpenGL ES 2.0
Hands-On Workshop: 3D Automotive Graphics on Connected Radios Using Rayleigh and OpenGL ES 2.0 FTF-AUT-F0348 Hugo Osornio Luis Olea A P R. 2 0 1 4 TM External Use Agenda Back to the Basics! What is a GPU?
More informationLecture 09: Shaders (Part 1)
Lecture 09: Shaders (Part 1) CSE 40166 Computer Graphics Peter Bui University of Notre Dame, IN, USA November 9, 2010 OpenGL Rendering Pipeline OpenGL Rendering Pipeline (Pseudo-Code) 1 f o r gl_vertex
More informationGeneral Purpose computation on GPUs. Liangjun Zhang 2/23/2005
General Purpose computation on GPUs Liangjun Zhang 2/23/2005 Outline Interpretation of GPGPU GPU Programmable interfaces GPU programming sample: Hello, GPGPU More complex programming GPU essentials, opportunity
More informationFrom system point of view, a graphics application handles the user input, changes the internal state, called the virtual world by modeling or
From system point of view, a graphics application handles the user input, changes the internal state, called the virtual world by modeling or animating it, and then immediately renders the updated model
More informationCS4621/5621 Fall Computer Graphics Practicum Intro to OpenGL/GLSL
CS4621/5621 Fall 2015 Computer Graphics Practicum Intro to OpenGL/GLSL Professor: Kavita Bala Instructor: Nicolas Savva with slides from Balazs Kovacs, Eston Schweickart, Daniel Schroeder, Jiang Huang
More informationTextures. Texture Mapping. Bitmap Textures. Basic Texture Techniques
Texture Mapping Textures The realism of an image is greatly enhanced by adding surface textures to the various faces of a mesh object. In part a) images have been pasted onto each face of a box. Part b)
More informationBest practices for effective OpenGL programming. Dan Omachi OpenGL Development Engineer
Best practices for effective OpenGL programming Dan Omachi OpenGL Development Engineer 2 What Is OpenGL? 3 OpenGL is a software interface to graphics hardware - OpenGL Specification 4 GPU accelerates rendering
More informationSign up for crits! Announcments
Sign up for crits! Announcments Reading for Next Week FvD 16.1-16.3 local lighting models GL 5 lighting GL 9 (skim) texture mapping Modern Game Techniques CS248 Lecture Nov 13 Andrew Adams Overview The
More informationGraphics Performance Optimisation. John Spitzer Director of European Developer Technology
Graphics Performance Optimisation John Spitzer Director of European Developer Technology Overview Understand the stages of the graphics pipeline Cherchez la bottleneck Once found, either eliminate or balance
More informationComputer graphics 2: Graduate seminar in computational aesthetics
Computer graphics 2: Graduate seminar in computational aesthetics Angus Forbes evl.uic.edu/creativecoding/cs526 Homework 2 RJ ongoing... - Follow the suggestions in the Research Journal handout and find
More informationWe assume that you are familiar with the following:
We will use WebGL 1.0. WebGL 2.0 is now being supported by most browsers but requires a better GPU so may not run on older computers or on most cell phones and tablets. See http://webglstats.com/. We will
More informationCENG 477 Introduction to Computer Graphics. Graphics Hardware and OpenGL
CENG 477 Introduction to Computer Graphics Graphics Hardware and OpenGL Introduction Until now, we focused on graphic algorithms rather than hardware and implementation details But graphics, without using
More informationLecture 2. Shaders, GLSL and GPGPU
Lecture 2 Shaders, GLSL and GPGPU Is it interesting to do GPU computing with graphics APIs today? Lecture overview Why care about shaders for computing? Shaders for graphics GLSL Computing with shaders
More information