From 828b1957c10c3bd5c10faa9599364816d401ceca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ole-Andr=C3=A9=20Rodlie?= Date: Sat, 23 Nov 2024 01:58:55 +0100 Subject: [PATCH] Read/Write: video+audio clip stretch #333 --- src/core/Boxes/videobox.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/core/Boxes/videobox.cpp b/src/core/Boxes/videobox.cpp index c790ac399..51dd53366 100644 --- a/src/core/Boxes/videobox.cpp +++ b/src/core/Boxes/videobox.cpp @@ -24,6 +24,7 @@ // Fork of enve - Copyright (C) 2016-2020 Maurycy Liebner #include "videobox.h" +#include "ReadWrite/evformat.h" extern "C" { #include @@ -103,12 +104,18 @@ void VideoBox::fileHandlerAfterAssigned(VideoFileHandler *obj) { void VideoBox::writeBoundingBox(eWriteStream& dst) const { AnimationBox::writeBoundingBox(dst); dst.writeFilePath(mFileHandler->path()); + dst << getStretch(); } void VideoBox::readBoundingBox(eReadStream& src) { AnimationBox::readBoundingBox(src); const QString path = src.readFilePath(); setFilePathNoRename(path); + if (src.evFileVersion() >= EvFormat::avStretch) { + qreal stretch; + src >> stretch; + setStretch(stretch); + } } QDomElement VideoBox::prp_writePropertyXEV_impl(const XevExporter& exp) const {