videoio(dshow) fix incompatible media type left set on video device

This commit is contained in:
Kai Stüdemann 2021-06-03 22:11:24 +02:00
parent c34445a496
commit 636db09d73

View File

@ -2609,7 +2609,8 @@ static bool setSizeAndSubtype(videoDevice * VD, int attemptWidth, int attemptHei
return true; return true;
}else{ }else{
VD->streamConf->SetFormat(tmpType); VD->streamConf->SetFormat(tmpType);
if( tmpType != NULL )MyDeleteMediaType(tmpType); if( VD->pAmMediaType != NULL)MyDeleteMediaType(VD->pAmMediaType);
VD->pAmMediaType = tmpType;
} }
return false; return false;