/[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.4 by jvk, Sun Jun 29 11:22:07 2003 UTC revision 1.5 by jvk, Sat Jul 5 13:13:03 2003 UTC
# Line 38  class Scene: Line 38  class Scene:
38          self.key = KeyPresses(          self.key = KeyPresses(
39              self,              self,
40              SlideLin("x", 0, 20, "x", "Left", "Right"),              SlideLin("x", 0, 20, "x", "Left", "Right"),
41                SlideLin("y", 0, 20, "y", "Down", "Up"),
42              SlideLin("angle", .15, .05, "angle scaling constant", "+", "-"),              SlideLin("angle", .15, .05, "angle scaling constant", "+", "-"),
43              *light3d.commonkeys              *light3d.commonkeys
44          )          )
# Line 50  class Scene: Line 51  class Scene:
51          #thick = vs.orthoCS(0, "Thi", 0, 100*(self.thick / (math.hypot(self.x - 500, self.y - 500)+50)), 0, 0, 0);          #thick = vs.orthoCS(0, "Thi", 0, 100*(self.thick / (math.hypot(self.x - 500, self.y - 500)+50)), 0, 0, 0);
52    
53          thick = vs.coords.rational1D22(0, self.thick, 0, 0,  1, 1, 0);          thick = vs.coords.rational1D22(0, self.thick, 0, 0,  1, 1, 0);
54            thick = vs.coords.rational1D22(0, 4 * self.thick, self.thick, 0, 4, 1, 1);
55          angle = vs.coords.rational1D22(0, self.angle, 0, 0, 1, 0, 0);          angle = vs.coords.rational1D22(0, self.angle, 0, 0, 1, 0, 0);
56          angle = vs.coords.rational1D22(0, 1, 0, self.angle, 0, 1, 0);          angle = vs.coords.rational1D22(0, 1, 0, self.angle, 0, 1, 0);
57          vs.matcher.add(thick, "Thi2")          vs.matcher.add(thick, "Thi2")
# Line 60  class Scene: Line 62  class Scene:
62          a = [vs.orthoBoxCS(0, "A%s" % i, 0, 100, 100+100*i,          a = [vs.orthoBoxCS(0, "A%s" % i, 0, 100, 100+100*i,
63                             1, 1, self.size, self.size)                             1, 1, self.size, self.size)
64               for i in range(0, N)]               for i in range(0, N)]
65          b = [vs.orthoBoxCS(0, "B%s" % i, 800, 150+50*i+self.x, 100+100*i,          b = [vs.orthoBoxCS(0, "B%s" % i, self.y, 150+50*i+self.x, 100+100*i,
66                             1, 1, self.size, self.size)                             1, 1, self.size, self.size)
67               for i in range(0, N)]               for i in range(0, N)]
68    

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

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