From 79ce29a7d5e41bb3bb2499bc7eb99164c423aa1d Mon Sep 17 00:00:00 2001 From: jvoisin Date: Sun, 22 Feb 2015 10:10:50 +0100 Subject: Preliminary implementation of PIL for images. PIL (Python Image Library) is used to open, then save images, in order to remove unknown metadata. --- libmat/exiftool.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'libmat/exiftool.py') diff --git a/libmat/exiftool.py b/libmat/exiftool.py index 9e38f04..2c2a2b8 100644 --- a/libmat/exiftool.py +++ b/libmat/exiftool.py @@ -1,11 +1,13 @@ ''' Care about images with help of the amazing (perl) library Exiftool. ''' -import parser import subprocess +import parser +import pillow + -class ExiftoolStripper(parser.GenericParser): +class ExiftoolStripper(parser.GenericParser, pillow.PillowStripper): ''' A generic stripper class using exiftool as backend ''' @@ -25,6 +27,7 @@ class ExiftoolStripper(parser.GenericParser): def remove_all(self): ''' Remove all metadata with help of exiftool ''' + self.open_and_save() try: if self.backup: self.create_backup_copy() -- cgit v1.3