Skip to content

Commit fcaf503

Browse files
committed
test/st20: full cases for 8 bit and 10bit (#610)
* test/st20: full cases for 8 bit and 10bit Signed-off-by: Du, Frank <[email protected]> (cherry picked from commit ec54696af977331601386dbb12d9d889630a6372)
1 parent 5cd0ca9 commit fcaf503

File tree

3 files changed

+113
-54
lines changed

3 files changed

+113
-54
lines changed

lib/src/st_main.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -771,6 +771,7 @@ struct st_rx_video_session_impl {
771771

772772
/* status */
773773
int st20_stat_pkts_idx_dropped;
774+
int st20_stat_pkts_idx_oo_bitmap;
774775
int st20_stat_pkts_enqueue_fallback; /* for pkt lcore */
775776
int st20_stat_pkts_offset_dropped;
776777
int st20_stat_pkts_redunant_dropped;

lib/src/st_rx_video_session.c

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1343,7 +1343,7 @@ static int rx_video_session_handle_frame_pkt(struct st_main_impl* impl,
13431343
if ((pkt_idx < 0) || (pkt_idx >= (s->st20_frame_bitmap_size * 8))) {
13441344
dbg("%s(%d,%d), drop as invalid pkt_idx %d base %u\n", __func__, s->idx, s_port,
13451345
pkt_idx, slot->seq_id_base_u32);
1346-
s->st20_stat_pkts_idx_dropped++;
1346+
s->st20_stat_pkts_idx_oo_bitmap++;
13471347
return -EIO;
13481348
}
13491349
bool is_set = st_bitmap_test_and_set(bitmap, pkt_idx);
@@ -1518,7 +1518,7 @@ static int rx_video_session_handle_rtp_pkt(struct st_main_impl* impl,
15181518
if ((pkt_idx < 0) || (pkt_idx >= (s->st20_frame_bitmap_size * 8))) {
15191519
dbg("%s(%d,%d), drop as invalid pkt_idx %d base %u\n", __func__, s->idx, s_port,
15201520
pkt_idx, slot->seq_id_base);
1521-
s->st20_stat_pkts_idx_dropped++;
1521+
s->st20_stat_pkts_idx_oo_bitmap++;
15221522
return -EIO;
15231523
}
15241524
bool is_set = st_bitmap_test_and_set(bitmap, pkt_idx);
@@ -1661,7 +1661,7 @@ static int rx_video_session_handle_st22_pkt(struct st_main_impl* impl,
16611661
if ((pkt_idx < 0) || (pkt_idx >= (s->st20_frame_bitmap_size * 8))) {
16621662
dbg("%s(%d,%d), drop as invalid pkt_idx %d base %u\n", __func__, s->idx, s_port,
16631663
pkt_idx, slot->seq_id_base);
1664-
s->st20_stat_pkts_idx_dropped++;
1664+
s->st20_stat_pkts_idx_oo_bitmap++;
16651665
return -EIO;
16661666
}
16671667
bool is_set = st_bitmap_test_and_set(bitmap, pkt_idx);
@@ -2282,8 +2282,8 @@ static int rx_video_session_attach(struct st_main_impl* impl,
22822282
s->st20_frame_size = ops->width * ops->height * s->st20_pg.size / s->st20_pg.coverage;
22832283
s->st20_uframe_size = ops->uframe_size;
22842284
if (ops->interlaced) s->st20_frame_size = s->st20_frame_size >> 1;
2285-
/* at least 1000 byte for each packet */
2286-
s->st20_frame_bitmap_size = s->st20_frame_size / 1000 / 8;
2285+
/* at least 800 byte for each packet */
2286+
s->st20_frame_bitmap_size = s->st20_frame_size / 800 / 8;
22872287
/* one line at line 2 packets for all the format */
22882288
if (s->st20_frame_bitmap_size < ops->height * 2 / 8)
22892289
s->st20_frame_bitmap_size = ops->height * 2 / 8;
@@ -2295,6 +2295,7 @@ static int rx_video_session_attach(struct st_main_impl* impl,
22952295
}
22962296

22972297
s->st20_stat_pkts_idx_dropped = 0;
2298+
s->st20_stat_pkts_idx_oo_bitmap = 0;
22982299
s->st20_stat_pkts_no_slot = 0;
22992300
s->st20_stat_pkts_offset_dropped = 0;
23002301
s->st20_stat_pkts_redunant_dropped = 0;
@@ -2438,11 +2439,12 @@ static void rx_video_session_stat(struct st_rx_video_sessions_mgr* mgr,
24382439
s->st20_stat_pkts_offset_dropped) {
24392440
info(
24402441
"RX_VIDEO_SESSION(%d,%d): incomplete frames %d, pkts (idx error: %d, offset "
2441-
"error: %d)\n",
2442+
"error: %d, idx out of bitmap: %d)\n",
24422443
m_idx, idx, s->st20_stat_frames_dropped, s->st20_stat_pkts_idx_dropped,
2443-
s->st20_stat_pkts_offset_dropped);
2444+
s->st20_stat_pkts_offset_dropped, s->st20_stat_pkts_idx_oo_bitmap);
24442445
s->st20_stat_frames_dropped = 0;
24452446
s->st20_stat_pkts_idx_dropped = 0;
2447+
s->st20_stat_pkts_idx_oo_bitmap = 0;
24462448
}
24472449
if (s->st20_stat_pkts_rtp_ring_full) {
24482450
info("RX_VIDEO_SESSION(%d,%d): rtp dropped pkts %d as ring full\n", m_idx, idx,

tests/src/st20_test.cpp

Lines changed: 103 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1429,7 +1429,7 @@ static void st20_digest_rx_field_check(void* args) {
14291429
static void st20_rx_digest_test(enum st20_type tx_type[], enum st20_type rx_type[],
14301430
enum st20_packing packing[], enum st_fps fps[],
14311431
int width[], int height[], bool interlaced[],
1432-
enum st20_fmt fmt, bool check_fps, int sessions = 1,
1432+
enum st20_fmt fmt[], bool check_fps, int sessions = 1,
14331433
bool out_of_order = false) {
14341434
auto ctx = (struct st_tests_context*)st_test_ctx();
14351435
auto m_handle = ctx->handle;
@@ -1487,7 +1487,7 @@ static void st20_rx_digest_test(enum st20_type tx_type[], enum st20_type rx_type
14871487
ops_tx.height = height[i];
14881488
ops_tx.interlaced = interlaced[i];
14891489
ops_tx.fps = fps[i];
1490-
ops_tx.fmt = fmt;
1490+
ops_tx.fmt = fmt[i];
14911491
ops_tx.payload_type = ST20_TEST_PAYLOAD_TYPE;
14921492
ops_tx.framebuff_cnt = test_ctx_tx[i]->fb_cnt;
14931493
ops_tx.get_next_frame = interlaced[i] ? tx_next_video_field : tx_next_video_frame;
@@ -1564,7 +1564,7 @@ static void st20_rx_digest_test(enum st20_type tx_type[], enum st20_type rx_type
15641564
ops_rx.width = width[i];
15651565
ops_rx.height = height[i];
15661566
ops_rx.fps = fps[i];
1567-
ops_rx.fmt = fmt;
1567+
ops_rx.fmt = fmt[i];
15681568
ops_rx.payload_type = ST20_TEST_PAYLOAD_TYPE;
15691569
ops_rx.interlaced = interlaced[i];
15701570
ops_rx.framebuff_cnt = test_ctx_rx[i]->fb_cnt;
@@ -1704,8 +1704,8 @@ TEST(St20_rx, digest_frame_1080p_fps59_94_s1) {
17041704
int width[1] = {1920};
17051705
int height[1] = {1080};
17061706
bool interlaced[1] = {false};
1707-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1708-
ST20_FMT_YUV_422_10BIT, true);
1707+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1708+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17091709
}
17101710

17111711
TEST(St20_rx, digest_field_1080p_fps59_94_s1) {
@@ -1716,8 +1716,8 @@ TEST(St20_rx, digest_field_1080p_fps59_94_s1) {
17161716
int width[1] = {1920};
17171717
int height[1] = {1080};
17181718
bool interlaced[1] = {true};
1719-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1720-
ST20_FMT_YUV_422_10BIT, true);
1719+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1720+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17211721
}
17221722

17231723
TEST(St20_rx, digest_frame_720p_fps59_94_s1_gpm) {
@@ -1728,8 +1728,8 @@ TEST(St20_rx, digest_frame_720p_fps59_94_s1_gpm) {
17281728
int width[1] = {1280};
17291729
int height[1] = {720};
17301730
bool interlaced[1] = {false};
1731-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1732-
ST20_FMT_YUV_422_10BIT, true);
1731+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1732+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17331733
}
17341734

17351735
TEST(St20_rx, digest_field_720p_fps59_94_s1_gpm) {
@@ -1740,8 +1740,8 @@ TEST(St20_rx, digest_field_720p_fps59_94_s1_gpm) {
17401740
int width[1] = {1280};
17411741
int height[1] = {720};
17421742
bool interlaced[1] = {true};
1743-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1744-
ST20_FMT_YUV_422_10BIT, true);
1743+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1744+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17451745
}
17461746

17471747
TEST(St20_rx, digest_frame_720p_fps29_97_s1_bpm) {
@@ -1752,8 +1752,8 @@ TEST(St20_rx, digest_frame_720p_fps29_97_s1_bpm) {
17521752
int width[1] = {1280};
17531753
int height[1] = {720};
17541754
bool interlaced[1] = {false};
1755-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1756-
ST20_FMT_YUV_422_10BIT, true);
1755+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1756+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17571757
}
17581758

17591759
TEST(St20_rx, digest_field_720p_fps29_97_s1_bpm) {
@@ -1764,8 +1764,8 @@ TEST(St20_rx, digest_field_720p_fps29_97_s1_bpm) {
17641764
int width[1] = {1280};
17651765
int height[1] = {720};
17661766
bool interlaced[1] = {true};
1767-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1768-
ST20_FMT_YUV_422_10BIT, true);
1767+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1768+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17691769
}
17701770

17711771
TEST(St20_rx, digest_rtp_1080p_fps59_94_s1) {
@@ -1776,8 +1776,8 @@ TEST(St20_rx, digest_rtp_1080p_fps59_94_s1) {
17761776
int width[1] = {1920};
17771777
int height[1] = {1080};
17781778
bool interlaced[1] = {false};
1779-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1780-
ST20_FMT_YUV_422_10BIT, true);
1779+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1780+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
17811781
}
17821782

17831783
TEST(St20_rx, digest_frame_4320p_fps59_94_s1) {
@@ -1788,8 +1788,8 @@ TEST(St20_rx, digest_frame_4320p_fps59_94_s1) {
17881788
int width[1] = {1920 * 4};
17891789
int height[1] = {1080 * 4};
17901790
bool interlaced[1] = {false};
1791-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1792-
ST20_FMT_YUV_422_10BIT, false);
1791+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1792+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false);
17931793
}
17941794

17951795
TEST(St20_rx, digest_field_4320p_fps59_94_s1) {
@@ -1800,8 +1800,8 @@ TEST(St20_rx, digest_field_4320p_fps59_94_s1) {
18001800
int width[1] = {1920 * 4};
18011801
int height[1] = {1080 * 4};
18021802
bool interlaced[1] = {true};
1803-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1804-
ST20_FMT_YUV_422_10BIT, false);
1803+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
1804+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false);
18051805
}
18061806

18071807
TEST(St20_rx, digest_frame_720p_fps59_94_s3) {
@@ -1815,8 +1815,10 @@ TEST(St20_rx, digest_frame_720p_fps59_94_s3) {
18151815
int width[3] = {1280, 1280, 1280};
18161816
int height[3] = {720, 720, 720};
18171817
bool interlaced[3] = {false, false, false};
1818-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1819-
ST20_FMT_YUV_422_10BIT, false, 3);
1818+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1819+
ST20_FMT_YUV_422_10BIT};
1820+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1821+
3);
18201822
}
18211823

18221824
TEST(St20_rx, digest_field_720p_fps59_94_s3) {
@@ -1830,8 +1832,10 @@ TEST(St20_rx, digest_field_720p_fps59_94_s3) {
18301832
int width[3] = {1280, 1280, 1280};
18311833
int height[3] = {720, 720, 720};
18321834
bool interlaced[3] = {true, false, true};
1833-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1834-
ST20_FMT_YUV_422_10BIT, false, 3);
1835+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1836+
ST20_FMT_YUV_422_10BIT};
1837+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1838+
3);
18351839
}
18361840

18371841
TEST(St20_rx, digest_frame_1080p_fps59_94_s3) {
@@ -1845,8 +1849,44 @@ TEST(St20_rx, digest_frame_1080p_fps59_94_s3) {
18451849
int width[3] = {1920, 1920, 1920};
18461850
int height[3] = {1080, 1080, 1080};
18471851
bool interlaced[3] = {false, false, false};
1848-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1849-
ST20_FMT_YUV_422_10BIT, false, 3);
1852+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1853+
ST20_FMT_YUV_422_10BIT};
1854+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1855+
3);
1856+
}
1857+
1858+
TEST(St20_rx, digest_frame_1080p_fps59_94_s4_8bit) {
1859+
enum st20_type type[4] = {ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL,
1860+
ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL};
1861+
enum st20_type rx_type[4] = {ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL,
1862+
ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL};
1863+
enum st20_packing packing[4] = {ST20_PACKING_GPM_SL, ST20_PACKING_GPM_SL,
1864+
ST20_PACKING_BPM, ST20_PACKING_GPM};
1865+
enum st_fps fps[4] = {ST_FPS_P59_94, ST_FPS_P50, ST_FPS_P59_94, ST_FPS_P50};
1866+
int width[4] = {1920, 1920, 1920, 1280};
1867+
int height[4] = {1080, 1080, 1080, 720};
1868+
bool interlaced[4] = {false, false, false, false};
1869+
enum st20_fmt fmt[4] = {ST20_FMT_YUV_422_8BIT, ST20_FMT_YUV_420_8BIT,
1870+
ST20_FMT_YUV_444_8BIT, ST20_FMT_RGB_8BIT};
1871+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1872+
4);
1873+
}
1874+
1875+
TEST(St20_rx, digest_frame_1080p_fps59_94_s4_10bit) {
1876+
enum st20_type type[4] = {ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL,
1877+
ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL};
1878+
enum st20_type rx_type[4] = {ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL,
1879+
ST20_TYPE_FRAME_LEVEL, ST20_TYPE_FRAME_LEVEL};
1880+
enum st20_packing packing[4] = {ST20_PACKING_GPM_SL, ST20_PACKING_GPM, ST20_PACKING_BPM,
1881+
ST20_PACKING_BPM};
1882+
enum st_fps fps[4] = {ST_FPS_P59_94, ST_FPS_P50, ST_FPS_P59_94, ST_FPS_P50};
1883+
int width[4] = {1920, 1920, 1920, 1280};
1884+
int height[4] = {1080, 1080, 1080, 720};
1885+
bool interlaced[4] = {false, false, false, false};
1886+
enum st20_fmt fmt[4] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_420_10BIT,
1887+
ST20_FMT_YUV_444_10BIT, ST20_FMT_RGB_10BIT};
1888+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1889+
4);
18501890
}
18511891

18521892
TEST(St20_rx, digest_field_1080p_fps59_94_s3) {
@@ -1860,8 +1900,10 @@ TEST(St20_rx, digest_field_1080p_fps59_94_s3) {
18601900
int width[3] = {1920, 1920, 1920};
18611901
int height[3] = {1080, 1080, 1080};
18621902
bool interlaced[3] = {true, true, true};
1863-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1864-
ST20_FMT_YUV_422_10BIT, false, 3);
1903+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1904+
ST20_FMT_YUV_422_10BIT};
1905+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1906+
3);
18651907
}
18661908

18671909
TEST(St20_rx, digest_rtp_1080p_fps59_94_s3) {
@@ -1875,8 +1917,10 @@ TEST(St20_rx, digest_rtp_1080p_fps59_94_s3) {
18751917
int width[3] = {1920, 1920, 1920};
18761918
int height[3] = {1080, 1080, 1080};
18771919
bool interlaced[3] = {false, false, false};
1878-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1879-
ST20_FMT_YUV_422_10BIT, false, 3);
1920+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1921+
ST20_FMT_YUV_422_10BIT};
1922+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1923+
3);
18801924
}
18811925

18821926
TEST(St20_rx, digest_ooo_frame_s3) {
@@ -1890,8 +1934,10 @@ TEST(St20_rx, digest_ooo_frame_s3) {
18901934
int width[3] = {1920, 1280, 1280};
18911935
int height[3] = {1080, 720, 720};
18921936
bool interlaced[3] = {false, false, false};
1893-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1894-
ST20_FMT_YUV_422_10BIT, false, 3, true);
1937+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1938+
ST20_FMT_YUV_422_10BIT};
1939+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1940+
3, true);
18951941
}
18961942

18971943
TEST(St20_rx, digest_tx_slice_s3) {
@@ -1905,8 +1951,10 @@ TEST(St20_rx, digest_tx_slice_s3) {
19051951
int width[3] = {1920, 1280, 1280};
19061952
int height[3] = {1080, 720, 720};
19071953
bool interlaced[3] = {false, false, false};
1908-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1909-
ST20_FMT_YUV_422_10BIT, false, 3, false);
1954+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1955+
ST20_FMT_YUV_422_10BIT};
1956+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1957+
3, false);
19101958
}
19111959

19121960
TEST(St20_rx, digest_slice_s3) {
@@ -1920,8 +1968,10 @@ TEST(St20_rx, digest_slice_s3) {
19201968
int width[3] = {1920, 1280, 1280};
19211969
int height[3] = {1080, 720, 720};
19221970
bool interlaced[3] = {false, false, false};
1923-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1924-
ST20_FMT_YUV_422_10BIT, false, 3, false);
1971+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1972+
ST20_FMT_YUV_422_10BIT};
1973+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1974+
3, false);
19251975
}
19261976

19271977
TEST(St20_rx, digest_field_slice_s3) {
@@ -1935,8 +1985,10 @@ TEST(St20_rx, digest_field_slice_s3) {
19351985
int width[3] = {1920, 1280, 1280};
19361986
int height[3] = {1080, 720, 720};
19371987
bool interlaced[3] = {true, true, true};
1938-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1939-
ST20_FMT_YUV_422_10BIT, false, 3, false);
1988+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
1989+
ST20_FMT_YUV_422_10BIT};
1990+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
1991+
3, false);
19401992
}
19411993

19421994
TEST(St20_rx, digest_ooo_slice_s3) {
@@ -1950,8 +2002,10 @@ TEST(St20_rx, digest_ooo_slice_s3) {
19502002
int width[3] = {1920, 1280, 1280};
19512003
int height[3] = {1080, 720, 720};
19522004
bool interlaced[3] = {false, false, false};
1953-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1954-
ST20_FMT_YUV_422_10BIT, false, 3, true);
2005+
enum st20_fmt fmt[3] = {ST20_FMT_YUV_422_10BIT, ST20_FMT_YUV_422_10BIT,
2006+
ST20_FMT_YUV_422_10BIT};
2007+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, false,
2008+
3, true);
19552009
}
19562010

19572011
TEST(St20_rx, digest_slice_4320p) {
@@ -1962,9 +2016,10 @@ TEST(St20_rx, digest_slice_4320p) {
19622016
int width[1] = {1920 * 4};
19632017
int height[1] = {1080 * 4};
19642018
bool interlaced[1] = {false};
2019+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
19652020
if (st_test_dma_available(st_test_ctx())) {
1966-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1967-
ST20_FMT_YUV_422_10BIT, false, 1, false);
2021+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt,
2022+
false, 1, false);
19682023
} else {
19692024
info("%s, skip as no dma available\n", __func__);
19702025
}
@@ -1978,9 +2033,10 @@ TEST(St20_rx, digest_ooo_slice_4320p) {
19782033
int width[1] = {1920 * 4};
19792034
int height[1] = {1080 * 4};
19802035
bool interlaced[1] = {false};
2036+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_422_10BIT};
19812037
if (st_test_dma_available(st_test_ctx())) {
1982-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1983-
ST20_FMT_YUV_422_10BIT, false, 1, true);
2038+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt,
2039+
false, 1, true);
19842040
} else {
19852041
info("%s, skip as no dma available\n", __func__);
19862042
}
@@ -1994,8 +2050,8 @@ TEST(St20_rx, digest_frame_4096_2160_fps59_94_12bit_yuv444_s1) {
19942050
int width[1] = {4096};
19952051
int height[1] = {2160};
19962052
bool interlaced[1] = {false};
1997-
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced,
1998-
ST20_FMT_YUV_444_12BIT, true);
2053+
enum st20_fmt fmt[1] = {ST20_FMT_YUV_444_12BIT};
2054+
st20_rx_digest_test(type, rx_type, packing, fps, width, height, interlaced, fmt, true);
19992055
}
20002056

20012057
static int st20_tx_meta_build_rtp(tests_context* s, struct st20_rfc4175_rtp_hdr* rtp,

0 commit comments

Comments
 (0)