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

Function amf_update_buffer_properties

libavcodec/amfdec.c:512–524  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

510}
511
512static AMF_RESULT amf_update_buffer_properties(AVCodecContext *avctx, AMFBuffer* buffer, const AVPacket* pkt)
513{
514 AMF_RESULT res;
515
516 AMF_RETURN_IF_FALSE(avctx, buffer != NULL, AMF_INVALID_ARG, "update_buffer_properties() - buffer not passed in");
517 AMF_RETURN_IF_FALSE(avctx, pkt != NULL, AMF_INVALID_ARG, "update_buffer_properties() - packet not passed in");
518 buffer->pVtbl->SetPts(buffer, pkt->pts);
519 buffer->pVtbl->SetDuration(buffer, pkt->duration);
520 AMF_ASSIGN_PROPERTY_INT64(res, buffer, L"FFMPEG:dts", pkt->dts);
521 if (res != AMF_OK)
522 av_log(avctx, AV_LOG_VERBOSE, "Failed to assign dts value.");
523 return AMF_OK;
524}
525
526static AMF_RESULT amf_buffer_from_packet(AVCodecContext *avctx, const AVPacket* pkt, AMFBuffer** buffer)
527{

Callers 1

amf_buffer_from_packetFunction · 0.85

Calls 1

av_logFunction · 0.85

Tested by

no test coverage detected