gpac uses the AVPicture API, which has been deprecated since 2017 and removed in the just released ffmpeg 5.0.

Trying to build gpac after updating ffmpeg to 5.0 results in

```
filters/ff_dec.c:127:2: error: use of undeclared identifier 'AVPicture'
        AVPicture pict;
        ^
filters/ff_dec.c:189:8: warning: implicit declaration of function 'avcodec_decode_video2' is invalid in C99 [-Wimplicit-function-declaration]
        res = avcodec_decode_video2(ctx->decoder, frame, &gotpic, &pkt);
              ^
filters/ff_dec.c:250:26: error: use of undeclared identifier 'pict'
        memset(&pict, 0, sizeof(pict));
                                ^
filters/ff_dec.c:250:10: error: use of undeclared identifier 'pict'
        memset(&pict, 0, sizeof(pict));
                ^
filters/ff_dec.c:257:48: error: no member named 'pkt_pts' in 'struct AVFrame'
                if (gf_filter_pck_get_cts(pck_src) == frame->pkt_pts) break;
                                                      ~~~~~  ^
filters/ff_dec.c:289:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:290:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = 3*ctx->width;
                ^
filters/ff_dec.c:294:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:295:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = 4*ctx->width;
                ^
filters/ff_dec.c:300:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:301:3: error: use of undeclared identifier 'pict'
                pict.data[1] =  (uint8_t *)out_buffer + ctx->stride * ctx->height;
                ^
filters/ff_dec.c:302:3: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * uv_height;
                ^
filters/ff_dec.c:302:30: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * uv_height;
                                           ^
filters/ff_dec.c:303:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = ctx->stride;
                ^
filters/ff_dec.c:304:3: error: use of undeclared identifier 'pict'
                pict.linesize[1] = pict.linesize[2] = ctx->stride_uv;
                ^
filters/ff_dec.c:304:22: error: use of undeclared identifier 'pict'
                pict.linesize[1] = pict.linesize[2] = ctx->stride_uv;
                                   ^
filters/ff_dec.c:313:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:314:3: error: use of undeclared identifier 'pict'
                pict.data[1] =  (uint8_t *)out_buffer + ctx->stride * ctx->height;
                ^
filters/ff_dec.c:315:3: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * ctx->height;
                ^
filters/ff_dec.c:315:30: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * ctx->height;
                                           ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
1 warning and 20 errors generated.
make[1]: *** [../config.mak:154: filters/ff_dec.o] Error 1
```
Fails to build with ffmpeg 5.0
This is a GitHub Issue
repo:gpac
owner:gpac
Title : Fails to build with ffmpeg 5.0
Issue date:

--- start body ---
gpac uses the AVPicture API, which has been deprecated since 2017 and removed in the just released ffmpeg 5.0.

Trying to build gpac after updating ffmpeg to 5.0 results in

```
filters/ff_dec.c:127:2: error: use of undeclared identifier 'AVPicture'
        AVPicture pict;
        ^
filters/ff_dec.c:189:8: warning: implicit declaration of function 'avcodec_decode_video2' is invalid in C99 [-Wimplicit-function-declaration]
        res = avcodec_decode_video2(ctx->decoder, frame, &gotpic, &pkt);
              ^
filters/ff_dec.c:250:26: error: use of undeclared identifier 'pict'
        memset(&pict, 0, sizeof(pict));
                                ^
filters/ff_dec.c:250:10: error: use of undeclared identifier 'pict'
        memset(&pict, 0, sizeof(pict));
                ^
filters/ff_dec.c:257:48: error: no member named 'pkt_pts' in 'struct AVFrame'
                if (gf_filter_pck_get_cts(pck_src) == frame->pkt_pts) break;
                                                      ~~~~~  ^
filters/ff_dec.c:289:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:290:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = 3*ctx->width;
                ^
filters/ff_dec.c:294:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:295:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = 4*ctx->width;
                ^
filters/ff_dec.c:300:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:301:3: error: use of undeclared identifier 'pict'
                pict.data[1] =  (uint8_t *)out_buffer + ctx->stride * ctx->height;
                ^
filters/ff_dec.c:302:3: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * uv_height;
                ^
filters/ff_dec.c:302:30: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * uv_height;
                                           ^
filters/ff_dec.c:303:3: error: use of undeclared identifier 'pict'
                pict.linesize[0] = ctx->stride;
                ^
filters/ff_dec.c:304:3: error: use of undeclared identifier 'pict'
                pict.linesize[1] = pict.linesize[2] = ctx->stride_uv;
                ^
filters/ff_dec.c:304:22: error: use of undeclared identifier 'pict'
                pict.linesize[1] = pict.linesize[2] = ctx->stride_uv;
                                   ^
filters/ff_dec.c:313:3: error: use of undeclared identifier 'pict'
                pict.data[0] =  (uint8_t *)out_buffer;
                ^
filters/ff_dec.c:314:3: error: use of undeclared identifier 'pict'
                pict.data[1] =  (uint8_t *)out_buffer + ctx->stride * ctx->height;
                ^
filters/ff_dec.c:315:3: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * ctx->height;
                ^
filters/ff_dec.c:315:30: error: use of undeclared identifier 'pict'
                pict.data[2] =  (uint8_t *)pict.data[1] + ctx->stride_uv * ctx->height;
                                           ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
1 warning and 20 errors generated.
make[1]: *** [../config.mak:154: filters/ff_dec.o] Error 1
```
--- end body ---
