diff mbox series

[FFmpeg-devel,2/2] fate/filter-video: add more rgbtestsrc tests

Message ID 20241030132543.726-2-jamrial@gmail.com
State New
Headers show
Series [FFmpeg-devel,1/2] vsrc_testsrc: add support for x2rgb10le to rgbtestsrc | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished

Commit Message

James Almer Oct. 30, 2024, 1:25 p.m. UTC
Signed-off-by: James Almer <jamrial@gmail.com>
---
 tests/fate/filter-video.mak                | 12 ++++++++++++
 tests/ref/fate/filter-rgbtestsrc-gbrp      | 10 ++++++++++
 tests/ref/fate/filter-rgbtestsrc-gbrp10    | 10 ++++++++++
 tests/ref/fate/filter-rgbtestsrc-rgba      | 10 ++++++++++
 tests/ref/fate/filter-rgbtestsrc-x2rgb10le | 10 ++++++++++
 5 files changed, 52 insertions(+)
 create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp
 create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp10
 create mode 100644 tests/ref/fate/filter-rgbtestsrc-rgba
 create mode 100644 tests/ref/fate/filter-rgbtestsrc-x2rgb10le

Comments

Michael Niedermayer Nov. 1, 2024, 4:44 p.m. UTC | #1
On Wed, Oct 30, 2024 at 10:25:42AM -0300, James Almer wrote:
> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>  tests/fate/filter-video.mak                | 12 ++++++++++++
>  tests/ref/fate/filter-rgbtestsrc-gbrp      | 10 ++++++++++
>  tests/ref/fate/filter-rgbtestsrc-gbrp10    | 10 ++++++++++
>  tests/ref/fate/filter-rgbtestsrc-rgba      | 10 ++++++++++
>  tests/ref/fate/filter-rgbtestsrc-x2rgb10le | 10 ++++++++++
>  5 files changed, 52 insertions(+)
>  create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp
>  create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp10
>  create mode 100644 tests/ref/fate/filter-rgbtestsrc-rgba
>  create mode 100644 tests/ref/fate/filter-rgbtestsrc-x2rgb10le

mips is unhappy:

The filters 'Parsed_format_1' and 'format' do not have a common format and automatic conversion is disabled.
[fc#0 @ 0x7f000750] Error configuring filter graph: Invalid argument
[fc#0 @ 0x7f000750] Task finished with error code: -22 (Invalid argument)
[fc#0 @ 0x7f000750] Terminating thread with return code -22 (Invalid argument)
[vost#0:0/rawvideo @ 0x7f0028b0] [enc:rawvideo @ 0x7f002cc0] Could not open encoder before EOF
[vost#0:0/rawvideo @ 0x7f0028b0] Task finished with error code: -22 (Invalid argument)
[vost#0:0/rawvideo @ 0x7f0028b0] Terminating thread with return code -22 (Invalid argument)
[out#0/framecrc @ 0x7f0021f0] Nothing was written into output file, because at least one of its streams received no packets.
frame=    0 fps=0.0 q=0.0 Lsize=       0KiB time=N/A bitrate=N/A speed=N/A
Conversion failed!
threads=1
make: *** [src/tests/Makefile:315: fate-filter-rgbtestsrc-gbrp10] Error 234

thx

[...]
James Almer Nov. 1, 2024, 4:56 p.m. UTC | #2
On 11/1/2024 1:44 PM, Michael Niedermayer wrote:
> On Wed, Oct 30, 2024 at 10:25:42AM -0300, James Almer wrote:
>> Signed-off-by: James Almer <jamrial@gmail.com>
>> ---
>>   tests/fate/filter-video.mak                | 12 ++++++++++++
>>   tests/ref/fate/filter-rgbtestsrc-gbrp      | 10 ++++++++++
>>   tests/ref/fate/filter-rgbtestsrc-gbrp10    | 10 ++++++++++
>>   tests/ref/fate/filter-rgbtestsrc-rgba      | 10 ++++++++++
>>   tests/ref/fate/filter-rgbtestsrc-x2rgb10le | 10 ++++++++++
>>   5 files changed, 52 insertions(+)
>>   create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp
>>   create mode 100644 tests/ref/fate/filter-rgbtestsrc-gbrp10
>>   create mode 100644 tests/ref/fate/filter-rgbtestsrc-rgba
>>   create mode 100644 tests/ref/fate/filter-rgbtestsrc-x2rgb10le
> 
> mips is unhappy:
> 
> The filters 'Parsed_format_1' and 'format' do not have a common format and automatic conversion is disabled.
> [fc#0 @ 0x7f000750] Error configuring filter graph: Invalid argument
> [fc#0 @ 0x7f000750] Task finished with error code: -22 (Invalid argument)
> [fc#0 @ 0x7f000750] Terminating thread with return code -22 (Invalid argument)
> [vost#0:0/rawvideo @ 0x7f0028b0] [enc:rawvideo @ 0x7f002cc0] Could not open encoder before EOF
> [vost#0:0/rawvideo @ 0x7f0028b0] Task finished with error code: -22 (Invalid argument)
> [vost#0:0/rawvideo @ 0x7f0028b0] Terminating thread with return code -22 (Invalid argument)
> [out#0/framecrc @ 0x7f0021f0] Nothing was written into output file, because at least one of its streams received no packets.
> frame=    0 fps=0.0 q=0.0 Lsize=       0KiB time=N/A bitrate=N/A speed=N/A
> Conversion failed!
> threads=1
> make: *** [src/tests/Makefile:315: fate-filter-rgbtestsrc-gbrp10] Error 234
> 
> thx
Forgot to insert the scale filter at the end of the chain, which is 
needed for BE hosts.
Should be fixed in https://github.com/jamrial/FFmpeg/commits/pixdesc/
diff mbox series

Patch

diff --git a/tests/fate/filter-video.mak b/tests/fate/filter-video.mak
index c956a81050..66a81ff761 100644
--- a/tests/fate/filter-video.mak
+++ b/tests/fate/filter-video.mak
@@ -100,6 +100,18 @@  fate-filter-pal100bars: CMD = framecrc -lavfi pal100bars=rate=5:duration=1 -pix_
 FATE_FILTER-$(call FILTERFRAMECRC, RGBTESTSRC) += fate-filter-rgbtestsrc
 fate-filter-rgbtestsrc: CMD = framecrc -lavfi rgbtestsrc=rate=5:duration=1 -pix_fmt rgb24
 
+FATE_FILTER-$(call FILTERFRAMECRC, RGBTESTSRC) += fate-filter-rgbtestsrc-rgba
+fate-filter-rgbtestsrc-rgba: CMD = framecrc -lavfi rgbtestsrc=rate=5:duration=1 -pix_fmt rgba
+
+FATE_FILTER-$(call FILTERFRAMECRC, RGBTESTSRC) += fate-filter-rgbtestsrc-gbrp
+fate-filter-rgbtestsrc-gbrp: CMD = framecrc -lavfi rgbtestsrc=rate=5:duration=1 -pix_fmt gbrp
+
+FATE_FILTER-$(call FILTERFRAMECRC, RGBTESTSRC SCALE) += fate-filter-rgbtestsrc-gbrp10
+fate-filter-rgbtestsrc-gbrp10: CMD = framecrc -lavfi rgbtestsrc=rate=5:duration=1,format=gbrp10 -pix_fmt gbrp10le
+
+FATE_FILTER-$(call FILTERFRAMECRC, RGBTESTSRC) += fate-filter-rgbtestsrc-x2rgb10le
+fate-filter-rgbtestsrc-x2rgb10le: CMD = framecrc -lavfi rgbtestsrc=rate=5:duration=1 -pix_fmt x2rgb10le
+
 FATE_FILTER-$(call FILTERFRAMECRC, SMPTEBARS) += fate-filter-smptebars
 fate-filter-smptebars: CMD = framecrc -lavfi smptebars=rate=5:duration=1 -pix_fmt yuv420p
 
diff --git a/tests/ref/fate/filter-rgbtestsrc-gbrp b/tests/ref/fate/filter-rgbtestsrc-gbrp
new file mode 100644
index 0000000000..0f8c0c7416
--- /dev/null
+++ b/tests/ref/fate/filter-rgbtestsrc-gbrp
@@ -0,0 +1,10 @@ 
+#tb 0: 1/5
+#media_type 0: video
+#codec_id 0: rawvideo
+#dimensions 0: 320x240
+#sar 0: 1/1
+0,          0,          0,        1,   230400, 0x0dbc18bb
+0,          1,          1,        1,   230400, 0x0dbc18bb
+0,          2,          2,        1,   230400, 0x0dbc18bb
+0,          3,          3,        1,   230400, 0x0dbc18bb
+0,          4,          4,        1,   230400, 0x0dbc18bb
diff --git a/tests/ref/fate/filter-rgbtestsrc-gbrp10 b/tests/ref/fate/filter-rgbtestsrc-gbrp10
new file mode 100644
index 0000000000..5e12d8c9a1
--- /dev/null
+++ b/tests/ref/fate/filter-rgbtestsrc-gbrp10
@@ -0,0 +1,10 @@ 
+#tb 0: 1/5
+#media_type 0: video
+#codec_id 0: rawvideo
+#dimensions 0: 320x240
+#sar 0: 1/1
+0,          0,          0,        1,   460800, 0xf82672bb
+0,          1,          1,        1,   460800, 0xf82672bb
+0,          2,          2,        1,   460800, 0xf82672bb
+0,          3,          3,        1,   460800, 0xf82672bb
+0,          4,          4,        1,   460800, 0xf82672bb
diff --git a/tests/ref/fate/filter-rgbtestsrc-rgba b/tests/ref/fate/filter-rgbtestsrc-rgba
new file mode 100644
index 0000000000..de1d9c7086
--- /dev/null
+++ b/tests/ref/fate/filter-rgbtestsrc-rgba
@@ -0,0 +1,10 @@ 
+#tb 0: 1/5
+#media_type 0: video
+#codec_id 0: rawvideo
+#dimensions 0: 320x240
+#sar 0: 1/1
+0,          0,          0,        1,   307200, 0xf238fe31
+0,          1,          1,        1,   307200, 0xf238fe31
+0,          2,          2,        1,   307200, 0xf238fe31
+0,          3,          3,        1,   307200, 0xf238fe31
+0,          4,          4,        1,   307200, 0xf238fe31
diff --git a/tests/ref/fate/filter-rgbtestsrc-x2rgb10le b/tests/ref/fate/filter-rgbtestsrc-x2rgb10le
new file mode 100644
index 0000000000..fec42b3bdb
--- /dev/null
+++ b/tests/ref/fate/filter-rgbtestsrc-x2rgb10le
@@ -0,0 +1,10 @@ 
+#tb 0: 1/5
+#media_type 0: video
+#codec_id 0: rawvideo
+#dimensions 0: 320x240
+#sar 0: 1/1
+0,          0,          0,        1,   307200, 0x88747fea
+0,          1,          1,        1,   307200, 0x88747fea
+0,          2,          2,        1,   307200, 0x88747fea
+0,          3,          3,        1,   307200, 0x88747fea
+0,          4,          4,        1,   307200, 0x88747fea