/[gzz]/gzz/gfx/libpaper/texcoords.py
ViewVC logotype

Diff of /gzz/gfx/libpaper/texcoords.py

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

revision 1.15 by jvk, Wed Oct 16 09:14:10 2002 UTC revision 1.16 by tjl, Wed Oct 23 13:45:37 2002 UTC
# Line 95  class TexGenXYRepeatUnit: Line 95  class TexGenXYRepeatUnit:
95          self.vecs = [[ rs * math.cos(as), rt * math.cos(at)],          self.vecs = [[ rs * math.cos(as), rt * math.cos(at)],
96                       [ rs * math.sin(as), rt * math.sin(at)]]                       [ rs * math.sin(as), rt * math.sin(at)]]
97    
98      def _getSTVectors(self, rnd):      def _getSTVectors(self, rnd=None):
99          """Get the 2 4-component vectors that (x,y,0,1) should          """Get the 2 4-component vectors that (x,y,0,1) should
100          be multiplied by to get (s,t).          be multiplied by to get (s,t).
101          """          """
# Line 107  class TexGenXYRepeatUnit: Line 107  class TexGenXYRepeatUnit:
107          r = [[ f * mat[1][1], -f * mat[0][1], 0, "?"],          r = [[ f * mat[1][1], -f * mat[0][1], 0, "?"],
108               [ -f * mat[1][0], f * mat[0][0], 0, "?"]]               [ -f * mat[1][0], f * mat[0][0], 0, "?"]]
109    
110          # Random offsets          if rnd != None:
111          r[0][3] = rnd.nextDouble()              # Random offsets
112          r[1][3] = rnd.nextDouble()              r[0][3] = rnd.nextDouble()
113                r[1][3] = rnd.nextDouble()
114    
115          return r          return r
116    

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