I try to remove the embedded thumbnail from the EXIF data or replace it with a empty thumbnail with code like this:
var jpeg = image.buffer;
var data = jpeg.toString("binary");
var exifObj = piexif.load(data);
exifObj["0th"][piexif.ImageIFD.Model] = "FOOBAR 2";
exifObj['thumbnail'] = null;
var exifbytes = piexif.dump(exifObj);
var newData = piexif.insert(exifbytes, data);
var newJpeg = new Buffer(newData, "binary");
Unfortunately the thumbnail stays in the resulting image files. Can you give me any hint on what I'm doing wrong here?
Hi,
I try to remove the embedded thumbnail from the EXIF data or replace it with a empty thumbnail with code like this:
Unfortunately the thumbnail stays in the resulting image files. Can you give me any hint on what I'm doing wrong here?