diff options
author | Kacper Michajłow <kasper93@gmail.com> | 2014-10-30 03:10:15 +0300 |
---|---|---|
committer | Kacper Michajłow <kasper93@gmail.com> | 2014-10-30 20:43:11 +0300 |
commit | 6ca1bca6f228f6c65744a81875e7b3b38847a171 (patch) | |
tree | 78472ed8a0e69dff7bc93b4b52da0c01ed6d6361 | |
parent | a11b1e28c007f9741a6c8191d2b0e75c1c667619 (diff) |
XySubPicProvider: Always preserve subtitle frame aspect ratio.
Fixes PGS/DVB subtitles on cropped video frames and maitain the same
output as with our internal renderer.
-rw-r--r-- | docs/Changelog.txt | 1 | ||||
-rw-r--r-- | src/SubPic/XySubPicProvider.cpp | 11 |
2 files changed, 6 insertions, 6 deletions
diff --git a/docs/Changelog.txt b/docs/Changelog.txt index a1026ce20..7e78cad88 100644 --- a/docs/Changelog.txt +++ b/docs/Changelog.txt @@ -26,6 +26,7 @@ next version - not released yet Croatian, Czech, Dutch, French, Galician, German, Greek, Hebrew, Hungarian, Italian, Japanese, Korean, Malay,
Polish, Portuguese (Brazil), Romanian, Russian, Slovak, Slovenian, Spanish, Swedish, Tatar, Thai, Turkish,
Ukrainian and Vietnamese translations
+! XySubFilter: Always preserve subtitle frame aspect ratio
! Ticket #2953, DVB: Fix crash when closing window right after switching channel
! Ticket #3666, DVB: Don't clear the channel list on saving new scan result
! Ticket #4436, DVB: Improve compatibility with certain tuners
diff --git a/src/SubPic/XySubPicProvider.cpp b/src/SubPic/XySubPicProvider.cpp index deaba7154..adf4ea300 100644 --- a/src/SubPic/XySubPicProvider.cpp +++ b/src/SubPic/XySubPicProvider.cpp @@ -125,12 +125,11 @@ STDMETHODIMP CXySubPicProvider::Render(SubPicDesc& spd, REFERENCE_TIME rt, doubl STDMETHODIMP CXySubPicProvider::GetTextureSize(POSITION pos, SIZE& MaxTextureSize, SIZE& VirtualSize, POINT& VirtualTopLeft) { - RECT outputRect, clipRect; + CRect outputRect, clipRect; if (m_pSubFrame && SUCCEEDED(m_pSubFrame->GetOutputRect(&outputRect)) && SUCCEEDED(m_pSubFrame->GetClipRect(&clipRect))) { - CRect rcOutput = outputRect, rcClip = clipRect; - MaxTextureSize = rcOutput.Size(); - VirtualSize = rcClip.Size(); - VirtualTopLeft = rcClip.TopLeft(); + MaxTextureSize = outputRect.Size(); + VirtualSize = clipRect.Size(); + VirtualTopLeft = clipRect.TopLeft(); return S_OK; } return E_FAIL; @@ -138,6 +137,6 @@ STDMETHODIMP CXySubPicProvider::GetTextureSize(POSITION pos, SIZE& MaxTextureSiz STDMETHODIMP CXySubPicProvider::GetRelativeTo(POSITION pos, RelativeTo& relativeTo) { - relativeTo = VIDEO; + relativeTo = BEST_FIT; return S_OK; } |