[mythtv-commits] Ticket #13186: Replace deprecated ffmpeg functions

MythTV noreply at mythtv.org
Mon Dec 4 20:27:43 UTC 2017

#13186: Replace deprecated ffmpeg functions
 Reporter:  pbennett          |          Owner:  pbennett
     Type:  Developer Task    |         Status:  accepted
 Priority:  minor             |      Milestone:  30.0
Component:  MythTV - General  |        Version:  Master Head
 Severity:  medium            |     Resolution:
 Keywords:                    |  Ticket locked:  0

Comment (by pbennett):

 Patch 004 - fix deprecated calls to avcodec_decode_video2

 Now that avcodec_decode_video2 is deprecated and replaced
 by 2 calls (receive frame and send packet), this could be optimized
 into separate routines or separate threads.
 Also now that it always consumes a whole buffer some code
 in the caller may be able to be optimized.

 avcodec_decode_video2 calls become
 * avcodec_receive_frame
 * avcodec_send_packet

 The code assumes that there is always space to add a new packet. This
 seems risky but has always worked. It should actually check if (ret ==
 AVERROR(EAGAIN)) and then keep the packet around and try it again after
 processing the frame received here.

Ticket URL: <https://code.mythtv.org/trac/ticket/13186#comment:4>
MythTV <http://www.mythtv.org>
MythTV Media Center

More information about the mythtv-commits mailing list