diff options
author | wm4 <wm4@nowhere> | 2014-07-05 16:45:28 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-07-05 17:07:14 +0200 |
commit | a97256c1d58fae714ae94301ab09044081d08c8e (patch) | |
tree | ece20e0f51153ea2266490dad64163ee91d3c006 /demux/packet.h | |
parent | e4221f318936aa970eeb1d220d8deae95fb91d98 (diff) | |
download | mpv-a97256c1d58fae714ae94301ab09044081d08c8e.tar.bz2 mpv-a97256c1d58fae714ae94301ab09044081d08c8e.tar.xz |
demux: move packet functions to a separate source file
Diffstat (limited to 'demux/packet.h')
-rw-r--r-- | demux/packet.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/demux/packet.h b/demux/packet.h index ca57179acb..e6cfafb5ee 100644 --- a/demux/packet.h +++ b/demux/packet.h @@ -20,6 +20,7 @@ #define MPLAYER_DEMUX_PACKET_H #include <stdbool.h> +#include <stddef.h> #include <inttypes.h> // Holds one packet/frame/whatever @@ -38,4 +39,12 @@ typedef struct demux_packet { struct AVPacket *avpacket; // original libavformat packet (demux_lavf) } demux_packet_t; +struct demux_packet *new_demux_packet(size_t len); +// data must already have suitable padding +struct demux_packet *new_demux_packet_fromdata(void *data, size_t len); +struct demux_packet *new_demux_packet_from(void *data, size_t len); +void demux_packet_shorten(struct demux_packet *dp, size_t len); +void free_demux_packet(struct demux_packet *dp); +struct demux_packet *demux_copy_packet(struct demux_packet *dp); + #endif /* MPLAYER_DEMUX_PACKET_H */ |