GreatCircles.h

Go to the documentation of this file.
00001 // -*- c-basic-offset: 4 -*-
00023 #ifndef GREATCIRCLES_H
00024 #define GREATCIRCLES_H
00025 
00026 #include "ViewState.h"
00027 #include <vector>
00028 #include <hugin_math/hugin_math.h>
00029 
00035 class GreatCircles
00036 {
00037 public:
00042     void setVisualizationState(VisualizationState * visualizationState);
00059     void drawLineFromSpherical(double startLat, double startLong,
00060                                double endLat, double endLong, double width = 1.0);
00061 private:
00062     VisualizationState * m_visualizationState;
00063 };
00064 
00065 class GreatCircleArc
00066 {
00067     public:
00072         GreatCircleArc();
00079         GreatCircleArc(double startLat, double startLong,
00080                        double endLat, double endLong,
00081                        VisualizationState & m_visualizationState);
00083         void draw(bool withCross=true, double width = 1.0) const;
00087         float squareDistance(hugin_utils::FDiff2D point) const;
00088                 double m_xscale ;
00089                 double getxscale() const;
00090 
00091         struct LineSegment
00092         {
00093             hugin_utils::FDiff2D vertices[2];
00095             float squareDistance(hugin_utils::FDiff2D point) const;
00097                         void doGLcross(int point, double cscale, VisualizationState *state) const;
00105             void doGL(double width, VisualizationState *state, LineSegment * preceding = NULL, LineSegment * proceeding = NULL) const;
00106         };
00107 
00108     protected:
00109         std::vector<LineSegment> m_lines;
00110         VisualizationState * m_visualizationState;
00111                 
00112 };
00113 
00114 #endif
00115 

Generated on Sun Apr 20 01:25:34 2014 for Hugintrunk by  doxygen 1.3.9.1