Images - wrong size

AndK

No avatar

2005-08-24 12:30

Hi All,
I'm using QC ver. 0.3.1. PHP is in 5.0.3.

I have a collection of pictures of products, all 300px wide. I'm trying to add new products. After uploading the picture (adding the product) it's thumbnail size is sometimes smaller then the default 100px as set in Configuration (PL: Rozmiar zdjęcia w produktach).

I checked that the tumbnails are 100px wide alright on the server yet they appear smaller both in the admin panel and on the "storefront" - from the customer side.

I tried deleting the picture files on the server, tried deleting the products and adding them anew but without success.

Is it a bug, is it a plane, is it... what is it? Please?

Regards
Andrzej

AndK

No avatar

2005-08-24 14:37

Answering myself,

deleting all the image files via FTP I changed the picture size to 150px and so far it seems to be working OK. The qustion still remains what was wrong before...

AndK

No avatar

2005-08-24 14:43

NO, it doesn't work :(. I've just added a picture and it was resized (_m affixed to the file name) to 150X212. I've checked, every single miniature image (_m) has different pixel size although they are corectly served as 150px wide with the exeption of the last one which revealed the problem.

AndK

No avatar

2005-08-24 14:56

Further remarks:

I added more products which resulted again in varied miniature size. I checked the pixel size of every single _m file on the server and it seemed that in every case ONE of the sides of the picture was 150px. Sometimes it is width sometimes height, randomly.

wewior (OpenSolution)

Avatar: wewior

2005-08-25 10:19

no randomly:

$iRatio = $this->iThumbX / $this->iThumbY;

if( $iRatio < $this->fRatio ) {
$this->iThumbY = $this->iThumbX;
$iScaleY = $this->iThumbY / ( $iImgCreateY );
$this->iThumbX = $iImgCreateX * $iScaleY;
}

and $fRatio is set as 0.65

AndK

No avatar

2005-08-25 13:18

Thank you for the prompt relply,

So, I must ensure that the width is not greater than 65% of the height of the image then?
If this is correct I'm a bit unfortunate as alla of my pictures are book cover scans and their X/Y ratio _oscilates_ around 0.65! Bummer! ;-)

OK, I'll try to reset the $iRatio value, that's If I can manage - I'm far from being a programer ;-).

Thanks for the explanation.

Pozdrawiam
Andrzej

Back to top
about us | contact