Geometric Model of Camera

Size: px
Start display at page:

Download "Geometric Model of Camera"

Transcription

1 Geometric Model of Camera Dr. Gerhard Roth COMP 42A Winter 25 Version 2

2 Similar Triangles 2

3 Geometric Model of Camera Perspective projection P(X,Y,Z) p(,) f X Z f Y Z 3

4 Parallel lines aren t 4 Figure b David Forsth

5 Lengths can t be trusted... 5

6 Coordinate Transformation 2D p p p p p cos sin sin cos ' ' ' P ' '' ' '' T T T p p T T p p p cos sin sin cos ' ' '' Rotation and Translation 6

7 Homogeneous Coordinates Go one dimensional higher: z z is an arbitrar non-zero scalar, usuall e choose / / / / / From homogeneous coordinates to Cartesian coordinates: 7

8 2D Transformation ith Homogeneous Coordinates 2D coordinate transformation using homogeneous coordinates: T T p p p cos sin sin cos '' cos sin sin cos '' '' p p T T p p 2D coordinate transformation: 8

9 Homogeneous coordinates (In 2d) To points are equal if and onl if: / = / and / = / =: points at infinit useful for projections and curve draing Homogenize = divide b. Homogenized point eample: = = / = 644/7 = = / = 78/7 =

10 Wh use homogeneous co-ordinates We require a composition (sequence of) rotations, translations and projections Even the projection is a matri multiplication Each of these can be described b matri operations using homogeneous coordinates Composing them together, appling them one after the other just matri multiplication The final operation, hich takes a 3d point and produces a 2d image is one big matri multiplication

11 Translations ith homogeneous t t t t t t

12 Scaling ith homogeneous s s s s s s 2

13 Rotation ith homogeneous co-ord s cos sin sin cos cos sin sin cos cos sin sin cos 3

14 3D Rotation about X-Ais Representation in homogeneous co-ordinates

15 3D Rotation about Y-Ais Representation in homogeneous co-ordinates 5

16 3D Rotation about Z-Ais Representation in homogeneous co-ordinates 6

17 3D Rotation Matri Euler Angles Rotate around each coordinate ais: R R Rz R ( ) cos sin sin cos R 2 ( ) cos sin sin cos sin R3( ) sin cos cos Combine the three rotations: R RRRz Can describe an 3d rotation b a sequence of rotations about the three ais So R = RRRz or RRzR or RRRz or RRzR or RzRR or RzRR 7

18 3d Rotation Matri When ou specif the values for each ais ou musts also specif order of operations Different orders have different angle values Succeeding rotations are about an alread modified set of three ais Remember matri multiplication is not commutative AB is not same as BA A rotation matri has 9 elements but e need onl three numbers to specif a 3d rotation uniquel! 8

19 3d Rotation Matri - Eamples 9

20 3D Rotation Rodriguez Rotations also described b ais and angle Rotation ais (2 parameters) and amount of rotation (angle parameter) Can convert beteen Euler Angles and Rodriguez representation 2

21 Degrees of freedom This is the number of parameters necessar to generate all possible instances of a given geometric object A 2d rotation has one degree of freedom Varing one parameter (angle) ill generate ever possible 2d rotation What are degrees of freedom of a 3d rotation It is a 3 b 3 matri ith nine numbers so is it 9? No, the anser is three (alas!) B varing three parameters e can generate ever possible 3d rotation matri (for ever representation!) Wh is it 3 and not 9? 2

22 Rotation Matrices Both 2d and 3d rotation matrices have to characteristics The are orthogonal (also called orthonormal) R T R I R T R Their determinant is Matri belo is orthogonal but not a rotation matri because the determinate is not this is a reflection matri 22

23 Rotation Matrices Ros and columns of a rotation matri are unit vectors Ever ro is orthogonal to ever other ros Their dot product is zero Ever column is orthogonal to ever other column Their dot product is zero These etra constraints mean that the entries in the rotation matri are not independent This reduces the degrees of freedom 23

24 3d Rotation Matri - Inversions Remember that cos(-t) = cos(t) And that sin(-t) = -sin(t) Also for rotation matrices hich e can see R T R I R T R 24

25 Homogeneous co-ordinates Transformation transform a point in an n dimensional space to another n dim point Transformations are scale, rotations, translations, etc. You can represent all these b multiplication b one appropriate matri using homogeneous co-ordinates Projection transform a point in an n dimensional space to an m dim point For projection m is normall less than n Perspective projection is a projection (3d to 2d) From the 3d orld to a 2d point in the image You can also represent a projection as matri multiplication ith one appropriate matri and homogeneous co-ordinates 25

26 Four Coordinate Frames im piel frame Z P Y Yc p im im camera frame optical center Xc Zc image plane frame principal point orld frame X Camera model: p transforma tion matri im P 26

27 Perspective Projection Z X f Z Y f These are nonlinear. Z Y X f f v u Using homogenous coordinate, e have a linear relation: u / v / 27

28 World to Camera Coordinate T RX X c T R c c c Z Y X Z Y X Transformation beteen the camera and orld coordinates. Here e rotate, then translate, to go from orld to camera co-ordinates hich is opposite of book, but is simpler and is the a in hich OpenCV routines do it: After R, and T e have converted from orld to camera frame. In the camera frame the z ais is along the optical center. 28

29 Camera Coordinates to Image Coordinates ( o ) s s im, s : ( o ) s im piel sizes in millimeters per piel (o,o) im im im im / s / s o o Camera co-ordinates, and are in millimetres Image co-ordinates im, im, are in piels Center of projection o, o is in piels Sign change because horizontal and vertical ais of the image and camera frame have opposite directions. 29

30 Image and Camera frames No e look from the camera outard and image origin is the top left piel (,) Zcamera Xcamera (im, im) (o,o) Ycamera Ximage Yimage 3

31 Put All Together World to Piel / / / / / / / / 3 2 c c c Z Y X T R o s f o s f Z Y X T R f f o s o s Z Y X f f o s o s v u o s o s Z Y X T R K / 3 im 3 im 2 / From camera to piel Add projection Add Rotation And Translation 3

32 Perspective Projection Matri Projection is a matri multiplication using homogeneous coordinates f f z f f z In practice: lots of coordinate transformations ( f z, f z ) divide b the third coordinate 2D point (3) = Camera to piel coord. trans. matri (33) Perspective projection matri (34) World to camera coord. trans. matri (44) 3D point (4) 32

33 Camera Parameters Etrinsic parameters define the location and orientation of the camera reference frame ith respect to a orld reference frame Depend on the eternal orld, so the are etrinsic Intrinsic parameters link piel co-ordinates in the image ith the corresponding coordinates in the camera reference frame An intrinsic characteristic of the camera Image co-ordinates are in piels Camera co-ordinates are in millimetres In formulas that do conversions the units must match! 33

34 Intrinsic Camera Parameters K f / s f / s o o K is a 33 upper triangular matri, called the Camera Calibration Matri. There are five intrinsic parameters: (a) The piel sizes in and directions s, s in millimeters/piel (b) The focal length f in millimeters (c) The principal point (o,o) in piels, hich is the point here the optic ais intersects the image plane. 34 (d) The units of f/s and f/s are in piels, h is this so?

35 Camera intrinsic parameters Can rite three of these parameters differentl b letting f/s = f and f/s = f Then intrinsic parameters are o,o,f,f The units of these parameters are piels! In practice piels are square (s = s) so that means f should equal f for most cameras Hoever, ever eplicit camera calibration process (using calibration objects) introduces some small errors These calibration errors make f not eactl equal to f So in OpenCV the intrinsic camera parameters are the four folloing o,o,f,f Hoever f is usuall ver close to f and if this is not the case then there is a problem 35

36 Etrinsic Parameters and Proj. Matri [R T] defines the etrinsic parameters. The 34 matri M = K[R T] is called the projection matri. It takes 3d points in the orld co-ordinate sstem and maps them to the appropriate image co-ordinates in piels 3 2 im Z Y X M Z Y X T R K p 36

37 Create a complete projection matri Camera located at T c =[T, T, T z ] t =[,2,3] t Camera aimed along z-ais,, aes parallel to orld aes (R=I) T I I I z I I I z I z I z I zz T c = = 2 R= = T T z 3 S= Camera has focal length f = f = image=6448, assume u =32, v =24 Calculate complete 34 projection matri P P 2 P 3 P 4 P 2 P 22 P 23 P = -2 = P 3 P 32 P 33 P

38 Using the projection matri - eample P P 2 P 3 P 4 P 2 P 22 P 23 P 24 P 3 P 32 P 33 P 34 = Where ould the point (2,5,2) project to in the image? Projection matri u v = P P 2 P 3 P 4 P 2 P 22 P 23 P 24 P 3 P 32 P 33 P 34 X Y Z = u v = u=u / = 644/7 = v=v / = 78/7 = 46.5 World point (2,5,2) project to piel With co-ordinates of (379,47) 38

39 Using the projection matri - eample P P 2 P 3 P 4 P 2 P 22 P 23 P 24 P 3 P 32 P 33 P 34 = Where ould the point (,2,2) project to in the image? Projection matri u v = P P 2 P 3 P 4 P 2 P 22 P 23 P 24 P 3 P 32 P 33 P 34 X Y Z = u v = u=u / = 544/7 = 32 v=v / = 48/7 = 24 39

40 Effect of change in focal length Small f is ide angle, large f is telescopic 4

41 Orthographic Projection X I m X Y M X Y Z C c Z Y 4

42 Orthographic Projection X I O 3 C Z O O2 Y 42

43 Orthographic Projection Special case of perspective projection Distance from center of projection to image plane is infinite Image World Also called parallel projection What s the projection matri? 43 Slide b Steve Seitz

44 Weak Perspective Model Assume the relative distance beteen an to points in an object along the principal ais is much smaller (/2 th at most) than the Z average distance of the object. Then the camera projection can be approimated as: f X Z f Z X f Y Z f Z Y This is the eak-perspective camera model. Sometimes called scaled orthograph. 44

45 Weak Perspective Projection To step projection: X I C Z c Z Y plane image plane average depth 45

46 Weak Perspective 46

47 Impact of different projections Perspective projections Parallel lines in orld are not parallel in the image Object projection gets smaller ith distance from camera Weak perspective projection Parallel lines in the orld are parallel in the image Object projection gets smaller ith distance from camera Orthographic projection Parallel lines in the orld are parallel in the image Object projection is unchanged ith distance from camera 47

48 Ordinar Perspective Parallel lines in orld - not parallel in image 48

49 Weak Perspective Parallel lines in orld parallel in image 49

50 Image distortion due to optics Radial distortion hich depends on radius r, distance of each point from center of image r 2 = (- o) 2 +(- o) 2 Correction uses three parameters, k,k 2,k 3 5

51 Radial Distortion Error is proportional to distance of piel from the camera center (the radius of the point) Barrel too far, Pincushion too close 5

52 Correcting Radial Distortions 52

53 Tangential Distortion (O, O) center of projection) is not the center of image Also causes a more comple distortion of the image 53

54 Tangential Distortion Lens not eactl parallel to the image plane Correction uses to parameter p, p 2 Both tpes of distortion are removed (image is un-distorted) and onl then does standard calibration matri K appl to the image Camera calibration computes both K and these five distortion parameters 54

55 Ho to find the camera parameters K Can use the EXIF tag for an digital image Has focal length f in millimeters but not the piel size But ou can get the piel size from the camera manual There are onl a finite number of different piels sizes because the number of sensing element sizes is limited If there is not a lot of image distortion due to optics then this approach is sufficient (this is onl a linear calibration) Can perform eplicit camera calibration Put a calibration pattern in front of the camera Take a number of different pictures of this pattern No run the calibration algorithm (different tpes) Result is intrinsic camera parameters (linear and non-linear) and the etrinsic camera parameters of all the images 55

56 Summar Questions Wh do e use homogeneous co-ordinates for image projection? Write the projection equation in a linear form using a matri ith homogeneous co-ordinates. What are the units of image co-ordinates and camera co-ordinates? Ho do ou convert beteen them? Wh do the names etrinsic, and intrinsic parameters of a lens make sense? What are the units of f/s, and f/s? Implications? What are characteristics of perspective, eak perspective and orthographic projection? What are parameters of models for non-linear lens characteristics? 56

3-Dimensional Viewing

3-Dimensional Viewing CHAPTER 6 3-Dimensional Vieing Vieing and projection Objects in orld coordinates are projected on to the vie plane, hich is defined perpendicular to the vieing direction along the v -ais. The to main tpes

More information

MAN-522: COMPUTER VISION SET-2 Projections and Camera Calibration

MAN-522: COMPUTER VISION SET-2 Projections and Camera Calibration MAN-522: COMPUTER VISION SET-2 Projections and Camera Calibration Image formation How are objects in the world captured in an image? Phsical parameters of image formation Geometric Tpe of projection Camera

More information

3D Geometry and Camera Calibration

3D Geometry and Camera Calibration 3D Geometr and Camera Calibration 3D Coordinate Sstems Right-handed vs. left-handed 2D Coordinate Sstems ais up vs. ais down Origin at center vs. corner Will often write (u, v) for image coordinates v

More information

2D transformations and homogeneous coordinates

2D transformations and homogeneous coordinates 2D transformations and homogeneous coordinates Dr Nicolas Holzschuch Universit of Cape Ton e-mail: holzschu@cs.uct.ac.za Map of the lecture Transformations in 2D: vector/matri notation eample: translation,

More information

3D Sensing. Translation and Scaling in 3D. Rotation about Arbitrary Axis. Rotation in 3D is about an axis

3D Sensing. Translation and Scaling in 3D. Rotation about Arbitrary Axis. Rotation in 3D is about an axis 3D Sensing Camera Model: Recall there are 5 Different Frames of Reference c Camera Model and 3D Transformations Camera Calibration (Tsai s Method) Depth from General Stereo (overview) Pose Estimation from

More information

Camera Model and Calibration

Camera Model and Calibration Camera Model and Calibration Lecture-10 Camera Calibration Determine extrinsic and intrinsic parameters of camera Extrinsic 3D location and orientation of camera Intrinsic Focal length The size of the

More information

Computer Graphics. Geometric Transformations

Computer Graphics. Geometric Transformations Contents coordinate sstems scalar values, points, vectors, matrices right-handed and left-handed coordinate sstems mathematical foundations transformations mathematical descriptions of geometric changes,

More information

Image Warping. Some slides from Steve Seitz

Image Warping.   Some slides from Steve Seitz Image Warping http://www.jeffre-martin.com Some slides from Steve Seitz 5-463: Computational Photograph Aleei Efros, CMU, Spring 2 Image Transformations image filtering: change range of image g() = T(f())

More information

Computer Graphics. Geometric Transformations

Computer Graphics. Geometric Transformations Computer Graphics Geometric Transformations Contents coordinate sstems scalar values, points, vectors, matrices right-handed and left-handed coordinate sstems mathematical foundations transformations mathematical

More information

Announcements. Equation of Perspective Projection. Image Formation and Cameras

Announcements. Equation of Perspective Projection. Image Formation and Cameras Announcements Image ormation and Cameras Introduction to Computer Vision CSE 52 Lecture 4 Read Trucco & Verri: pp. 22-4 Irfanview: http://www.irfanview.com/ is a good Windows utilit for manipulating images.

More information

CS 2770: Intro to Computer Vision. Multiple Views. Prof. Adriana Kovashka University of Pittsburgh March 14, 2017

CS 2770: Intro to Computer Vision. Multiple Views. Prof. Adriana Kovashka University of Pittsburgh March 14, 2017 CS 277: Intro to Computer Vision Multiple Views Prof. Adriana Kovashka Universit of Pittsburgh March 4, 27 Plan for toda Affine and projective image transformations Homographies and image mosaics Stereo

More information

Agenda. Rotations. Camera models. Camera calibration. Homographies

Agenda. Rotations. Camera models. Camera calibration. Homographies Agenda Rotations Camera models Camera calibration Homographies D Rotations R Y = Z r r r r r r r r r Y Z Think of as change of basis where ri = r(i,:) are orthonormal basis vectors r rotated coordinate

More information

CSE328 Fundamentals of Computer Graphics: Theory, Algorithms, and Applications

CSE328 Fundamentals of Computer Graphics: Theory, Algorithms, and Applications CSE328 Fundamentals of Computer Graphics: Theor, Algorithms, and Applications Hong in State Universit of New York at Ston Brook (Ston Brook Universit) Ston Brook, New York 794-44 Tel: (63)632-845; Fa:

More information

1. We ll look at: Types of geometrical transformation. Vector and matrix representations

1. We ll look at: Types of geometrical transformation. Vector and matrix representations Tob Howard COMP272 Computer Graphics and Image Processing 3: Transformations Tob.Howard@manchester.ac.uk Introduction We ll look at: Tpes of geometrical transformation Vector and matri representations

More information

Modeling Transformations

Modeling Transformations Modeling Transformations Michael Kazhdan (601.457/657) HB Ch. 5 FvDFH Ch. 5 Overview Ra-Tracing so far Modeling transformations Ra Tracing Image RaTrace(Camera camera, Scene scene, int width, int heigh,

More information

Image Warping. Some slides from Steve Seitz

Image Warping.   Some slides from Steve Seitz Image Warping http://www.jeffre-martin.com Some slides from Steve Seitz 5-463: Computational Photograph Aleei Efros, CMU, Fall 26 Image Warping image filtering: change range of image g() T(f()) f T f image

More information

Announcements. The equation of projection. Image Formation and Cameras

Announcements. The equation of projection. Image Formation and Cameras Announcements Image ormation and Cameras Introduction to Computer Vision CSE 52 Lecture 4 Read Trucco & Verri: pp. 5-4 HW will be on web site tomorrow or Saturda. Irfanview: http://www.irfanview.com/ is

More information

Perspective Projection Transformation

Perspective Projection Transformation Perspective Projection Transformation Where does a point of a scene appear in an image?? p p Transformation in 3 steps:. scene coordinates => camera coordinates. projection of camera coordinates into image

More information

Camera Model and Calibration. Lecture-12

Camera Model and Calibration. Lecture-12 Camera Model and Calibration Lecture-12 Camera Calibration Determine extrinsic and intrinsic parameters of camera Extrinsic 3D location and orientation of camera Intrinsic Focal length The size of the

More information

Image Warping CSE399b, Spring 07 Computer Vision

Image Warping CSE399b, Spring 07 Computer Vision Image Warping CSE399b, Spring 7 Computer Vision http://maps.a9.com http://www.cs.ubc.ca/~mbrown/autostitch/autostitch.html http://www.cs.ubc.ca/~mbrown/autostitch/autostitch.html Autostiching on A9.com

More information

Image formation - About the course. Grading & Project. Tentative Schedule. Course Content. Students introduction

Image formation - About the course. Grading & Project. Tentative Schedule. Course Content. Students introduction About the course Instructors: Haibin Ling (hbling@temple, Wachman 305) Hours Lecture: Tuesda 5:30-8:00pm, TTLMAN 403B Office hour: Tuesda 3:00-5:00pm, or b appointment Tetbook Computer Vision: Models,

More information

ECE Digital Image Processing and Introduction to Computer Vision. Outline

ECE Digital Image Processing and Introduction to Computer Vision. Outline ECE592-064 Digital Image Processing and Introduction to Computer Vision Depart. of ECE, NC State University Instructor: Tianfu (Matt) Wu Spring 2017 1. Recap Outline 2. Modeling Projection and Projection

More information

What and Why Transformations?

What and Why Transformations? 2D transformations What and Wh Transformations? What? : The geometrical changes of an object from a current state to modified state. Changing an object s position (translation), orientation (rotation)

More information

Image Warping : Computational Photography Alexei Efros, CMU, Fall Some slides from Steve Seitz

Image Warping : Computational Photography Alexei Efros, CMU, Fall Some slides from Steve Seitz Image Warping http://www.jeffre-martin.com Some slides from Steve Seitz 5-463: Computational Photograph Aleei Efros, CMU, Fall 2 Image Transformations image filtering: change range of image g() T(f())

More information

Geometry of image formation

Geometry of image formation Geometr of image formation Tomáš Svoboda, svoboda@cmp.felk.cvut.c ech Technical Universit in Prague, enter for Machine Perception http://cmp.felk.cvut.c Last update: November 0, 2008 Talk Outline Pinhole

More information

Image Warping (Szeliski Sec 2.1.2)

Image Warping (Szeliski Sec 2.1.2) Image Warping (Szeliski Sec 2..2) http://www.jeffre-martin.com CS94: Image Manipulation & Computational Photograph Aleei Efros, UC Berkele, Fall 7 Some slides from Steve Seitz Image Transformations image

More information

Motivation. What we ve seen so far. Demo (Projection Tutorial) Outline. Projections. Foundations of Computer Graphics

Motivation. What we ve seen so far. Demo (Projection Tutorial) Outline. Projections. Foundations of Computer Graphics Foundations of Computer Graphics Online Lecture 5: Viewing Orthographic Projection Ravi Ramamoorthi Motivation We have seen transforms (between coord sstems) But all that is in 3D We still need to make

More information

CS770/870 Spring 2017 Transformations

CS770/870 Spring 2017 Transformations CS770/870 Spring 2017 Transformations Coordinate sstems 2D Transformations Homogeneous coordinates Matrices, vectors, points Coordinate Sstems Coordinate sstems used in graphics Screen coordinates: the

More information

Modeling Transformations

Modeling Transformations Modeling Transformations Michael Kazhdan (601.457/657) HB Ch. 5 FvDFH Ch. 5 Announcement Assignment 2 has been posted: Due: 10/24 ASAP: Download the code and make sure it compiles» On windows: just build

More information

Geometry of a single camera. Odilon Redon, Cyclops, 1914

Geometry of a single camera. Odilon Redon, Cyclops, 1914 Geometr o a single camera Odilon Redon, Cclops, 94 Our goal: Recover o 3D structure Recover o structure rom one image is inherentl ambiguous??? Single-view ambiguit Single-view ambiguit Rashad Alakbarov

More information

Geometric camera models and calibration

Geometric camera models and calibration Geometric camera models and calibration http://graphics.cs.cmu.edu/courses/15-463 15-463, 15-663, 15-862 Computational Photography Fall 2018, Lecture 13 Course announcements Homework 3 is out. - Due October

More information

Determining the 2d transformation that brings one image into alignment (registers it) with another. And

Determining the 2d transformation that brings one image into alignment (registers it) with another. And Last two lectures: Representing an image as a weighted combination of other images. Toda: A different kind of coordinate sstem change. Solving the biggest problem in using eigenfaces? Toda Recognition

More information

Today s class. Geometric objects and transformations. Informationsteknologi. Wednesday, November 7, 2007 Computer Graphics - Class 5 1

Today s class. Geometric objects and transformations. Informationsteknologi. Wednesday, November 7, 2007 Computer Graphics - Class 5 1 Toda s class Geometric objects and transformations Wednesda, November 7, 27 Computer Graphics - Class 5 Vector operations Review of vector operations needed for working in computer graphics adding two

More information

Camera Models and Image Formation. Srikumar Ramalingam School of Computing University of Utah

Camera Models and Image Formation. Srikumar Ramalingam School of Computing University of Utah Camera Models and Image Formation Srikumar Ramalingam School of Computing University of Utah srikumar@cs.utah.edu VisualFunHouse.com 3D Street Art Image courtesy: Julian Beaver (VisualFunHouse.com) 3D

More information

Rigid Body Motion and Image Formation. Jana Kosecka, CS 482

Rigid Body Motion and Image Formation. Jana Kosecka, CS 482 Rigid Body Motion and Image Formation Jana Kosecka, CS 482 A free vector is defined by a pair of points : Coordinates of the vector : 1 3D Rotation of Points Euler angles Rotation Matrices in 3D 3 by 3

More information

Computer Graphics. P04 Transformations. Aleksandra Pizurica Ghent University

Computer Graphics. P04 Transformations. Aleksandra Pizurica Ghent University Computer Graphics P4 Transformations Aleksandra Pizurica Ghent Universit Telecommunications and Information Processing Image Processing and Interpretation Group Transformations in computer graphics Goal:

More information

To Do. Demo (Projection Tutorial) Motivation. What we ve seen so far. Outline. Foundations of Computer Graphics (Fall 2012) CS 184, Lecture 5: Viewing

To Do. Demo (Projection Tutorial) Motivation. What we ve seen so far. Outline. Foundations of Computer Graphics (Fall 2012) CS 184, Lecture 5: Viewing Foundations of Computer Graphics (Fall 0) CS 84, Lecture 5: Viewing http://inst.eecs.berkele.edu/~cs84 To Do Questions/concerns about assignment? Remember it is due Sep. Ask me or TAs re problems Motivation

More information

Jorge Salvador Marques, geometric camera model

Jorge Salvador Marques, geometric camera model geometric camera model image acquisition 6 years ago today curc of te Holy Spirit, Brunellesci, 436 te camera projects 3D points into an image plane geometric primitives and transformations How do we see

More information

Viewing Transformations I Comp 535

Viewing Transformations I Comp 535 Viewing Transformations I Comp 535 Motivation Want to see our virtual 3-D worl on a 2-D screen 2 Graphics Pipeline Moel Space Moel Transformations Worl Space Viewing Transformation Ee/Camera Space Projection

More information

Uses of Transformations. 2D transformations Homogeneous coordinates. Transformations. Transformations. Transformations. Transformations and matrices

Uses of Transformations. 2D transformations Homogeneous coordinates. Transformations. Transformations. Transformations. Transformations and matrices Uses of Transformations 2D transformations Homogeneous coordinates odeling: position and resie parts of a comple model; Viewing: define and position the virtual camera Animation: define how objects move/change

More information

CSE528 Computer Graphics: Theory, Algorithms, and Applications

CSE528 Computer Graphics: Theory, Algorithms, and Applications CSE528 Computer Graphics: Theor, Algorithms, and Applications Hong Qin State Universit of New York at Ston Brook (Ston Brook Universit) Ston Brook, New York 794--44 Tel: (63)632-845; Fa: (63)632-8334 qin@cs.sunsb.edu

More information

Camera Models and Image Formation. Srikumar Ramalingam School of Computing University of Utah

Camera Models and Image Formation. Srikumar Ramalingam School of Computing University of Utah Camera Models and Image Formation Srikumar Ramalingam School of Computing University of Utah srikumar@cs.utah.edu Reference Most slides are adapted from the following notes: Some lecture notes on geometric

More information

MEM380 Applied Autonomous Robots Winter Robot Kinematics

MEM380 Applied Autonomous Robots Winter Robot Kinematics MEM38 Applied Autonomous obots Winter obot Kinematics Coordinate Transformations Motivation Ultimatel, we are interested in the motion of the robot with respect to a global or inertial navigation frame

More information

CS559: Computer Graphics

CS559: Computer Graphics CS559: Computer Graphics Lecture 8: 3D Transforms Li Zhang Spring 28 Most Slides from Stephen Chenne Finish Color space Toda 3D Transforms and Coordinate sstem Reading: Shirle ch 6 RGB and HSV Green(,,)

More information

Homogeneous Coordinates. Lecture18: Camera Models. Representation of Line and Point in 2D. Cross Product. Overall scaling is NOT important.

Homogeneous Coordinates. Lecture18: Camera Models. Representation of Line and Point in 2D. Cross Product. Overall scaling is NOT important. Homogeneous Coordinates Overall scaling is NOT important. CSED44:Introduction to Computer Vision (207F) Lecture8: Camera Models Bohyung Han CSE, POSTECH bhhan@postech.ac.kr (",, ) ()", ), )) ) 0 It is

More information

To Do. Motivation. Demo (Projection Tutorial) What we ve seen so far. Computer Graphics. Summary: The Whole Viewing Pipeline

To Do. Motivation. Demo (Projection Tutorial) What we ve seen so far. Computer Graphics. Summary: The Whole Viewing Pipeline Computer Graphics CSE 67 [Win 9], Lecture 5: Viewing Ravi Ramamoorthi http://viscomp.ucsd.edu/classes/cse67/wi9 To Do Questions/concerns about assignment? Remember it is due tomorrow! (Jan 6). Ask me or

More information

4. Two Dimensional Transformations

4. Two Dimensional Transformations 4. Two Dimensional Transformations CS362 Introduction to Computer Graphics Helena Wong, 2 In man applications, changes in orientations, sizes, and shapes are accomplished with geometric transformations

More information

CS F-07 Objects in 2D 1

CS F-07 Objects in 2D 1 CS420-2010F-07 Objects in 2D 1 07-0: Representing Polgons We want to represent a simple polgon Triangle, rectangle, square, etc Assume for the moment our game onl uses these simple shapes No curves for

More information

Image Warping. Computational Photography Derek Hoiem, University of Illinois 09/28/17. Photo by Sean Carroll

Image Warping. Computational Photography Derek Hoiem, University of Illinois 09/28/17. Photo by Sean Carroll Image Warping 9/28/7 Man slides from Alosha Efros + Steve Seitz Computational Photograph Derek Hoiem, Universit of Illinois Photo b Sean Carroll Reminder: Proj 2 due monda Much more difficult than project

More information

CS6670: Computer Vision

CS6670: Computer Vision CS6670: Computer Vision Noah Snavely Lecture 5: Projection Reading: Szeliski 2.1 Projection Reading: Szeliski 2.1 Projection Müller Lyer Illusion http://www.michaelbach.de/ot/sze_muelue/index.html Modeling

More information

[ ] [ ] Orthogonal Transformation of Cartesian Coordinates in 2D & 3D. φ = cos 1 1/ φ = tan 1 [ 2 /1]

[ ] [ ] Orthogonal Transformation of Cartesian Coordinates in 2D & 3D. φ = cos 1 1/ φ = tan 1 [ 2 /1] Orthogonal Transformation of Cartesian Coordinates in 2D & 3D A vector is specified b its coordinates, so it is defined relative to a reference frame. The same vector will have different coordinates in

More information

Pinhole Camera Model 10/05/17. Computational Photography Derek Hoiem, University of Illinois

Pinhole Camera Model 10/05/17. Computational Photography Derek Hoiem, University of Illinois Pinhole Camera Model /5/7 Computational Photography Derek Hoiem, University of Illinois Next classes: Single-view Geometry How tall is this woman? How high is the camera? What is the camera rotation? What

More information

Image Warping. Many slides from Alyosha Efros + Steve Seitz. Photo by Sean Carroll

Image Warping. Many slides from Alyosha Efros + Steve Seitz. Photo by Sean Carroll Image Warping Man slides from Alosha Efros + Steve Seitz Photo b Sean Carroll Morphing Blend from one object to other with a series of local transformations Image Transformations image filtering: change

More information

Viewing and Projection

Viewing and Projection Viewing and Projection Sheelagh Carpendale Camera metaphor. choose camera position 2. set up and organie objects 3. choose a lens 4. take the picture View Volumes what gets into the scene perspective view

More information

Transformations. Examples of transformations: shear. scaling

Transformations. Examples of transformations: shear. scaling Transformations Eamples of transformations: translation rotation scaling shear Transformations More eamples: reflection with respect to the y-ais reflection with respect to the origin Transformations Linear

More information

Geometric Transformations

Geometric Transformations Geometric Transformations CS 4620 Lecture 9 2017 Steve Marschner 1 A little quick math background Notation for sets, functions, mappings Linear and affine transformations Matrices Matrix-vector multiplication

More information

Two Dimensional Viewing

Two Dimensional Viewing Two Dimensional Viewing Dr. S.M. Malaek Assistant: M. Younesi Two Dimensional Viewing Basic Interactive Programming Basic Interactive Programming User controls contents, structure, and appearance of objects

More information

COSC579: Scene Geometry. Jeremy Bolton, PhD Assistant Teaching Professor

COSC579: Scene Geometry. Jeremy Bolton, PhD Assistant Teaching Professor COSC579: Scene Geometry Jeremy Bolton, PhD Assistant Teaching Professor Overview Linear Algebra Review Homogeneous vs non-homogeneous representations Projections and Transformations Scene Geometry The

More information

Agenda. Rotations. Camera calibration. Homography. Ransac

Agenda. Rotations. Camera calibration. Homography. Ransac Agenda Rotations Camera calibration Homography Ransac Geometric Transformations y x Transformation Matrix # DoF Preserves Icon translation rigid (Euclidean) similarity affine projective h I t h R t h sr

More information

3D Viewing and Projec5on. Taking Pictures with a Real Camera. Steps: Graphics does the same thing for rendering an image for 3D geometric objects

3D Viewing and Projec5on. Taking Pictures with a Real Camera. Steps: Graphics does the same thing for rendering an image for 3D geometric objects 3D Vieing and Projec5on Taking Pictures ith a Real Camera Steps: Iden5 interes5ng objects Rotate and translate the camera to desired viepoint Adjust camera seings such as ocal length Choose desired resolu5on

More information

Image warping. image filtering: change range of image. image warping: change domain of image g(x) = f(h(x)) h(y)=0.5y+0.5. h([x,y])=[x,y/2] f h

Image warping. image filtering: change range of image. image warping: change domain of image g(x) = f(h(x)) h(y)=0.5y+0.5. h([x,y])=[x,y/2] f h Image warping Image warping image filtering: change range of image g() () = h(f()) h(f()) f h g h()=0.5+0.5 image warping: change domain of image g() = f(h()) f h g h([,])=[,/2] Parametric (global) warping

More information

Image Formation. Antonino Furnari. Image Processing Lab Dipartimento di Matematica e Informatica Università degli Studi di Catania

Image Formation. Antonino Furnari. Image Processing Lab Dipartimento di Matematica e Informatica Università degli Studi di Catania Image Formation Antonino Furnari Image Processing Lab Dipartimento di Matematica e Informatica Università degli Studi di Catania furnari@dmi.unict.it 18/03/2014 Outline Introduction; Geometric Primitives

More information

521466S Machine Vision Exercise #1 Camera models

521466S Machine Vision Exercise #1 Camera models 52466S Machine Vision Exercise # Camera models. Pinhole camera. The perspective projection equations or a pinhole camera are x n = x c, = y c, where x n = [x n, ] are the normalized image coordinates,

More information

Pin Hole Cameras & Warp Functions

Pin Hole Cameras & Warp Functions Pin Hole Cameras & Warp Functions Instructor - Simon Lucey 16-423 - Designing Computer Vision Apps Today Pinhole Camera. Homogenous Coordinates. Planar Warp Functions. Motivation Taken from: http://img.gawkerassets.com/img/18w7i1umpzoa9jpg/original.jpg

More information

Affine and Projective Transformations

Affine and Projective Transformations CS 674: Intro to Computer Vision Affine and Projective Transformations Prof. Adriana Kovaska Universit of Pittsburg October 3, 26 Alignment problem We previousl discussed ow to matc features across images,

More information

3D Computer Vision II. Reminder Projective Geometry, Transformations. Nassir Navab. October 27, 2009

3D Computer Vision II. Reminder Projective Geometry, Transformations. Nassir Navab. October 27, 2009 3D Computer Vision II Reminder Projective Geometr, Transformations Nassir Navab based on a course given at UNC b Marc Pollefes & the book Multiple View Geometr b Hartle & Zisserman October 27, 29 2D Transformations

More information

Computer Vision Projective Geometry and Calibration. Pinhole cameras

Computer Vision Projective Geometry and Calibration. Pinhole cameras Computer Vision Projective Geometry and Calibration Professor Hager http://www.cs.jhu.edu/~hager Jason Corso http://www.cs.jhu.edu/~jcorso. Pinhole cameras Abstract camera model - box with a small hole

More information

Image Formation I Chapter 2 (R. Szelisky)

Image Formation I Chapter 2 (R. Szelisky) Image Formation I Chapter 2 (R. Selisky) Guido Gerig CS 632 Spring 22 cknowledgements: Slides used from Prof. Trevor Darrell, (http://www.eecs.berkeley.edu/~trevor/cs28.html) Some slides modified from

More information

Visual Recognition: Image Formation

Visual Recognition: Image Formation Visual Recognition: Image Formation Raquel Urtasun TTI Chicago Jan 5, 2012 Raquel Urtasun (TTI-C) Visual Recognition Jan 5, 2012 1 / 61 Today s lecture... Fundamentals of image formation You should know

More information

Vector Algebra Transformations. Lecture 4

Vector Algebra Transformations. Lecture 4 Vector Algebra Transformations Lecture 4 Cornell CS4620 Fall 2008 Lecture 4 2008 Steve Marschner 1 Geometry A part of mathematics concerned with questions of size, shape, and relative positions of figures

More information

Projections. Let us start with projections in 2D, because there are easier to visualize.

Projections. Let us start with projections in 2D, because there are easier to visualize. Projetions Let us start ith projetions in D, beause there are easier to visualie. Projetion parallel to the -ais: Ever point in the -plane ith oordinates (, ) ill be transformed into the point ith oordinates

More information

More on Transformations. COS 426, Spring 2019 Princeton University

More on Transformations. COS 426, Spring 2019 Princeton University More on Transformations COS 426, Spring 2019 Princeton Universit Agenda Grab-bag of topics related to transformations: General rotations! Euler angles! Rodrigues s rotation formula Maintaining camera transformations!

More information

12.4 The Ellipse. Standard Form of an Ellipse Centered at (0, 0) (0, b) (0, -b) center

12.4 The Ellipse. Standard Form of an Ellipse Centered at (0, 0) (0, b) (0, -b) center . The Ellipse The net one of our conic sections we would like to discuss is the ellipse. We will start b looking at the ellipse centered at the origin and then move it awa from the origin. Standard Form

More information

Projective Geometry and Camera Models

Projective Geometry and Camera Models Projective Geometry and Camera Models Computer Vision CS 43 Brown James Hays Slides from Derek Hoiem, Alexei Efros, Steve Seitz, and David Forsyth Administrative Stuff My Office hours, CIT 375 Monday and

More information

Modeling Transformations

Modeling Transformations Modeling Transformations Thomas Funkhouser Princeton Universit CS 426, Fall 2 Modeling Transformations Specif transformations for objects Allos definitions of objects in on coordinate sstems Allos use

More information

Computer Vision cmput 428/615

Computer Vision cmput 428/615 Computer Vision cmput 428/615 Basic 2D and 3D geometry and Camera models Martin Jagersand The equation of projection Intuitively: How do we develop a consistent mathematical framework for projection calculations?

More information

Homogeneous Coordinates

Homogeneous Coordinates COMS W4172 3D Math 2 Steven Feiner Department of Computer Science Columbia Universit New York, NY 127 www.cs.columbia.edu/graphics/courses/csw4172 Februar 1, 218 1 Homogeneous Coordinates w X W Y X W Y

More information

Last Lecture. Edge Detection. Filtering Pyramid

Last Lecture. Edge Detection. Filtering Pyramid Last Lecture Edge Detection Filtering Pramid Toda Motion Deblur Image Transformation Removing Camera Shake from a Single Photograph Rob Fergus, Barun Singh, Aaron Hertzmann, Sam T. Roweis and William T.

More information

Modeling Transformations

Modeling Transformations Transformations Transformations Specif transformations for objects o Allos definitions of objects in on coordinate sstems o Allos use of object definition multiple times in a scene Adam Finkelstein Princeton

More information

Image Formation I Chapter 1 (Forsyth&Ponce) Cameras

Image Formation I Chapter 1 (Forsyth&Ponce) Cameras Image Formation I Chapter 1 (Forsyth&Ponce) Cameras Guido Gerig CS 632 Spring 213 cknowledgements: Slides used from Prof. Trevor Darrell, (http://www.eecs.berkeley.edu/~trevor/cs28.html) Some slides modified

More information

3-D D Euclidean Space - Vectors

3-D D Euclidean Space - Vectors 3-D D Euclidean Space - Vectors Rigid Body Motion and Image Formation A free vector is defined by a pair of points : Jana Kosecka http://cs.gmu.edu/~kosecka/cs682.html Coordinates of the vector : 3D Rotation

More information

CS4670: Computer Vision

CS4670: Computer Vision CS467: Computer Vision Noah Snavely Lecture 13: Projection, Part 2 Perspective study of a vase by Paolo Uccello Szeliski 2.1.3-2.1.6 Reading Announcements Project 2a due Friday, 8:59pm Project 2b out Friday

More information

How is project #1 going?

How is project #1 going? How is project # going? Last Lecture Edge Detection Filtering Pramid Toda Motion Deblur Image Transformation Removing Camera Shake from a Single Photograph Rob Fergus, Barun Singh, Aaron Hertzmann, Sam

More information

Transformations II. Week 2, Wed Jan 17

Transformations II. Week 2, Wed Jan 17 Universit of British Columbia CPSC 34 Computer Graphics Jan-Apr 27 Tamara Munzner Transformations II Week 2, Wed Jan 7 http://www.ugrad.cs.ubc.ca/~cs34/vjan27 Readings for Jan 5-22 FCG Chap 6 Transformation

More information

Announcements. Introduction to Cameras. The Key to Axis Angle Rotation. Axis-Angle Form (review) Axis Angle (4 steps) Mechanics of Axis Angle

Announcements. Introduction to Cameras. The Key to Axis Angle Rotation. Axis-Angle Form (review) Axis Angle (4 steps) Mechanics of Axis Angle Ross Beerige Bruce Draper Introuction to Cameras September th 25 Announcements PA ue eek from Tuesa Q: hat i I mean b robust I/O? Hanle arious numbers of erte/face features Check for count matches Goo

More information

Camera Calibration. Schedule. Jesus J Caban. Note: You have until next Monday to let me know. ! Today:! Camera calibration

Camera Calibration. Schedule. Jesus J Caban. Note: You have until next Monday to let me know. ! Today:! Camera calibration Camera Calibration Jesus J Caban Schedule! Today:! Camera calibration! Wednesday:! Lecture: Motion & Optical Flow! Monday:! Lecture: Medical Imaging! Final presentations:! Nov 29 th : W. Griffin! Dec 1

More information

THE INVERSE GRAPH. Finding the equation of the inverse. What is a function? LESSON

THE INVERSE GRAPH. Finding the equation of the inverse. What is a function? LESSON LESSON THE INVERSE GRAPH The reflection of a graph in the line = will be the graph of its inverse. f() f () The line = is drawn as the dotted line. Imagine folding the page along the dotted line, the two

More information

Image Formation I Chapter 1 (Forsyth&Ponce) Cameras

Image Formation I Chapter 1 (Forsyth&Ponce) Cameras Image Formation I Chapter 1 (Forsyth&Ponce) Cameras Guido Gerig CS 632 Spring 215 cknowledgements: Slides used from Prof. Trevor Darrell, (http://www.eecs.berkeley.edu/~trevor/cs28.html) Some slides modified

More information

Basic Elements. Geometry is the study of the relationships among objects in an n-dimensional space

Basic Elements. Geometry is the study of the relationships among objects in an n-dimensional space Basic Elements Geometry is the study of the relationships among objects in an n-dimensional space In computer graphics, we are interested in objects that exist in three dimensions We want a minimum set

More information

Pin Hole Cameras & Warp Functions

Pin Hole Cameras & Warp Functions Pin Hole Cameras & Warp Functions Instructor - Simon Lucey 16-423 - Designing Computer Vision Apps Today Pinhole Camera. Homogenous Coordinates. Planar Warp Functions. Example of SLAM for AR Taken from:

More information

What does OpenGL do?

What does OpenGL do? Theor behind Geometrical Transform What does OpenGL do? So the user specifies a lot of information Ee Center Up Near, far, UP EE Left, right top, bottom, etc. f b CENTER left right top bottom What does

More information

Warping, Morphing and Mosaics

Warping, Morphing and Mosaics Computational Photograph and Video: Warping, Morphing and Mosaics Prof. Marc Pollefes Dr. Gabriel Brostow Toda s schedule Last week s recap Warping Morphing Mosaics Toda s schedule Last week s recap Warping

More information

Cameras and Stereo CSE 455. Linda Shapiro

Cameras and Stereo CSE 455. Linda Shapiro Cameras and Stereo CSE 455 Linda Shapiro 1 Müller-Lyer Illusion http://www.michaelbach.de/ot/sze_muelue/index.html What do you know about perspective projection? Vertical lines? Other lines? 2 Image formation

More information

Prof. Feng Liu. Winter /05/2019

Prof. Feng Liu. Winter /05/2019 Prof. Feng Liu Winter 2019 http://www.cs.pd.edu/~fliu/courses/cs410/ 02/05/2019 Last Time Image alignment 2 Toda Image warping The slides for this topic are used from Prof. Yung-Yu Chuang, which use materials

More information

Viewing. Reading: Angel Ch.5

Viewing. Reading: Angel Ch.5 Viewing Reading: Angel Ch.5 What is Viewing? Viewing transform projects the 3D model to a 2D image plane 3D Objects (world frame) Model-view (camera frame) View transform (projection frame) 2D image View

More information

Projective Geometry and Camera Models

Projective Geometry and Camera Models /2/ Projective Geometry and Camera Models Computer Vision CS 543 / ECE 549 University of Illinois Derek Hoiem Note about HW Out before next Tues Prob: covered today, Tues Prob2: covered next Thurs Prob3:

More information

Augmented Reality II - Camera Calibration - Gudrun Klinker May 11, 2004

Augmented Reality II - Camera Calibration - Gudrun Klinker May 11, 2004 Augmented Reality II - Camera Calibration - Gudrun Klinker May, 24 Literature Richard Hartley and Andrew Zisserman, Multiple View Geometry in Computer Vision, Cambridge University Press, 2. (Section 5,

More information

Image Warping, mesh, and triangulation CSE399b, Spring 07 Computer Vision

Image Warping, mesh, and triangulation CSE399b, Spring 07 Computer Vision http://grail.cs.washington.edu/projects/rotoscoping/ Image Warping, mesh, and triangulation CSE399b, Spring 7 Computer Vision Man of the slides from A. Efros. Parametric (global) warping Eamples of parametric

More information

CS231M Mobile Computer Vision Structure from motion

CS231M Mobile Computer Vision Structure from motion CS231M Mobile Computer Vision Structure from motion - Cameras - Epipolar geometry - Structure from motion Pinhole camera Pinhole perspective projection f o f = focal length o = center of the camera z y

More information

Section 9.3: Functions and their Graphs

Section 9.3: Functions and their Graphs Section 9.: Functions and their Graphs Graphs provide a wa of displaing, interpreting, and analzing data in a visual format. In man problems, we will consider two variables. Therefore, we will need to

More information