summaryrefslogtreecommitdiff
path: root/rapid/thumbnail.py
diff options
context:
space:
mode:
Diffstat (limited to 'rapid/thumbnail.py')
-rw-r--r--rapid/thumbnail.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/rapid/thumbnail.py b/rapid/thumbnail.py
index e9c7e66..7a41e54 100644
--- a/rapid/thumbnail.py
+++ b/rapid/thumbnail.py
@@ -333,7 +333,7 @@ class GetPreviewImage(multiprocessing.Process):
def run(self):
while True:
unique_id, full_file_name, file_type, size_max = self.results_pipe.recv()
- full_size_preview, reduced_size_preview = self.thumbnail_maker.get_thumbnail(full_file_name, file_type, size_max=size_max, size_reduced=None)
+ full_size_preview, reduced_size_preview = self.thumbnail_maker.get_thumbnail(full_file_name, file_type, size_max=size_max, size_reduced=(100,100))
if full_size_preview is None:
full_size_preview = self.get_stock_image(file_type)
self.results_pipe.send((unique_id, full_size_preview, reduced_size_preview))
@@ -341,7 +341,7 @@ class GetPreviewImage(multiprocessing.Process):
class GenerateThumbnails(multiprocessing.Process):
- def __init__(self, files, batch_size, results_pipe, terminate_queue,
+ def __init__(self, scan_pid, files, batch_size, results_pipe, terminate_queue,
run_event):
multiprocessing.Process.__init__(self)
self.results_pipe = results_pipe
@@ -353,6 +353,8 @@ class GenerateThumbnails(multiprocessing.Process):
self.thumbnail_maker = Thumbnail()
+ self.scan_pid = scan_pid
+
def run(self):
counter = 0
@@ -385,6 +387,6 @@ class GenerateThumbnails(multiprocessing.Process):
if counter > 0:
# send any remaining results
self.results_pipe.send((rpdmp.CONN_PARTIAL, self.results))
- self.results_pipe.send((rpdmp.CONN_COMPLETE, None))
+ self.results_pipe.send((rpdmp.CONN_COMPLETE, self.scan_pid))
self.results_pipe.close()