| Previous | Next |
| CO_E_RELEASED | EVENT_E_ALL_SUBSCRIBERS_FAILED |
VFW_E_INVALIDMEDIATYPE
VFW_E_INVALIDMEDIATYPE is a DirectShow HRESULT. This error is returned when a filter or pin is given a media type that is structurally invalid for the requested operation. It is different from a supported type being rejected: the media-type object itself is malformed or incomplete.
What to inspect
- Check the major type, subtype and format type GUIDs before calling a connection or format-setting method.
- For a format block, verify that
cbFormatmatches the allocated data and thatpbFormatis valid for the selected format type. - When copying an
AM_MEDIA_TYPE, use the DirectShow helpers or duplicate the format buffer correctly; a shallow copy can leave a dangling pointer.
Compare the type offered by the upstream pin with the type expected by the downstream pin. A malformed type should be fixed before attempting graph-level negotiation.
Microsoft: media-type acceptance during a DirectShow connection
Looking for a different code? Search another status or error code.