1 /****************************************************************************** 2 * 3 * Copyright (C) 2015 The Android Open Source Project 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); 6 * you may not use this file except in compliance with the License. 7 * You may obtain a copy of the License at: 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 * 17 ***************************************************************************** 18 * Originally developed and contributed by Ittiam Systems Pvt. Ltd, Bangalore 19 */ 20 21 /*****************************************************************************/ 22 /* */ 23 /* File Name : ih264d_vui.h */ 24 /* */ 25 /* Description : This file contains routines to parse SEI NAL's */ 26 /* */ 27 /* List of Functions : <List the functions defined in this file> */ 28 /* */ 29 /* Issues / Problems : None */ 30 /* */ 31 /* Revision History : */ 32 /* */ 33 /* DD MM YYYY Author(s) Changes (Describe the changes made) */ 34 /* 25 05 2005 NS Draft */ 35 /* */ 36 /*****************************************************************************/ 37 38 #ifndef _IH264D_VUI_H_ 39 #define _IH264D_VUI_H_ 40 41 #include "ih264_typedefs.h" 42 #include "ih264_macros.h" 43 #include "ih264_platform_macros.h" 44 #include "ih264d_bitstrm.h" 45 46 #define VUI_EXTENDED_SAR 255 47 48 typedef struct 49 { 50 UWORD32 u4_cpb_cnt; 51 UWORD8 u1_bit_rate_scale; 52 UWORD8 u1_cpb_size_scale; 53 UWORD32 u4_bit_rate[32]; 54 UWORD32 u4_cpb_size[32]; 55 UWORD8 u1_cbr_flag[32]; 56 UWORD8 u1_initial_cpb_removal_delay; 57 UWORD8 u1_cpb_removal_delay_length; 58 UWORD8 u1_dpb_output_delay_length; 59 UWORD8 u1_time_offset_length; 60 } hrd_t; 61 62 typedef struct 63 { 64 UWORD8 u1_aspect_ratio_idc; 65 UWORD16 u2_sar_width; 66 UWORD16 u2_sar_height; 67 UWORD8 u1_overscan_appropriate_flag; 68 UWORD8 u1_video_format; 69 UWORD8 u1_video_full_range_flag; 70 UWORD8 u1_colour_primaries; 71 UWORD8 u1_tfr_chars; 72 UWORD8 u1_matrix_coeffs; 73 UWORD8 u1_cr_top_field; 74 UWORD8 u1_cr_bottom_field; 75 UWORD32 u4_num_units_in_tick; 76 UWORD32 u4_time_scale; 77 UWORD8 u1_fixed_frame_rate_flag; 78 UWORD8 u1_nal_hrd_params_present; 79 hrd_t s_nal_hrd; 80 UWORD8 u1_vcl_hrd_params_present; 81 hrd_t s_vcl_hrd; 82 UWORD8 u1_low_delay_hrd_flag; 83 UWORD8 u1_pic_struct_present_flag; 84 UWORD8 u1_bitstream_restriction_flag; 85 UWORD8 u1_mv_over_pic_boundaries_flag; 86 UWORD32 u4_max_bytes_per_pic_denom; 87 UWORD32 u4_max_bits_per_mb_denom; 88 UWORD32 u4_log2_max_mv_length_horz; 89 UWORD32 u4_log2_max_mv_length_vert; 90 UWORD32 u4_num_reorder_frames; 91 UWORD32 u4_max_dec_frame_buffering; 92 } vui_t; 93 94 WORD32 ih264d_parse_vui_parametres(vui_t *ps_vu4, 95 dec_bit_stream_t *ps_bitstrm); 96 #endif /* _SEI_H_ */ 97 98