MCPcopy Create free account
hub / github.com/Aleksoid1978/VideoRenderer / UpdateScalingStrings

Method UpdateScalingStrings

Source/DX9VideoProcessor.cpp:979–1000  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

977}
978
979void CDX9VideoProcessor::UpdateScalingStrings()
980{
981 const int w2 = m_videoRect.Width();
982 const int h2 = m_videoRect.Height();
983 const int k = m_bInterpolateAt50pct ? 2 : 1;
984 int w1, h1;
985 if (m_iRotation == 90 || m_iRotation == 270) {
986 w1 = m_srcRectHeight;
987 h1 = m_srcRectWidth;
988 } else {
989 w1 = m_srcRectWidth;
990 h1 = m_srcRectHeight;
991 }
992 m_strShaderX = (w1 == w2) ? nullptr
993 : (w1 > k * w2)
994 ? s_Downscaling9ResIDs[m_iDownscaling].description
995 : s_Upscaling9ResIDs[m_iUpscaling].description;
996 m_strShaderY = (h1 == h2) ? nullptr
997 : (h1 > k * h2)
998 ? s_Downscaling9ResIDs[m_iDownscaling].description
999 : s_Upscaling9ResIDs[m_iUpscaling].description;
1000}
1001
1002void CDX9VideoProcessor::CalcStatsParams()
1003{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected