Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: sharpening the normal pictures  (Read 3829 times)

0 Members and 1 Guest are viewing this topic.

redlock

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
sharpening the normal pictures
« on: October 25, 2006, 08:35:59 pm »

Hello stramm,

your modepack sharpening the tumbnails. that is very good. can we do the same procedure for the normal pictures? these are unsharp too.
if, can you say to me what i can do ?

thanks already

best greet and sorry for me bad english

tom from germany
« Last Edit: October 27, 2006, 11:27:54 am by Stramm »
Logged

Stramm

  • Moderator
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: sharpening the normal pictures
« Reply #1 on: October 26, 2006, 08:21:45 pm »

include/picmgmnt.inc.php

find
Code: [Select]
        if (max($imagesize[0], $imagesize[1]) > $CONFIG['picture_width'] && $CONFIG['make_intermediate'] && !file_exists($normal)) {
            if ($CONFIG['enable_watermark'] == '1' && $CONFIG['which_files_to_watermark'] == 'both' || $CONFIG['which_files_to_watermark'] == 'resized'){
if (!resize_image($work_image, $normal, $CONFIG['picture_width'], $CONFIG['thumb_method'], $resize_method, "true"))
                return false;
}
else {
if (!resize_image($work_image, $normal, $CONFIG['picture_width'], $CONFIG['thumb_method'], $resize_method, "false"))
            return false;
}
}

replace with
Code: [Select]
        if (max($imagesize[0], $imagesize[1]) > $CONFIG['picture_width'] && $CONFIG['make_intermediate'] && !file_exists($normal)) {
            if ($CONFIG['enable_watermark'] == '1' && $CONFIG['which_files_to_watermark'] == 'both' || $CONFIG['which_files_to_watermark'] == 'resized'){
if (!resize_image($work_image, $normal, $CONFIG['picture_width'], $CONFIG['thumb_method'], $resize_method, "true", 1))
                return false;
}
else {
if (!resize_image($work_image, $normal, $CONFIG['picture_width'], $CONFIG['thumb_method'], $resize_method, "false", 1))
            return false;
}
}

untested, but should work. Image size will be larger, significant larger

edit: I've just seen that I've pasted one excess line into the replacement code
« Last Edit: October 27, 2006, 07:22:50 pm by Stramm »
Logged

redlock

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: sharpening the normal pictures
« Reply #2 on: October 27, 2006, 10:46:13 am »

thanks
Logged
Pages: [1]   Go Up
 

Page created in 0.015 seconds with 22 queries.