/[libvob]/libvob/include/vob/vobs/Trivial.hxx
ViewVC logotype

Diff of /libvob/include/vob/vobs/Trivial.hxx

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.15 by humppake, Fri Apr 11 12:45:42 2003 UTC revision 1.16 by tjl, Fri Apr 25 17:16:45 2003 UTC
# Line 43  Trivial.hxx Line 43  Trivial.hxx
43  namespace Vob {  namespace Vob {
44  namespace Vobs {  namespace Vobs {
45    
46    using namespace Vob::VecGL;
47    
48  /** A line drawn between the centers of two coordinate systems.  /** A line drawn between the centers of two coordinate systems.
49   */   */
50  struct LineConnector {  struct LineConnector {
# Line 164  struct CallListBoxCoorded : public CallL Line 166  struct CallListBoxCoorded : public CallL
166  };  };
167  VOB_DEFINED(CallListBoxCoorded);  VOB_DEFINED(CallListBoxCoorded);
168    
169    /** For debugging differences between GL and real transformations.
170     */
171    struct Quad {
172        enum { NTrans = 1 };
173        int flags;
174        template<class F> void params(F &f) {
175            f(flags);
176        }
177        template<class T> void render(const T &t) const {
178            Pt boxwh = t.getSqSize();
179            if(flags & 1) {
180                glPushMatrix();
181                t.performGL();
182                glBegin(GL_QUAD_STRIP);
183                    glVertex(ZPt(0,0,0));
184                    glVertex(ZPt(boxwh.x,0,0));
185                    glVertex(ZPt(0,boxwh.y,0));
186                    glVertex(ZPt(boxwh.x,boxwh.y,0));
187                glEnd();
188                glPopMatrix();
189            } else {
190                glBegin(GL_QUAD_STRIP);
191                    glVertex(t.transform(ZPt(0,0,0)));
192                    glVertex(t.transform(ZPt(boxwh.x,0,0)));
193                    glVertex(t.transform(ZPt(0,boxwh.y,0)));
194                    glVertex(t.transform(ZPt(boxwh.x,boxwh.y,0)));
195                glEnd();
196            }
197        }
198    };
199    VOB_DEFINED(Quad);
200    
201    
202    /** Timing transformations.
203     */
204  struct TransTest {  struct TransTest {
205      enum { NTrans = 1 };      enum { NTrans = 1 };
206    

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26