Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/LAVFilters.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHendrik Leppkes <h.leppkes@gmail.com>2014-05-25 15:10:26 +0400
committerHendrik Leppkes <h.leppkes@gmail.com>2014-05-25 15:10:26 +0400
commit2fd99a5c4311a9ffaa5120e43219129984c9aa0d (patch)
tree333c5beb29666d206f15b3c63c18ff61cd2be756
parent523ad323a4e9ebd3d4fc1df172bc06fff294e002 (diff)
biPlanes is documented to always be 1.
-rw-r--r--decoder/LAVVideo/LAVPixFmtConverter.cpp6
-rw-r--r--demuxer/Demuxers/LAVFVideoHelper.cpp4
2 files changed, 3 insertions, 7 deletions
diff --git a/decoder/LAVVideo/LAVPixFmtConverter.cpp b/decoder/LAVVideo/LAVPixFmtConverter.cpp
index f6c533d8..687f39e5 100644
--- a/decoder/LAVVideo/LAVPixFmtConverter.cpp
+++ b/decoder/LAVVideo/LAVPixFmtConverter.cpp
@@ -259,14 +259,10 @@ void CLAVPixFmtConverter::GetMediaType(CMediaType *mt, int index, LONG biWidth,
pBIH->biWidth = biWidth;
pBIH->biHeight = biHeight;
pBIH->biBitCount = lav_pixfmt_desc[pixFmt].bpp;
- pBIH->biPlanes = lav_pixfmt_desc[pixFmt].planes;
+ pBIH->biPlanes = 1;
pBIH->biSizeImage = GetImageSize(biWidth, abs(biHeight), pixFmt);
pBIH->biCompression = guid.Data1;
- if (!pBIH->biPlanes) {
- pBIH->biPlanes = 1;
- }
-
if (guid == MEDIASUBTYPE_RGB32 || guid == MEDIASUBTYPE_RGB24) {
pBIH->biCompression = BI_RGB;
}
diff --git a/demuxer/Demuxers/LAVFVideoHelper.cpp b/demuxer/Demuxers/LAVFVideoHelper.cpp
index 53025e06..380733ed 100644
--- a/demuxer/Demuxers/LAVFVideoHelper.cpp
+++ b/demuxer/Demuxers/LAVFVideoHelper.cpp
@@ -328,7 +328,7 @@ MPEG1VIDEOINFO *CLAVFVideoHelper::CreateMPEG1VI(const AVStream* avstream, ULONG
mp1vi->hdr.bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
mp1vi->dwStartTimeCode = 0; // is this not 0 anywhere..?
- mp1vi->hdr.bmiHeader.biPlanes = 0;
+ mp1vi->hdr.bmiHeader.biPlanes = 1;
mp1vi->hdr.bmiHeader.biCompression = 0;
// copy extradata over
@@ -384,7 +384,7 @@ MPEG2VIDEOINFO *CLAVFVideoHelper::CreateMPEG2VI(const AVStream *avstream, ULONG
} else if (avstream->codec->codec_id == AV_CODEC_ID_MPEG2VIDEO) {
CExtradataParser parser = CExtradataParser(extradata, extra);
mp2vi->cbSequenceHeader = (DWORD)parser.ParseMPEGSequenceHeader((BYTE *)&mp2vi->dwSequenceHeader[0]);
- mp2vi->hdr.bmiHeader.biPlanes = 0;
+ mp2vi->hdr.bmiHeader.biPlanes = 1;
mp2vi->hdr.bmiHeader.biCompression = 0;
} else {
bCopyUntouched = TRUE;