MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / decode_frame

Function decode_frame

libavcodec/libvpxdec.c:216–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

214}
215
216static int decode_frame(AVCodecContext *avctx, vpx_codec_ctx_t *decoder,
217 const uint8_t *data, uint32_t data_sz)
218{
219 if (vpx_codec_decode(decoder, data, data_sz, NULL, 0) != VPX_CODEC_OK) {
220 const char *error = vpx_codec_error(decoder);
221 const char *detail = vpx_codec_error_detail(decoder);
222
223 av_log(avctx, AV_LOG_ERROR, "Failed to decode frame: %s\n", error);
224 if (detail) {
225 av_log(avctx, AV_LOG_ERROR, " Additional information: %s\n",
226 detail);
227 }
228 return AVERROR_INVALIDDATA;
229 }
230 return 0;
231}
232
233static int vpx_decode(AVCodecContext *avctx, AVFrame *picture,
234 int *got_frame, AVPacket *avpkt)

Callers 1

vpx_decodeFunction · 0.70

Calls 1

av_logFunction · 0.85

Tested by

no test coverage detected