mirror of
https://github.com/Genymobile/scrcpy.git
synced 2026-04-21 01:33:36 +00:00
Expose decoder as packet sink
Make decoder implement the packet sink trait. This will allow the stream to push packets without depending on the concrete sink type.
This commit is contained in:
parent
db418d0825
commit
c64f5ff71e
2 changed files with 33 additions and 0 deletions
|
|
@ -3,12 +3,16 @@
|
|||
|
||||
#include "common.h"
|
||||
|
||||
#include "trait/packet_sink.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <libavformat/avformat.h>
|
||||
|
||||
struct video_buffer;
|
||||
|
||||
struct decoder {
|
||||
struct sc_packet_sink packet_sink; // packet sink trait
|
||||
|
||||
struct video_buffer *video_buffer;
|
||||
|
||||
AVCodecContext *codec_ctx;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue