mirror of
https://github.com/ultravideo/uvg266.git
synced 2024-11-24 10:34:05 +00:00
Changed intra to use best rough cost when using inter and rd=2
This commit is contained in:
parent
33ce101ab5
commit
9f605152ae
|
@ -836,7 +836,7 @@ void kvz_search_cu_intra(encoder_state_t * const state,
|
||||||
|
|
||||||
// Set transform depth to current depth, meaning no transform splits.
|
// Set transform depth to current depth, meaning no transform splits.
|
||||||
kvz_lcu_set_trdepth(lcu, x_px, y_px, depth, depth);
|
kvz_lcu_set_trdepth(lcu, x_px, y_px, depth, depth);
|
||||||
|
double best_rough_cost = costs[select_best_mode_index(modes, costs, number_of_modes)];
|
||||||
// Refine results with slower search or get some results if rough search was skipped.
|
// Refine results with slower search or get some results if rough search was skipped.
|
||||||
const int32_t rdo_level = state->encoder_control->cfg.rdo;
|
const int32_t rdo_level = state->encoder_control->cfg.rdo;
|
||||||
if (rdo_level >= 2 || skip_rough_search) {
|
if (rdo_level >= 2 || skip_rough_search) {
|
||||||
|
@ -863,5 +863,5 @@ void kvz_search_cu_intra(encoder_state_t * const state,
|
||||||
uint8_t best_mode_i = select_best_mode_index(modes, costs, number_of_modes);
|
uint8_t best_mode_i = select_best_mode_index(modes, costs, number_of_modes);
|
||||||
|
|
||||||
*mode_out = modes[best_mode_i];
|
*mode_out = modes[best_mode_i];
|
||||||
*cost_out = costs[best_mode_i];
|
*cost_out = best_rough_cost;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue