[FFmpeg-devel] avcodec/utvideoenc: switch to planar RGB formats

Submitted by Paul B Mahol on Dec. 31, 2017, 9:48 a.m.

Details

Message ID 20171231094836.32024-1-onemda@gmail.com
State New
Headers show

Commit Message

Paul B Mahol Dec. 31, 2017, 9:48 a.m.
Signed-off-by: Paul B Mahol <onemda@gmail.com>
---
 libavcodec/utvideoenc.c               |  47 +++++++++-------
 tests/ref/fate/utvideoenc_rgb_left    | 100 +++++++++++++++++-----------------
 tests/ref/fate/utvideoenc_rgb_median  | 100 +++++++++++++++++-----------------
 tests/ref/fate/utvideoenc_rgb_none    | 100 +++++++++++++++++-----------------
 tests/ref/fate/utvideoenc_rgba_left   | 100 +++++++++++++++++-----------------
 tests/ref/fate/utvideoenc_rgba_median | 100 +++++++++++++++++-----------------
 tests/ref/fate/utvideoenc_rgba_none   | 100 +++++++++++++++++-----------------
 7 files changed, 327 insertions(+), 320 deletions(-)

Comments

Carl Eugen Hoyos Dec. 31, 2017, 1:45 p.m.
2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
> Signed-off-by: Paul B Mahol <onemda@gmail.com>
> ---
>  libavcodec/utvideoenc.c               |  47 +++++++++-------
>  tests/ref/fate/utvideoenc_rgb_left    | 100 +++++++++++++++++-----------------
>  tests/ref/fate/utvideoenc_rgb_median  | 100 +++++++++++++++++-----------------
>  tests/ref/fate/utvideoenc_rgb_none    | 100 +++++++++++++++++-----------------
>  tests/ref/fate/utvideoenc_rgba_left   | 100 +++++++++++++++++-----------------
>  tests/ref/fate/utvideoenc_rgba_median | 100 +++++++++++++++++-----------------
>  tests/ref/fate/utvideoenc_rgba_none   | 100 +++++++++++++++++-----------------
>  7 files changed, 327 insertions(+), 320 deletions(-)

Is there a speed impact?
(Or actually: How much faster is gbr encoding, how much slower rgb encoding?)

> diff --git a/tests/ref/fate/utvideoenc_rgb_left b/tests/ref/fate/utvideoenc_rgb_left
> index a1d200096a..1ee7c58564 100644
> --- a/tests/ref/fate/utvideoenc_rgb_left
> +++ b/tests/ref/fate/utvideoenc_rgb_left

Why do they change?
Do I understand correctly that the files get bigger (~5%)?
If yes, wouldn't that indicate that the patch is not a good idea?

Please add a micro version bump, Carl Eugen
Paul B Mahol Dec. 31, 2017, 1:49 p.m.
On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
> 2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>> Signed-off-by: Paul B Mahol <onemda@gmail.com>
>> ---
>>  libavcodec/utvideoenc.c               |  47 +++++++++-------
>>  tests/ref/fate/utvideoenc_rgb_left    | 100
>> +++++++++++++++++-----------------
>>  tests/ref/fate/utvideoenc_rgb_median  | 100
>> +++++++++++++++++-----------------
>>  tests/ref/fate/utvideoenc_rgb_none    | 100
>> +++++++++++++++++-----------------
>>  tests/ref/fate/utvideoenc_rgba_left   | 100
>> +++++++++++++++++-----------------
>>  tests/ref/fate/utvideoenc_rgba_median | 100
>> +++++++++++++++++-----------------
>>  tests/ref/fate/utvideoenc_rgba_none   | 100
>> +++++++++++++++++-----------------
>>  7 files changed, 327 insertions(+), 320 deletions(-)
>
> Is there a speed impact?
> (Or actually: How much faster is gbr encoding, how much slower rgb
> encoding?)

Very very fast, very very slow.

>
>> diff --git a/tests/ref/fate/utvideoenc_rgb_left
>> b/tests/ref/fate/utvideoenc_rgb_left
>> index a1d200096a..1ee7c58564 100644
>> --- a/tests/ref/fate/utvideoenc_rgb_left
>> +++ b/tests/ref/fate/utvideoenc_rgb_left
>
> Why do they change?
> Do I understand correctly that the files get bigger (~5%)?
> If yes, wouldn't that indicate that the patch is not a good idea?

Its because of different scaling path. Have nothing to do with good or bad idea.

>
> Please add a micro version bump, Carl Eugen

Added.
Carl Eugen Hoyos Dec. 31, 2017, 2:04 p.m.
2017-12-31 14:49 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
> On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
>> 2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>>> Signed-off-by: Paul B Mahol <onemda@gmail.com>
>>> ---
>>>  libavcodec/utvideoenc.c               |  47 +++++++++-------
>>>  tests/ref/fate/utvideoenc_rgb_left    | 100
>>> +++++++++++++++++-----------------
>>>  tests/ref/fate/utvideoenc_rgb_median  | 100
>>> +++++++++++++++++-----------------
>>>  tests/ref/fate/utvideoenc_rgb_none    | 100
>>> +++++++++++++++++-----------------
>>>  tests/ref/fate/utvideoenc_rgba_left   | 100
>>> +++++++++++++++++-----------------
>>>  tests/ref/fate/utvideoenc_rgba_median | 100
>>> +++++++++++++++++-----------------
>>>  tests/ref/fate/utvideoenc_rgba_none   | 100
>>> +++++++++++++++++-----------------
>>>  7 files changed, 327 insertions(+), 320 deletions(-)
>>
>> Is there a speed impact?
>> (Or actually: How much faster is gbr encoding, how much
>> slower rgb encoding?)
>
> Very very fast, very very slow.

This is not helpful;-(
Is it so unlikely that the patch has small gain for gbr
(theoretically compensated by existing fast conversion
from gbr to rgb) but large impact for rgb (with slow
conversion from rgb into gbr)?

>>> diff --git a/tests/ref/fate/utvideoenc_rgb_left
>>> b/tests/ref/fate/utvideoenc_rgb_left
>>> index a1d200096a..1ee7c58564 100644
>>> --- a/tests/ref/fate/utvideoenc_rgb_left
>>> +++ b/tests/ref/fate/utvideoenc_rgb_left
>>
>> Why do they change?
>> Do I understand correctly that the files get bigger (~5%)?
>> If yes, wouldn't that indicate that the patch is not a good idea?
>
> Its because of different scaling path. Have nothing to do with
> good or bad idea.

Thank you, imo this indicates the utvideo rgb tests
should be fixed to use rgb input.

Carl Eugen
Paul B Mahol Dec. 31, 2017, 2:08 p.m.
On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
> 2017-12-31 14:49 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>> On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
>>> 2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>>>> Signed-off-by: Paul B Mahol <onemda@gmail.com>
>>>> ---
>>>>  libavcodec/utvideoenc.c               |  47 +++++++++-------
>>>>  tests/ref/fate/utvideoenc_rgb_left    | 100
>>>> +++++++++++++++++-----------------
>>>>  tests/ref/fate/utvideoenc_rgb_median  | 100
>>>> +++++++++++++++++-----------------
>>>>  tests/ref/fate/utvideoenc_rgb_none    | 100
>>>> +++++++++++++++++-----------------
>>>>  tests/ref/fate/utvideoenc_rgba_left   | 100
>>>> +++++++++++++++++-----------------
>>>>  tests/ref/fate/utvideoenc_rgba_median | 100
>>>> +++++++++++++++++-----------------
>>>>  tests/ref/fate/utvideoenc_rgba_none   | 100
>>>> +++++++++++++++++-----------------
>>>>  7 files changed, 327 insertions(+), 320 deletions(-)
>>>
>>> Is there a speed impact?
>>> (Or actually: How much faster is gbr encoding, how much
>>> slower rgb encoding?)
>>
>> Very very fast, very very slow.
>
> This is not helpful;-(
> Is it so unlikely that the patch has small gain for gbr
> (theoretically compensated by existing fast conversion
> from gbr to rgb) but large impact for rgb (with slow
> conversion from rgb into gbr)?

No.

>
>>>> diff --git a/tests/ref/fate/utvideoenc_rgb_left
>>>> b/tests/ref/fate/utvideoenc_rgb_left
>>>> index a1d200096a..1ee7c58564 100644
>>>> --- a/tests/ref/fate/utvideoenc_rgb_left
>>>> +++ b/tests/ref/fate/utvideoenc_rgb_left
>>>
>>> Why do they change?
>>> Do I understand correctly that the files get bigger (~5%)?
>>> If yes, wouldn't that indicate that the patch is not a good idea?
>>
>> Its because of different scaling path. Have nothing to do with
>> good or bad idea.
>
> Thank you, imo this indicates the utvideo rgb tests
> should be fixed to use rgb input.

Patch welcome.
Carl Eugen Hoyos Dec. 31, 2017, 2:11 p.m.
2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:

>  static void mangle_rgb_planes(uint8_t *dst[4], ptrdiff_t dst_stride,

Why don't you add a new function mangle_gbr_planes() and
keep rgb encoding? The function is not very large.

Carl Eugen
Paul B Mahol Dec. 31, 2017, 2:16 p.m.
On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
> 2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>
>>  static void mangle_rgb_planes(uint8_t *dst[4], ptrdiff_t dst_stride,
>
> Why don't you add a new function mangle_gbr_planes() and
> keep rgb encoding? The function is not very large.

No. UtVideo expect planar rgb and planar rgb should be given to it.

This is also to keep sync with decoder, which dropped rgb packed support.
Carl Eugen Hoyos Dec. 31, 2017, 2:21 p.m.
2017-12-31 15:16 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
> On 12/31/17, Carl Eugen Hoyos <ceffmpeg@gmail.com> wrote:
>> 2017-12-31 10:48 GMT+01:00 Paul B Mahol <onemda@gmail.com>:
>>
>>>  static void mangle_rgb_planes(uint8_t *dst[4], ptrdiff_t dst_stride,
>>
>> Why don't you add a new function mangle_gbr_planes() and
>> keep rgb encoding? The function is not very large.
>
> No. UtVideo expect planar rgb and planar rgb should be given to it.

The real-world issue I see is screen-recording.

Given that these are small functions and the obvious user advantage
I really believe supporting both pix_fmts is the best solution.

Carl Eugen
Derek Buitenhuis Dec. 31, 2017, 5:10 p.m.
On 12/31/2017 2:21 PM, Carl Eugen Hoyos wrote:
> The real-world issue I see is screen-recording.
> 
> Given that these are small functions and the obvious user advantage
> I really believe supporting both pix_fmts is the best solution.

Generic RGB packing has no place inside the encoder and decoder, IMO.
We've decided against it several times in the past, as well, such as
the cinepak encoder.

- Derek
Derek Buitenhuis Dec. 31, 2017, 5:13 p.m.
On 12/31/2017 2:08 PM, Paul B Mahol wrote:
>>>> Why do they change?
>>>> Do I understand correctly that the files get bigger (~5%)?
>>>> If yes, wouldn't that indicate that the patch is not a good idea?
>>>
>>> Its because of different scaling path. Have nothing to do with
>>> good or bad idea.
>>
>> Thank you, imo this indicates the utvideo rgb tests
>> should be fixed to use rgb input.
> 
> Patch welcome.

Shouldn't it be easy to force it in utvideo.mak? That would
avoid the unnecessary FATE changes totally, and IMO, is preferable
to changing them back later.

- Derek

> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
Derek Buitenhuis Dec. 31, 2017, 5:45 p.m.
On 12/31/2017 2:04 PM, Carl Eugen Hoyos wrote:
> This is not helpful;-(
> Is it so unlikely that the patch has small gain for gbr
> (theoretically compensated by existing fast conversion
> from gbr to rgb) but large impact for rgb (with slow
> conversion from rgb into gbr)?

I went and tested the speed difference with and without this
patch, with rgb24 input. You'll be happy to know it came out
to be pretty much exactly the same speed after averaging 100
runs of each.

- Derek
Paul B Mahol Dec. 31, 2017, 6:43 p.m.
On 12/31/17, Derek Buitenhuis <derek.buitenhuis@gmail.com> wrote:
> On 12/31/2017 2:08 PM, Paul B Mahol wrote:
>>>>> Why do they change?
>>>>> Do I understand correctly that the files get bigger (~5%)?
>>>>> If yes, wouldn't that indicate that the patch is not a good idea?
>>>>
>>>> Its because of different scaling path. Have nothing to do with
>>>> good or bad idea.
>>>
>>> Thank you, imo this indicates the utvideo rgb tests
>>> should be fixed to use rgb input.
>>
>> Patch welcome.
>
> Shouldn't it be easy to force it in utvideo.mak? That would
> avoid the unnecessary FATE changes totally, and IMO, is preferable
> to changing them back later.

No because its swscale nonsense.

If input is rgb, output is unchanged with this patch.
Carl Eugen Hoyos Jan. 1, 2018, 10:11 p.m.
2017-12-31 18:45 GMT+01:00 Derek Buitenhuis <derek.buitenhuis@gmail.com>:
> On 12/31/2017 2:04 PM, Carl Eugen Hoyos wrote:
>> This is not helpful;-(
>> Is it so unlikely that the patch has small gain for gbr
>> (theoretically compensated by existing fast conversion
>> from gbr to rgb) but large impact for rgb (with slow
>> conversion from rgb into gbr)?
>
> I went and tested the speed difference with and without this
> patch, with rgb24 input. You'll be happy to know it came out
> to be pretty much exactly the same speed after averaging 100
> runs of each.

(Why?)

Thank you for the testing!

Carl Eugen

Patch hide | download patch | download mbox

diff --git a/libavcodec/utvideoenc.c b/libavcodec/utvideoenc.c
index 840742caf7..9073be885d 100644
--- a/libavcodec/utvideoenc.c
+++ b/libavcodec/utvideoenc.c
@@ -67,12 +67,12 @@  static av_cold int utvideo_encode_init(AVCodecContext *avctx)
     c->slice_stride    = FFALIGN(avctx->width, 32);
 
     switch (avctx->pix_fmt) {
-    case AV_PIX_FMT_RGB24:
+    case AV_PIX_FMT_GBRP:
         c->planes        = 3;
         avctx->codec_tag = MKTAG('U', 'L', 'R', 'G');
         original_format  = UTVIDEO_RGB;
         break;
-    case AV_PIX_FMT_RGBA:
+    case AV_PIX_FMT_GBRAP:
         c->planes        = 4;
         avctx->codec_tag = MKTAG('U', 'L', 'R', 'A');
         original_format  = UTVIDEO_RGBA;
@@ -243,36 +243,43 @@  FF_ENABLE_DEPRECATION_WARNINGS
 }
 
 static void mangle_rgb_planes(uint8_t *dst[4], ptrdiff_t dst_stride,
-                              uint8_t *src, int step, ptrdiff_t stride,
+                              uint8_t *const src[4], int planes, const int stride[4],
                               int width, int height)
 {
     int i, j;
     int k = 2 * dst_stride;
+    const uint8_t *sg = src[0];
+    const uint8_t *sb = src[1];
+    const uint8_t *sr = src[2];
+    const uint8_t *sa = src[3];
     unsigned int g;
 
     for (j = 0; j < height; j++) {
-        if (step == 3) {
-            for (i = 0; i < width * step; i += step) {
-                g         = src[i + 1];
+        if (planes == 3) {
+            for (i = 0; i < width; i++) {
+                g         = sg[i];
                 dst[0][k] = g;
                 g        += 0x80;
-                dst[1][k] = src[i + 2] - g;
-                dst[2][k] = src[i + 0] - g;
+                dst[1][k] = sb[i] - g;
+                dst[2][k] = sr[i] - g;
                 k++;
             }
         } else {
-            for (i = 0; i < width * step; i += step) {
-                g         = src[i + 1];
+            for (i = 0; i < width; i++) {
+                g         = sg[i];
                 dst[0][k] = g;
                 g        += 0x80;
-                dst[1][k] = src[i + 2] - g;
-                dst[2][k] = src[i + 0] - g;
-                dst[3][k] = src[i + 3];
+                dst[1][k] = sb[i] - g;
+                dst[2][k] = sr[i] - g;
+                dst[3][k] = sa[i];
                 k++;
             }
+            sa += stride[3];
         }
         k += dst_stride - width;
-        src += stride;
+        sg += stride[0];
+        sb += stride[1];
+        sr += stride[2];
     }
 }
 
@@ -572,14 +579,14 @@  static int utvideo_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
     }
 
     /* In case of RGB, mangle the planes to Ut Video's format */
-    if (avctx->pix_fmt == AV_PIX_FMT_RGBA || avctx->pix_fmt == AV_PIX_FMT_RGB24)
-        mangle_rgb_planes(c->slice_buffer, c->slice_stride, pic->data[0],
-                          c->planes, pic->linesize[0], width, height);
+    if (avctx->pix_fmt == AV_PIX_FMT_GBRAP || avctx->pix_fmt == AV_PIX_FMT_GBRP)
+        mangle_rgb_planes(c->slice_buffer, c->slice_stride, &pic->data[0],
+                          c->planes, pic->linesize, width, height);
 
     /* Deal with the planes */
     switch (avctx->pix_fmt) {
-    case AV_PIX_FMT_RGB24:
-    case AV_PIX_FMT_RGBA:
+    case AV_PIX_FMT_GBRP:
+    case AV_PIX_FMT_GBRAP:
         for (i = 0; i < c->planes; i++) {
             ret = encode_plane(avctx, c->slice_buffer[i] + 2 * c->slice_stride,
                                c->slice_buffer[i], c->slice_stride, i,
@@ -690,7 +697,7 @@  AVCodec ff_utvideo_encoder = {
     .close          = utvideo_encode_close,
     .capabilities   = AV_CODEC_CAP_FRAME_THREADS | AV_CODEC_CAP_INTRA_ONLY,
     .pix_fmts       = (const enum AVPixelFormat[]) {
-                          AV_PIX_FMT_RGB24, AV_PIX_FMT_RGBA, AV_PIX_FMT_YUV422P,
+                          AV_PIX_FMT_GBRP, AV_PIX_FMT_GBRAP, AV_PIX_FMT_YUV422P,
                           AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUV444P, AV_PIX_FMT_NONE
                       },
 };
diff --git a/tests/ref/fate/utvideoenc_rgb_left b/tests/ref/fate/utvideoenc_rgb_left
index a1d200096a..1ee7c58564 100644
--- a/tests/ref/fate/utvideoenc_rgb_left
+++ b/tests/ref/fate/utvideoenc_rgb_left
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   182328, cd084b244939d7e0008d8e5ab3429dc1
-0,          1,          1,        1,   182336, c9c40672750f372134185901147fb776
-0,          2,          2,        1,   182956, c728911ca73225f2dc7453533c9be95e
-0,          3,          3,        1,   182384, 54521f709b461a25198db755bce582fa
-0,          4,          4,        1,   181704, 5e03ab58b4480a6613f54857f10c39e5
-0,          5,          5,        1,   182136, c623fb06b90fdd7a5ba0b4f217b6a388
-0,          6,          6,        1,   181552, 5d03be9dfc01ad99364fc3cc8378af72
-0,          7,          7,        1,   182292, fc90878278c82b2f835151dc6d43dd47
-0,          8,          8,        1,   181424, 9b6339a0d3af2d3034162183cd4d79e4
-0,          9,          9,        1,   182316, 7e45bb5ffe57f98a433420abaffe78cc
-0,         10,         10,        1,   182064, d9525605a7d7d75a8e33502f61733af1
-0,         11,         11,        1,   182596, 62e87fa5c33a8d208deaa8719682b9a5
-0,         12,         12,        1,   180900, 149059d3d56c55358c7044c7d569730f
-0,         13,         13,        1,   181920, 0d20f588c27471a038e159a131e9c8ea
-0,         14,         14,        1,   182824, a301a411ff11042ecb583e1e3b12dbda
-0,         15,         15,        1,   182452, 0ee2a9ed39fb8569a8d6c2b3afb8f80a
-0,         16,         16,        1,   182312, 68dd3b820adf2cbc6686a7d48fa22c6e
-0,         17,         17,        1,   181856, 1897926cfe9b7acaf9c21714c449ce41
-0,         18,         18,        1,   181108, 15d2af460733fdd896078632cdfef9fd
-0,         19,         19,        1,   181388, 8b8e7a4b7d355f41f7e836120c4792ac
-0,         20,         20,        1,   180936, e18e27aa027f2470bfa95c536a0a89af
-0,         21,         21,        1,   180900, eb663ae3c5ffa8e751280e0dbb260e02
-0,         22,         22,        1,   181936, 7514bbe06cee027f54710dc900297863
-0,         23,         23,        1,   182304, 8cb2dcdbd4c919b4c977f45bee46c54c
-0,         24,         24,        1,   182580, 9185ed53b7e8339b61d3abe230bbab71
-0,         25,         25,        1,   182572, 81f8bdd3255b91d6621e9ebd3c9d7679
-0,         26,         26,        1,   182356, 1f9ff40700881054c62e33acde06910d
-0,         27,         27,        1,   181532, 10d2477aa1e319a61e517d25fd6c95d0
-0,         28,         28,        1,   179580, 3012480c43d15866ccc4a81d56650ee2
-0,         29,         29,        1,   179528, 5e0fbd62a164dc72cf511023da792175
-0,         30,         30,        1,   180760, 679f430c86dca203456f532e978dffc2
-0,         31,         31,        1,   181564, 64d31faf01cb7b52d7d7e20280e6652b
-0,         32,         32,        1,   181428, 04961d71aa3c81b33d28b39ead20ee1d
-0,         33,         33,        1,   182980, 51361c802005721002f5f4924f081708
-0,         34,         34,        1,   182624, 67c5582c45e3ee7e6aca49fdc0a980b8
-0,         35,         35,        1,   182352, 4fade9db12f2d6ce633556fdb8914971
-0,         36,         36,        1,   181336, ac8fbab67b36d58c4e8374bfb07458e7
-0,         37,         37,        1,   181528, f798157b6d4d04c767ecb76346922ddc
-0,         38,         38,        1,   179776, 01d407ed0b86eeb2c3ee3c24dd452d8d
-0,         39,         39,        1,   180100, 062e4af150100d7accf86a907a4b99b5
-0,         40,         40,        1,   180228, 23c617b76ef8f274bd089016fb8516c7
-0,         41,         41,        1,   180592, 5cd3d93597325196079dc019556f6933
-0,         42,         42,        1,   181188, d39d52f5b690661434b1abd8717b3e30
-0,         43,         43,        1,   181300, 9e202444287234bafd103fab83b1a974
-0,         44,         44,        1,   180812, 602165271de71594132cce98af56a7b2
-0,         45,         45,        1,   178816, c427d67196f43ece6bf3855e1256d7bb
-0,         46,         46,        1,   178196, 0d05902e2870a85333a216c723077e98
-0,         47,         47,        1,   178772, 57f528eb984b5b7181c89b48b58271f3
-0,         48,         48,        1,   178652, 5cd1031b0ada3ba9c2d4c2f2b7c8e277
-0,         49,         49,        1,   178512, d3c0c84fc63f1e32a4a026e2cd39b161
+0,          0,          0,        1,   197832, 11da778d3d904fcd2ad6daf84b227e6b
+0,          1,          1,        1,   197840, e89c967c27d7cd9963c9f12f9df2c268
+0,          2,          2,        1,   198632, b2c59f9834024d1e4b829e540a91814e
+0,          3,          3,        1,   197100, b21b344d42da10ef6730fed553fb3f2f
+0,          4,          4,        1,   196236, e61de0e4ff879b6630ae8eb63d063b7f
+0,          5,          5,        1,   197352, efd21105f5f98cbd5953e85a10091531
+0,          6,          6,        1,   197252, 0e2444a9185f68294c16f034dd522666
+0,          7,          7,        1,   197204, 0254750d85c474c13fe3c0e4e3c272cf
+0,          8,          8,        1,   197084, 4c89a99df233575978d9bcd8936e4588
+0,          9,          9,        1,   197692, 681a76f67892f9d05be72abaa403bc32
+0,         10,         10,        1,   197456, bba96b8520eaa5b6612b5c48d6409938
+0,         11,         11,        1,   197024, b9ea3dcc0cb8cf552e536765c5bb31f6
+0,         12,         12,        1,   195132, 2664b79397af76081b7ddd5c3507d579
+0,         13,         13,        1,   196796, d6128308c1fc3493ebc2cece7ed785cb
+0,         14,         14,        1,   198708, 6b3e50d5d47f29dfb38e178ffb9036c5
+0,         15,         15,        1,   198000, a3d6be893edb02e44f65f7a06aa8eeed
+0,         16,         16,        1,   197568, 1ed7a01f810770d62aed3d12d10cd12c
+0,         17,         17,        1,   197396, 515e13befb9eebf92f77574d6cd9fec4
+0,         18,         18,        1,   196680, ac1835b9a426927855e3e5dbab28c177
+0,         19,         19,        1,   196784, 56fa26a339c69df17d003fb00b335baa
+0,         20,         20,        1,   195980, 853744fb2a2de76858d32f35f8b3d836
+0,         21,         21,        1,   196120, e9c50124d92e261f7a98599cb9a20e36
+0,         22,         22,        1,   196620, e750eaed752d09874d823ee40a8904c4
+0,         23,         23,        1,   197528, 6671598014db402b70e2753efda028d1
+0,         24,         24,        1,   198204, 6e471eb9c354d6be4e0d8a691313e23e
+0,         25,         25,        1,   197512, 7e415738fb7889dee478f63900f47e7c
+0,         26,         26,        1,   196832, 0e30afab6de602d099d88edd6276f1de
+0,         27,         27,        1,   196396, 13880ad888c9cf3504e2eb087767602e
+0,         28,         28,        1,   194220, aa9007687cade8c9a872de063bed0755
+0,         29,         29,        1,   194428, 78ab57958ef8914095477e58ee4461c2
+0,         30,         30,        1,   195676, a7d0779dcda7f93da5601482bb68625b
+0,         31,         31,        1,   196352, 668c525c910000aab7d9285be6ac7ed1
+0,         32,         32,        1,   196468, 9c124995d63f2a548e640811e9391951
+0,         33,         33,        1,   198188, 1cb600005e68d1ef1418b1b42e463f0a
+0,         34,         34,        1,   197556, 80f6223aba2d6cfab3cb596f372243f2
+0,         35,         35,        1,   197020, b1890bbb734c016103190a9c043e9fe2
+0,         36,         36,        1,   196208, 7adf4b08c90231eddec16aff65cc138f
+0,         37,         37,        1,   196448, de69c81a605c9e173a7ac65077d0396d
+0,         38,         38,        1,   194072, 8b3afb6897210f1660b4427df0d9cc51
+0,         39,         39,        1,   194036, 1827f1deef659426939ffd94b73575bc
+0,         40,         40,        1,   194436, 46f3ad01e18a2a24d720e78f9bdb532d
+0,         41,         41,        1,   195696, a160ff1e281959147fe11606754ecc7d
+0,         42,         42,        1,   196044, 37f15771f5c04c13b02c0127bd977fed
+0,         43,         43,        1,   196384, fc43c356e577555757e220bee7e8a232
+0,         44,         44,        1,   195424, 6820346735e390b86d9564298c934101
+0,         45,         45,        1,   193688, 5f346f622f8e0d33d7f662e9dfbcccb5
+0,         46,         46,        1,   193000, 15eb6569d9fd39a343d110b965a97277
+0,         47,         47,        1,   193592, d41d561eb927b8e0d608177af90d0e1d
+0,         48,         48,        1,   193512, 35112e23e238beff03c769674db40399
+0,         49,         49,        1,   192528, 3a3ac1b24fb8fc72174970d668c30292
diff --git a/tests/ref/fate/utvideoenc_rgb_median b/tests/ref/fate/utvideoenc_rgb_median
index b1558d7f53..6c4d2f808a 100644
--- a/tests/ref/fate/utvideoenc_rgb_median
+++ b/tests/ref/fate/utvideoenc_rgb_median
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   182160, abcf4f477f74b696faca2fcff1f62aa9
-0,          1,          1,        1,   182104, 7cbcf339fa40c24522067295b39d637f
-0,          2,          2,        1,   183108, dfc2c418f4379a89654c16b34ff19446
-0,          3,          3,        1,   182320, 62a4647b05709d86c51a18be16877e98
-0,          4,          4,        1,   181920, 61d63520703503f6e17fad67cbc08794
-0,          5,          5,        1,   182424, f467638396feabe613b3c851289452d8
-0,          6,          6,        1,   182248, 8a0cba950d6c5d63ba9603212ca95b0e
-0,          7,          7,        1,   181876, 91432f472cf373d5d4036bd100950f3e
-0,          8,          8,        1,   182104, 1c8852d82a48c1b01911ffbedf0ac1f4
-0,          9,          9,        1,   182540, f36b9d48123b55f2141ae10dd26e1ca0
-0,         10,         10,        1,   182120, e6ecdb9af6591916153ca9aeba76b9d0
-0,         11,         11,        1,   182136, 7dc7b828a5b7c652df612474fad66f6b
-0,         12,         12,        1,   181296, 347eac6563435a62f75298cefe13d3a6
-0,         13,         13,        1,   182136, 3bbcd8afacdf9549da9ebd736df548a7
-0,         14,         14,        1,   182412, 17f8c6ef692b4085624ce1ef7efbc963
-0,         15,         15,        1,   182732, 9212760fa11fe4fa193ba1aa259e9765
-0,         16,         16,        1,   181944, 7dd6d6a7084f97a77ec09ec6c62f0ab8
-0,         17,         17,        1,   182232, 518552687d47ae93726679f0ed962ef4
-0,         18,         18,        1,   181512, 29a66924742add13a0cae65d93d38ea9
-0,         19,         19,        1,   181424, 67c965637248333f92da9d493bf7546e
-0,         20,         20,        1,   180764, 298457c6c2b3f4ebcda87a12579f094d
-0,         21,         21,        1,   181072, 493ea592b7d59eebf01c002e7e22fc43
-0,         22,         22,        1,   181160, e30195fcc16ecfbb9348943cff01623f
-0,         23,         23,        1,   182156, d26cfac33e19b4ca11210c9e6cb91955
-0,         24,         24,        1,   182260, 963c157d3f0023b49d23099d53d60c8b
-0,         25,         25,        1,   181976, 2494d481bf2be97692eaeda95f279b0d
-0,         26,         26,        1,   181832, f1be95c840d4fcb0c8d4b7aed5b197c5
-0,         27,         27,        1,   181424, 03d92e89358a8b9b9e7cf302edde307e
-0,         28,         28,        1,   180632, 09f9e162fdaf28342c442172179a75c9
-0,         29,         29,        1,   180624, 481e7f7730ab3ba67c06faa620a8bd5e
-0,         30,         30,        1,   181024, 7a1d1b06b73d2bf41563eb749805780c
-0,         31,         31,        1,   181844, 8a6ce6dd6f79e423a3bb6c2b163adc55
-0,         32,         32,        1,   181712, a68007bbdf0169c9ed2dffae3dc63221
-0,         33,         33,        1,   182008, f37dd0635de369761e2de979ee799c3a
-0,         34,         34,        1,   181800, 14029ba1c364eca476559ce553919e99
-0,         35,         35,        1,   181840, ee227d15f15c3cd564dcad2160453fb7
-0,         36,         36,        1,   181848, 13b5d0892cc76a25b4914f2d706a0ad5
-0,         37,         37,        1,   181976, 1a0be9f2cefe0d867c5c03d6b3987ad8
-0,         38,         38,        1,   181216, 79795d735f9e0f92091203bf8b9eb9ed
-0,         39,         39,        1,   181236, 2d006c8c4ba448ca7841df76e44ffa88
-0,         40,         40,        1,   180672, ed5210abdae49042fcae9bde2f65a057
-0,         41,         41,        1,   181324, fbbc7839c595cd0f0efc0917edfed2c3
-0,         42,         42,        1,   180980, c6120b5a9440f4a0d83731627eb96d98
-0,         43,         43,        1,   181204, ac4371912d16f657c90e8a00cfafdfd2
-0,         44,         44,        1,   180720, d392d95c67349296d922dbf53ec3f832
-0,         45,         45,        1,   180028, 37a2717fbd5aaeb128812298484f8267
-0,         46,         46,        1,   179704, e8716f4856e4ccdc541632a218894f62
-0,         47,         47,        1,   179648, e99cbe5d1bbd7bce241ae500b4de06c2
-0,         48,         48,        1,   179424, 6f8a5e356fb77b61d9dfcabdf97340b9
-0,         49,         49,        1,   178980, 75a7700b822236b0ecb169fd692910f1
+0,          0,          0,        1,   194232, 96431f57c15dfce7894563df186457c7
+0,          1,          1,        1,   194256, f7617d88a5bb862047dd62a3618eca2c
+0,          2,          2,        1,   195048, 77aa5446e64733aa29bf5ba4ad92073d
+0,          3,          3,        1,   194012, 4a73e8b156eebc15de299c57087639a5
+0,          4,          4,        1,   193268, a0afb35be4f9f91366d848b0600c949d
+0,          5,          5,        1,   194168, b0580fbf05dc9a2abc053f2deb48b8c9
+0,          6,          6,        1,   194240, 5f5adb862a13843123e27f01d1870799
+0,          7,          7,        1,   193512, 71dca88d3fdf753858887006ac3cc13b
+0,          8,          8,        1,   193952, 7efa7d138fa412343741ccbeb18acd18
+0,          9,          9,        1,   194700, ffddf410e5b8e49cf0462baf7bc9e179
+0,         10,         10,        1,   193984, c71b59a9699f2832e8c3d76e5d5e4f0c
+0,         11,         11,        1,   193640, 598bdf3a814db44775ad703d674e9ab9
+0,         12,         12,        1,   192900, de83dd60e69a305ab0a79c4a859d444d
+0,         13,         13,        1,   193780, 7858349baa970794b0353e011f751259
+0,         14,         14,        1,   194564, 9470359eb6f09d5a1db5dc199e910bcf
+0,         15,         15,        1,   194856, c15823765a9d4d1583f2dd7b63534c95
+0,         16,         16,        1,   194056, 5f60ee32c9e06f080dcd0b4025576d5b
+0,         17,         17,        1,   194124, a10815c6603e375ab0b21331e03651de
+0,         18,         18,        1,   193508, 54a5762f2717ce1be3b9193b930d1b1f
+0,         19,         19,        1,   193412, 782b07b8ac3bd1a86ad562ef7d7ebca5
+0,         20,         20,        1,   192472, 96f7f1983d6ac34c591e33045c5ba3dc
+0,         21,         21,        1,   192844, b56bec01d69b3e073ac9823b2bf4c2f5
+0,         22,         22,        1,   192668, 3071c2d282672a597bee4682cef304ff
+0,         23,         23,        1,   194108, 3484d2ca748c20d87280f5333054552d
+0,         24,         24,        1,   194552, b05a90da02c18ee880234d620259361d
+0,         25,         25,        1,   193860, 08617a493d2abe75b438a35315aef7a0
+0,         26,         26,        1,   193452, 958eaccd55d6a55832ec9cb6ce201fc4
+0,         27,         27,        1,   193364, 8cab6850866ce9c0ecf818cc4630bdb3
+0,         28,         28,        1,   192064, 03ce30fadf6b80d0b901c0f53f09e23b
+0,         29,         29,        1,   192464, 7bf3364a095cbea2a032f6762d3433bf
+0,         30,         30,        1,   192880, 6176bcbdf42f787aa4c21791fd3d73e2
+0,         31,         31,        1,   193672, 0760b04edf969c5b0914fcae82ee7ee3
+0,         32,         32,        1,   193636, a08c905e46e35d575001e570389a9b70
+0,         33,         33,        1,   193976, dff151dc2dfa5a86103bddc11484a38f
+0,         34,         34,        1,   193456, 86f44e4a438ad150baee14facdebb701
+0,         35,         35,        1,   193768, 5645f55ed8154a0c913890a11b6f1261
+0,         36,         36,        1,   193584, 023ca364d9a88ccb2bae08008c6c3098
+0,         37,         37,        1,   193844, be83062bffff72ba0c442f502c41a187
+0,         38,         38,        1,   193008, 6e1dd8f2d18145ee199395d34c0e55ff
+0,         39,         39,        1,   192680, 27256f3f1111554a75d7b7366b77457f
+0,         40,         40,        1,   192188, d86ea5fafc41d57e320479f54fd1286a
+0,         41,         41,        1,   193200, a37553416c0187b364ce2b64ece22975
+0,         42,         42,        1,   193052, 8e3c81d246b744c2aed9b735015ee93f
+0,         43,         43,        1,   193032, dd8e2b350d8181c6a73832c868ea99f4
+0,         44,         44,        1,   192444, 6844e2dc435f417028644d3314b94c4f
+0,         45,         45,        1,   191824, fc01e22ba45bca6eac69ba76043e1484
+0,         46,         46,        1,   191772, 5e2bedda3828d590d25caa14f96ba7b0
+0,         47,         47,        1,   191720, edaae522f8a975bbef0e909ef09e7fc7
+0,         48,         48,        1,   191528, f2d98179f5cf0752ecbd6d39c4457283
+0,         49,         49,        1,   190692, 74cd0f762371781712e2ff2e3f60ac57
diff --git a/tests/ref/fate/utvideoenc_rgb_none b/tests/ref/fate/utvideoenc_rgb_none
index 403c807a4a..27df8badca 100644
--- a/tests/ref/fate/utvideoenc_rgb_none
+++ b/tests/ref/fate/utvideoenc_rgb_none
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   301024, 44de62472f485410819707c44b53f276
-0,          1,          1,        1,   301036, ff3c28c23b15834a84c57b304610924f
-0,          2,          2,        1,   300812, 72f02a697464f5fdd54ae2e054c131d1
-0,          3,          3,        1,   300876, 8879becf8b3d5001b196f45b7817ef6b
-0,          4,          4,        1,   300880, 2edeed55c4d84dea1fc9386553d7503f
-0,          5,          5,        1,   300904, f799f26eae30e1796bd62f9cdbcb2b17
-0,          6,          6,        1,   300908, bc606ee3ab284d3567a3fbd476d674f0
-0,          7,          7,        1,   301012, 404f55be9ec860a1ab3d15711965c9ba
-0,          8,          8,        1,   301048, 112394db28656101b4e8ba3621b437ae
-0,          9,          9,        1,   301008, 8945bb7668b4a529844e68e1f6b6522b
-0,         10,         10,        1,   300908, a9097c5f0bd7ddea711a25aa74696f70
-0,         11,         11,        1,   300876, 579de317d166295088530c78f403611d
-0,         12,         12,        1,   301012, d97e3627c494012d6167a30ec8192360
-0,         13,         13,        1,   300928, fd20066b7f31363751328aefedfae04c
-0,         14,         14,        1,   300836, d9bdd5606f4426b503f19a674e8058a3
-0,         15,         15,        1,   300848, 6c8f2cbd75646592876f8138a017c1ce
-0,         16,         16,        1,   300988, 54e19940011b3bfed809a0edc12c3dd7
-0,         17,         17,        1,   301040, b1d5f39215f305953a846fb01dbc2f24
-0,         18,         18,        1,   301164, 9dde74f0ee3626eeea41c538fd80e1fb
-0,         19,         19,        1,   301196, fdf22d2c35c7ab72416a268bf6612650
-0,         20,         20,        1,   301148, 275261bc1c1dec0bf712dcf05213def2
-0,         21,         21,        1,   301144, 66ccea6fce9d6d7016dafb3b349fa163
-0,         22,         22,        1,   301080, d6dc6ce0708dfdf74e936271a98c19e9
-0,         23,         23,        1,   301028, 48e610b9d798e0642825919fab233524
-0,         24,         24,        1,   301100, aed8f8f0a9d96ab9906ea8175e18c9ff
-0,         25,         25,        1,   301116, fe9e1eccb9ccc92b4041228ea2c56c8e
-0,         26,         26,        1,   301052, 3ec2f76b41fd8a6eafaa6bb14b94c153
-0,         27,         27,        1,   301200, 60d608bbe0ca285a7d8a1a4822a84c4d
-0,         28,         28,        1,   301120, 6d2cec50ee32e76eb6dff76a4976d221
-0,         29,         29,        1,   301188, 8faa69fd62e0646e4eb85c1601827364
-0,         30,         30,        1,   301192, eb1fa109c5e9b89f29be7cf363649acd
-0,         31,         31,        1,   301128, 32ba1797f5dee6643712688621984326
-0,         32,         32,        1,   301088, a1bfa70314c40f60a0823beef74e233e
-0,         33,         33,        1,   301064, b18d84efa0091199dd9167bbdb36b873
-0,         34,         34,        1,   300964, a2ae8d3dd655403bcfdace40aaa1d78b
-0,         35,         35,        1,   301124, 8ece60df0f0ef4f3d887eac16c23cad6
-0,         36,         36,        1,   301200, 13eb4b5ec7471837aadce38848e48cb2
-0,         37,         37,        1,   301196, b5fdef211755134f8e7998793a0ab0c0
-0,         38,         38,        1,   301260, 2f7e2046bae9e664e74bc56a3596743c
-0,         39,         39,        1,   301264, 2cfc013c9e66a5dd0229c6551febd658
-0,         40,         40,        1,   301272, 47e8ff02a8f054c66687e2b613e46cf5
-0,         41,         41,        1,   301236, f4d766155eeeb7b03687a3141840bf32
-0,         42,         42,        1,   301312, 8fe134aefc02b6910dc2054447fd9c37
-0,         43,         43,        1,   301272, 9ec57db275fca2b596734c48a50c28bc
-0,         44,         44,        1,   301256, 17bae207d8d6f5b2b500885e3058185f
-0,         45,         45,        1,   301308, 9f8e91f3fbbdd0ca17b2ad0ffe888d5a
-0,         46,         46,        1,   301400, 8184e55eb5432516547df512175c15fc
-0,         47,         47,        1,   301408, dd0c0aa1426427549e9cbb22ef82f930
-0,         48,         48,        1,   301424, c65025dc3fa21fad98118ab0386b910e
-0,         49,         49,        1,   301408, 2982b49e94aa25b8ef30f81769650f15
+0,          0,          0,        1,   303768, c37d23b5bc1dcceacafcebd0a5054590
+0,          1,          1,        1,   303764, a6a8b445323c00ab56ad1077a90b34bf
+0,          2,          2,        1,   303672, 029048769e006f2a2357f373cfc0b6bf
+0,          3,          3,        1,   303672, e13433d7e8f75a26eeca86523d47d0cf
+0,          4,          4,        1,   303724, 4c3d437c158255e398071bdd2e699d9e
+0,          5,          5,        1,   303672, 11e335df4fdfcfb7563305a33740058e
+0,          6,          6,        1,   303676, 594a7a6101fbf884bb3bc309479bdf18
+0,          7,          7,        1,   303764, 09f91a05f8f507f6338d15591df34002
+0,          8,          8,        1,   303772, 1e177889c188fdd783815103c1987e5e
+0,          9,          9,        1,   303700, f6da8873c69fb6365764327305a36840
+0,         10,         10,        1,   303684, 6810c80719058078b7d40a787fabee70
+0,         11,         11,        1,   303696, f8dcad694c276074f5022276e4067694
+0,         12,         12,        1,   303720, d1f764aaf14e78b64b182503342df764
+0,         13,         13,        1,   303676, 43066ddba20726f57d76230891f76730
+0,         14,         14,        1,   303548, 6512bff050521cd6343e5b2f4b18be6c
+0,         15,         15,        1,   303604, 76c91368e8db8c18591c7cb569774e12
+0,         16,         16,        1,   303748, 365805842ee3cefee8d5feb169075ecf
+0,         17,         17,        1,   303740, e6bbc34d7057d812cd994473b93ccadb
+0,         18,         18,        1,   303788, 48bcbbc3bf805586c34ff23ebeaa28ea
+0,         19,         19,        1,   303808, 29f268867c4522551e6f73dd4afb36e1
+0,         20,         20,        1,   303808, effd1cf0a61501f427e47c76c469ff32
+0,         21,         21,        1,   303832, 0ea84576612a4b0b8f9e14b3ecf10861
+0,         22,         22,        1,   303800, 4b4d24ce4f176de4c34ec85656ea1e49
+0,         23,         23,        1,   303716, 58845ad1c9a07d62f83414662eaf1181
+0,         24,         24,        1,   303780, 8db647c5324b3c061aa2cdae7527ec8d
+0,         25,         25,        1,   303824, 7a2ddbe9d1af3d34d7538ba10a0aae3c
+0,         26,         26,        1,   303796, a8444e8ec7b64c3481766ebcafd2e7b7
+0,         27,         27,        1,   303816, bf78e04e04429aab3527baacd51da1b0
+0,         28,         28,        1,   303872, 02d9693cc78af1b9d4a17b5361daa325
+0,         29,         29,        1,   303900, 065cde35c0ac49675a9ee8e047bb1471
+0,         30,         30,        1,   303876, 0888dd5201864a9f34f784b7959563ba
+0,         31,         31,        1,   303828, 6837a1a3f4ae04c9601fa9f4c27098b2
+0,         32,         32,        1,   303720, 8c90fc8481d745b020c325134bf0047d
+0,         33,         33,        1,   303704, d37bd88a42e4b84a98f0e51208a3877d
+0,         34,         34,        1,   303640, 2444c069427bf6a847113fd16e7a863f
+0,         35,         35,        1,   303780, 7a9aa1d7d43bcb22a754fa5e7ee911a0
+0,         36,         36,        1,   303828, 4a0ab1bbea88697950bbafe566a03b52
+0,         37,         37,        1,   303860, 6d2073d28e226286e1e78df92bc27154
+0,         38,         38,        1,   303884, 74c43f24d636de3fd6afd1d0ab098e57
+0,         39,         39,        1,   303876, 329a1d1558ffc42b7cdb1f141e042431
+0,         40,         40,        1,   303912, 6b1f3c35f28ab1182354b33ea9e37331
+0,         41,         41,        1,   303856, ec00db5b019a3f72c3fc934d3811cad7
+0,         42,         42,        1,   303880, 6d291f829145c07f0002631b0e22a1f9
+0,         43,         43,        1,   303856, c438ae4db7f897c9e2a1bc6526bb43e1
+0,         44,         44,        1,   303828, d9e5870cf4598577e4ba0ac468ef25db
+0,         45,         45,        1,   303936, 6c90dbca317295010024cc4ec70d3f87
+0,         46,         46,        1,   303940, 025d9173ff307f89c3edf43074a261e9
+0,         47,         47,        1,   303948, 48e7ab65fb9c7a35e4933a7658935726
+0,         48,         48,        1,   303944, 925eb3c42b865d0861ae0348136fc18c
+0,         49,         49,        1,   303924, 83ae105d9d301ea900f004d274adf894
diff --git a/tests/ref/fate/utvideoenc_rgba_left b/tests/ref/fate/utvideoenc_rgba_left
index eb3305d61a..11bde1e63f 100644
--- a/tests/ref/fate/utvideoenc_rgba_left
+++ b/tests/ref/fate/utvideoenc_rgba_left
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   195260, a8fdb226460f210542e7aca6c12b0874
-0,          1,          1,        1,   195268, 45f098764ccba85dc641b7e401461c0a
-0,          2,          2,        1,   195888, e922261672c7de46a302abad3a3fe450
-0,          3,          3,        1,   195316, f8febd5af0fed000fab2943cc649975f
-0,          4,          4,        1,   194636, d90985ad8afd2f969afa842510085852
-0,          5,          5,        1,   195068, 909adb44bd049186a959f2803e641520
-0,          6,          6,        1,   194484, 547772233e653daccc6610fcb6369da7
-0,          7,          7,        1,   195224, aa82b75f6230b2e948abdfe36bce1150
-0,          8,          8,        1,   194356, d67fb1208532137252701ddcbf7bfc2e
-0,          9,          9,        1,   195248, 7b08698d2a911fba5231c0fef0ded4c2
-0,         10,         10,        1,   194996, 570e7d9caec52975dec1c2a5dbf7cdef
-0,         11,         11,        1,   195528, 7309c0531b942902c691781f2a6da1a1
-0,         12,         12,        1,   193832, 40954ceb87370cac3db5c8c2d7c001d1
-0,         13,         13,        1,   194852, 538382c377f0c6e9070ec0b8c5fb3e39
-0,         14,         14,        1,   195756, d002a80346f3460380abb794f2d56a62
-0,         15,         15,        1,   195384, 1a4f58b3c710f2fedaf746c281556b4c
-0,         16,         16,        1,   195244, 218832dab1251e1dc852e6839a48b3fc
-0,         17,         17,        1,   194788, a035acf428bd9565a4c3fec25dfc6f4f
-0,         18,         18,        1,   194040, 6dbfeb949bdeeb055a4f7ebf78af9a85
-0,         19,         19,        1,   194320, 8b4aa3f6f05aa684d9e4adfa4cdce814
-0,         20,         20,        1,   193868, 98cd8b150784f6695f8dea163cecf286
-0,         21,         21,        1,   193832, 27a8db33014c4bc6a8da356c4b1a3e4f
-0,         22,         22,        1,   194868, f1e1460dca9127197c0a40e659924616
-0,         23,         23,        1,   195236, a012f8548e92243334edcd7c8f57aa52
-0,         24,         24,        1,   195512, bf3d4e968d126231baa6618d3344ef81
-0,         25,         25,        1,   195504, adf4b49d8721f1b323fa518f2f0d4750
-0,         26,         26,        1,   195288, aa16dd087a73a9cadc5abfc0a46ccdd4
-0,         27,         27,        1,   194464, 2e3f07244999cbe949495b57adcabe69
-0,         28,         28,        1,   192512, 2d6ce0d29a929e0208e1578e95c9d388
-0,         29,         29,        1,   192460, 081d18cd138eead0cd4b25f54a7c7540
-0,         30,         30,        1,   193692, 546b6ad28b612c2f601c7d87b265ba95
-0,         31,         31,        1,   194496, b2b2ae3b1d67e332295456e6c7bdd381
-0,         32,         32,        1,   194360, 0837b122d85abc4d704d40629266c58d
-0,         33,         33,        1,   195912, b7a4bbe436d63394cee70d40e8a8a4cf
-0,         34,         34,        1,   195556, 1b9a3eb6cda9bbd44bbdd0dc26a74252
-0,         35,         35,        1,   195284, f28d780d43fa6979379dd21fcb12e906
-0,         36,         36,        1,   194268, 5508989dad06fa05ee4054e759cdfd4b
-0,         37,         37,        1,   194460, cb65a0e97c03b2fbe69caa6ac1660070
-0,         38,         38,        1,   192708, 4125ee86cf4b8ca6d891c176662e584f
-0,         39,         39,        1,   193032, 096ee24b3e35049480e28171693fbd85
-0,         40,         40,        1,   193160, c01aef63b8bc792d08355ce6d68affee
-0,         41,         41,        1,   193524, 57af47b7bfe132cf58eab2807996b3fe
-0,         42,         42,        1,   194120, 9a4e2d72f4526815b253b3acce2dd49c
-0,         43,         43,        1,   194232, e575508ffbd2a53871e817cd8947e2d2
-0,         44,         44,        1,   193744, 95d8eefbfbf5a7354ecbf35835243e44
-0,         45,         45,        1,   191748, de2eedebb28491e59700300635af1f90
-0,         46,         46,        1,   191128, 652670f6881419be5068f2de6ac2d91e
-0,         47,         47,        1,   191704, 070f46dc278230528aa6b40256a6d891
-0,         48,         48,        1,   191584, e4b76fcf344e125729c339e360a14b15
-0,         49,         49,        1,   191444, 6a33b374a8b48549094a24543d81d999
+0,          0,          0,        1,   210764, 7c17cd8382580fcfd6dac1ddaa644c8d
+0,          1,          1,        1,   210772, 4c6bcde52e58d800927620df9e0e03b8
+0,          2,          2,        1,   211564, c0754e5c821ae0c0ca0bae78ad8fe1aa
+0,          3,          3,        1,   210032, 6ea988397d00f553c6e5ddbca7a08af9
+0,          4,          4,        1,   209168, c2d1fcee61bfdb5e3925aca342550ae5
+0,          5,          5,        1,   210284, dc92cc07ac1211e664a24c701c410e0e
+0,          6,          6,        1,   210184, 0977e253355bff82f0efd330e94cec6c
+0,          7,          7,        1,   210136, d81c28cfef7dd47abf2ac951b6a948e7
+0,          8,          8,        1,   210016, d378efd0efe103407afa8b8f45d17e24
+0,          9,          9,        1,   210624, 1a7e4a4c7b4ccbd10b9238b22dbc953b
+0,         10,         10,        1,   210388, 607fdb29b0bf5846cbbb776459840401
+0,         11,         11,        1,   209956, c4c4c18b83db1983b1d9268024027025
+0,         12,         12,        1,   208064, f1a73d7fe1dfdeb33758c9d7c61fa81b
+0,         13,         13,        1,   209728, ce7b81e19d940ebddeef93e281fed00d
+0,         14,         14,        1,   211640, 0d6929d8d034f8accd00f58b887073f5
+0,         15,         15,        1,   210932, b895f81c00f959868e24944ee816e0df
+0,         16,         16,        1,   210500, c43494420a45bb8fb0a907d3169d30b7
+0,         17,         17,        1,   210328, 5e4d72389e2733d8ce274f0c9a7cf7aa
+0,         18,         18,        1,   209612, 59d368acc1ea2c0f28ed0787fe5bad4a
+0,         19,         19,        1,   209716, 77a331effc0bb544ef1445fd5c42cfe2
+0,         20,         20,        1,   208912, 1de694210d8e781ce8ea29add190ad06
+0,         21,         21,        1,   209052, b48927d6e1658b5df335c34bf0fc0dc9
+0,         22,         22,        1,   209552, 1c00ad79bcf1efdb633baa040f5e1400
+0,         23,         23,        1,   210460, 755c6daf2681ba0aed4e4c962faa288c
+0,         24,         24,        1,   211136, e6a5687e05a70fc7c741f2ef7afb93b9
+0,         25,         25,        1,   210444, 6fe3ec5657f092b009a7bcc4815fc5b3
+0,         26,         26,        1,   209764, 19bc9792b30711fb7276a9f74d423c3e
+0,         27,         27,        1,   209328, 0144894411a4c5f14c66a393a46bb3b4
+0,         28,         28,        1,   207152, 61bbd2676caf8fbe6582274fe8add09d
+0,         29,         29,        1,   207360, 9663a6d131b029c9ad7469d67a381823
+0,         30,         30,        1,   208608, a0908484dfeead74fb351bb1ba3b514a
+0,         31,         31,        1,   209284, 00dda733e216eb968cfdf97f6138294d
+0,         32,         32,        1,   209400, 7f7e4d3546ab89ba5eaed835a2fabf64
+0,         33,         33,        1,   211120, 3b281fadbc1eed3b4d0e6b14deb4a18f
+0,         34,         34,        1,   210488, f3fb93f6504ffee9984574a7b6854d89
+0,         35,         35,        1,   209952, 1ccf5aa118c8cd51e099749289fdc374
+0,         36,         36,        1,   209140, 4e4c0f0a38608f1ff760a7ada9d44a6f
+0,         37,         37,        1,   209380, dac76683c0ce9e1008fe1490dc1479bf
+0,         38,         38,        1,   207004, e914b5454210fc6b4c39d22b7daf16da
+0,         39,         39,        1,   206968, 0a9566c879a6897536ec094100f32fbf
+0,         40,         40,        1,   207368, a644c2b3b8c89ec01b2b51576a5b09b5
+0,         41,         41,        1,   208628, 2ce6ca69d5f6e29641f5a907ffac9bb0
+0,         42,         42,        1,   208976, d3be7fe389e80df517eafd0c861947a2
+0,         43,         43,        1,   209316, c5148e0073cebd50d8f619d4875874dd
+0,         44,         44,        1,   208356, 54e0082cdc1aa7fcbb8c655e94fbd410
+0,         45,         45,        1,   206620, 77ec6d3714a0dcbf0cdd5349df0951fc
+0,         46,         46,        1,   205932, 7857acd2afd3169126a5428ddef97abd
+0,         47,         47,        1,   206524, c903ec677106ec1f7f583bb813a1120a
+0,         48,         48,        1,   206444, ea549da62a460b50811cb3f182fe5c19
+0,         49,         49,        1,   205460, 81d823633491b13a31dfdbc5f33d79f4
diff --git a/tests/ref/fate/utvideoenc_rgba_median b/tests/ref/fate/utvideoenc_rgba_median
index 0cdab8d41a..a2118c276f 100644
--- a/tests/ref/fate/utvideoenc_rgba_median
+++ b/tests/ref/fate/utvideoenc_rgba_median
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   195092, d32d5a3dc88b9aef0826b565ee5dfbc6
-0,          1,          1,        1,   195036, ea13e3522d1f3aeddd47117c91eccc55
-0,          2,          2,        1,   196040, 21c2c9abe791bed2a9bf02e539caa787
-0,          3,          3,        1,   195252, 58d5e081127f246f711f5b8ee1c760ff
-0,          4,          4,        1,   194852, 8ceb3824ec628a73e1c08e498f369484
-0,          5,          5,        1,   195356, 30ea64094f29d670e2ff8f43b50578d6
-0,          6,          6,        1,   195180, 08b406b9f3063a54681d7195fb53e953
-0,          7,          7,        1,   194808, e28c43ef3aef174f0f9b9d7a702ca747
-0,          8,          8,        1,   195036, 66247b40b0def9373bf6fdda9ef832f7
-0,          9,          9,        1,   195472, efa8a624d6b0fa69e0c1c746baed0b33
-0,         10,         10,        1,   195052, fdfc784aed661cb76bc5b3ef1863bd89
-0,         11,         11,        1,   195068, 040ad503d18a36d4f1cdaec64998138a
-0,         12,         12,        1,   194228, 1cd168427d022825a801b232cb23ca12
-0,         13,         13,        1,   195068, e4082f833d3bf75af24e1bb5f06d94fe
-0,         14,         14,        1,   195344, 19638340e93d4f1f7099deda34d28e3f
-0,         15,         15,        1,   195664, 001a801c5c5ceb197576c0f7b793850d
-0,         16,         16,        1,   194876, 9550b3cf6133997bf7557483f346b036
-0,         17,         17,        1,   195164, eb7220caf48ab2605ec971ca1297a7ae
-0,         18,         18,        1,   194444, a2ac812e6307a92ecd09d4282367a9d4
-0,         19,         19,        1,   194356, ee4d250226ab2a34cef0e3ed8920f7b2
-0,         20,         20,        1,   193696, 4bff0fc871969d17ad1f7391bbd543b2
-0,         21,         21,        1,   194004, 080e2a91fe768fd1725a8400bc6a1331
-0,         22,         22,        1,   194092, 5b9d65275695372e1f6b9c0a23f1ffa0
-0,         23,         23,        1,   195088, a4060bf595c877476a5952b335526d57
-0,         24,         24,        1,   195192, 17b55735834f291ecae399c317007d2c
-0,         25,         25,        1,   194908, fc78d797bd5740f4fec8f3d34bc2ff1b
-0,         26,         26,        1,   194764, d229a9e4d1c782504cad617d2b00802b
-0,         27,         27,        1,   194356, f987a587cb9fdcd04e36d9382c4d9139
-0,         28,         28,        1,   193564, bdfa512e3a0a46aabf289c22dbaee0b9
-0,         29,         29,        1,   193556, 341708f3181ba4b37114d6dbffc65e63
-0,         30,         30,        1,   193956, f97693469ae6f49c3995794d00430c4a
-0,         31,         31,        1,   194776, 970c96fe0f733683ce4f2b478af21b88
-0,         32,         32,        1,   194644, 8a96248e2821040e4d0d6d32d0a4f1a9
-0,         33,         33,        1,   194940, 70a462d8de0da8b5718bf8fb8034fa38
-0,         34,         34,        1,   194732, 2fb3437abbc0a85b6c46e1b1edd922c9
-0,         35,         35,        1,   194772, 0a0f54e266438e1a840247e1af2fb1f1
-0,         36,         36,        1,   194780, c4d516a459523b1c150d8aad1d5e3a6d
-0,         37,         37,        1,   194908, e09db67196513400dd55397a525b73c2
-0,         38,         38,        1,   194148, f3cc9fc8597f8806fbc2a0c13af5b9ba
-0,         39,         39,        1,   194168, 2bb82f80c239984fe7c1091ab6afb332
-0,         40,         40,        1,   193604, 6fd128240c540a0655e8f27ff6a50ee9
-0,         41,         41,        1,   194256, 9b49275154b4538abdebbddffe010105
-0,         42,         42,        1,   193912, 6acff798f9cca91347e36ee1ea86183c
-0,         43,         43,        1,   194136, f24ca78d9b813ab8bfc720bad2682e7b
-0,         44,         44,        1,   193652, d7d927faf59a3b82bd1cce418c13c430
-0,         45,         45,        1,   192960, 8a813fce1d21dd4ad474d06d890a3de5
-0,         46,         46,        1,   192636, 6bbe157ec4f799cfd47a69c5a5cbb0fc
-0,         47,         47,        1,   192580, 1c17bf08a3928533a0036bda1fb08ecb
-0,         48,         48,        1,   192356, a5b34ac48c82e79ff827f72dddbfc6b0
-0,         49,         49,        1,   191912, afceb467ddffd9697c9566c43f2576f9
+0,          0,          0,        1,   207164, 91bd0a04c522e4a449a2b2729cceb273
+0,          1,          1,        1,   207188, 8a9a23c32503fe30df47a598d319591e
+0,          2,          2,        1,   207980, fac02289d860c485b09053119a259772
+0,          3,          3,        1,   206944, bc0251f0a3ad5881cb402d1d071cbfe8
+0,          4,          4,        1,   206200, e3b811ea58b790b171b75c9af46a3637
+0,          5,          5,        1,   207100, 076ca542190996d4ff4380bfff1b8707
+0,          6,          6,        1,   207172, 87d8540012df5c62ffcec97ac4255e44
+0,          7,          7,        1,   206444, 8a4a787dd73b93653ab69622b3fcaa6d
+0,          8,          8,        1,   206884, e4ce5916ecee62387a44257f9f7e309f
+0,          9,          9,        1,   207632, 67f343e24f47b1eddb47e59831752aab
+0,         10,         10,        1,   206916, 6a1d003a2b3c10bd87d5b71a0ecb6fae
+0,         11,         11,        1,   206572, 8939adde46e92bf02be301590de578ae
+0,         12,         12,        1,   205832, ac36ce0cc201b89aa85aea9f8f85b654
+0,         13,         13,        1,   206712, 1d85faa22ef18e060354d2e2931f78f3
+0,         14,         14,        1,   207496, 2459b868050730ba3c3152443f119e59
+0,         15,         15,        1,   207788, 27616d7494e570814378a35fd72b3d4a
+0,         16,         16,        1,   206988, 4f0daddba744ae0ebeea8b55ebc6778b
+0,         17,         17,        1,   207056, e2340667064a25a75f67e261fe96baf7
+0,         18,         18,        1,   206440, d487795c5f4a3f338cebfd36b264a760
+0,         19,         19,        1,   206344, 0cd1a4c459402e82d7c89a131d6f75fe
+0,         20,         20,        1,   205404, 52ea62992efacc4bf4234507752cd4ed
+0,         21,         21,        1,   205776, 7712e82b94fd155c1e0dfec1db19a298
+0,         22,         22,        1,   205600, ec081ebb4e12f35aa47e673c5cd8c858
+0,         23,         23,        1,   207040, 637d7b20ab169db4671d76abc986c20d
+0,         24,         24,        1,   207484, a776de1269ad564e1dc21ead94dcc71e
+0,         25,         25,        1,   206792, 6aaa68388fb12b2e70eb542819902a97
+0,         26,         26,        1,   206384, b4c4d079d7c75b03e2d3915a8676a64d
+0,         27,         27,        1,   206296, 521647a00535f63c241b54699b5d803a
+0,         28,         28,        1,   204996, 892f0c216d04dfa120576c0cbbbdb0a2
+0,         29,         29,        1,   205396, fa1b2301c765bb1ca1c85828918462b9
+0,         30,         30,        1,   205812, e40d8da60a07f19b43ab27a13928b87d
+0,         31,         31,        1,   206604, 2a06b115a3a400a73ad06b69c90a0768
+0,         32,         32,        1,   206568, e6d367cc3d7bd17a6c470fe86591e56d
+0,         33,         33,        1,   206908, 8d53fe57b1043562c50a2fd63fa2ebfa
+0,         34,         34,        1,   206388, 3a5544a0a814dbba171d0384c91ea566
+0,         35,         35,        1,   206700, bfe43124bcbbaef9884893c32396f316
+0,         36,         36,        1,   206516, a93e303f30a9269c6d6b59882b668630
+0,         37,         37,        1,   206776, 3044d9c98555d3415fc75b085f8aab0a
+0,         38,         38,        1,   205940, 870403f6326de73750a57692a288bc2d
+0,         39,         39,        1,   205612, f97b94da7b565f67cb476c73c2196bb1
+0,         40,         40,        1,   205120, 78341e169158f97791ec9a88ee936048
+0,         41,         41,        1,   206132, 83d31e0b40f2850b0767fbd162b4aabd
+0,         42,         42,        1,   205984, ba029595b56087c55f324a54cb5e20a6
+0,         43,         43,        1,   205964, d067932b507acda9020837ed271eb09e
+0,         44,         44,        1,   205376, 62b45f4949405875f947cd6d5133b76d
+0,         45,         45,        1,   204756, ec45bcef0601faff97d89f89bfede4f3
+0,         46,         46,        1,   204704, 59c9d309aa381e39f3b236d332ae516a
+0,         47,         47,        1,   204652, c44f8fba96dfb305cdc797ddfa033899
+0,         48,         48,        1,   204460, d0116d06128babcf8ec55205ce89d46a
+0,         49,         49,        1,   203624, bbd3523ac263c622541aa67825601fd2
diff --git a/tests/ref/fate/utvideoenc_rgba_none b/tests/ref/fate/utvideoenc_rgba_none
index 65f07289d1..f388c9101d 100644
--- a/tests/ref/fate/utvideoenc_rgba_none
+++ b/tests/ref/fate/utvideoenc_rgba_none
@@ -8,53 +8,53 @@ 
 #dimensions 0: 352x288
 #sar 0: 0/1
 #stream#, dts,        pts, duration,     size, hash
-0,          0,          0,        1,   301284, 55e84c6e1f41e48f47dcefb63e3c1efd
-0,          1,          1,        1,   301296, 12dab23dfd2c2d5b48bed2292b876688
-0,          2,          2,        1,   301072, cc2e2889403dcc5d8e36868f07918b9d
-0,          3,          3,        1,   301136, 9813d60e613a3a14e639f9af0a5b1fe7
-0,          4,          4,        1,   301140, 58554bb6749e8bbd9476335ac1cb0076
-0,          5,          5,        1,   301164, 37a249286019761a4a3e498e977f9da1
-0,          6,          6,        1,   301168, f3aa11b419ec6f683ad906e7f7a36342
-0,          7,          7,        1,   301272, f489654640f0e42225815ea9c9681201
-0,          8,          8,        1,   301308, f10eb3c1d0324b59bd25c8bc6556aca0
-0,          9,          9,        1,   301268, 2163aa992afef5210d677953d81adb17
-0,         10,         10,        1,   301168, 684d19d14212615ebffa1748a9c552ed
-0,         11,         11,        1,   301136, a5c47c30d12dbc679ce932a5988b32e5
-0,         12,         12,        1,   301272, 3a51dc37d7e5ecb4a8db948eade2e0fa
-0,         13,         13,        1,   301188, f9f9ed41c233e791e6cd75a34e52edf8
-0,         14,         14,        1,   301096, 63bbfbee6f0fa6745e143dfae40ce7ff
-0,         15,         15,        1,   301108, 1fb3340dd1804d27fb40aea6b073e9ce
-0,         16,         16,        1,   301248, 476d27f29da8e74db696ff38e81743fc
-0,         17,         17,        1,   301300, 84a7f5804a856b7ef640838320634568
-0,         18,         18,        1,   301424, f34006fb55745aac29e265e0362434bf
-0,         19,         19,        1,   301456, d9207e54e261d184ddd02f3706e63103
-0,         20,         20,        1,   301408, 89b5a6804bad85025a6a3d23dc539426
-0,         21,         21,        1,   301404, 5987d22d6e3bf18cd2ebea98a1915f57
-0,         22,         22,        1,   301340, 43ff13bb237a7899ecb04fa7d27e94ab
-0,         23,         23,        1,   301288, 01b3e148ed6b8a0d05ee628fb21fa4a5
-0,         24,         24,        1,   301360, aa7704007e3c437cfcad4fb83a69594a
-0,         25,         25,        1,   301376, 4dea983f0b4a012ba6875aa857d02e91
-0,         26,         26,        1,   301312, e263f1cb0fb19b50751e9a214a4c9d81
-0,         27,         27,        1,   301460, 85ad441664c99c591d6dc427910faa19
-0,         28,         28,        1,   301380, 86ffe8273011763d800dbf6c89942a70
-0,         29,         29,        1,   301448, 500862ea62e1982325d653d4853dcbcd
-0,         30,         30,        1,   301452, 91c4390a805e02d1924bd75946bc0b63
-0,         31,         31,        1,   301388, 4eb3040d65948355c4506ee8e8e041ca
-0,         32,         32,        1,   301348, ece814a764470f1d80973743a7adaa4b
-0,         33,         33,        1,   301324, 2ae0b9af5380c8f98087b90c646af813
-0,         34,         34,        1,   301224, d6a3ba0b543534bd7de9dd82107c468c
-0,         35,         35,        1,   301384, 4f4919c1b2502c6e03ddaa83f4c03f15
-0,         36,         36,        1,   301460, b45189bc89e6583f4426c390622fa1fc
-0,         37,         37,        1,   301456, db0c5e2bc705c825e554c2da54314746
-0,         38,         38,        1,   301520, 8d01037b2dcbba39d4746758fd53323c
-0,         39,         39,        1,   301524, 0a78af44bf49520ae8830060e6011898
-0,         40,         40,        1,   301532, da9032ac97b76ec10f94d74ee878cf41
-0,         41,         41,        1,   301496, 9a22b2a9a3ad897406fc7c3137d41a3b
-0,         42,         42,        1,   301572, a14a80ab416cf4a9a1ec24bfc72602a1
-0,         43,         43,        1,   301532, 71ea5a240540a2e08ced8ad78c1a0676
-0,         44,         44,        1,   301516, fffe101d036ed5afee9b6f86267c2a0c
-0,         45,         45,        1,   301568, 58ea3a6edaee760d98eadb072fb30796
-0,         46,         46,        1,   301660, 9886e77f5df35d8bd164d598d0f87514
-0,         47,         47,        1,   301668, 1f326eb789974fc853e1db57115ef58b
-0,         48,         48,        1,   301684, 08b2eb620b9a7be1bded4744cd4c88db
-0,         49,         49,        1,   301668, bfcce1ce5f7c30230aae9a2d67fc8a70
+0,          0,          0,        1,   304028, e1687f63bd131ace3866b61881e8e9a1
+0,          1,          1,        1,   304024, 93067fdad1470b1c2f2fd4ae603a3afe
+0,          2,          2,        1,   303932, 2fef08ce570f581373bd48b3a4773acb
+0,          3,          3,        1,   303932, 8623d4635239deac16d56085edb8aec1
+0,          4,          4,        1,   303984, ef0a1be76f7c854e5f2724d7a6707f54
+0,          5,          5,        1,   303932, 0e57009f6e93c2e5ce80d6109d9a66f3
+0,          6,          6,        1,   303936, db988d8d6e9ee0383cfc69a201de62e2
+0,          7,          7,        1,   304024, 963e86c081fafed2f757c4aafc9186df
+0,          8,          8,        1,   304032, e867c068706bff34a561a4b2c4622fd3
+0,          9,          9,        1,   303960, 0dd6d1cbe6a9fb07e3f3cb4a12c2821a
+0,         10,         10,        1,   303944, 424612ce8850b378171ee8bfca5d91ce
+0,         11,         11,        1,   303956, f26d5065818f98bbf97aae56fe07b057
+0,         12,         12,        1,   303980, dfd1a61b5a717805a06f19ee899c3917
+0,         13,         13,        1,   303936, 2223f98ac58078c49489811171c713e1
+0,         14,         14,        1,   303808, 6a63bd7cd4cafe5e64dc8dc46f9f3760
+0,         15,         15,        1,   303864, a355699c989795379d1ef2089c98e619
+0,         16,         16,        1,   304008, 07a0c41088846ed77fedc565cfeaeba7
+0,         17,         17,        1,   304000, dbb37a1af0bb534112aac9269b7d7c2c
+0,         18,         18,        1,   304048, 3129997c9ba84a0c91ff9d1c48d12d7e
+0,         19,         19,        1,   304068, 620b4c964daca105cd1b6bf8d55e86ae
+0,         20,         20,        1,   304068, bafaf53530f76d525eafb75a3866b5e7
+0,         21,         21,        1,   304092, 678138b93f07ef8f30ad373499a9caa3
+0,         22,         22,        1,   304060, 4bf8174ff9ee62c13bde29ad5bba3fc9
+0,         23,         23,        1,   303976, e6e926057f49e69e2ea8e679871e449a
+0,         24,         24,        1,   304040, f81ba4d36df7e8967a16e7de5c7a023b
+0,         25,         25,        1,   304084, a5a63a22e6bc3a54bfbd60852ca9da60
+0,         26,         26,        1,   304056, df9bd50b9dd7437afb3671c99e2e1746
+0,         27,         27,        1,   304076, 785a2a7de44e83f1111e66165b3d0765
+0,         28,         28,        1,   304132, ab01bacd7aee91ab80b30a48f54ec4d7
+0,         29,         29,        1,   304160, 4893296140e7ee6f2d194bc279f928f3
+0,         30,         30,        1,   304136, 6046c7516a5e8db2f4dd3b1286ad46c0
+0,         31,         31,        1,   304088, e6dbc1ec86cb678bab6a1ca0e93888d0
+0,         32,         32,        1,   303980, 66db98674c107af297a3de01c047ebce
+0,         33,         33,        1,   303964, e2ce0a2ee5ba8de50960873a8405c001
+0,         34,         34,        1,   303900, 7ae96a39e66e0abe63e298f45477c0ec
+0,         35,         35,        1,   304040, d5fc8f7809470bc40935285d4ed69a80
+0,         36,         36,        1,   304088, efae0966a7e421c3107016df862b0429
+0,         37,         37,        1,   304120, c6a3bf8991bf2b559f27d5ea9ae76d08
+0,         38,         38,        1,   304144, 588ac89c403c5d3ca9289fbd339fdb74
+0,         39,         39,        1,   304136, a3824537484dd2fc25dde9ec2974068c
+0,         40,         40,        1,   304172, e1a024aa9faba0ee0cb98e41cef254c9
+0,         41,         41,        1,   304116, c26c4c053d53b70c97cbf989cb51a15d
+0,         42,         42,        1,   304140, 4d13ee2a3b32ba3f080fffa7ca2db6e6
+0,         43,         43,        1,   304116, fb02b57f9a9fafa7bc6d2a35a68548fc
+0,         44,         44,        1,   304088, 6daa494c1ed11c9ea8da6c83eb473ce7
+0,         45,         45,        1,   304196, 8886953ff026efef28f4af12ce5239b6
+0,         46,         46,        1,   304200, 51ff2c8552b8b044a1a183330a188d62
+0,         47,         47,        1,   304208, 72fcd3dbf45284bb434ad3660f8a1ddf
+0,         48,         48,        1,   304204, 1d5e2170963d70acea2ad01e1486d490
+0,         49,         49,        1,   304184, 6eec23c3d4402f7a0ab4de16fde86462