AVDemuxer mediastatus after unload call?
Steven Robbins
steve at sumost.ca
Sun Sep 18 00:19:26 BST 2022
Looking for a sanity check on my understanding. I've written a test case (see
below) that passes. What puzzles me is that the call to mediaStatus() returns
"LoadedMedia" after a call to unload(). Is that correct?
void status()
{
AVDemuxer demux;
QCOMPARE(demux.mediaStatus(), MediaStatus::NoMedia);
QCOMPARE(demux.atEnd(), false);
QCOMPARE(demux.fileName(), QLatin1String(""));
QCOMPARE(demux.isLoaded(), false);
QVERIFY(demux.setMedia(testFile1()));
QCOMPARE(demux.mediaStatus(), MediaStatus::NoMedia);
QCOMPARE(demux.atEnd(), false);
QCOMPARE(demux.fileName(), testFile1());
QCOMPARE(demux.isLoaded(), false);
QVERIFY(demux.load());
QCOMPARE(demux.mediaStatus(), MediaStatus::LoadedMedia);
QCOMPARE(demux.atEnd(), false);
QCOMPARE(demux.fileName(), testFile1());
QCOMPARE(demux.isLoaded(), true);
QVERIFY(demux.unload());
QCOMPARE(demux.mediaStatus(), MediaStatus::LoadedMedia); // ??? why
status shows loaded?
QCOMPARE(demux.atEnd(), false);
QCOMPARE(demux.fileName(), testFile1());
QCOMPARE(demux.isLoaded(), false);
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/digikam-devel/attachments/20220917/d7a88b99/attachment.sig>
More information about the Digikam-devel
mailing list