summaryrefslogtreecommitdiffstats
path: root/dxsdk/Include/Mpeg2Bits.h
diff options
context:
space:
mode:
authorFire-Head <Fire-Head@users.noreply.github.com>2019-06-02 05:00:38 +0200
committerFire-Head <Fire-Head@users.noreply.github.com>2019-06-02 05:00:38 +0200
commitb1f9e28cd155459ab2843690c248ed9f4767bc3f (patch)
tree8e7d2a33d4c5109ea3c3562940268afc57d0915c /dxsdk/Include/Mpeg2Bits.h
parentrw skeleton (diff)
downloadre3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar.gz
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar.bz2
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar.lz
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar.xz
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.tar.zst
re3-b1f9e28cd155459ab2843690c248ed9f4767bc3f.zip
Diffstat (limited to 'dxsdk/Include/Mpeg2Bits.h')
-rw-r--r--dxsdk/Include/Mpeg2Bits.h95
1 files changed, 95 insertions, 0 deletions
diff --git a/dxsdk/Include/Mpeg2Bits.h b/dxsdk/Include/Mpeg2Bits.h
new file mode 100644
index 00000000..45debbb6
--- /dev/null
+++ b/dxsdk/Include/Mpeg2Bits.h
@@ -0,0 +1,95 @@
+/////////////////////////////////////////////////////////////////////////////
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+//
+// Module Name:
+//
+// Mpeg2Bits.h
+//
+// Abstract:
+//
+// This file defines the MPEG-2 section header bitfields. These are
+// defined here instead of in mpegstructs.idl because of MIDL
+// compiler conflicts with bitfield definitions.
+//
+/////////////////////////////////////////////////////////////////////////////
+
+#pragma once
+
+#pragma pack(push)
+#pragma pack(1)
+
+
+//
+// PID structure
+//
+
+#ifdef __midl
+
+typedef struct
+{
+ WORD Bits;
+} PID_BITS_MIDL;
+
+#else
+
+typedef struct
+{
+ WORD Reserved : 3;
+ WORD ProgramId : 13;
+} PID_BITS, *PPID_BITS;
+
+#endif
+
+
+
+//
+// Generic MPEG packet header structure
+//
+
+#ifdef __midl
+
+typedef struct
+{
+ WORD Bits;
+} MPEG_HEADER_BITS_MIDL;
+
+#else
+
+typedef struct
+{
+ WORD SectionLength : 12;
+ WORD Reserved : 2;
+ WORD PrivateIndicator : 1;
+ WORD SectionSyntaxIndicator : 1;
+} MPEG_HEADER_BITS, *PMPEG_HEADER_BITS;
+
+#endif
+
+
+
+//
+// Long MPEG packet header structure
+//
+
+#ifdef __midl
+
+typedef struct
+{
+ BYTE Bits;
+} MPEG_HEADER_VERSION_BITS_MIDL;
+
+#else
+
+typedef struct
+{
+ BYTE CurrentNextIndicator : 1;
+ BYTE VersionNumber : 5;
+ BYTE Reserved : 2;
+} MPEG_HEADER_VERSION_BITS, *PMPEG_HEADER_VERSION_BITS;
+
+#endif
+
+
+
+#pragma pack(pop)