HuginBase::Lens Class Reference

#include <Lens.h>

List of all members.

Public Types

typedef BaseSrcPanoImage::Projection LensProjectionFormat

Public Member Functions

 Lens ()
 construct a new lens.
LensProjectionFormat getProjection () const
 get projection type
void setProjection (LensProjectionFormat l)
 set projection type
double getHFOV () const
 get HFOV in degrees
void setHFOV (double d)
 set HFOV in degrees
double getFocalLength () const
 get focal length of lens, it is calculated from the HFOV
double getCropFactor () const
 get crop factor, d35mm/dreal
void setCropFactor (double newCropFactor)
 sets the crop factor
double getAspectRatio () const
 return the sensor ratio (width/height)
bool isLandscape () const
 check if the image associated with this lens is in landscape orientation.
void setEV (double ev)
 set the exposure value
vigra::Size2D getImageSize () const
 get the image size, in pixels
void setImageSize (const vigra::Size2D &sz)
 set image size in pixels
void update (const Lens &l)

Public Attributes

LensVarMap variables
bool m_hasExif

Static Public Attributes

static const char * variableNames []

Private Attributes

LensProjectionFormat m_projectionFormat
vigra::Size2D m_imageSize
double m_cropFactor


Detailed Description

Definition at line 44 of file Lens.h.


Member Typedef Documentation

typedef BaseSrcPanoImage::Projection HuginBase::Lens::LensProjectionFormat

Definition at line 47 of file Lens.h.


Constructor & Destructor Documentation

HuginBase::Lens::Lens (  ) 

construct a new lens.

Definition at line 38 of file Lens.cpp.

References HuginBase::fillLensVarMap(), and variables.


Member Function Documentation

double HuginBase::Lens::getAspectRatio (  )  const

return the sensor ratio (width/height)

Definition at line 73 of file Lens.cpp.

References m_imageSize.

double HuginBase::Lens::getCropFactor (  )  const [inline]

get crop factor, d35mm/dreal

Definition at line 73 of file Lens.h.

Referenced by getFocalLength(), HFOVDialog::OnLoadLensParameters(), SaveLensParameters(), and update().

double HuginBase::Lens::getFocalLength (  )  const

get focal length of lens, it is calculated from the HFOV

Definition at line 61 of file Lens.cpp.

References PT::calcFocalLength(), const_map_get(), getCropFactor(), HFOV, m_imageSize, m_projectionFormat, and variables.

double HuginBase::Lens::getHFOV (  )  const

get HFOV in degrees

Definition at line 51 of file Lens.cpp.

References const_map_get().

Referenced by HFOVDialog::OnLoadLensParameters().

vigra::Size2D HuginBase::Lens::getImageSize (  )  const [inline]

get the image size, in pixels

Definition at line 92 of file Lens.h.

Referenced by LoadLensParametersChoose(), and SaveLensParameters().

LensProjectionFormat HuginBase::Lens::getProjection (  )  const [inline]

get projection type

Definition at line 56 of file Lens.h.

Referenced by HFOVDialog::OnLoadLensParameters(), and SaveLensParameters().

bool HuginBase::Lens::isLandscape (  )  const

check if the image associated with this lens is in landscape orientation.

Definition at line 79 of file Lens.cpp.

References m_imageSize.

void HuginBase::Lens::setCropFactor ( double  newCropFactor  )  [inline]

sets the crop factor

Definition at line 77 of file Lens.h.

Referenced by LoadLensParametersChoose().

void HuginBase::Lens::setEV ( double  ev  ) 

set the exposure value

Definition at line 68 of file Lens.cpp.

References map_get(), and variables.

void HuginBase::Lens::setHFOV ( double  d  ) 

set HFOV in degrees

Definition at line 56 of file Lens.cpp.

References map_get(), and variables.

void HuginBase::Lens::setImageSize ( const vigra::Size2D &  sz  )  [inline]

set image size in pixels

Definition at line 96 of file Lens.h.

Referenced by HFOVDialog::OnLoadLensParameters().

void HuginBase::Lens::setProjection ( LensProjectionFormat  l  )  [inline]

set projection type

Definition at line 60 of file Lens.h.

Referenced by LoadLensParametersChoose().

void HuginBase::Lens::update ( const Lens l  ) 

Definition at line 85 of file Lens.cpp.

References getCropFactor(), m_cropFactor, m_imageSize, m_projectionFormat, and variables.


Member Data Documentation

double HuginBase::Lens::m_cropFactor [private]

Definition at line 122 of file Lens.h.

Referenced by update().

bool HuginBase::Lens::m_hasExif

Definition at line 116 of file Lens.h.

vigra::Size2D HuginBase::Lens::m_imageSize [private]

Definition at line 121 of file Lens.h.

Referenced by getAspectRatio(), getFocalLength(), isLandscape(), and update().

LensProjectionFormat HuginBase::Lens::m_projectionFormat [private]

Definition at line 120 of file Lens.h.

Referenced by getFocalLength(), and update().

const char * HuginBase::Lens::variableNames [static]

Initial value:

 { "v", "a", "b", "c", "d", "e", "g", "t",
                                    "Va", "Vb", "Vc", "Vd", "Vx", "Vy", 
                                    "Eev", "Er", "Eb",
                                    "Ra", "Rb", "Rc", "Rd", "Re",  0}

Definition at line 113 of file Lens.h.

Referenced by LoadLensParametersChoose(), and SaveLensParameters().

LensVarMap HuginBase::Lens::variables

Definition at line 109 of file Lens.h.

Referenced by getFocalLength(), Lens(), LoadLensParametersChoose(), HFOVDialog::OnLoadLensParameters(), SaveLensParameters(), setEV(), setHFOV(), and update().


The documentation for this class was generated from the following files:
Generated on 2 Sep 2015 for Hugintrunk by  doxygen 1.4.7