Closed melinath closed 12 years ago
Is it possible there would be some advantage to centralizing this logic,—i.e., maybe importing Image
into utils.py
and then always importing from there? It seems DRYer, but this is also a very small bit of code.
This, actually, raises the question of centralizing all the image processing stuff altogether... sorl, for instance, provides multiple thumbnailing engines. On the other hand, maybe sticking with and requiring PIL would give us more flexibility in what sorts of processing we're capable of (this is beyond the scope my my knowledge, so I look to your comment).
I see no problems merging this, otherwise, though.
I actually considered adding a PIL module (or PIL_compat, or something) that would handle this, but I wasn't sure whether it was enough to warrant it. (it might be.)
As for multiple engines - I have no idea what sorl's convert_engine backend is doing, and I don't have a clear idea of the advantages of pymagick over PIL. It would be a great feature, in abstract, and we should maybe open a ticket for it, but I don't think it's something we need to do this instant.
OK. In that case I am just going to merge this in that case. (Also, according to the documentation, convert_engine seems to be an ImageMagick and/or GraphicsMagick backend?)
PIL can be installed in two different ways, and we haven't been accounting for that.