Closed (fixed)
Project:
Image
Version:
6.x-1.x-dev
Component:
image.module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
23 Jun 2007 at 22:02 UTC
Updated:
27 Feb 2009 at 01:44 UTC
Jump to comment: Most recent file
Comments
Comment #1
ktnk commentedcan you at least add an option in the image edit form to "update the thumbnails upon saving"
so that I can manually force thumbnails to get regenerated on certain images?
Comment #2
drewish commentedi think adding an option to manually rebuild the thumbnails for an image would be helpful. but if rebuilding thumbnails from the admin-content menu doesn't work there's another problem. the option on the node edit form would call exactly the same code and have the same result.
Comment #3
ktnk commentedadding an option to manually rebuild the thumbnails for an image will solve at least half of my problems.
We'll se about the remaining ones that don't resize (perhaps an image format issue?..)
Comment #4
drewish commentedwell now we're back to what's wrong with using the rebuild thumbnails on the admin/content/node ? because as i just said it's going to work just as well... you can filter the list of nodes to just show images and then rebuild a way...
Comment #5
ktnk commentedWell, at this point, I have 4000 images.
there's no easy way to filter for images that need resizing. if I navigate my albums, I see the ones that need resizing. When in admin-contents, I can't even filter images by name. Si it's really hard to search for each one needing resizing, then going to admin menu and trying out the resize..
Karima.
Comment #6
drewish commentedi'm with you now. while test this patch: http://drupal.org/node/133436 i ran into the same problem. the admin/content/node screen makes it hard to find a specific image. i've added the feature to the patch on #133436 so when that gets tested and committed it'll be in there.
Comment #7
drewish commentedbetter title. i think i'm going to put this in before #133436. it's too useful of a feature.
Comment #8
drewish commentedokay here's a patch that pulls in some of the code from #133436. i'd love to get some feedback on this.
Comment #9
Camus-1 commentedI think this is a useful function to have.
I've applied this patch on top of #158334. Understandably, hunk #6 failed at 560. I've fixed that by hand. I've also added an underscore characters to the call to image_get_sizes() in function _image_save and in function image_update after getting the fatal error of "call to undefined function image_get_sizes()" on both lines.
The module works as expected with uploading new images, but I could see the option to "Rebuild image derivatives" on node/add/image. I'm afraid the option is going to cause unnecessary confusion among casual users as it might sound cryptic to them.
Now when I try to use the "Rebuild image derivatives" option on the images which previously failed using admin/content/node, I got the following messages:
Unable to create scaled Thumbnail image
* The derivative images for {image name} have been regenerated.
* The Image has been updated.
As drewish has mentioned, if it fails using admin/content/node it would also fail here as it is using the same codes. Perhaps we should try a different approach.
If I re-upload the very same image at node/{nid}/edit, the image derivatives would be perfectly created. Perhaps, for it to work, the new approach should treat the image as being freshly uploaded.
I did re-try the "Rebuild image derivatives" option on the very same node. It failed and I got the following messages:
* Unable to create scaled Thumbnail image
* The selected file /var/www/sites/8087/files/images/P9200563aO.thumbnail_0.jpg could not be copied, because no file by that name exists. Please check that you supplied the correct filename.
* The selected file /var/www/sites/8087/files/images/P9200563aO.preview.jpg could not be copied, because no file by that name exists. Please check that you supplied the correct filename.
* The derivative images for {image name} have been regenerated.
* The Image has been updated.
Comment #10
drewish commentedcamus, if image_get_sizes() doesn't exists it sounds like you don't have the latest version of -dev. i'd committed that recently. i'll try to spend some more time later debugging your problem.
Comment #11
Camus-1 commentedYou're right, drewish. I didn't have the latest version of -dev.
But I now do, and we should be on the same page. Thanks.
Comment #12
Hetta commentedApplied the patch in #8 to the latest dev version of image.module.
It works a treat.
I'd love to see this committed - I'd tried the patch earlier, upgraded image to the latest version and have been wondering where that checkbox went.
Comment #13
drewish commentedi committed this to HEAD. i'm not going to backport it to the 1.x branch.
Comment #14
(not verified) commentedComment #15
cozzi commentedYou right, this "rebuild derivative images" is cryptic all right. After reading this thread I still not sure what it does, and if it's so useful why would I only use for certain images. Why is it not a default background feature that runs on every image upload.
There should at least be a link next to it that leads to a clear explanation.
Comment #16
sunIf you think that it needs to be improved, then open a new issue.