]> granicus.if.org Git - handbrake/commitdiff
Fixing available Levels for VCE and other H265 encoders.
authorsr55 <sr55.hb@outlook.com>
Thu, 16 Aug 2018 18:44:38 +0000 (19:44 +0100)
committersr55 <sr55.hb@outlook.com>
Thu, 16 Aug 2018 18:44:38 +0000 (19:44 +0100)
libhb/common.c
libhb/vce_common.h

index ebc24b0ecf354d22933031e68c26e6e5210a0b95..e1257c930d582f8ed86c0dbdcd8bb80d6cd0ced4 100644 (file)
@@ -1504,9 +1504,9 @@ const char* const* hb_video_encoder_get_profiles(int encoder)
 
 #ifdef USE_VCE
         case HB_VCODEC_FFMPEG_VCE_H264:
-            return hb_h264_profile_names;
+            return hb_vce_h264_profile_names;
         case HB_VCODEC_FFMPEG_VCE_H265:
-            return hb_h265_profile_names;
+            return hb_vce_h265_profile_names;
 #endif
 
         case HB_VCODEC_FFMPEG_NVENC_H264:
@@ -1531,17 +1531,20 @@ const char* const* hb_video_encoder_get_levels(int encoder)
         case HB_VCODEC_X264_8BIT:
         case HB_VCODEC_X264_10BIT:
         case HB_VCODEC_FFMPEG_NVENC_H264:
-        case HB_VCODEC_FFMPEG_VCE_H264:
             return hb_h264_level_names;
-            
+
+#ifdef USE_VCE
+     case HB_VCODEC_FFMPEG_VCE_H264:
+            return hb_vce_h264_level_names; // Not quite the same as x264
+#endif
+
         case HB_VCODEC_X265_8BIT:
         case HB_VCODEC_X265_10BIT:
         case HB_VCODEC_X265_12BIT:
         case HB_VCODEC_X265_16BIT:
         case HB_VCODEC_FFMPEG_NVENC_H265:
         case HB_VCODEC_FFMPEG_VCE_H265:
-            return hb_h264_level_names;
-            
+            return hb_h265_level_names;
 
         default:
             return NULL;
index 3a6949e162606561eb6f35eb5b5f75b597326199..7d513c8dade0d1f235ba2b7710cec127a47f614d 100644 (file)
 int            hb_vce_h264_available();
 int            hb_vce_h265_available();
 
-static const char * const hb_h264_profile_names[]  = { "baseline", "main", "high",  NULL, };
-static const char * const hb_h265_profile_names[]  = { "main", NULL, };
\ No newline at end of file
+static const char * const hb_vce_h264_profile_names[] = { "baseline", "main", "high",  NULL, };
+static const char * const hb_vce_h265_profile_names[] = { "main", NULL, };
+
+static const char * const hb_vce_h264_level_names[] = 
+{
+    "auto", "1.0", "1.1", "1.2", "1.3", "2.0", "2.1", "2.2", "3.0",
+    "3.1", "3.2", "4.0", "4.1", "4.2", "5.0", "5.1", "5.2",  NULL,
+};