From: <ma...@us...> - 2003-05-29 22:45:16
|
Update of /cvsroot/jrman/drafts/src/org/jrman/primitive In directory sc8-pr-cvs1:/tmp/cvs-serv13159/src/org/jrman/primitive Modified Files: Primitive.java Log Message: Small corrections to ribs. Added shader language source. Fixed displacement bug. Index: Primitive.java =================================================================== RCS file: /cvsroot/jrman/drafts/src/org/jrman/primitive/Primitive.java,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Primitive.java 22 May 2003 07:36:26 -0000 1.15 --- Primitive.java 29 May 2003 22:45:12 -0000 1.16 *************** *** 57,60 **** --- 57,62 ---- protected Bounds2f rasterBounds; + protected float screenDisplacement; + protected float distance; *************** *** 82,85 **** --- 84,99 ---- } + public Bounds2f getRasterBounds() { + return rasterBounds; + } + + public void setScreenDisplacement(float sd) { + screenDisplacement = sd; + } + + public float getScreenDisplacement() { + return screenDisplacement; + } + public void setDistance(float f) { distance = f; *************** *** 90,97 **** } - public Bounds2f getRasterBounds() { - return rasterBounds; - } - public int compareTo(Object other) { Primitive op = (Primitive) other; --- 104,107 ---- *************** *** 481,486 **** public boolean isReadyToBeDiced(int gridSize) { ! float width = rasterBounds.getWidth(); ! float height = rasterBounds.getHeight(); boolean ready = width * height <= gridSize * attributes.getShadingRate(); if (!ready) --- 491,496 ---- public boolean isReadyToBeDiced(int gridSize) { ! float width = rasterBounds.getWidth() - screenDisplacement * 2; ! float height = rasterBounds.getHeight() - screenDisplacement * 2; boolean ready = width * height <= gridSize * attributes.getShadingRate(); if (!ready) |