28 #include "wx/msw/wrapwin.h"
32 #include <OpenGL/gl.h>
48 double width3 = (double) roi.width()/3.0;
49 double height3 = (double) roi.height()/3.0;
51 glVertex2f((
double)roi.left()+width3,roi.top());
52 glVertex2f((
double)roi.left()+width3,roi.bottom());
53 glVertex2f((
double)roi.left()+2.0*width3,roi.top());
54 glVertex2f((
double)roi.left()+2.0*width3,roi.bottom());
55 glVertex2f(roi.left(), (double)roi.top()+height3);
56 glVertex2f(roi.right(),(double)roi.top()+height3);
57 glVertex2f(roi.left(), (double)roi.top()+2.0*height3);
58 glVertex2f(roi.right(),(double)roi.top()+2.0*height3);
64 double width = (double) roi.width();
65 double height = (double) roi.height();
67 glVertex2f((
double)roi.left()+width*0.382,roi.top());
68 glVertex2f((
double)roi.left()+width*0.382,roi.bottom());
69 glVertex2f((
double)roi.left()+width*0.618,roi.top());
70 glVertex2f((
double)roi.left()+width*0.618,roi.bottom());
71 glVertex2f(roi.left(), (double)roi.top()+height*0.382);
72 glVertex2f(roi.right(),(double)roi.top()+height*0.382);
73 glVertex2f(roi.left(), (double)roi.top()+height*0.618);
74 glVertex2f(roi.right(),(double)roi.top()+height*0.618);
81 glVertex2f(roi.left(), roi.top());
82 glVertex2f(roi.right(), roi.bottom());
83 glVertex2f(roi.left(), roi.bottom());
84 glVertex2f(roi.right(), roi.top());
85 glVertex2f(roi.left(), roi.top()+roi.height()/2.0);
86 glVertex2f(roi.right(), roi.top()+roi.height()/2.0);
87 glVertex2f(roi.left()+roi.width()/2.0, roi.top());
88 glVertex2f(roi.left()+roi.width()/2.0, roi.bottom());
95 double h=roi.height();
96 double x=w/(1+
pow(w/h,2));
97 double y=h/(1+
pow(w/h,2));
101 glVertex2f(roi.left(), roi.bottom());
102 glVertex2f(roi.right(), roi.top());
103 glVertex2f(roi.right()-x, roi.top()+y);
104 glVertex2f(roi.right(), roi.bottom());
105 glVertex2f(roi.left()+x, roi.bottom()-y);
106 glVertex2f(roi.left(), roi.top());
110 glVertex2f(roi.left(), roi.top());
111 glVertex2f(roi.right(), roi.bottom());
112 glVertex2f(roi.right()-x, roi.bottom()-y);
113 glVertex2f(roi.right(), roi.top());
114 glVertex2f(roi.left()+x, roi.top()+y);
115 glVertex2f(roi.left(), roi.bottom());
122 double w=roi.width();
123 double h=roi.height();
125 glVertex2f(roi.left(), roi.top());
128 glVertex2f(roi.left()+
h, roi.bottom());
132 glVertex2f(roi.right(), roi.top()+w);
134 glVertex2f(roi.left(), roi.bottom());
137 glVertex2f(roi.left()+
h, roi.top());
141 glVertex2f(roi.right(), roi.bottom()-w);
143 glVertex2f(roi.right(), roi.top());
146 glVertex2f(roi.right()-
h, roi.bottom());
150 glVertex2f(roi.left(), roi.top()+w);
152 glVertex2f(roi.right(), roi.bottom());
155 glVertex2f(roi.right()-
h, roi.top());
159 glVertex2f(roi.left(), roi.bottom()-w);
171 vigra::Rect2D roi = opts->
getROI();
172 glDisable(GL_TEXTURE_2D);
197 glEnable(GL_TEXTURE_2D);
HuginBase::PanoramaOptions * GetOptions()
const vigra::Rect2D & getROI() const
float pow(float a, double b)