mirror of
https://github.com/QIDITECH/QIDISlicer.git
synced 2026-01-31 16:08:43 +03:00
40 lines
751 B
C++
40 lines
751 B
C++
#ifndef slic3r_ThumbnailData_hpp_
|
|
#define slic3r_ThumbnailData_hpp_
|
|
|
|
#include <vector>
|
|
#include <functional>
|
|
|
|
#include "libslic3r/Point.hpp"
|
|
|
|
namespace Slic3r {
|
|
|
|
struct ThumbnailData
|
|
{
|
|
unsigned int width;
|
|
unsigned int height;
|
|
std::vector<unsigned char> pixels;
|
|
|
|
ThumbnailData() { reset(); }
|
|
void set(unsigned int w, unsigned int h);
|
|
void reset();
|
|
|
|
bool is_valid() const;
|
|
};
|
|
|
|
using ThumbnailsList = std::vector<ThumbnailData>;
|
|
|
|
struct ThumbnailsParams
|
|
{
|
|
Vec2ds sizes;
|
|
bool printable_only;
|
|
bool parts_only;
|
|
bool show_bed;
|
|
bool transparent_background;
|
|
};
|
|
|
|
typedef std::function<ThumbnailsList(const ThumbnailsParams&)> ThumbnailsGeneratorCallback;
|
|
|
|
} // namespace Slic3r
|
|
|
|
#endif // slic3r_ThumbnailData_hpp_
|