/[libvob]/libvob/vob/demo/multifil/stretching.py
ViewVC logotype

Diff of /libvob/vob/demo/multifil/stretching.py

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

revision 1.2 by jvk, Fri Jun 27 11:53:15 2003 UTC revision 1.3 by jvk, Fri Jun 27 12:06:06 2003 UTC
# Line 44  class Scene: Line 44  class Scene:
44          )          )
45      def scene(self, vs):      def scene(self, vs):
46          vs.put( background((.5,1,.2)))          vs.put( background((.5,1,.2)))
         vs.put(getDListNocoords("""  
             PushAttrib POLYGON_BIT  
             Enable DEPTH_TEST  
             DepthFunc LEQUAL  
             LineWidth 1  
             PolygonOffset -100 -100  
             ShadeModel SMOOTH  
         """))  
   
         if self.lines:  
             vs.put(getDListNocoords("PolygonMode FRONT_AND_BACK LINE"))  
47    
48          #angle = vs.orthoCS(0, "Ang", 0, self.angle, 0, 0, 0);          #angle = vs.orthoCS(0, "Ang", 0, self.angle, 0, 0, 0);
49    
# Line 67  class Scene: Line 56  class Scene:
56          vs.matcher.add(thick, "Thi")          vs.matcher.add(thick, "Thi")
57          vs.matcher.add(angle, "Ang")          vs.matcher.add(angle, "Ang")
58    
         border = 2  
         conns = GLRen.createSortedConnections(  
             GLRen.createFilletSpan2(border, self.dice,  
                                     1 +  
                                     4 * self.depthColor +  
                                     16 * self.ellipses +  
                                     64 * self.stretched +  
                                     128 * self.sectors),  
             2)  
         conns_l = GLRen.createSortedConnections(  
             GLRen.createFilletSpan2(border, self.dice,  
                                     2 +  
                                     4 * self.depthColor +  
                                     16 * self.ellipses +  
                                     64 * self.stretched +  
                                     128 * self.sectors),  
             2)  
         conns_c = GLRen.createSortedConnections(  
             GLRen.createFilletSpan2(1000, self.dice,  
                                     2 +  
                                     4 * self.depthColor +  
                                     16 * self.ellipses +  
                                     32 +  
                                     64 * self.stretched +  
                                     128 * self.sectors),  
             2)  
   
59          N = 10          N = 10
60    
61          a = [vs.orthoBoxCS(0, "A%s" % i, 0, 100, 100+100*i,          a = [vs.orthoBoxCS(0, "A%s" % i, 0, 100, 100+100*i,
# Line 110  class Scene: Line 72  class Scene:
72                  vs.put(conns, [thick, angle, b[i],  a[i]]);                  vs.put(conns, [thick, angle, b[i],  a[i]]);
73    
74    
75          vs.put(getDListNocoords("""          light3d.drawFillets(self, vs, pc)
             Color 1 1 1  
         """))  
         if self.drawInside: pc(conns)  
         vs.put(getDListNocoords("""  
             Color 0 0 0  
         """))  
         if self.drawEdge: pc(conns_l)  
   
         if self.curvature : pc(conns_c)  
   
         vs.put(getDListNocoords("""  
             PopAttrib  
         """))  
76    

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

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