- Add support for display time windows for images in folder.options

- the times are defined in a JSON array with start and end times, if inside the window the image is valid to display
This commit is contained in:
Alfred Reynolds
2021-08-12 17:40:56 +12:00
parent 6784a5dcb3
commit de7af88e53
5 changed files with 78 additions and 4 deletions

View File

@@ -1,16 +1,25 @@
#ifndef IMAGESTRUCTS_H
#define IMAGESTRUCTS_H
#include <QTime>
#include <QVector>
#include <string>
// possible aspect ratios of an image
enum ImageAspect { ImageAspect_Landscape = 0, ImageAspect_Portrait, ImageAspect_Any, ImageAspect_Monitor /* match monitors aspect */ };
struct DisplayTimeWindow
{
QTime startDisplay = QTime(0,0,0,0);
QTime endDisplay = QTime(23,59,59,0);
};
// options to consider when displaying an image
struct ImageDisplayOptions
{
ImageAspect onlyAspect = ImageAspect_Any;
bool fitAspectAxisToWindow = false;
QVector<DisplayTimeWindow> timeWindows;
};
// details of a particular image