WMF: re-enabled video probes and made it more robust.
Fixed the way the custom MF Transform (getting the frames) works: - Recreate it whenever we load a new media - During media type negotiation between nodes, the MFT should support the same types as the video sink supports - Allow input and output types to be changed as many times as needed, otherwise the topology cannot be resolved in some cases Change-Id: I7ca77e1a3dee83643f1a97f2e6ada9c5c0e88309 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
This commit is contained in:
committed by
The Qt Project
parent
b64ca061fd
commit
73200f5464
@@ -61,6 +61,8 @@ public:
|
||||
void addProbe(MFVideoProbeControl* probe);
|
||||
void removeProbe(MFVideoProbeControl* probe);
|
||||
|
||||
void addSupportedMediaType(IMFMediaType *type);
|
||||
|
||||
// IUnknown methods
|
||||
STDMETHODIMP QueryInterface(REFIID iid, void** ppv);
|
||||
STDMETHODIMP_(ULONG) AddRef();
|
||||
@@ -97,6 +99,7 @@ private:
|
||||
static QVideoSurfaceFormat videoFormatForMFMediaType(IMFMediaType *mediaType, int *bytesPerLine);
|
||||
QVideoFrame makeVideoFrame();
|
||||
QByteArray dataFromBuffer(IMFMediaBuffer *buffer, int height, int *bytesPerLine);
|
||||
bool isMediaTypeSupported(IMFMediaType *type);
|
||||
|
||||
long m_cRef;
|
||||
IMFMediaType *m_inputType;
|
||||
@@ -104,6 +107,8 @@ private:
|
||||
IMFSample *m_sample;
|
||||
QMutex m_mutex;
|
||||
|
||||
QList<IMFMediaType*> m_mediaTypes;
|
||||
|
||||
QList<MFVideoProbeControl*> m_videoProbes;
|
||||
QMutex m_videoProbeMutex;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user