Skip to content
Snippets Groups Projects
Commit 90cff8fa authored by Brian Heng's avatar Brian Heng
Browse files

Fixes for Q0487 on encode side.

   - Configure scaling window correctly.
   - Use unscaled picture info for isRefScaled determination.
parent 3d9177cc
No related branches found
No related tags found
No related merge requests found
......@@ -243,8 +243,8 @@ public:
Window& getScalingWindow() { return m_scalingWindow; }
const Window& getScalingWindow() const { return m_scalingWindow; }
#if JVET_Q0487_SCALING_WINDOW_ISSUES
bool isRefScaled( const PPS* pps ) const { return getPicWidthInLumaSamples() != pps->getPicWidthInLumaSamples() ||
getPicHeightInLumaSamples() != pps->getPicHeightInLumaSamples() ||
bool isRefScaled( const PPS* pps ) const { return unscaledPic->getPicWidthInLumaSamples() != pps->getPicWidthInLumaSamples() ||
unscaledPic->getPicHeightInLumaSamples() != pps->getPicHeightInLumaSamples() ||
getScalingWindow().getWindowLeftOffset() != pps->getScalingWindow().getWindowLeftOffset() ||
getScalingWindow().getWindowRightOffset() != pps->getScalingWindow().getWindowRightOffset() ||
getScalingWindow().getWindowTopOffset() != pps->getScalingWindow().getWindowTopOffset() ||
......
......@@ -316,7 +316,11 @@ void EncLib::init( bool isFieldCoding, AUWriterIf* auWriterIf )
pps.setConformanceWindow( conformanceWindow );
Window scalingWindow;
#if JVET_Q0487_SCALING_WINDOW_ISSUES
scalingWindow.setWindow( 0, ( width - scaledWidth ) / SPS::getWinUnitX( sps0.getChromaFormatIdc() ), 0, ( height - scaledHeight ) / SPS::getWinUnitY( sps0.getChromaFormatIdc() ) );
#else
scalingWindow.setWindow( 0, width - scaledWidth, 0, height - scaledHeight );
#endif
pps.setScalingWindow( scalingWindow );
#if JVET_Q0179_SCALING_WINDOW_SIZE_CONSTRAINT
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment