We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpPrograms › Scaling Screen Image
Page Index Toggle Pages: 1
Scaling Screen Image (Read 480 times)
Scaling Screen Image
Sep 17th, 2008, 8:18pm
 
Is it possible to scale the entire screen to compensate for small graphics files?

I am currently displaying a few >10 pixel images on the screen on a 200x200 size screen. Is there anyway I could scale the entire presentation in a matter similar to this java approach:
Graphics2D g1 = (Graphics2D) g;
g1.scale(3, 3);

Basically multiplying all of the visual content in size.
Re: Scaling Screen Image
Reply #1 - Sep 24th, 2008, 6:17pm
 
http://processing.org/reference/scale_.html  ??
Re: Scaling Screen Image
Reply #2 - Oct 1st, 2008, 2:23pm
 
Cedric wrote on Sep 24th, 2008, 6:17pm:
http://processing.org/reference/scale_.html  ?


Does that just scale a vector object or can I apply it to a PImage of the screen in a similar way I would implement a buffer

How would this be done
Re: Scaling Screen Image
Reply #3 - Oct 2nd, 2008, 1:27pm
 
It will scale further vector drawings like rect or line, indeed.
To scale bitmap images, you can use copy(), for example.
To scale the whole sketch, you can draw it in a buffer and use copy() (playing with dwidth and dheight parameters). At the cost of some pixelation.
Page Index Toggle Pages: 1