mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
Make GIFs and videos with captions larger.
This commit is contained in:
@@ -482,6 +482,10 @@ bool RotationSwapWidthHeight(int rotation) {
|
||||
return (rotation == 90 || rotation == 270);
|
||||
}
|
||||
|
||||
QSize TransposeSizeByRotation(QSize size, int rotation) {
|
||||
return RotationSwapWidthHeight(rotation) ? size.transposed() : size;
|
||||
}
|
||||
|
||||
bool GoodStorageForFrame(const QImage &storage, QSize size) {
|
||||
return !storage.isNull()
|
||||
&& (storage.format() == kImageFormat)
|
||||
|
@@ -180,6 +180,7 @@ void LogError(QLatin1String method, FFmpeg::AvErrorWrap error);
|
||||
[[nodiscard]] int ReadRotationFromMetadata(not_null<AVStream*> stream);
|
||||
[[nodiscard]] AVRational ValidateAspectRatio(AVRational aspect);
|
||||
[[nodiscard]] bool RotationSwapWidthHeight(int rotation);
|
||||
[[nodiscard]] QSize TransposeSizeByRotation(QSize size, int rotation);
|
||||
[[nodiscard]] QSize CorrectByAspect(QSize size, AVRational aspect);
|
||||
|
||||
[[nodiscard]] bool GoodStorageForFrame(const QImage &storage, QSize size);
|
||||
|
Reference in New Issue
Block a user