-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathImageReader.h
More file actions
26 lines (21 loc) · 931 Bytes
/
ImageReader.h
File metadata and controls
26 lines (21 loc) · 931 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifndef IMAGEREADER_H
#define IMAGEREADER_H
#include <string>
#include <memory>
#include <vector>
#include <string>
#include "Utils.h"
#include "CustomOpenGLWidget.h"
class ImageReader
{
public:
static int readHEIF(const std::string& filename, std::shared_ptr<ImageData>& imageData);
static int readPNG(const std::string& filename, std::shared_ptr<ImageData>& imageData);
static int readJPG(const std::string& filename, std::shared_ptr<ImageData>& imageData);
static int readRaw(const std::string& filename, std::shared_ptr<ImageData>& imageData);
static int readImageExif(const std::string& filename, std::vector<std::pair<std::string, std::string>>& exif, int& orientation);
static int createThumbnail(const std::string& filename, FileType fileType, std::vector<uint8_t>& imageData);
private:
static std::string translateNumToText(const std::string& type, int num);
};
#endif // IMAGEREADER_H