how to maintain quality of Source image after conversion
Posted: 2011-08-08T00:31:15-07:00
Hi,
In my application (java based), I have to convert given image (.jpg only) from user to below 4 sizes and need to maintain the quality of the converted image same as originally supplied by user.
I am using below command -
convert -geometry 470x580 -unsharp 1.0x1.0+1.0+0.10 -quality 90 -map /sourceDirectory/colortable.gif /sourceDirectory /abc.jpg /targetDirectory/abc_size1.jpg
Issue – is there any way I can identify optimum size for the source image (user can share in aay size) so that I can apply above command for size changes and maintain the same quality.
Size 1 -
imageconversion.SMALLIMAGEHEIGHT=60
imageconversion.SMALLIMAGEWIDTH=40
Size2 -
imageconversion.NORAMLIMAGEHEIGHT=160
imageconversion.NORAMLIMAGEWIDTH=106
Size 3-
imageconversion.LARGEIMAGEHEIGHT=580
imageconversion.LARGEIMAGEWIDTH=470
Size 4 -
imageconversion.BANNERIMAGEHEIGHT=110
imageconversion.BANNERIMAGEWIDTH=100
Regards,
Pranay
In my application (java based), I have to convert given image (.jpg only) from user to below 4 sizes and need to maintain the quality of the converted image same as originally supplied by user.
I am using below command -
convert -geometry 470x580 -unsharp 1.0x1.0+1.0+0.10 -quality 90 -map /sourceDirectory/colortable.gif /sourceDirectory /abc.jpg /targetDirectory/abc_size1.jpg
Issue – is there any way I can identify optimum size for the source image (user can share in aay size) so that I can apply above command for size changes and maintain the same quality.
Size 1 -
imageconversion.SMALLIMAGEHEIGHT=60
imageconversion.SMALLIMAGEWIDTH=40
Size2 -
imageconversion.NORAMLIMAGEHEIGHT=160
imageconversion.NORAMLIMAGEWIDTH=106
Size 3-
imageconversion.LARGEIMAGEHEIGHT=580
imageconversion.LARGEIMAGEWIDTH=470
Size 4 -
imageconversion.BANNERIMAGEHEIGHT=110
imageconversion.BANNERIMAGEWIDTH=100
Regards,
Pranay