Rémi Bernon (@rbernon) commented about dlls/winegstreamer/wmv_decoder.c:
+static const struct decoder_type wmv_decoder_output_types[] = +{
- { &MEDIASUBTYPE_NV12, 12, MAKEFOURCC('N', 'V', '1', '2') },
- { &MEDIASUBTYPE_YV12, 12, MAKEFOURCC('Y', 'V', '1', '2') },
- { &MEDIASUBTYPE_IYUV, 12, MAKEFOURCC('I', 'Y', 'U', 'V') },
- { &MEDIASUBTYPE_I420, 12, MAKEFOURCC('I', '4', '2', '0') },
- { &MEDIASUBTYPE_YUY2, 16, MAKEFOURCC('Y', 'U', 'Y', '2') },
- { &MEDIASUBTYPE_UYVY, 16, MAKEFOURCC('U', 'Y', 'V', 'Y') },
- { &MEDIASUBTYPE_YVYU, 16, MAKEFOURCC('Y', 'V', 'Y', 'U') },
- { &MEDIASUBTYPE_NV11, 12, MAKEFOURCC('N', 'V', '1', '1') },
- { &MEDIASUBTYPE_RGB32, 32, BI_RGB },
- { &MEDIASUBTYPE_RGB24, 24, BI_RGB },
- { &MEDIASUBTYPE_RGB565, 16, BI_BITFIELDS },
- { &MEDIASUBTYPE_RGB555, 16, BI_RGB },
- { &MEDIASUBTYPE_RGB8, 8, BI_RGB },
};
What about using a `struct wg_format` array here and `amt_from_wg_format` to create the DMO_MEDIA_TYPE, could it work and reduce the code duplication of DMO_MEDIA_TYPE creation?