PreviewControlPointTool Class Reference

The PreviewCropTool shows lines between the ends of control points in the fast preview. More...

#include <PreviewControlPointTool.h>

Inheritance diagram for PreviewControlPointTool:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 PreviewControlPointTool (ToolHelper *helper)
void Activate ()
 Switch on a tool.
void AfterDrawImagesEvent ()
 Draw (using OpenGL) images above the others.

Private Member Functions

void MakeTransforms ()

Private Attributes

HuginBase::PTools::Transformtransforms
GreatCircles m_greatCircles

Detailed Description

The PreviewCropTool shows lines between the ends of control points in the fast preview.

Regular control points are drawn in orange, blue control points are drawn in sky blue.

Todo:
: Delete control points when clicked and show the control point window on right click / middle click / modifier-key click? Perhaps not - not responding to user input allows us to show the control points while using the interactive tools.

Definition at line 44 of file PreviewControlPointTool.h.


Constructor & Destructor Documentation

PreviewControlPointTool::PreviewControlPointTool ( ToolHelper helper  ) 

Definition at line 38 of file PreviewControlPointTool.cpp.

References ToolHelper::GetVisualizationStatePtr(), Tool::helper, m_greatCircles, and GreatCircles::setVisualizationState().


Member Function Documentation

void PreviewControlPointTool::Activate (  )  [virtual]

Switch on a tool.

Inherited classes also register events they want to respond to with the PreviewToolHelper. As events are lost when the tool is deactivated without notification to the PreviewTool, things from the last activation can be cleaned up here too.

Implements Tool.

Definition at line 45 of file PreviewControlPointTool.cpp.

References ToolHelper::DRAW_OVER_IMAGES, Tool::helper, and ToolHelper::NotifyMe().

void PreviewControlPointTool::AfterDrawImagesEvent (  )  [virtual]

Draw (using OpenGL) images above the others.

Reimplemented from Tool.

Definition at line 51 of file PreviewControlPointTool.cpp.

References hugin_utils::ControlPointErrorColour(), TextureManager::DisableTexture(), GreatCircles::drawLineFromSpherical(), HuginBase::Panorama::getCtrlPoints(), HuginBase::Panorama::getImage(), ToolHelper::GetPanoramaPtr(), ViewState::GetTextureManager(), ToolHelper::GetViewStatePtr(), Tool::helper, m_greatCircles, MakeTransforms(), HuginBase::PTools::Transform::transformImgCoord(), transforms, and HuginBase::ControlPoint::X_Y.

void PreviewControlPointTool::MakeTransforms (  )  [private]

Definition at line 96 of file PreviewControlPointTool.cpp.

References HuginBase::Panorama::getNrOfImages(), ToolHelper::GetPanoramaPtr(), VisualizationState::GetSrcImage(), ToolHelper::GetVisualizationStatePtr(), Tool::helper, HuginBase::PanoramaOptions::setHeight(), HuginBase::PanoramaOptions::setWidth(), and transforms.

Referenced by AfterDrawImagesEvent().


Member Data Documentation

GreatCircles PreviewControlPointTool::m_greatCircles [private]

Definition at line 53 of file PreviewControlPointTool.h.

Referenced by AfterDrawImagesEvent(), and PreviewControlPointTool().

HuginBase::PTools::Transform* PreviewControlPointTool::transforms [private]

Definition at line 51 of file PreviewControlPointTool.h.

Referenced by AfterDrawImagesEvent(), and MakeTransforms().


The documentation for this class was generated from the following files:
Generated on 5 Dec 2014 for Hugintrunk by  doxygen 1.4.7