Advanced Computer Graphics (Fall 2009)Computational ImagingOutlineHow do we see the world?Pinhole cameraPinhole camera modelDimensionality Reduction Machine (3D to 2D)Funny things happen…Parallel lines aren’t…Lengths can’t be trusted...…but humans adopt!Camera ObscuraFrom Pinhole to LensesHome-made pinhole cameraShrinking the apertureThe reason for lensesFocus and DefocusThin lensesDepth of FieldSlide 20Slide 21Lenslet-based Light Field cameraStanford Plenoptic Camera [Ng et al 2005]Digital RefocusingSlide 25Slide 26Slide 27Slide 28Slide 29Slide 30Slide 31Slide 32Slide 33Captured Blurred PhotoSlide 35Slide 36Slide 37Slide 38Slide 39Slide 40Slide 41Slide 42Slide 43Slide 44Slide 45Slide 46Slide 47Advanced Computer Graphics Advanced Computer Graphics (Fall 2009)(Fall 2009)CS 294, Rendering Lecture 12 Computational Imaging and PhotographyRavi Ramamoorthihttp://inst.eecs.berkeley.edu/~cs294-13/fa09Many slides courtesy Ramesh Raskar, SIGGRAPH 2008 courseComputational ImagingComputational ImagingDigital cameras now commonplaceCan we use computation for better imagesMany novel capabilities relative to filmAnd new ways of processing imagesIs this computer graphics, optics, or image proc?All of the above; many rendering ideas applyApplication shift. Computer aided design to movies/games to photography (big market)Brief lecture. Some more on image processing by Prof. Agrawala in 2 weeksOutlineOutlineImage formation, basic lens-based cameraLight Field cameraCoded aperture depth of fieldFlutter shutter (coded aperture shutter)Many many more old, new innovationsHow do we see the world?Let’s design a camera•Idea 1: put a piece of film in front of an object•Do we get a reasonable image?Slide by Steve SeitzPinhole cameraAdd a barrier to block off most of the rays•This reduces blurring•The opening known as the aperture•How does this transform the image?Slide by Steve SeitzPinhole camera modelPinhole model:•Captures pencil of rays – all rays through a single point•The point is called Center of Projection (COP)•The image is formed on the Image Plane•Effective focal length f is distance from COP to Image PlaneSlide by Steve SeitzPoint of observationFigures © Stephen E. Palmer, 2002Dimensionality Reduction Machine (3D to 2D)3D world 2D imageWhat have we lost?•Angles•Distances (lengths)Funny things happen…Parallel lines aren’t…Figure by David ForsythLengths can’t be trusted...Figure by David ForsythB’C’A’…but humans adopt!http://www.michaelbach.de/ot/sze_muelue/index.html Müller-Lyer IllusionWe don’t make measurements in the image planeCamera ObscuraThe first camera•Known to Aristotle•Depth of the room is the effective focal lengthCamera Obscura, Gemma Frisius, 1558From Pinhole to LensesComputer graphics assumes pinhole modelBut making aperture narrow limits lightMaking aperture large causes blurrinessReal cameras have lenses to collect more light, and focus it on the image plane(Kolb et al. 95 simulates lens effects rendering)Home-made pinhole camera http://www.debevec.org/Pinhole/Why soblurry?Shrinking the apertureWhy not make the aperture as small as possible?•Less light gets through•Diffraction effects…Less light gets throughSlide by Steve SeitzThe reason for lensesSlide by Steve SeitzFocus and DefocusA lens focuses light onto the film•There is a specific distance at which objects are “in focus”–other points project to a “circle of confusion” in the image•Changing the shape/separation of lens changes this distance“circle of confusion”Slide by Steve SeitzThin lensesThin lens equation:•Any object point satisfying this equation is in focus•What is the shape of the focus region?•How can we change the focus region?•Thin lens applet: http://www.phy.ntnu.edu.tw/java/Lens/lens_e.html (by Fu-Kwun Hwang )Slide by Steve SeitzDepth of Fieldhttp://www.cambridgeincolour.com/tutorials/depth-of-field.htmOutlineOutlineImage formation, basic lens-based cameraLight Field cameraCoded aperture depth of fieldFlutter shutter (coded aperture shutter)Many many more old, new innovationsLight Field Inside a CameraLight Field Inside a CameraLenslet-based Light Field cameraLenslet-based Light Field camera[Adelson and Wang, 1992, Ng et al. 2005 ]Light Field Inside a CameraLight Field Inside a CameraStanford Plenoptic Camera Stanford Plenoptic Camera [Ng et al 2005][Ng et al 2005]4000 × 4000 pixels ÷ 292 × 292 lenses = 14 × 14 pixels per lensContax medium format camera Kodak 16-megapixel sensorAdaptive Optics microlens array 125μ square-sided microlensesDigital RefocusingDigital Refocusing[Ng et al 2005][Ng et al 2005]Mask based Light Field CameraMaskSensor [Veeraraghavan, Raskar, Agrawal, Tumblin, Mohan, Siggraph 2007 ]1/f0Mask TileCosine Mask UsedCaptured 2D PhotoEncoding due to Mask [Veeraraghavan, Raskar, Agrawal, Tumblin, Mohan, Siggraph 2007 ]2D FFTTraditional Camera PhotoHeterodyne Camera PhotoMagnitude of 2D FFT2D FFTMagnitude of 2D FFTOutlineOutlineImage formation, basic lens-based cameraLight Field cameraCoded aperture depth of fieldFlutter shutter (coded aperture shutter)Many many more old, new innovationsOut of Focus Photo: Coded ApertureEngineering the PSF when you cannot capture LightfieldIn Focus PhotoLED2D PhotoOut of Focus Photo: Open ApertureOut of Focus Photo: Coded ApertureCaptured Blurred Photo [Veeraraghavan, Raskar, Agrawal, Tumblin, Mohan, Siggraph 2007 ]Refocused on PersonIncrease DoF +large apertureOutlineOutlineImage formation, basic lens-based cameraLight Field cameraCoded aperture depth of fieldFlutter shutter (coded aperture shutter)Many many more old, new innovationsTraditional CameraShutter is OPENOur CameraFlutter ShutterShutter is OPEN and CLOSEDLab SetupBlurring ==ConvolutionTraditional Camera: Box FilterSync FunctionFlutter Shutter: Coded FilterPreserves High Frequencies!!!ComparisonInverse Filter UnstableInverse Filter stableInput ImageRectified CropDeblurred
View Full Document