Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 1 | /* |
Adrian Grange | ee9843d | 2016-03-24 12:08:51 -0700 | [diff] [blame] | 2 | * Copyright (c) 2016, Alliance for Open Media. All rights reserved |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 3 | * |
Adrian Grange | ee9843d | 2016-03-24 12:08:51 -0700 | [diff] [blame] | 4 | * This source code is subject to the terms of the BSD 2 Clause License and |
| 5 | * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License |
| 6 | * was not distributed with this source code in the LICENSE file, you can |
| 7 | * obtain it at www.aomedia.org/license/software. If the Alliance for Open |
| 8 | * Media Patent License 1.0 was not distributed with this source code in the |
| 9 | * PATENTS file, you can obtain it at www.aomedia.org/license/patent. |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 10 | */ |
| 11 | |
Yaowu Xu | 01dee0b | 2016-03-25 12:43:01 -0700 | [diff] [blame] | 12 | #ifndef AV1_ENCODER_BITSTREAM_H_ |
| 13 | #define AV1_ENCODER_BITSTREAM_H_ |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 14 | |
| 15 | #ifdef __cplusplus |
| 16 | extern "C" { |
| 17 | #endif |
| 18 | |
Yaowu Xu | cfea7dd | 2016-03-22 09:52:13 -0700 | [diff] [blame] | 19 | #include "av1/encoder/encoder.h" |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 20 | |
Yaowu Xu | 01dee0b | 2016-03-25 12:43:01 -0700 | [diff] [blame] | 21 | void av1_encode_token_init(); |
| 22 | void av1_pack_bitstream(AV1_COMP *const cpi, uint8_t *dest, size_t *size); |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 23 | |
Yaowu Xu | 01dee0b | 2016-03-25 12:43:01 -0700 | [diff] [blame] | 24 | static INLINE int av1_preserve_existing_gf(AV1_COMP *cpi) { |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 25 | return !cpi->multi_arf_allowed && cpi->refresh_golden_frame && |
Yunqing Wang | c147c4d | 2015-08-27 15:11:38 -0700 | [diff] [blame] | 26 | cpi->rc.is_src_frame_alt_ref; |
Jingning Han | 3ee6db6 | 2015-08-05 19:00:31 -0700 | [diff] [blame] | 27 | } |
| 28 | |
| 29 | #ifdef __cplusplus |
| 30 | } // extern "C" |
| 31 | #endif |
| 32 | |
Yaowu Xu | 01dee0b | 2016-03-25 12:43:01 -0700 | [diff] [blame] | 33 | #endif // AV1_ENCODER_BITSTREAM_H_ |