@@ -841,9 +841,9 @@ void fill_sps_header(struct SeqParamSet *sps, int id)
841
841
sps -> log2_min_luma_transform_block_size_minus2 ) : 3 ;
842
842
sps -> max_transform_hierarchy_depth_inter = use_block_sizes ? block_sizes .max_max_transform_hierarchy_depth_inter : 2 ;
843
843
sps -> max_transform_hierarchy_depth_intra = use_block_sizes ? block_sizes .max_max_transform_hierarchy_depth_intra : 2 ;
844
- sps -> scaling_list_enabled_flag = use_features ? features . scaling_lists : 0 ;
845
- sps -> sps_scaling_list_data_present_flag = 0 ;
846
- sps -> amp_enabled_flag = use_features ? features .amp : 1 ;
844
+ sps -> scaling_list_enabled_flag = 0 ;
845
+ // sps->sps_scaling_list_data_present_flag; // ignore since scaling_list_enabled_flag equal to 0
846
+ sps -> amp_enabled_flag = use_features ? features .amp >= 1 : 1 ;
847
847
sps -> sample_adaptive_offset_enabled_flag = use_features ? features .sao : 1 ;
848
848
sps -> pcm_enabled_flag = use_features ? features .pcm : 0 ;
849
849
/* ignore below parameters seting since pcm_enabled_flag equal to 0
@@ -899,7 +899,7 @@ static void fill_pps_header(
899
899
pps -> init_qp_minus26 = initial_qp - 26 ;
900
900
pps -> constrained_intra_pred_flag = use_features ? features .constrained_intra_pred : 0 ;
901
901
pps -> transform_skip_enabled_flag = use_features ? features .transform_skip : 0 ;
902
- pps -> cu_qp_delta_enabled_flag = use_features ? features .cu_qp_delta : 1 ;
902
+ pps -> cu_qp_delta_enabled_flag = use_features ? features .cu_qp_delta >= 1 : 1 ;
903
903
if (pps -> cu_qp_delta_enabled_flag )
904
904
pps -> diff_cu_qp_delta_depth = 2 ;
905
905
pps -> pps_cb_qp_offset = 0 ;
@@ -1986,6 +1986,7 @@ static int init_va(void)
1986
1986
VAEntrypoint * entrypoints ;
1987
1987
int num_entrypoints , slice_entrypoint ;
1988
1988
int support_encode = 0 ;
1989
+ int support_lpEntryPoint = 0 ;
1989
1990
int major_ver , minor_ver ;
1990
1991
VAStatus va_status ;
1991
1992
unsigned int i ;
@@ -2009,10 +2010,12 @@ static int init_va(void)
2009
2010
hevc_profile = profile_list [i ];
2010
2011
vaQueryConfigEntrypoints (va_dpy , hevc_profile , entrypoints , & num_entrypoints );
2011
2012
for (slice_entrypoint = 0 ; slice_entrypoint < num_entrypoints ; slice_entrypoint ++ ) {
2012
- if (entrypoints [slice_entrypoint ] == VAEntrypointEncSlice ||
2013
- entrypoints [slice_entrypoint ] == VAEntrypointEncSliceLP ) {
2013
+ if (entrypoints [slice_entrypoint ] == VAEntrypointEncSlice ) {
2014
2014
support_encode = 1 ;
2015
- break ;
2015
+ }
2016
+ else if (entrypoints [slice_entrypoint ] == VAEntrypointEncSliceLP ) {
2017
+ support_encode = 1 ;
2018
+ support_lpEntryPoint = 1 ;
2016
2019
}
2017
2020
}
2018
2021
if (support_encode == 1 )
@@ -2048,8 +2051,10 @@ static int init_va(void)
2048
2051
2049
2052
if (lowpower )
2050
2053
{
2051
- entryPoint = VAEntrypointEncSliceLP ;
2052
2054
LCU_SIZE = 64 ;
2055
+ if (support_lpEntryPoint == 1 ) {
2056
+ entryPoint = VAEntrypointEncSliceLP ;
2057
+ }
2053
2058
}
2054
2059
2055
2060
va_status = vaGetConfigAttributes (va_dpy , hevc_profile , entryPoint ,
0 commit comments