summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2019-05-16 16:20:45 +0200
committerwm4 <wm4@nowhere>2019-09-19 20:37:04 +0200
commitd7c7f80cc1cf5b6a8207a3954ccdc984316c0602 (patch)
tree6d4d9d091ed9da765ada3b291123844be28ee581
parent075111c4d2674dc7b9c4dbee9e23ed08d112e7ac (diff)
downloadmpv-d7c7f80cc1cf5b6a8207a3954ccdc984316c0602.tar.bz2
mpv-d7c7f80cc1cf5b6a8207a3954ccdc984316c0602.tar.xz
packet: reorder fields
Saves 8 bytes on 64 bit platforms.
-rw-r--r--demux/packet.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/demux/packet.h b/demux/packet.h
index 7c5b04720f..a5df6ce121 100644
--- a/demux/packet.h
+++ b/demux/packet.h
@@ -24,17 +24,18 @@
// Holds one packet/frame/whatever
typedef struct demux_packet {
- int len;
- unsigned char *buffer;
-
double pts;
double dts;
double duration;
- bool keyframe;
-
int64_t pos; // position in source file byte stream
+
+ unsigned char *buffer;
+ int len;
+
int stream; // source stream index (typically sh_stream.index)
+ bool keyframe;
+
// segmentation (ordered chapters, EDL)
bool segmented;
struct mp_codec_params *codec; // set to non-NULL iff segmented is set