Files
ffmpeg-rockchip/libavcodec
Shaofei Wang eb6bb8f32f libavcodec/vp8dec: fix the multi-thread HWAccel decode error
Fix the issue: https://github.com/intel/media-driver/issues/317

the root cause is update_dimensions will be called multple times
when decoder thread number is not only 1, but update_dimensions
call get_pixel_format in each decode thread will trigger the
hwaccel_uninit/hwaccel_init more than once. But only one hwaccel
should be shared with all decode threads.
in current context,
there are 3 situations in the update_dimensions():
1. First time calling. No matter single thread or multithread,
   get_pixel_format() should be called after dimensions were
   set;
2. Dimention changed at the runtime. Dimention need to be
   updated when macroblocks_base is already allocated,
   get_pixel_format() should be called to recreate new frames
   according to updated dimension;
3. Multithread first time calling. After decoder init, the
   other threads will call update_dimensions() at first time
   to allocate macroblocks_base and set dimensions.
   But get_pixel_format() is shouldn't be called due to low
   level frames and context are already created.

In this fix, we only call update_dimensions as need.

Signed-off-by: Wang, Shaofei <shaofei.wang@intel.com>
Reviewed-by: Jun, Zhao <jun.zhao@intel.com>
Reviewed-by: Haihao Xiang <haihao.xiang@intel.com>
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2020-09-23 13:47:36 -04:00
..
2020-02-07 13:36:57 -03:00
2020-08-07 23:04:28 +10:00
2020-09-18 11:34:11 +02:00
2020-06-10 12:36:44 +02:00
2020-09-02 00:00:57 +01:00
2020-09-02 00:00:57 +01:00
2020-08-30 16:18:37 +02:00
2020-08-26 21:13:38 +02:00
2020-08-26 21:13:38 +02:00
2020-09-04 16:01:53 +02:00
2020-09-04 16:01:53 +02:00
2020-03-12 20:26:48 +00:00
2020-03-12 20:26:48 +00:00
2020-05-21 09:31:08 +02:00
2020-02-22 00:15:43 +01:00
2020-03-22 11:55:44 -03:00
2020-06-05 18:14:17 +02:00
2020-06-14 18:20:37 +02:00
2020-06-15 04:22:28 +02:00
2020-07-20 18:41:09 +02:00
2020-07-20 18:41:09 +02:00
2020-05-12 01:00:28 +02:00
2020-05-26 10:52:12 +01:00
2020-05-26 10:52:12 +01:00
2020-05-26 10:52:12 +01:00
2020-06-08 20:45:56 +02:00
2020-05-30 18:02:55 +02:00
2020-07-05 19:59:49 +02:00
2020-02-19 22:37:30 +01:00
2020-09-01 14:19:19 +02:00
2020-04-26 18:38:25 +01:00
2020-04-04 23:26:15 +02:00
2020-05-22 22:23:18 +02:00
2020-07-06 18:23:50 +01:00
2020-09-19 00:40:56 +02:00
2020-07-20 18:41:09 +02:00
2020-04-26 18:38:25 +01:00
2020-04-17 19:33:43 +10:00
2020-04-16 15:05:07 -03:00
2020-03-22 11:55:44 -03:00
2020-05-23 07:07:36 +02:00