This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Graphics2D ??? help  RSS feed

Raschin Ghanad
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I have some principal question to this Graphics2D class:

It seems, that the use of this class transforms my drawing in some way.
Could this be possible?

I was reading a little around in the API-documentation and there was something about this AffineTransform class and that my Graphcis2D context
uses a default instance of that.

I would like to draw 1 : 1, so , like I give the coordiantes to my function.

Does somebody knows something about this?
[ August 11, 2004: Message edited by: Raschin Ghanad ]
clio katz
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the only thing i can offer on this topic is this tidbit: regardless of
what points/coordinates you want to draw, the image will be rendered onto a graphics device - typically the default screen device, but otherwise a device you specify (eg. a printer device w certain resolution)

if the rendered image lacks the resolution you desire, you do have to perform the image transformation yourself to fix it. for example, the same image renders differently to a screen device than a printer device because the underlying device resolution differs.

On second part of your question, the default AffineTransform is supposed to be the identity transform, which - by definition - won't alter your image... You can try:

to double-check this

[ August 17, 2004: Message edited by: clio katz ]
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!