| 359 | } |
| 360 | |
| 361 | void MfMediaEngine::UpdateVideoExtent() |
| 362 | { |
| 363 | if (m_mediaEngine && m_readyToPlay) |
| 364 | { |
| 365 | DWORD x = 0, y = 0; |
| 366 | DX::ThrowIfFailed(m_mediaEngine->GetNativeVideoSize(&x, &y)); |
| 367 | |
| 368 | int mods = 0; |
| 369 | if (m_videoExtent.x != x) |
| 370 | { |
| 371 | m_videoExtent.x = x; |
| 372 | ++mods; |
| 373 | } |
| 374 | if (m_videoExtent.x != y) |
| 375 | { |
| 376 | m_videoExtent.y = y; |
| 377 | ++mods; |
| 378 | } |
| 379 | |
| 380 | if (mods) |
| 381 | DX::ThrowIfFailed(m_wicFactory->CreateBitmap(x, y, GUID_WICPixelFormat32bppBGRA, WICBitmapCacheOnDemand, |
| 382 | m_wicBitmap.ReleaseAndGetAddressOf())); |
| 383 | } |
| 384 | } |
| 385 | |
| 386 | } |
| 387 |
nothing calls this directly
no test coverage detected