I want to expand on the ImageField functionality of django. Mainly, I want to check the dimensions of the image the user is uploading, and resize / crop where appropriate. I would also like to set compression amount, and perhaps even allow for watermarking. I know there are several libraries out there that do this, but I want to keep it as lightweight as possible, and haven't had much luck with sorl.
It seems to me the best way to do this would be to create a custom field type, so I could do something like this in my model: image_tb = models.CustomImageField("Thumbnail Image", upload_to ='uploads/projects', size=(50, 50), compression="60", watermark="path/ to/watermark.png") Is this the best way to do something like this? I understand that you could also hijack the save method, but I might want to have more than one image field in each model meaning the sizes might vary. Can anyone point me towards any articles which will help me on my way? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---