Photogrammetry

Photogrammetry

From the Photogrammetry workshop at 2014 SketchUp Basecamp by Joshua Cohen - as remembered by catamountain

Joshua Cohen of Fat Pencil Studio presented his company's use of used both Match Photo and Advanced Camera Tools (ACT) to recreate a time-stamped accident scene during SketchUp Basecamp 2014 showcasing his SketchUp photogrammetry work to help the TriMet Case settle out-of-court.

General, introductory instructions for Match Photo and Advanced Camera Tools (Google Doc) - a SketchUp Pro extension from the SketchUp team - do not cover all possible uses of these two powerful tools. Advanced Camera Tools (ACT) can be used for more things than the film and television industry.

Photogrammetry is the term used to measure physical space from photographs. In cases when it is important to know the physical camera location, the ACT extension now makes it possible to determine camera location from a digital picture.

The 2014 SketchUp Basecamp Photogrammetry Workshop files to examine:

ford building.zip

football field.zip (note that the football field example has less reference lines in the image and relies more on setting the scene with Advanced Camera Tools.)

Fat Pencil Studio YouTube home with more examples.


Here's a Match Photo version of the Ford Building, geo-located, file available for study from the 2014 Photogrammetry Workshop.

Next follows the steps to locate the camera position.

Setting up a custom digital camera in Advanced Camera Tools

Note: to obtain accurate information from digital photograph metadata, use the original, unaltered (uncropped) digital image. A cropped image should not be used as that may adversely affect the results.

Focal length and image sensor are the two things that determine the angle of view and amount of detail seen through a camera. The apex of the angle of view is the camera position.

Frustum lines and frustum volume are ACT camera options that will show the cropped region of view seen through a camera. View Frustums of an average digital camera, from standard ACT camera options, in red and the green camera shows the position of the actual camera that took the picture used in this tutorial.

Finding the data

Focal Length is found in the image metadata. Metadata is information about the camera contained within the image. In the viewer IrfranView, open your image and look for Focal Length under Image > Information > EXIF Info.

Camera Sensor width in mm is the value to use as the Image Width in the ACT custom camera properties. Depending on the camera, it can take more effort to find this measurement. Smartphones also have a sensor size for the camera, but the information is not as 'easy' to find as with a digital camera. Most common camera sensor sizes can be found on Wikipedia.

Find the camera model under EXIF metadata.

Look for comparative charts of real sensor size, like this one for the Nikon that took this picture. Quite a few cameras have this information on Wikipedia, but some hunting may be required.


More: Field of View Calculator (FoV) of a Camera and Lens

Entering the data

Install Advanced Camera Tools (ACT) in SketchUp Pro. Either add the ACT toolbar through View > Toolbars or access the tools through the Tools menu. If the extension was installed but does not show up in either the View or Tools menu, check that the extension was enabled in Window > Preferences > Extensions.

Add a camera.

Add a Scene for the camera location. With that Scene selected, r-click on the workspace to open the edit camera menu. Don't forget to refresh the Scene as you go along with any notable changes.

TIP: If you plan on using the same camera often, add the camera specs to ACT by editing the cameras.csv file.

Add the image as a Watermark

Add the original photograph as a watermark through the Styles browser.

Set the watermark as Stretched and enable Lock Aspect Ratio.

Initially, set the model/image visibility somewhere in the middle, so both watermark and match photo model are visible. This set-up will be used to fine-tune the ACT camera position by moving the camera to align the model space with the watermark image.

Scene Set-up

Don't forget to refresh the Scene as you go along with any notable changes which should be saved.

Look through the camera

This gives the option to look through the camera in the Scene where the camera was originally set up.

Make Watermark visibility adjustments through the Styles browser.

Fine-tune the camera position by first adjusting the watermark/model visibility so they both can be seen then adjusting the camera to align the SketchUp model to the watermark. As shown below, to move the ACT camera use ACT camera adjustments as shown in the tool tips listed in the status bar.


Pressing the keyboard modifier will show the camera movement in the square brackets for people unfamiliar with the given film industry camera movement names.

Tip: Quickly revert back to the previous camera position encase the camera was over adjusted by using Camera > Previous. The commands Previous and Next will cycle through the most recent camera positions. Might as well make this a keyboard shortcut through Window > Preferences > Shortcuts as it is very useful in many SketchUp modeling situations (keyboard shortcuts are displayed in menus along the right margin.)