Skip to content
Snippets Groups Projects

JVET-AD0169: Downsampling filters in range 1.1 to 1.35 based on Kaiser(7) windowed sinc

All threads resolved!
Files
2
@@ -364,7 +364,25 @@ const TFilterCoeff DownsamplingFilterSRC[8][16][12] =
{ 0, 0, 0, 1, -5, 16, 125, -12, 3, 0, 0, 0 },
{ 0, 0, 0, 0, -2, 7, 127, -6, 2, 0, 0, 0 }
},
{ // D = 1.5
{ // Kaiser(7)-windowed sinc ratio 1.35
#if JVET_AD0169_SMALL_SCALE_DOWNSAMPLING
{ 0, 0, 4, -14, 27, 94, 27, -14, 4, 0, 0, 0 },
{ 0, 0, 4, -13, 21, 94, 32, -14, 3, 1, 0, 0 },
{ 0, 0, 4, -12, 16, 93, 39, -15, 3, 1, -1, 0 },
{ 0, 0, 4, -11, 11, 92, 45, -15, 2, 1, -1, 0 },
{ 0, -1, 4, -10, 7, 89, 51, -14, 1, 2, -1, 0 },
{ 0, -1, 4, -8, 2, 86, 57, -13, 0, 2, -1, 0 },
{ 0, -1, 4, -7, -1, 82, 63, -12, -1, 2, -1, 0 },
{ 0, -1, 4, -5, -5, 78, 68, -10, -3, 3, -1, 0 },
{ 0, -1, 3, -4, -8, 74, 74, -8, -4, 3, -1, 0 },
{ 0, -1, 3, -3, -10, 68, 78, -5, -5, 4, -1, 0 },
{ 0, -1, 2, -1, -12, 63, 82, -1, -7, 4, -1, 0 },
{ 0, -1, 2, 0, -13, 57, 86, 2, -8, 4, -1, 0 },
{ 0, -1, 2, 1, -14, 51, 89, 7, -10, 4, -1, 0 },
{ 0, -1, 1, 2, -15, 45, 92, 11, -11, 4, 0, 0 },
{ 0, -1, 1, 3, -15, 39, 93, 16, -12, 4, 0, 0 },
{ 0, 0, 1, 3, -14, 32, 94, 21, -13, 4, 0, 0 }
#else
{ 0, 2, 0, -14, 33, 86, 33, -14, 0, 2, 0, 0 },
{ 0, 1, 1, -14, 29, 85, 38, -13, -1, 2, 0, 0 },
{ 0, 1, 2, -14, 24, 84, 43, -12, -2, 2, 0, 0 },
@@ -381,6 +399,7 @@ const TFilterCoeff DownsamplingFilterSRC[8][16][12] =
{ 0, 0, 2, -3, -11, 48, 83, 19, -13, 2, 1, 0 },
{ 0, 0, 2, -2, -12, 43, 84, 24, -14, 2, 1, 0 },
{ 0, 0, 2, -1, -13, 38, 85, 29, -14, 1, 1, 0 }
#endif
},
{ // D = 2
{ 0, 5, -6, -10, 37, 76, 37, -10, -6, 5, 0, 0}, //0
@@ -684,11 +703,19 @@ void Picture::sampleRateConv(const ScalingRatio scalingRatio, const int scaleX,
{
horFilter = 3;
}
#if JVET_AD0169_SMALL_SCALE_DOWNSAMPLING
else if (scalingRatio.x > (27 << ScalingRatio::BITS) / 20)
#else
else if (scalingRatio.x > (5 << ScalingRatio::BITS) / 4)
#endif
{
horFilter = 2;
}
#if JVET_AD0169_SMALL_SCALE_DOWNSAMPLING
else if (scalingRatio.x > (11 << ScalingRatio::BITS) / 10)
#else
else if (scalingRatio.x > (20 << ScalingRatio::BITS) / 19)
#endif
{
horFilter = 1;
}
@@ -713,11 +740,19 @@ void Picture::sampleRateConv(const ScalingRatio scalingRatio, const int scaleX,
{
verFilter = 3;
}
#if JVET_AD0169_SMALL_SCALE_DOWNSAMPLING
else if (scalingRatio.y > (27 << ScalingRatio::BITS) / 20)
#else
else if (scalingRatio.y > (5 << ScalingRatio::BITS) / 4)
#endif
{
verFilter = 2;
}
#if JVET_AD0169_SMALL_SCALE_DOWNSAMPLING
else if (scalingRatio.y > (11 << ScalingRatio::BITS) / 10)
#else
else if (scalingRatio.y > (20 << ScalingRatio::BITS) / 19)
#endif
{
verFilter = 1;
}
Loading