TUT HEVC Encoder
Loading...
Searching...
No Matches
rate_control.h
Go to the documentation of this file.
1#ifndef RATE_CONTROL_H_
2#define RATE_CONTROL_H_
3/*****************************************************************************
4 * This file is part of Kvazaar HEVC encoder.
5 *
6 * Copyright (c) 2021, Tampere University, ITU/ISO/IEC, project contributors
7 * All rights reserved.
8 *
9 * Redistribution and use in source and binary forms, with or without modification,
10 * are permitted provided that the following conditions are met:
11 *
12 * * Redistributions of source code must retain the above copyright notice, this
13 * list of conditions and the following disclaimer.
14 *
15 * * Redistributions in binary form must reproduce the above copyright notice, this
16 * list of conditions and the following disclaimer in the documentation and/or
17 * other materials provided with the distribution.
18 *
19 * * Neither the name of the Tampere University or ITU/ISO/IEC nor the names of its
20 * contributors may be used to endorse or promote products derived from
21 * this software without specific prior written permission.
22 *
23 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
24 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
25 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
26 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
27 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
28 * INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
29 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION HOWEVER CAUSED AND ON
30 * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
31 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 * INCLUDING NEGLIGENCE OR OTHERWISE ARISING IN ANY WAY OUT OF THE USE OF THIS
33 ****************************************************************************/
34
41#include "global.h" // IWYU pragma: keep
42
43#include "encoderstate.h"
44#include "pthread.h"
45
66
67kvz_rc_data * kvz_get_rc_data(const encoder_control_t * const encoder);
68void kvz_free_rc_data();
69
71
73 vector2d_t pos);
74
75void kvz_set_ctu_qp_lambda(encoder_state_t * const state, vector2d_t pos);
78
79#endif // RATE_CONTROL_H_
Top level of the encoder implementation.
Header that is included in every other header.
#define KVZ_MAX_GOP_LAYERS
Maximum amount of GoP layers.
Definition kvazaar.h:83
void kvz_set_lcu_lambda_and_qp(encoder_state_t *const state, vector2d_t pos)
Definition rate_control.c:1082
struct kvz_rc_data kvz_rc_data
void kvz_set_ctu_qp_lambda(encoder_state_t *const state, vector2d_t pos)
Definition rate_control.c:693
void kvz_set_picture_lambda_and_qp(encoder_state_t *const state)
Allocate bits and set lambda and QP for the current picture.
Definition rate_control.c:1012
void kvz_update_after_picture(encoder_state_t *const state)
Definition rate_control.c:904
void kvz_free_rc_data()
Definition rate_control.c:121
void kvz_estimate_pic_lambda(encoder_state_t *const state)
Definition rate_control.c:492
kvz_rc_data * kvz_get_rc_data(const encoder_control_t *const encoder)
Definition rate_control.c:63
Definition encoder.h:49
Definition encoderstate.h:274
Definition rate_control.h:46
double * k_para[6]
Definition rate_control.h:48
double * intra_dis
Definition rate_control.h:54
pthread_mutex_t ck_frame_lock
Definition rate_control.h:62
pthread_mutex_t intra_lock
Definition rate_control.h:64
double * intra_bpp
Definition rate_control.h:53
double intra_pic_distortion
Definition rate_control.h:55
double intra_beta
Definition rate_control.h:59
double pic_c_para[6]
Definition rate_control.h:49
double previous_lambdas[6+1]
Definition rate_control.h:51
pthread_rwlock_t ck_ctu_lock[6]
Definition rate_control.h:61
double pic_k_para[6]
Definition rate_control.h:50
double intra_alpha
Definition rate_control.h:58
double previous_frame_lambda
Definition rate_control.h:52
pthread_mutex_t lambda_lock
Definition rate_control.h:63
double intra_pic_bpp
Definition rate_control.h:56
double * c_para[6]
Definition rate_control.h:47
Definition cu.h:121