: Stretch whole Image to have inner section be a specific dimension I have an image. Below is a small representation of the real image's layout. The dimenstions of my image are 600px × 449px,
I have an image. Below is a small representation of the real image's layout. The dimenstions of my image are 600px × 449px, and The dimensions for the inner secion of my image are 541px × 341px.
I want the dimensions for the inner section of my image to be 320px × 240px. I want to know how much I would have to shrink the whole image, both width and height (aspect ratio is not important) in order to make the inner section have the dimensions of 320px × 240px.
I would be grateful if you could tell me how to calculate this and/or calculate it yourself as well as tell me how much to shrink the width, and how much to shrink the height.
More posts by @Ravi4787994
1 Comments
Sorted by latest first Latest Oldest Best
320 / 541 = .591 (that is, 320 pixels is 59.1% of 541 pixels)
600 * .591 = 354.6 (so 354.6 is 59.1% of 600)
rounded up to 355 pixels
There's your width; do the same calculations for the height.
//edit for height:
240 / 341 = .704
449 * .704 = 316.1
round down to 316px
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.