2009-05-13 06:23:57 +01:00
|
|
|
from imagekit.specs import ImageSpec
|
|
|
|
from imagekit import processors
|
|
|
|
|
|
|
|
class ResizeThumb(processors.Resize):
|
|
|
|
width = 100
|
2009-05-15 03:29:19 +01:00
|
|
|
crop = False
|
2009-05-13 06:23:57 +01:00
|
|
|
|
|
|
|
class ResizeDisplay(processors.Resize):
|
|
|
|
width = 600
|
|
|
|
|
2009-05-15 03:29:19 +01:00
|
|
|
#class EnhanceThumb(processors.Adjustment):
|
|
|
|
#contrast = 1.2
|
|
|
|
#sharpness = 2
|
2009-05-13 06:23:57 +01:00
|
|
|
|
|
|
|
class Thumbnail(ImageSpec):
|
|
|
|
access_as = 'thumbnail_image'
|
|
|
|
pre_cache = True
|
2009-05-15 03:29:19 +01:00
|
|
|
processors = [ResizeThumb]
|
2009-05-13 06:23:57 +01:00
|
|
|
|
|
|
|
class Display(ImageSpec):
|
|
|
|
increment_count = True
|
|
|
|
processors = [ResizeDisplay]
|