Isis Developer Reference
ControlPointGraphicsItem.h
Go to the documentation of this file.
1 #ifndef ControlPointGraphicsItem_h
2 #define ControlPointGraphicsItem_h
3 
4 #include <QGraphicsRectItem>
5 
6 class QPointF;
7 
8 namespace Isis {
9  class ControlPoint;
10  class MosaicSceneWidget;
11  class SerialNumberList;
12 
46  public:
47  ControlPointGraphicsItem(QPointF center, QPointF apriori,
48  ControlPoint *cp, SerialNumberList *snList, MosaicSceneWidget *scene,
49  QGraphicsItem *parent);
50  virtual ~ControlPointGraphicsItem();
51 
52  void paint(QPainter *, const QStyleOptionGraphicsItem *,
53  QWidget * widget = 0);
54 
56 
57  void setArrowVisible(bool visible, bool colorByMeasureCount, int measureCount,
58  bool colorByResidualMagnitude, double residualMagnitude);
59 
60  protected:
61  void contextMenuEvent(QGraphicsSceneContextMenuEvent * event);
62 
63  private:
64  QRectF calcRect() const;
65  QRectF calcCrosshairRect() const;
66  QPolygonF calcArrowHead() const;
67  QString makeToolTip(SerialNumberList *snlist);
68 
69  QPointF *m_centerPoint;
70  QPointF *m_origPoint;
71  MosaicSceneWidget *m_mosaicScene;
72  ControlPoint *m_controlPoint;
73  bool m_showArrow;
75  bool m_colorByMeasureCount;
77  bool m_colorByResidualMagnitude;
79  int m_measureCount;
81  double m_residualMagnitude;
82  };
83 }
84 
85 #endif
Isis::ControlMeasure::GetResidualMagnitude
double GetResidualMagnitude() const
Return Residual magnitude.
Definition: ControlMeasure.cpp:712
FileName.h
Isis::ControlPointGraphicsItem::controlPoint
ControlPoint * controlPoint()
Definition: ControlPointGraphicsItem.cpp:195
Isis::MosaicSceneWidget::getView
MosaicGraphicsView * getView() const
Definition: MosaicSceneWidget.h:162
QWidget
Isis::ControlPoint::getMeasures
QList< ControlMeasure * > getMeasures(bool excludeIgnored=false) const
Definition: ControlPoint.cpp:1873
Isis::Statistics
This class is used to accumulate statistics on double arrays.
Definition: Statistics.h:94
Isis::Statistics::AddData
void AddData(const double *data, const unsigned int count)
Add an array of doubles to the accumulators and counters.
Definition: Statistics.cpp:141
Isis::ControlPointGraphicsItem::paint
void paint(QPainter *, const QStyleOptionGraphicsItem *, QWidget *widget=0)
This virtual paint method is called anytime an update() or paintEvent() is called.
Definition: ControlPointGraphicsItem.cpp:99
Isis::PI
const double PI
The mathematical constant PI.
Definition: Constants.h:40
Isis::ControlPoint::GetMeasure
const ControlMeasure * GetMeasure(QString serialNumber) const
Get a control measure based on its cube's serial number.
Definition: ControlPoint.cpp:416
MosaicSceneWidget.h
QMenu
Directory.h
Isis::Directory::editPointId
QString editPointId()
Return the current control point id loaded in the ControlPointEditWidget.
Definition: Directory.cpp:1909
Isis::ControlPoint::GetNumMeasures
int GetNumMeasures() const
Definition: ControlPoint.cpp:1702
Isis::ControlPointGraphicsItem::~ControlPointGraphicsItem
virtual ~ControlPointGraphicsItem()
Definition: ControlPointGraphicsItem.cpp:77
Isis::Statistics::Maximum
double Maximum() const
Returns the absolute maximum double found in all data passed through the AddData method.
Definition: Statistics.cpp:403
Isis::MosaicSceneWidget
This widget encompasses the entire mosaic scene.
Definition: MosaicSceneWidget.h:153
Isis::ControlPoint::IsEditLocked
bool IsEditLocked() const
Definition: ControlPoint.cpp:1272
Isis::ControlPoint::GetId
QString GetId() const
Return the Id of the control point.
Definition: ControlPoint.cpp:1306
QStringList
Isis::toString
QString toString(bool boolToConvert)
Global function to convert a boolean to a string.
Definition: IString.cpp:211
Isis::SerialNumberList
Serial Number list generator.
Definition: SerialNumberList.h:64
Isis::IsSpecial
bool IsSpecial(const double d)
Returns if the input pixel is special.
Definition: SpecialPixel.h:197
Isis::ControlPoint::getCubeSerialNumbers
QList< QString > getCubeSerialNumbers() const
Definition: ControlPoint.cpp:1889
Isis::ControlPointGraphicsItem::ControlPointGraphicsItem
ControlPointGraphicsItem(QPointF center, QPointF apriori, ControlPoint *cp, SerialNumberList *snList, MosaicSceneWidget *scene, QGraphicsItem *parent)
Create a CP graphics item.
Definition: ControlPointGraphicsItem.cpp:33
Isis::ControlPointGraphicsItem
The visual display of a single control point.
Definition: ControlPointGraphicsItem.h:45
Isis::ControlPoint
A single control point.
Definition: ControlPoint.h:354
Isis::ControlPoint::Fixed
@ Fixed
A Fixed point is a Control Point whose lat/lon is well established and should not be changed.
Definition: ControlPoint.h:371
Isis::ControlPointGraphicsItem::setArrowVisible
void setArrowVisible(bool visible, bool colorByMeasureCount, int measureCount, bool colorByResidualMagnitude, double residualMagnitude)
Definition: ControlPointGraphicsItem.cpp:199
Isis::MosaicSceneWidget::directory
Directory * directory() const
Definition: MosaicSceneWidget.cpp:719
Isis::ControlPoint::Constrained
@ Constrained
A Constrained point is a Control Point whose lat/lon/radius is somewhat established and should not be...
Definition: ControlPoint.h:376
SerialNumberList.h
Isis::ControlPointGraphicsItem::contextMenuEvent
void contextMenuEvent(QGraphicsSceneContextMenuEvent *event)
Definition: ControlPointGraphicsItem.cpp:214
MosaicGraphicsView.h
ControlPoint.h
Isis::Null
const double Null
Value for an Isis Null pixel.
Definition: SpecialPixel.h:95
Isis::Statistics::Average
double Average() const
Computes and returns the average.
Definition: Statistics.cpp:300
Statistics.h
std
Namespace for the standard library.
Isis::ControlPoint::IsIgnored
bool IsIgnored() const
Definition: ControlPoint.cpp:1311
Isis::ControlPoint::GetType
PointType GetType() const
Definition: ControlPoint.cpp:1401
Constants.h
QAction
QGraphicsItem
QGraphicsRectItem
ControlMeasure.h
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
Isis::ControlPoint::GetPointTypeString
QString GetPointTypeString() const
Obtain a string representation of the PointType.
Definition: ControlPoint.cpp:1392
ControlPointGraphicsItem.h
Isis::ControlMeasure
a control measurement
Definition: ControlMeasure.h:175