1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-31 08:13:04 +04:00

Fixed MediaSDK tests and build warnings

This commit is contained in:
Maksim Shabunin
2017-08-30 18:08:36 +03:00
parent 05b99a4dde
commit 235b00b6ee
3 changed files with 17 additions and 20 deletions
-10
View File
@@ -156,16 +156,6 @@ inline std::ostream & operator<<(std::ostream &out, const mfxFrameData &data) {
//==================================================================================================
static const int CC_MPG2 = FourCC('M', 'P', 'G', '2').vali32;
static const int CC_H264 = FourCC('H', '2', '6', '4').vali32;
static const int CC_X264 = FourCC('X', '2', '6', '4').vali32;
static const int CC_AVC = FourCC('A', 'V', 'C', ' ').vali32;
static const int CC_H265 = FourCC('H', '2', '6', '5').vali32;
static const int CC_HEVC = FourCC('H', 'E', 'V', 'C').vali32;
static const int CC_VC1 = FourCC('V', 'C', '1', ' ').vali32;
//==================================================================================================
template <typename T>
inline void cleanup(T * &ptr)
{
+7
View File
@@ -11,6 +11,13 @@ using namespace cv;
inline mfxU32 codecIdByFourCC(int fourcc)
{
const int CC_MPG2 = FourCC('M', 'P', 'G', '2').vali32;
const int CC_H264 = FourCC('H', '2', '6', '4').vali32;
const int CC_X264 = FourCC('X', '2', '6', '4').vali32;
const int CC_AVC = FourCC('A', 'V', 'C', ' ').vali32;
const int CC_H265 = FourCC('H', '2', '6', '5').vali32;
const int CC_HEVC = FourCC('H', 'E', 'V', 'C').vali32;
if (fourcc == CC_X264 || fourcc == CC_H264 || fourcc == CC_AVC)
return MFX_CODEC_AVC;
else if (fourcc == CC_H265 || fourcc == CC_HEVC)