summaryrefslogtreecommitdiffstats
path: root/core/imagedownloader.h
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-07-15 17:56:18 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-07-23 15:58:55 -0700
commitb3feaa80e26510928c73e92049ec346841f6093a (patch)
tree1a1f002959ea09aa5a16a5cc04ace06326941377 /core/imagedownloader.h
parentc7428859840bfcf973a14f27c6376e39e915cb29 (diff)
downloadsubsurface-b3feaa80e26510928c73e92049ec346841f6093a.tar.gz
Dive video: paint duration-bar above thumbnail in profile plot
Paint a rectangle on top of thumbnails indicating the run-time of the video. Use the z=100.0-101.0 range for painting the thumbnails, whereby the z-value increases uniformly from first to last thumbnail (sorted by timestamp). The duration-bars are placed at z-values midway between those of the thumbnails. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/imagedownloader.h')
-rw-r--r--core/imagedownloader.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/imagedownloader.h b/core/imagedownloader.h
index dcdf08d20..cab945e5f 100644
--- a/core/imagedownloader.h
+++ b/core/imagedownloader.h
@@ -47,7 +47,7 @@ public slots:
void imageDownloaded(QString filename);
void imageDownloadFailed(QString filename);
signals:
- void thumbnailChanged(QString filename, QImage thumbnail);
+ void thumbnailChanged(QString filename, QImage thumbnail, duration_t duration);
private:
struct Thumbnail {
QImage img;
@@ -56,9 +56,9 @@ private:
};
Thumbnailer();
- static void addPictureThumbnailToCache(const QString &picture_filename, const QImage &thumbnail);
- static void addVideoThumbnailToCache(const QString &picture_filename, duration_t duration);
- static void addUnknownThumbnailToCache(const QString &picture_filename);
+ Thumbnail addPictureThumbnailToCache(const QString &picture_filename, const QImage &thumbnail);
+ Thumbnail addVideoThumbnailToCache(const QString &picture_filename, duration_t duration);
+ Thumbnail addUnknownThumbnailToCache(const QString &picture_filename);
void recalculate(QString filename);
void processItem(QString filename, bool tryDownload);
Thumbnail getThumbnailFromCache(const QString &picture_filename);