[x265] [PATCH 1 of 9] api: remove reserved NAL enums and C++ style comments from public header

Steve Borho steve at borho.org
Tue Nov 19 08:41:12 CET 2013


# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1384824695 21600
#      Mon Nov 18 19:31:35 2013 -0600
# Node ID 85f3089367c11655b4e23c8a2dc6232a6d4934ed
# Parent  2f5f538d2cbca3b46e8d27d860e9787cc19f406f
api: remove reserved NAL enums and C++ style comments from public header

diff -r 2f5f538d2cbc -r 85f3089367c1 source/x265.h
--- a/source/x265.h	Mon Nov 18 16:44:31 2013 -0600
+++ b/source/x265.h	Mon Nov 18 19:31:35 2013 -0600
@@ -35,84 +35,34 @@
  *      opaque handler for encoder */
 typedef struct x265_encoder x265_encoder;
 
-// TODO: Existing names used for the different NAL unit types can be altered to better reflect the names in the spec.
-//       However, the names in the spec are not yet stable at this point. Once the names are stable, a cleanup
-//       effort can be done without use of macros to alter the names used to indicate the different NAL unit types.
 typedef enum
 {
-    NAL_UNIT_CODED_SLICE_TRAIL_N = 0, // 0
-    NAL_UNIT_CODED_SLICE_TRAIL_R,   // 1
-
-    NAL_UNIT_CODED_SLICE_TSA_N,     // 2
-    NAL_UNIT_CODED_SLICE_TLA_R,     // 3
-
-    NAL_UNIT_CODED_SLICE_STSA_N,    // 4
-    NAL_UNIT_CODED_SLICE_STSA_R,    // 5
-
-    NAL_UNIT_CODED_SLICE_RADL_N,    // 6
-    NAL_UNIT_CODED_SLICE_RADL_R,    // 7
-
-    NAL_UNIT_CODED_SLICE_RASL_N,    // 8
-    NAL_UNIT_CODED_SLICE_RASL_R,    // 9
-
-    NAL_UNIT_RESERVED_VCL_N10,
-    NAL_UNIT_RESERVED_VCL_R11,
-    NAL_UNIT_RESERVED_VCL_N12,
-    NAL_UNIT_RESERVED_VCL_R13,
-    NAL_UNIT_RESERVED_VCL_N14,
-    NAL_UNIT_RESERVED_VCL_R15,
-
-    NAL_UNIT_CODED_SLICE_BLA_W_LP,  // 16
-    NAL_UNIT_CODED_SLICE_BLA_W_RADL, // 17
-    NAL_UNIT_CODED_SLICE_BLA_N_LP,  // 18
-    NAL_UNIT_CODED_SLICE_IDR_W_RADL, // 19
-    NAL_UNIT_CODED_SLICE_IDR_N_LP,  // 20
-    NAL_UNIT_CODED_SLICE_CRA,       // 21
-    NAL_UNIT_RESERVED_IRAP_VCL22,
-    NAL_UNIT_RESERVED_IRAP_VCL23,
-
-    NAL_UNIT_RESERVED_VCL24,
-    NAL_UNIT_RESERVED_VCL25,
-    NAL_UNIT_RESERVED_VCL26,
-    NAL_UNIT_RESERVED_VCL27,
-    NAL_UNIT_RESERVED_VCL28,
-    NAL_UNIT_RESERVED_VCL29,
-    NAL_UNIT_RESERVED_VCL30,
-    NAL_UNIT_RESERVED_VCL31,
-
-    NAL_UNIT_VPS,                   // 32
-    NAL_UNIT_SPS,                   // 33
-    NAL_UNIT_PPS,                   // 34
-    NAL_UNIT_ACCESS_UNIT_DELIMITER, // 35
-    NAL_UNIT_EOS,                   // 36
-    NAL_UNIT_EOB,                   // 37
-    NAL_UNIT_FILLER_DATA,           // 38
-    NAL_UNIT_PREFIX_SEI,            // 39
-    NAL_UNIT_SUFFIX_SEI,            // 40
-    NAL_UNIT_RESERVED_NVCL41,
-    NAL_UNIT_RESERVED_NVCL42,
-    NAL_UNIT_RESERVED_NVCL43,
-    NAL_UNIT_RESERVED_NVCL44,
-    NAL_UNIT_RESERVED_NVCL45,
-    NAL_UNIT_RESERVED_NVCL46,
-    NAL_UNIT_RESERVED_NVCL47,
-    NAL_UNIT_UNSPECIFIED_48,
-    NAL_UNIT_UNSPECIFIED_49,
-    NAL_UNIT_UNSPECIFIED_50,
-    NAL_UNIT_UNSPECIFIED_51,
-    NAL_UNIT_UNSPECIFIED_52,
-    NAL_UNIT_UNSPECIFIED_53,
-    NAL_UNIT_UNSPECIFIED_54,
-    NAL_UNIT_UNSPECIFIED_55,
-    NAL_UNIT_UNSPECIFIED_56,
-    NAL_UNIT_UNSPECIFIED_57,
-    NAL_UNIT_UNSPECIFIED_58,
-    NAL_UNIT_UNSPECIFIED_59,
-    NAL_UNIT_UNSPECIFIED_60,
-    NAL_UNIT_UNSPECIFIED_61,
-    NAL_UNIT_UNSPECIFIED_62,
-    NAL_UNIT_UNSPECIFIED_63,
-    NAL_UNIT_INVALID,
+    NAL_UNIT_CODED_SLICE_TRAIL_N = 0,
+    NAL_UNIT_CODED_SLICE_TRAIL_R,
+    NAL_UNIT_CODED_SLICE_TSA_N,
+    NAL_UNIT_CODED_SLICE_TLA_R,
+    NAL_UNIT_CODED_SLICE_STSA_N,
+    NAL_UNIT_CODED_SLICE_STSA_R,
+    NAL_UNIT_CODED_SLICE_RADL_N,
+    NAL_UNIT_CODED_SLICE_RADL_R,
+    NAL_UNIT_CODED_SLICE_RASL_N,
+    NAL_UNIT_CODED_SLICE_RASL_R,
+    NAL_UNIT_CODED_SLICE_BLA_W_LP = 16,
+    NAL_UNIT_CODED_SLICE_BLA_W_RADL,
+    NAL_UNIT_CODED_SLICE_BLA_N_LP,
+    NAL_UNIT_CODED_SLICE_IDR_W_RADL,
+    NAL_UNIT_CODED_SLICE_IDR_N_LP,
+    NAL_UNIT_CODED_SLICE_CRA,
+    NAL_UNIT_VPS = 32,
+    NAL_UNIT_SPS,
+    NAL_UNIT_PPS,
+    NAL_UNIT_ACCESS_UNIT_DELIMITER,
+    NAL_UNIT_EOS,
+    NAL_UNIT_EOB,
+    NAL_UNIT_FILLER_DATA,
+    NAL_UNIT_PREFIX_SEI,
+    NAL_UNIT_SUFFIX_SEI,
+    NAL_UNIT_INVALID = 64,
 } NalUnitType;
 
 /* The data within the payload is already NAL-encapsulated; the type


More information about the x265-devel mailing list