From 23ab8cc08d2d6281ef56c184f1e1e905e70a2a22 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sun, 8 Aug 2021 10:48:55 +0200 Subject: Matrix: fix thumbnail upload of small thumbnails, fix small thumbnail creation if webp --- include/AsyncImageLoader.hpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/AsyncImageLoader.hpp b/include/AsyncImageLoader.hpp index 689ec5f..6258b02 100644 --- a/include/AsyncImageLoader.hpp +++ b/include/AsyncImageLoader.hpp @@ -26,8 +26,9 @@ namespace QuickMedia { size_t counter = 0; }; - // This function is async - bool create_thumbnail(const Path &thumbnail_path, const Path &thumbnail_path_resized, sf::Vector2i resize_target_size, ContentType content_type); + // If |symlink_if_no_resize| is false then a copy is made from |thumbnail_path| to |thumbnail_path_resized| instead of a symlink if |thumbnail_path| is not larger than |resize_target_size|. + // One example of why you might not want a symlink is if |thumbnail_path| is a temporary file. + bool create_thumbnail(const Path &thumbnail_path, const Path &thumbnail_path_resized, sf::Vector2i resize_target_size, ContentType content_type, bool symlink_if_no_resize); constexpr int NUM_IMAGE_LOAD_THREADS = 4; -- cgit v1.2.3