Computer Graphics Fundamentals. Jon Macey

Similar documents
Graphics Hardware and Display Devices

Computer Graphics. Instructor: Oren Kapah. Office Hours: T.B.A.

CS130 : Computer Graphics Lecture 2: Graphics Pipeline. Tamar Shinar Computer Science & Engineering UC Riverside

Animation & Rendering

3D graphics, raster and colors CS312 Fall 2010

Key 3D Modeling Terms Beginners Need To Master

Computer Graphics Introduction. Taku Komura

Previously... contour or image rendering in 2D

CS 464 Review. Review of Computer Graphics for Final Exam

CS4620/5620: Lecture 14 Pipeline

03 Vector Graphics. Multimedia Systems. 2D and 3D Graphics, Transformations

Graphics and Interaction Rendering pipeline & object modelling

Pipeline Operations. CS 4620 Lecture Steve Marschner. Cornell CS4620 Spring 2018 Lecture 11

Lecture 1. Computer Graphics and Systems. Tuesday, January 15, 13

Representing Graphical Data

CS451Real-time Rendering Pipeline

3 Polygonal Modeling. Getting Started with Maya 103

Graphics (Output) Primitives. Chapters 3 & 4

5 Subdivision Surfaces

Graphics Pipeline 2D Geometric Transformations

Computer Graphics 1 Instructor Information. Books. Graphics? Course Goals and Outcomes. Where are computer graphics? Where are computer graphics?

Lets assume each object has a defined colour. Hence our illumination model is looks unrealistic.

Computer Graphics CS 543 Lecture 13a Curves, Tesselation/Geometry Shaders & Level of Detail

Illumination and Shading

CHAPTER 1 Graphics Systems and Models 3

Object Representation Affine Transforms. Polygonal Representation. Polygonal Representation. Polygonal Representation of Objects

CS230 : Computer Graphics Lecture 4. Tamar Shinar Computer Science & Engineering UC Riverside

Pipeline Operations. CS 4620 Lecture 14

CS123 INTRODUCTION TO COMPUTER GRAPHICS. Describing Shapes. Constructing Objects in Computer Graphics 1/15

Subdivision Of Triangular Terrain Mesh Breckon, Chenney, Hobbs, Hoppe, Watts

Computer Graphics. Shadows

Introduction to Computer Graphics. Knowledge basic concepts 2D and 3D computer graphics

COMP30019 Graphics and Interaction Rendering pipeline & object modelling

Lecture outline. COMP30019 Graphics and Interaction Rendering pipeline & object modelling. Introduction to modelling

3D Programming. 3D Programming Concepts. Outline. 3D Concepts. 3D Concepts -- Coordinate Systems. 3D Concepts Displaying 3D Models

Pipeline Operations. CS 4620 Lecture 10

2D Spline Curves. CS 4620 Lecture 18

Computergrafik. Matthias Zwicker. Herbst 2010

CSC 8470 Computer Graphics. What is Computer Graphics?

CS337 INTRODUCTION TO COMPUTER GRAPHICS. Describing Shapes. Constructing Objects in Computer Graphics. Bin Sheng Representing Shape 9/20/16 1/15

255, 255, 0 0, 255, 255 XHTML:

Graphics for VEs. Ruth Aylett

Volume Rendering. Computer Animation and Visualisation Lecture 9. Taku Komura. Institute for Perception, Action & Behaviour School of Informatics

Computer Graphics I Lecture 11

1.2.3 The Graphics Hardware Pipeline

CS 130 Final. Fall 2015

Sculpting 3D Models. Glossary

3D GRAPHICS. design. animate. render

Lecturer Athanasios Nikolaidis

Project 1, 467. (Note: This is not a graphics class. It is ok if your rendering has some flaws, like those gaps in the teapot image above ;-)

Introduction to Computer Graphics

Data Representation in Visualisation

Shading Techniques Denbigh Starkey

- Rasterization. Geometry. Scan Conversion. Rasterization

2D rendering takes a photo of the 2D scene with a virtual camera that selects an axis aligned rectangle from the scene. The photograph is placed into

Graphics in IT82. Representing Graphical Data. Graphics in IT82. Lectures Overview. Representing Graphical Data. Logical / Physical Representation

Course Title: Computer Graphics Course no: CSC209

CS 4620 Program 3: Pipeline

3D Rasterization II COS 426

Graphics for VEs. Ruth Aylett

How do we draw a picture?

Advanced Lighting Techniques Due: Monday November 2 at 10pm

Rendering. Converting a 3D scene to a 2D image. Camera. Light. Rendering. View Plane

TSBK03 Screen-Space Ambient Occlusion

Advanced Computer Graphics

Data Visualization. What is the goal? A generalized environment for manipulation and visualization of multidimensional data

Cornell CS4620 Fall 2011!Lecture Kavita Bala (with previous instructors James/Marschner) Cornell CS4620 Fall 2011!Lecture 1.

Character Modeling COPYRIGHTED MATERIAL

C P S C 314 S H A D E R S, O P E N G L, & J S RENDERING PIPELINE. Mikhail Bessmeltsev

CSE528 Computer Graphics: Theory, Algorithms, and Applications

Volume Shadows Tutorial Nuclear / the Lab

How shapes are represented in 3D Graphics. Aims and objectives By the end of the lecture you will be able to describe

0. Introduction: What is Computer Graphics? 1. Basics of scan conversion (line drawing) 2. Representing 2D curves

Geometric modeling 1

Introduction to Computer Graphics

Software Engineering. ò Look up Design Patterns. ò Code Refactoring. ò Code Documentation? ò One of the lessons to learn for good design:

Dgp _ lecture 2. Curves

Computer Graphics (CS 543) Lecture 1 (Part 1): Introduction to Computer Graphics

CS559 Computer Graphics Fall 2015

National Chiao Tung Univ, Taiwan By: I-Chen Lin, Assistant Professor

SRM INSTITUTE OF SCIENCE AND TECHNOLOGY

Computer Graphics 1. Chapter 2 (May 19th, 2011, 2-4pm): 3D Modeling. LMU München Medieninformatik Andreas Butz Computergraphik 1 SS2011

How to draw and create shapes

Fig. A. Fig. B. Fig. 1. Fig. 2. Fig. 3 Fig. 4

Computer Graphics CS 543 Lecture 1 (Part I) Prof Emmanuel Agu. Computer Science Dept. Worcester Polytechnic Institute (WPI)

Graphics Programming

Multimedia Technology CHAPTER 4. Video and Animation

CS2401 COMPUTER GRAPHICS ANNA UNIV QUESTION BANK

Representing Graphical Data

Chapter IV Fragment Processing and Output Merging. 3D Graphics for Game Programming

Surface shading: lights and rasterization. Computer Graphics CSE 167 Lecture 6

Adaptive Point Cloud Rendering

Real Time Rendering of Complex Height Maps Walking an infinite realistic landscape By: Jeffrey Riaboy Written 9/7/03

Computer Graphics. Chapter 1 (Related to Introduction to Computer Graphics Using Java 2D and 3D)

Output models Drawing Rasterization Color models

Some Resources. What won t I learn? What will I learn? Topics

Chapter 4-3D Modeling

The Viewing Pipeline Coordinate Systems

Computer Science 426 Midterm 3/11/04, 1:30PM-2:50PM

Beginning Direct3D Game Programming: 1. The History of Direct3D Graphics

Transcription:

Computer Graphics Fundamentals Jon Macey jmacey@bournemouth.ac.uk http://nccastaff.bournemouth.ac.uk/jmacey/ 1 1

What is CG Fundamentals Looking at how Images (and Animations) are actually produced in the Computer Gaining an in depth understanding of the processes the tools we use apply to create animations and images. What does this Involve? Some Maths (nothing too complex) Some Science (Physics) Why Do I need to know this? To help you use the tools better (and know some of the limitations) To help you communicate with the technical people who write the tools and give us common language for expressing ideas 2 2

Why do I need Maths So you know why things get slower the more buttons you press So you know why things don't look quite right when you combine a number of Render passes So you can figure out how to get your characters facing in the right direction and get them to go the correct way when you place them on a path So when you start scripting you can express your ideas in a way the computer understands And countless other reasons which will come apparent as the course progresses 3 3

And what about Physics? Physics isn't just about gravity (although that is important) Physics is also used to describe how light interacts with object This is exactly how (but much simplified) Computer Rendering works So once we learn the basics we can understand what the different shading models actually do and thus create the images we really want to see 4 4

Basic Curriculum Basic Maths Trigonometry (lines, triangles, circles) 3D Maths Vectors, Matrices, Affine Transforms How Animation Systems work The Computer Image, The Animation Pipeline (how XSI, Maya, Houdini, Shake etc really work) Some Basic Computer Principles, How the computer Actually works Rendering How a renderer actually produces and image, Lighting Models, Shading Models. And a whole lot more besides. 5 5

Lecture Program The computer Image Numbers, number manipulation, functions and basic algebra Trigonometry, Lines, Circles Pythagorus Vectors, Matrices and Affine Transforms Viewing Systems, Perspective and CG Images The Virtual Camera The Mathematics of Compositing Image Representation, Culling, Clipping Image Generation, Rendering Ray-tracing Scanline rendering 6 6

Pixels "A pixel (a portmanteau of picture element) is one of the many tiny dots that make up the representation of a picture in a computer's memory. Each such information element is not really a dot, nor a square, but an abstract sample. With care, pixels in an image can be reproduced at any size without the appearance of visible dots or squares; but in many contexts, they are reproduced as dots or squares and can be visibly distinct when not fine enough. The intensity of each pixel is variable; in color systems, each pixel has typically three or four dimensions of variability such and Red, Green and Blue, or Cyan, Magenta, Yellow and Black." [1] 7 7

Pixels The more pixels used to represent an image, the closer the results can resemble the original. This is usually called the resolution. Pixels are usually expressed as a single number 3 Mega-Pixel digital camera (which has a nominal 3 million Pixels) or as a pair of numbers 640 x 480 which represent width (640) by Height 480. with a total number of pixel = 640x480 = 307,200 pixels 8 8

Resolution Image resolution describes the detail an image holds. The term is most often used in relation to digital images, but is also used to describe how grainy a "filmbased" image is. Higher resolution means more image detail. For digital raster-images, the convention is to describe the image resolution with the set of two positive integer-numbers, where the first number is the number of pixel-columns (width) and the second is the number of pixel-rows (height). The second most popular convention is to describe the total number of pixels in the image (typically given as number of mega-pixels), which can be calculated by multiplying pixel-columns with pixel-rows. 9 9

Resolution 10 10

Resolution 10 10

Resolution 10 10

Resolution 10 10

Resolution 10 10

Resolution 10 10

Resolution 10 10

Pixel Depth [2] Pixel Depth refers to the number of colours possible on screen. Another way of looking at this is to determine how many different bits are used to make up an individual pixel (pixel depth). 11 11

Pixel Depth 12 12

Pixel Depth 12 12

Pixel Depth 12 12

Pixel Depth Most grey scale images are referred to by pixel depth with the most common shown below Two bits per pixel produces 4 grey levels Four bits per pixel produces 16 grey levels Eight bits per pixel produces 256 grey levels 13 13

Raster Images [3,4] A raster Image (commonly called a Bitmap, pixmap etc) Is a data structure for storing computer images (usually in a rectangular grid) composing of a number of pixels A bitmap corresponds bit-for-bit with an image displayed on a screen, generally in the same format used for storage in the display's video memory, or maybe as a device-independent bitmap. Bitmap is technically characterized by the width and height of the image in pixels and by the number of bits per pixel (a colour depth, which determines the number of colors it can represent). 14 14

Raster Images The following raster image is made up of many cells in different shades of grey. Zooming in on these show 15 15

Raster Images The following raster image is made up of many cells in different shades of grey. Zooming in on these show 15 15

Raster Images The example above shows a simple 3 level bitmap image. Each level of grey is encoded with the values 1,2 and 7 The second image shows how this is stored for the upper left 6 by 8 section of the image 16 16

Representation of grey and Colour The simplest format for a raster image is the bi-level format as shown apposite This is usually referred to as a onebit-per-pixel image. 17 17

Colour images are usually represented by an ordered Colour Raster Images triple Colour value Displayed This is used to represent the red green and blue intensity of the pixel [0,0,0] Black [0,0,1] Blue [0,1,0] Green [0,1,1] Cyan The number of bits used to represent each pixel is called the colour depth. In its simplest form we can use the following table [1,0,0] Red [1,0,1] Magenta [1,1,0] Yellow [1,1,1] White 18

Colour Although the previous example is good for simple colour often images need more detail True colour images have a pixel depth of 24 bits. This allows for finer control of the colour However images become very big at this level. Another alternative is to use a colour look up table in the image. This is also known as a palette, and is usually stored as part of the image format 19

32 Bit Colour A common misconception is that 32-bit colour produces 4,294,967,296 distinct colours. In reality, 32-bit colour actually refers to 24-bit colour (True colour) with an additional 8 bits These extra bits are used to represent an alpha channel. 20

Representing Images in the Computer Computer images are usually composed of the following output primitives polylines text filled regions raster images 21

Polyline A polyline is a sequence of connected straight lines The polyline may appear smooth but as shown below this is not the case 22

Polyline A polyline is a sequence of connected straight lines The polyline may appear smooth but as shown below this is not the case 22

Polyline A polyline is a sequence of connected straight lines The polyline may appear smooth but as shown below this is not the case 22

Drawing polylines The simplest polyline is a straight line segment represented by a start point and an end point :- (x 1, y 1 )(x 2, y 2 ) When there are several lines in a polyline, each one is called an edge and two adjacent lines meet at a vertex (more on these in another lecture) (2,4),(2,11),(6,14),(12,11),(12,4)... 23

Polygons Mathematically a Polygon is described as a closed plane figure with n sides. [6] In computer graphics the term polygon has taken on a slightly altered meaning, more related to the way the shape is stored and manipulated within the computer. [7] Typically in CG we use Triangles and Quads as our basic polygon primitives 24

Polygons We can now assign colours, textures and surfaces to the polygons Then render them to produce the final image. 25

Polygons We can now assign colours, textures and surfaces to the polygons Then render them to produce the final image. 25

Polygons We can now assign colours, textures and surfaces to the polygons Then render them to produce the final image. 25

NURBS non-uniform, rational B-spline (NURBS) is a mathematical model commonly used in computer graphics for generating and representing curves and surfaces The control points determine the shape of the curve. 26

Subdivision Surfaces A subdivision surface is a method of representing a smooth surface via the specification of a coarser polygon mesh. A Refinement Scheme is then applied to this mesh. This process takes that mesh and subdivides it, creating new vertices and new faces. 27

Subdivision Surfaces A subdivision surface is a method of representing a smooth surface via the specification of a coarser polygon mesh. A Refinement Scheme is then applied to this mesh. This process takes that mesh and subdivides it, creating new vertices and new faces. 27

References [1] http://en.wikipedia.org/wiki/pixel [2] http://www.usu.edu/sanderso/multinet/depth.html [3] http://en.wikipedia.org/wiki/raster_graphics [4] Computer Graphics With OpenGL F.S. Hill Jr Prentice Hall [5] The Computer Image Watt & Policarpo Addison Wesley [6] http://mathworld.wolfram.com/polygon.html [7] http://en.wikipedia.org/wiki/polygon 28 28