[test]: Improve decoder reader usage

1. Change to new reader slot interface.
2. Use reader slot in all decoder test case.
3. Do not async reset on eos to avoid eos stream issue.

Change-Id: If296f6555fd0e57f6931085f02b0378e41a5f2ce
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
This commit is contained in:
Herman Chen
2021-10-19 17:03:48 +08:00
parent 7b86c1abe4
commit d56760acd2
5 changed files with 132 additions and 79 deletions

View File

@@ -105,8 +105,16 @@ static int dec_simple(MpiDecLoopData *data)
// when packet size is valid read the input binary file
if (packet_size) {
FileBufSlot *slot = NULL;
ret = reader_read(reader, &slot);
data->eos = pkt_eos = reader_read(reader, &buf, &read_size);
mpp_assert(ret == MPP_OK);
mpp_assert(slot);
pkt_eos = slot->eos;
buf = slot->data;
read_size = slot->size;
data->eos = pkt_eos;
if (pkt_eos) {
if (data->frame_num < 0) {