virtual Point middlepoint(double t, double u) =0;
};
-class Moebius : public Surface {
+class Edge {
public:
+ // t varies from 0 to 1.0
+ virtual Point edgepoint(double t) =0;
+};
+
+class Moebius : public Surface, Edge {
+public:
+ virtual Point edgepoint(double t) =0;
virtual Point middlepoint(double t, double u) =0;
};
// Z ranges from -halfbreadth to +halfbreadth.
double halfgap; // 1/2 the width of the strip at the crossing point
double halfbreadth; // 1/2 the width of the strip at the flat part
- Point edgepoint(double t);
public:
MoebiusStrip() { halfgap= 0.15; halfbreadth= 0.15; }
MoebiusStrip(double b) { halfgap= halfbreadth= b/2.0; }
MoebiusStrip(double hg, double hb) { halfgap= hg/2.0; halfbreadth= hb/2.0; }
+ Point edgepoint(double t);
Point middlepoint(double t, double u);
};
-class MoebiusEnfoldment : public Moebius {
+class MoebiusEnfoldmentAny : public Moebius {
+public:
+ Point edgepoint(double t);
+};
+
+class MoebiusEnfoldment : public MoebiusEnfoldmentAny {
double thickness;
double bottomportion;
public:
MoebiusEnfoldment(double t=.35, double bp=.5) { thickness= t; bottomportion= bp; }
-
- Point edgepoint(double t);
Point middlepoint(double t, double u);
};
-class MoebiusNewEnfoldment : public Moebius {
+class MoebiusEnfoldmentNew : public MoebiusEnfoldmentAny {
public:
- MoebiusNewEnfoldment() { }
-
- Point edgepoint(double t);
+ MoebiusEnfoldmentNew() { }
Point middlepoint(double t, double u);
};