summaryrefslogtreecommitdiffstats
path: root/imagekit/lib.py
diff options
context:
space:
mode:
Diffstat (limited to 'imagekit/lib.py')
-rw-r--r--imagekit/lib.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/imagekit/lib.py b/imagekit/lib.py
new file mode 100644
index 0000000..65646a4
--- /dev/null
+++ b/imagekit/lib.py
@@ -0,0 +1,17 @@
+# Required PIL classes may or may not be available from the root namespace
+# depending on the installation method used.
+try:
+ import Image
+ import ImageFile
+ import ImageFilter
+ import ImageEnhance
+ import ImageColor
+except ImportError:
+ try:
+ from PIL import Image
+ from PIL import ImageFile
+ from PIL import ImageFilter
+ from PIL import ImageEnhance
+ from PIL import ImageColor
+ except ImportError:
+ raise ImportError('ImageKit was unable to import the Python Imaging Library. Please confirm it`s installed and available on your current Python path.') \ No newline at end of file