/[gzz]/gzz/gzz/gfx/gl/GLVobCoorder.java
ViewVC logotype

Diff of /gzz/gzz/gfx/gl/GLVobCoorder.java

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

revision 1.48 by humppake, Tue Oct 29 15:07:40 2002 UTC revision 1.49 by tjl, Tue Oct 29 19:55:36 2002 UTC
# Line 44  public static final String rcsid = "$Id$ Line 44  public static final String rcsid = "$Id$
44      }      }
45    
46      public int getCSAt(int parent, float x, float y, float[] targetcoords) {      public int getCSAt(int parent, float x, float y, float[] targetcoords) {
47            int[] inds = GL.getAllCSAt(ninds, this.inds, floats, parent, x, y);
48            for(int i=0; i<inds.length; i++)
49                if(isAncestor(inds[i], parent))
50                    return inds[i];
51          return -1;          return -1;
52      }      }
53    
54        private boolean isAncestor(int cs, int parent) {
55            while(cs != parent && cs != -1)
56                cs = getParent(cs);
57            return cs == parent;
58        }
59    
60        public int getParent(int cs) {
61            return inds[cs+1];
62        }
63    
64      public int affineCoordsys(      public int affineCoordsys(
65              int into, float depth,              int into, float depth,
66              float cx, float cy,              float cx, float cy,

Legend:
Removed from v.1.48  
changed lines
  Added in v.1.49

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