summaryrefslogtreecommitdiffstats
path: root/demux/packet.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-07-05 16:45:28 +0200
committerwm4 <wm4@nowhere>2014-07-05 17:07:14 +0200
commita97256c1d58fae714ae94301ab09044081d08c8e (patch)
treeece20e0f51153ea2266490dad64163ee91d3c006 /demux/packet.h
parente4221f318936aa970eeb1d220d8deae95fb91d98 (diff)
downloadmpv-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.h9
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 */