Thread View: borland.public.jbuilder.java.api
1 messages
1 total messages
Started by Andreas Patschkowski
Thu, 17 Jul 2003 13:45
Generate image with Java2D
Author: Andreas Patschkowski
Date: Thu, 17 Jul 2003 13:45
Date: Thu, 17 Jul 2003 13:45
29 lines
1994 bytes
1994 bytes
Hi, i try to generate a jpg with the java2d-api. I like to generate a calendar for a year, so i make a big offscreen-image and draw image for the month on it by changing the clipping area for the Graphic2d: area.setRect(startX,startY,widthMonth,heightMonth); g2.clip(area); I clip the area, draw the image on the offscreen-image, change the clipping area, draw the image again and so on. This works pretty fine, but when i change the width of the offscreen-image to a value greater than 500 px, i get a very curious effect. In the right lower third of the image the image is drew again. Sounds confusing, so i made two screenshots which are self-explaining: This is ok: http://www.krefelder76.de/graphik/calendar_ok.jpg This not: http://www.krefelder76.de/graphik/calendar.jpg Knows anybody was is going wrong here? Thank's. So long, Andreas
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads