deweese 02/03/02 13:53:11
Modified: sources/org/apache/batik/ext/awt/image GraphicsUtil.java
Log:
Fixed normal code path for new Mac OS X JVM (is now in line with
most of the rest of code for which drawImage it uses).
Revision Changes Path
1.24 +9 -11
xml-batik/sources/org/apache/batik/ext/awt/image/GraphicsUtil.java
Index: GraphicsUtil.java
===================================================================
RCS file:
/home/cvs/xml-batik/sources/org/apache/batik/ext/awt/image/GraphicsUtil.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- GraphicsUtil.java 2 Jan 2002 21:21:16 -0000 1.23
+++ GraphicsUtil.java 2 Mar 2002 21:53:11 -0000 1.24
@@ -66,13 +66,10 @@
* implementations.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Thomas DeWeese</a>
- * @version $Id: GraphicsUtil.java,v 1.23 2002/01/02 21:21:16 deweese Exp $
+ * @version $Id: GraphicsUtil.java,v 1.24 2002/03/02 21:53:11 deweese Exp $
*/
public class GraphicsUtil {
- public static boolean useMacOSXHacks =
- ("Mac OS X".equals(System.getProperty("os.name")));
-
public static AffineTransform IDENTITY = new AffineTransform();
/**
@@ -286,7 +283,7 @@
// System.out.println("Starting Draw: " + cr);
// long startTime = System.currentTimeMillis();
- boolean useDrawRenderedImage = useMacOSXHacks;
+ boolean useDrawRenderedImage = false;
SampleModel srcSM = cr.getSampleModel();
if ((srcSM.getWidth()*srcSM.getHeight()) >
@@ -387,16 +384,17 @@
System.out.println("IR: " + iR);
}
- AffineTransform trans;
- trans = AffineTransform.getTranslateInstance(iR.x,
- iR.y);
+ // For some reason using the transform version
+ // causes a gStackUnderflow error but if I just
+ // use the drawImage with an x & y it works.
+ g2d.drawImage(subBI, iR.x, iR.y, null);
+ // AffineTransform trans
+ // = AffineTransform.getTranslateInstance(iR.x, iR.y);
+ // g2d.drawImage(subBI, trans, null);
// String label = "sub [" + x + ", " + y + "]: ";
// org.ImageDisplay.showImage
// (label, subBI);
-
- g2d.drawImage(subBI, trans, null);
- // big2d.fillRect(0, 0, tw, th);
}
xStep = -xStep; // Reverse directions.
xloc += xStep; // Get back in bounds.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]