[gameprogrammer] Re: Image sizing with constrain

  • From: Johan Jacobs <JohanJa@xxxxxxxxxxxxxxx>
  • To: "'gameprogrammer@xxxxxxxxxxxxx'" <gameprogrammer@xxxxxxxxxxxxx>
  • Date: Wed, 28 Jul 2004 12:09:49 +0200

Won't it help to reduce the Y of the image with the same persentage U
reduced the X with...

X = 700 - 70 = 630 
                                means U reduced by 10% Eg. (70/700)*100 = 10
Y = 300 - 10% = 270 
                                300/100*10 = 30
                                Thus Ur Y = 270

Johan Jacobs
> -----Original Message-----
> From: gameprogrammer-bounce@xxxxxxxxxxxxx [mailto:gameprogrammer-
> bounce@xxxxxxxxxxxxx] On Behalf Of Orel Beckford
> Sent: Wednesday 28 July 2004 11:52
> To: gameprogrammer@xxxxxxxxxxxxx
> Subject: [gameprogrammer] Image sizing with constrain
> 
> Hi
> 
> I have'nt posted to this list for months, still
> reading you mails :-)
> 
> I having a problem trying to resize an image with
> constrain.  for example if I have an image which was
> 400 x 300 and I wanted to reduce the x of the image by
> 70,  I need to calculate what the reduction of y
> should be, to keep the image looking like the the
> original but smaller, if I was to reduce the y by 70
> also the image looks a bit stretched, does anyone have
> the formular to work out how much to reduce the y by.
> 
> Rgds
> Force
> 
> 
> 
> 
> __________________________________
> Do you Yahoo!?
> New and Improved Yahoo! Mail - 100MB free storage!
> http://promotions.yahoo.com/new_mail
> 
> 
> ---------------------
> To unsubscribe go to http://gameprogrammer.com/mailinglist.html



---------------------
To unsubscribe go to http://gameprogrammer.com/mailinglist.html


Other related posts: