update image path

This commit is contained in:
Eliz Kilic 2026-01-24 01:24:57 +00:00
parent 1a1a44be39
commit 6454db007e
2 changed files with 10 additions and 2 deletions

View File

@ -419,7 +419,11 @@ bool Epub::generateCoverBmp(bool cropped) const {
return false;
}
std::string Epub::getThumbBmpPath() const { return cachePath + "/thumb.bmp"; }
std::string Epub::getThumbBmpPath() const {
constexpr int THUMB_TARGET_WIDTH = 240;
constexpr int THUMB_TARGET_HEIGHT = 400;
return getThumbBmpPath(THUMB_TARGET_WIDTH, THUMB_TARGET_HEIGHT);
}
std::string Epub::getThumbBmpPath(int width, int height) const {
return cachePath + "/thumb_" + std::to_string(width) + "x" + std::to_string(height) + ".bmp";

View File

@ -293,7 +293,11 @@ bool Xtc::generateCoverBmp() const {
return true;
}
std::string Xtc::getThumbBmpPath() const { return cachePath + "/thumb.bmp"; }
std::string Xtc::getThumbBmpPath() const {
constexpr int THUMB_TARGET_WIDTH = 240;
constexpr int THUMB_TARGET_HEIGHT = 400;
return getThumbBmpPath(THUMB_TARGET_WIDTH, THUMB_TARGET_HEIGHT);
}
std::string Xtc::getThumbBmpPath(int width, int height) const {
return cachePath + "/thumb_" + std::to_string(width) + "x" + std::to_string(height) + ".bmp";