| 1957 | #endif /* !HAVE_THREADS */ |
| 1958 | |
| 1959 | static av_cold int progress_frame_pool_init_cb(AVRefStructOpaque opaque, void *obj) |
| 1960 | { |
| 1961 | const AVCodecContext *avctx = opaque.nc; |
| 1962 | ProgressInternal *progress = obj; |
| 1963 | int ret; |
| 1964 | |
| 1965 | ret = ff_thread_progress_init(&progress->progress, avctx->active_thread_type & FF_THREAD_FRAME); |
| 1966 | if (ret < 0) |
| 1967 | return ret; |
| 1968 | |
| 1969 | progress->f = av_frame_alloc(); |
| 1970 | if (!progress->f) |
| 1971 | return AVERROR(ENOMEM); |
| 1972 | |
| 1973 | return 0; |
| 1974 | } |
| 1975 | |
| 1976 | static void progress_frame_pool_reset_cb(AVRefStructOpaque unused, void *obj) |
| 1977 | { |
nothing calls this directly
no test coverage detected