Vr Mapping

ON-LINE REFERENCE DOCUMENTATION

CARDINAL SYSTEMS, LLC

www.cardinalsystems.net

VR Camera Definitions and Editing

Type: Utility accessed from multiple VR programs.

 

All VR programs use this interface to define and edit cameras.

Overview

The camera calibration parameters relate the ideal model of a camera to the actual physical device.  This information includes focal length, principal points, and lens distortion parameters.  Extreme lens distortion is apparent when images of straight lines appear curved (this is common on lenses with short focal lengths).  Even in cameras without obvious distortion calibration parameters are important in metric work.

 

Aerial mapping companies have historically have been spending between 300,000 and 1.5 million dollars on specially built cameras that hold these parameters in check.  These metric cameras come with calibration reports.  Non-metric cameras can be calibrated using Vr Camera Calibration.

 

The bundle adjustment also does camera calibration, but it is important to give it reasonable initial values.

 

Contents

Digital Cameras

Film Cameras

RPC Cameras

Lens Distortion

Importing Camera Data

 Agisoft

 Datumate

 ISAT

 Pix4D

 SocketSet Camera

 SocketSet Support File

 VR Camera File

 

Digital Cameras

 

To Setup a digital camera begin by setting the Camera type and setting the camera units as appropriate.  Changing the camera units updates the units notations next to all the inputs to clarify what is expected.  If editing an existing cameras these two fields will already be set and probably do not need to be changed.

 

EditCamera_digital

The Digital Camera dialog

 

Camera type - Defines the type of camera and determines the parameters to display in the dialog.

Calibration units - The coordinate and focal length units are typically defined as Millimeters (mm) or Pixels (px).

Description - A description of the camera may be provided for user convenience and does not affect how the software operates.

Focal length - Defines a fundamental description of the geometry of the bundle of rays captured by image and is usual provided by manufacturers of metric cameras.  Non-metric camera users can estimate it from the lens size or use VR Camera Calibration to determine it. This parameter is entered in the calibration units (millimeters or pixels).

Vr2Ori_image010

Photo size - The physical dimensions of the image sensor.  This parameter is entered in the calibration units (millimeters or pixels).

Principal point - Describe the point of symmetry of the lens distortion.  It is often provided by manufacturers of metric cameras, but never by manufacturers of non-metric cameras.  In can be estimated to be (0,0) and then determined as part of a bundle adjustment in VR Aerial Triangulation or determined in Vr Camera Calibration. This parameter is entered in the calibration units (millimeters or pixels).

Edit Radial Distortions - Please see Lens distortion

Edit Boresite Parameters - The “boresight” parameters are typically used to describe the differences in the rotations of the sensor (such as camera) rotational axes and the rotational axes of the Inertial Measurement Unit (IMU), which is usually bolted to the camera body. These parameters are set to zero by default.

Note: Even though most of the fields in this dialog indicate millimeters (mm) as the parameter units, the units are entered as specified in the 'Calibration units' field which is Millimeters or Pixels.

Film Cameras

To Setup a film camera begin by setting the camera type to 'Scanned film' and setting the camera units as appropriate, this is probably millimeters.  Changing the camera units updates the units notations next to all the inputs to clarify what is expected.  If editing an existing cameras these two fields will already be set and probably do not need to be changed.

 

EditCamera_film

The File Camera dialog

 

Camera type - Defines the type of camera and determines the parameters to display in the dialog.

Calibration units - The coordinate and focal length units are typically defined as Millimeters (mm) or Pixels (px).

Description - A description of the camera may be provided for user convenience and does not affect how the software operates.

Focal length - Defines a fundamental description of the geometry of the bundle of rays captured by image and is usual provided by manufacturers of metric cameras.  Non-metric camera users can estimate it from the lens size or use VR Camera Calibration to determine it. This parameter is entered in the calibration units (millimeters or pixels).

Vr2Ori_image010

Photo size - The physical dimensions of the image sensor.  This parameter is entered in the calibration units (millimeters or pixels).

Principal point - Describe the point of symmetry of the lens distortion.  It is often provided by manufacturers of metric cameras, but never by manufacturers of non-metric cameras.  In can be estimated to be (0,0) and then determined as part of a bundle adjustment in VR Aerial Triangulation or determined in Vr Camera Calibration. This parameter is entered in the calibration units (millimeters or pixels).

Fiducial n X and Y - Defines the coordinate positions for up to eight fiducial marks.  Most aerial cameras have eight fiducial marks, and it is strongly recommended that all fiducial marks be used to compute the interior orientations.  If there are less than eight fiducial marks (or you elect to use less) leave the undefined fiducial mark coordinates zeros. These parameters are entered in the calibration units (millimeters or pixels).

Edit Radial Distortions - Please see Lens distortion

Edit Boresite Parameters - The “boresight” parameters are typically used to describe the differences in the rotations of the sensor (such as camera) rotational axes and the rotational axes of the Inertial Measurement Unit (IMU), which is usually bolted to the camera body. These parameters are set to zero by default.

Note: Even though most of the fields in this dialog indicate millimeters (mm) as the parameter units, the units are entered as specified in the 'Calibration units' field which is Millimeters or Pixels.

 

 

RPC Cameras

 

To Setup a RPC camera select the 'Camera type" to RPC

 

EditCamera_RPC

The RPC dialog

 

Notice that there are no parameters.  RPCs (rational polynomial coefficients) encode not only the exterior orientation of images but their interior orientation and camera parameters as well.  The only reason a camera is even created is as a place holder.  The Vr software requires that images be assigned a camera, so here a dummy camera is used.  This serves the purpose of telling the software to expect/require an RPC data file for this image.

Lens Distortion

VrAirTrigRadialDistortions

 

Lens distortion causes imaged positions to be displaced from the ideal or true locations. In aerial cameras these distortions are normally minimal but can still have an effect on accuracy. Some of the digital cameras have large lens distortions and radial distortions must be entered for accurate mapping results.

Adjustment mode - There are two methods of representing radial distortions which are by distance or with polynomial values. Most camera calibration programs output radial distortions values as polynomial parameters. The Angular option is currently not supported.

Distance Parameters

Radial distortions that are represented as concentric rings about the camera lens calibrated principal point may be entered as distance parameters. The radial distortions shown below are from a small format camera.

 

VrAirTrigRadialDistortionsDistance

Defining radial distortions by distance

Radial distance increment - Represents the distance between the concentric rings that make up the distance parameters. Radial distance increment units should be the same as those used for Fiducial positions.

Distortion values - Specifies distortion values for each distance. There may be up to 15 values. Distortion value units should be the same as those used for Fiducial positions.

Angular Parameters

The Angular Parameters are currently unsupported.

Polynomial Parameters

The mathematical model used is based on the Simultaneous Multi-camera Analytical Calibration (SMAC) method as defined by the USGS. Care should be taken when entering these parameters, as entry errors cause model orientation errors and distortions which affect model accuracy.  For metric cameras these values should be provided in a calibration report.  For non-metric cameras they can be determined in VR Camera Calibration or assumed zero and calculate as part of the bundle adjustment.

 

Up to five symmetric radial distortion coefficients (K values) can be defined.  Unused (undefined) K values should be left zero.

 

Up to four decentering coefficient values (P Values) can be defined.  Unused (undefined) P values should be left zero.

 

The K and P values are entered into the Polynomial Parameters dialog box in exponential notation. The values entered from the USGS camera calibration report may have the decimal place moved one position to the left depending on the number entered. For example:

USGS value:  0.1403x10-3

Value typed:  .1043e-3

Shown value: 1.403000e-004

 

VrAirTrigRadialDistortionsPolynomial

The Radial Distortions dialog box for entering the polynomial parameters

 

Importing Camera Data

If supported, a camera file should be imported to avoid transcription errors and other frustrations.  Various formats are supported, but several of them have only partial definitions and some values must still be manually entered.  Finally, some camera formats cannot be translated into VR exactly.  Please read the documentation carefully.  Also, file formats from other software do change periodically, if you have an issue please send an email to support@cardinalsystems.net and we will get it fixed.

 

All camera importing is done using the 'Import Camera Data' located near the top of the camera edit dialog.

 

EditCamera_import

Import Camera dialog

 

The type of camera is selected from file type combo box near the bottom right of the windows file open dialog.

 

Agisoft Camera Import

Agisoft camera files are among those that are not translated exactly into VR.  The camera definition is complete, but includes multiple focal lengths and skew parameters that are not currently supported.  If importing from Agisoft it is recommended that you import the block measurements and run a bundle in VR AT to compensate for this.

 

File Format:

  <sensors>

     <sensor id="0" label="ILCE-5100 (20 mm)" type="frame">

     <resolution width="6000" height="4000"/>

     <property name="pixel_width" value="4.0000000000000010e-003"/>

     <property name="pixel_height" value="4.0000000000000010e-003"/>

     <property name="focal_length" value="2.0000000000000000e+001"/>

     <property name="fixed" value="false"/>

     <calibration type="frame" class="adjusted">

        <resolution width="6000" height="4000"/>

        <fx>5.2542324878152913e+003</fx>

        <fy>5.2548648186137489e+003</fy>

        <cx>2.9641988929952763e+003</cx>

        <cy>1.9857667758296288e+003</cy>

        <skew>7.0995629195644328e-001</skew>

        <k1>-1.6570203169850198e-001</k1>

        <k2>1.6255130389270986e-001</k2>

        <k3>-1.6184373209953556e-002</k3>

        <p1>2.7834959305479836e-004</p1>

        <p2>-7.6558212510163196e-004</p2>

     </calibration>

     </sensor>

  </sensors>

 

Datumate Camera Import

The Datumate camera information is stored in the Datumate .ori files. There is a .ori file for each photo that was used by Datumate. Any .ori file may be selected if a single camera was used for the entire project. If multiple camera were used then this procedure would be repeated for each camera. If multiple cameras were used when the .ori files might need to be viewed to determine a .ori file for each camera. A fully functional camera definition will be imported, but a description can be added for convenience.

 

The Datumate camera import does not import radial distortions and the resulting camera file has the radial distortions turned off.

 

File format:

$ImageID___________________________________________________(ORI_Ver_1.1)

         C:\Users\efusco\Documents\DatuGram3D\Jobs\4437 Edgewood2\DJI_0042.JPG

$IntOri_FocalLength_________________________________________________[mm]

 3641.03399123682

$IntOri_PixelSize______(x|y)________________________________________[mm]

 1.0        1.0

$IntOri_SensorSize_____(x|y)_____________________________________[pixel]

 4864        3648

$IntOri_PrincipalPoint_(x|y)_____________________________________[pixel]

 2430.13821103775        1829.13666785524

$IntOri_CameraMatrix_____________________________(ImageCoordinateSystem)

 3641.03399123682        0.0        2430.13821103775

 0.0        3641.03399123682        1829.13666785524

 0.0        0.0        1.0

$ExtOri_RotationMatrix____________________(World->ImageCoordinateSystem)

 -0.0221952154000378        -0.99974523079716        0.00410437713666893

 -0.999702089254286        0.0222355802304079        0.010065371946993

 -0.0101540708073241        -0.00387975130017045        -0.999940919442688

$ExtOri_TranslationVector________________________(WorldCoordinateSystem)

 2499566.78335786        7104704.29847965        1009.9040071593

$IntOri_Distortion_____(Model|ParameterCount|(Parameters))______________

         BROWN5 5 0.00919791907365037        -0.0261102747197858        0.0268052984509787        0.000457924221920482        -0.000448249900254116

$Rectification_Method______________________________________________________

         NONE

 

Pix4D Camera Import

Pix4D is among those formats that cannot be exactly duplicated.  I appears that they use some kind of irregular distortion grid internally, but only export a SMAC like set of polynomial parameters.   If importing from Pix4D it is recommended that you import the block measurements and run a bundle in VR AT to compensate for this.

 

File format:

  Pix4D camera calibration file 0

  #Focal Length mm assuming a sensor width of 6.31747999999999976239x4.73810999999999982180mm

  F 3.73320024386105409064

  #Principal Point mm

  Px 3.15119568290642693142

  Py 2.38913699995431461076

  #Symmetrical Lens Distortion Coeffs

  K1 -0.01268751795503417212

  K2 0.00500201292706088565

  K3 0.00883570912425699420

  #Tangential Lens Distortion Coeffs

  T1 0.00006907855258670360

  T2 0.00007440408018383493

 

ISAT Camera Import

 

SocketSet Camera Import

There are two support flavors of Socket set camera files.  Both contain the same data, but their formatting is quite different.  Both are missing the camera photo (chip) size, which must be manually added to complete the camera definition.

 

SocketSet Camera File, Flavor1:

 

  Focal Length (mm)

  -208.205000

  Principal Point Offset xpoff ypoff in mm

  -6.0000000000000001e-003  -2.0000000000000000e-003

  How many fiducial pairs (max 8):

  8

  Fiducial x,y pairs in mm

  106.004000 -106.008000

  -105.999000 -105.998000

  -106.004000 106.005000

  106.002000 106.002000

  0.003000 -109.992000

  -109.996000 0.003000

  -0.004000 109.997000

  109.998000 -0.002000

  Symmetrical Lens Distortion Odd-order Poly Coeffs c0,c1,c2,c3 (c0=offset)

  0.000e+00 0.0000000000000000e+000   0.0000000000000000e+000   0.0000000000000000e+000  

  Decentering Lens Coeffs p1, p2, p3

  0.0000000000000000e+000   0.0000000000000000e+000   0.0000000000000000e+000  

  How many distortion pairs (max 20):

  0

  Distortion Data Units (m=radial dist in mm, d=field angle in deg):

  m

  Distortion Data Pairs, if any (Radius in mm or deg, Distortion in Microns):

 

Socket Set Camera, Flavor 2:

  camera_calibration_file 1

 

  #Focal Length (mm)

  FOCAL 92.000500

 

  #Principal Point Offset xpoff ypoff in mm

  XPOFF 3.000000e-003

  YPOFF 2.000000e-003

 

  #Principal Point symmetry xsoff ysoff in mm

  XSOFF 0.000000e+000

  YSOFF 0.000000e+000

 

  #How many fiducial pairs (max 8):

  NUM_FIDS 4

 

  #Fiducials position

  DATA_STRIP_SIDE left

 

  #Fiducial x,y pairs in mm:

  FID_PAIRS

  -39.603200 -43.545600

  39.603200 43.545600

  -39.603200 43.545600

  39.603200 -43.545600

 

  #Symmetrical Lens Distortion Odd-order Poly Coeffs:K0,K1,K2,K3

  SYM_DIST 0.000000e+000   0.000000e+000   0.000000e+000   0.000000e+000

 

  #Decentering Lens Coeffs p1,p2,p3

  DEC_DIST 0.000000e+000   0.000000e+000   0.000000e+000

 

  #How many distortion pairs (max 20):

  NUM_DIST_PAIRS 0

 

  #Distortion Data Units (m=radial dist im mm, d=field angle in deg):

  DIST_UNITS m

 

  #Distortion Data Pairs, if any (Radius in mm or deg, Distortion in Microns)

  DIST_PAIRS

 

SocketSet Support File Camera Import

Socket Set camera data is also found in the support files.  The data here is not as complete.  There are not fiducial coordinates (for film cameras) or a photo size.  However, some software does camera calibration during the bundle adjustment and records the tweaked focal length, etc. in the support files.  Importing a support file will update the changed values.  If creating a camera from a support file care should be taken to manually set the fiducial coordinates (if a film camera) and the photo size.

 

Socket Set Support File:

  support_file d

  IMAGE_ID "613020_206_115"

  IMAGE_FILE_NAME 1 "d:\stereo_rfp\dataset1_film\scans\613020_206_115.img"

  LINES 16576

  SAMPLES 16576

  RECTIFICATION_TERMS

  0.00000000000000e+000 0.00000000000000e+000 1.00000000000000e+000

  0.00000000000000e+000 1.00000000000000e+000 0.00000000000000e+000

  GRND_BIAS 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  BIAS 0.000000 GAIN 1.000000

  GROUND_ZERO 3.98854531019135e+006 4.35194217455687e+005 2.67353727151535e+003

  LOAD_PT 3.98854531019135e+006 4.35194217455687e+005 2.67353727151535e+003

  COORD_SYSTEM 6

  UNITS 1

  USE_FAST_MATH 0

  MAX_AND_MIN_ELEVATION 0.0 1000.0

  IMAGE_MOTION 0

  INITIALIZED 2

  STATUS 0

  QUALITY 53

  SENSOR_TYPE FRAME

  FOCAL 2.08205000000000e+002

  IOCOEF_LINE -1.56472108149629e+001 7.13940026073314e+001 -4.37494679097658e-001 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000        0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  IOCOEF_SAMPLE -1.54474111419888e+001 4.25912380706273e-001 7.13946648078216e+001 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  OPK_LSR -8.28834522463146e-003 -2.65238839172880e-002 -1.53268429353673e+000

  LSR_CAMERA -1.41202811810784e+001 -4.52335264346011e+003 7.62697206937887e+003

  X0Y0Z0_GEO 6.29715707011150e-001 -1.84514880423643e+000 0.00000000000000e+000

  AZIMUTH_LSR 0.00000000000000e+000

  ATMREF 0

  ATMCO 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  ABERR 0

  USE_LENS_DISTORTION 0

  LENSCO 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  XPOFF -6.00000000000000e-003

  YPOFF -2.00000000000000e-003

  ELLIPSOID NAD_83

  VERTICAL_REFERENCE 1

  A_EARTH 6.37813700000000e+006

  E_EARTH 8.18191910434947e-002

  ELLIPSOID_CENTER 0.00000000000000e+000 0.00000000000000e+000 0.00000000000000e+000

  PROJECTION_TYPE UTM_PROJECTION

  ZONE 13

  FALSE_NORTHING_POS 0.0000000000000000e+000

  FALSE_NORTHING_NEG 0.0000000000000000e+000

  FALSE_EASTING_POS 5.0000000000000000e+005

  FALSE_EASTING_NEG 5.0000000000000000e+005

  GRID_NAME UTM_13N

 

 

VR Camera Import

Importing VR's native camera format is straight forward.  The camera definition is complete and no speacial considerations are required.

 

File Format:

# VrTwo Camera File

# 14-Jul-2010 00:51:06

#

# FILENAME   - Parameter file name

# DESC       - Camera description

# FOCALLEN   - Focal length (Fiducial units)

# FIDSIZE    - Fiducial size (Fiducial units)

# FIDUNITS   - Fiducial units (0=mm 1=in 2=pixels)

# FIDCOUNT   - Number of fiducials used (4 | 8)# PHOTOSIZEX - Photo size X (width)  (Fiducial units)

# PHOTOSIZEY - Photo size Y (height) (Fiducial units)

# PPOX       - Calibrated principal Point X (Fiducial units)

# PPOX       - Calibrated principal Point Y (Fiducial units)

# FID        - Fiducial coordinates

# RADDIST    - Radial distortion Angle Distance DistortValue

 

FILENAME   "K:\Jobs\ManAtControl\man_rc10.cam"

DESC       "man_rc10"

FOCALLEN   152.67300000

FIDSIZE    3.00000000

FIDUNITS   0

FIDCOUNT   4

PHOTOSIZEX 240.00000000

PHOTOSIZEY 240.00000000

PPOX       0.00100000

PPOY       -0.00700000

FID        0 -105.99200000 -105.99300000

FID        1 106.01700000 106.00500000

FID        2 -105.98600000 106.01600000

FID        3 105.99100000 -105.99300000

FID        4 0.00000000 0.00000000

FID        5 0.00000000 0.00000000

FID        6 0.00000000 0.00000000

FID        7 0.00000000 0.00000000

#

# Radial distortion parameters

#

Mode        0

Dis_Incr    10.000

Dis_Distort  0 0.00000

Dis_Distort  1 0.00000

Dis_Distort  2 0.00000

Dis_Distort  3 0.00000

Dis_Distort  4 0.00000

Dis_Distort  5 0.00000

Dis_Distort  6 0.00000

Dis_Distort  7 0.00000

Dis_Distort  8 0.00000

Dis_Distort  9 0.00000

Dis_Distort 10 0.00000

Dis_Distort 11 0.00000

Dis_Distort 12 0.00000

Dis_Distort 13 0.00000

Dis_Distort 14 0.00000

Dis_Distort 15 0.00000

#

Ang_Angle    0 0.00000

Ang_Angle    1 0.13090

Ang_Angle    2 0.26180

Ang_Angle    3 0.39619

Ang_Angle    4 0.52360

Ang_Angle    5 0.61087

Ang_Angle    6 0.69813

Ang_Angle    7 0.00000

Ang_Angle    8 0.00000

Ang_Angle    9 0.00000

#

Ang_Distort  0 0.00000

Ang_Distort  1 0.00000

Ang_Distort  2 0.00000

Ang_Distort  3 0.00000

Ang_Distort  4 0.00000

Ang_Distort  5 0.00000

Ang_Distort  6 0.00000

Ang_Distort  7 0.00000

Ang_Distort  8 0.00000

Ang_Distort  9 0.00000

#

k0            0.000000e+000

k1            0.000000e+000

k2            0.000000e+000

k3            0.000000e+000

k4            0.000000e+000

p1            0.000000e+000

p2            0.000000e+000

p3            0.000000e+000

p4            0.000000e+000

xipp               0.000000

yipp               0.000000