| 2176 | } |
| 2177 | |
| 2178 | void CDX9VideoProcessor::UpdateTexures() |
| 2179 | { |
| 2180 | if (!m_srcWidth || !m_srcHeight) { |
| 2181 | return; |
| 2182 | } |
| 2183 | |
| 2184 | // TODO: try making w and h a multiple of 128. |
| 2185 | HRESULT hr = S_OK; |
| 2186 | |
| 2187 | if (m_DXVA2VP.IsReady()) { |
| 2188 | if (m_bVPScaling) { |
| 2189 | CSize texsize = m_videoRect.Size(); |
| 2190 | if (m_iRotation == 90 || m_iRotation == 270) { |
| 2191 | std::swap(texsize.cx, texsize.cy); |
| 2192 | } |
| 2193 | hr = m_TexConvertOutput.CheckCreate(m_pD3DDevEx, m_DXVA2OutputFmt, texsize.cx, texsize.cy, D3DUSAGE_RENDERTARGET); |
| 2194 | if (FAILED(hr)) { |
| 2195 | hr = m_TexConvertOutput.CheckCreate(m_pD3DDevEx, m_DXVA2OutputFmt, m_srcRectWidth, m_srcRectHeight, D3DUSAGE_RENDERTARGET); |
| 2196 | } |
| 2197 | } else { |
| 2198 | hr = m_TexConvertOutput.CheckCreate(m_pD3DDevEx, m_DXVA2OutputFmt, m_srcRectWidth, m_srcRectHeight, D3DUSAGE_RENDERTARGET); |
| 2199 | } |
| 2200 | } |
| 2201 | else { |
| 2202 | hr = m_TexConvertOutput.CheckCreate(m_pD3DDevEx, m_InternalTexFmt, m_srcRectWidth, m_srcRectHeight, D3DUSAGE_RENDERTARGET); |
| 2203 | } |
| 2204 | } |
| 2205 | |
| 2206 | void CDX9VideoProcessor::UpdatePostScaleTexures() |
| 2207 | { |
nothing calls this directly
no test coverage detected