/[libvob]/libvob/test/tools/gfx.py
ViewVC logotype

Diff of /libvob/test/tools/gfx.py

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

revision 1.8 by humppake, Tue Apr 8 20:23:08 2003 UTC revision 1.9 by tjl, Fri Apr 25 17:16:45 2003 UTC
# Line 129  def checkTrans(vs, cs, srclist, dstlist, Line 129  def checkTrans(vs, cs, srclist, dstlist,
129              d = vob.vobs.TestSpotVob(src[i], src[i+1], src[i+2])              d = vob.vobs.TestSpotVob(src[i], src[i+1], src[i+2])
130              vs.map.put(d, cs)              vs.map.put(d, cs)
131              render(vs)              render(vs)
132                if (not 3 < dstlist[i] < 500-3 or
133                    not 3 < dstlist[i+1] < 500-3):
134                    continue
135              checkNotAvgColor(              checkNotAvgColor(
136                  int(dstlist[i])-1, int(dstlist[i+1])-1,                  int(dstlist[i])-1, int(dstlist[i+1])-1,
137                  3, 3, (255, 0, 0), delta=50)                  3, 3, (255, 0, 0), delta=50)
138    
139    def checkTransEq(vs, cs, srclist):
140        """Check that opengl and c++ transformations yield equal results.
141        """
142        src = array(srclist, 'f')
143        dst = vs.coords.transformPoints3(cs, src, None)
144        failUnless(dst != None)
145        dstlist = [i for i in dst]
146        checkTrans(vs, cs, srclist, dstlist)
147    
148    
149  def checkInterp(vs1, vs2, i, fract, cs, srclist, dstlist, delta=0):  def checkInterp(vs1, vs2, i, fract, cs, srclist, dstlist, delta=0):
150      src = array(srclist, 'f')      src = array(srclist, 'f')
151      dst = zeros(len(src), 'f')      dst = zeros(len(src), 'f')

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

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