libbluray
clpi_data.h
Go to the documentation of this file.
1 /*
2  * This file is part of libbluray
3  * Copyright (C) 2009-2010 John Stebbins
4  * Copyright (C) 2012-2013 Petri Hintukainen <phintuka@users.sourceforge.net>
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library. If not, see
18  * <http://www.gnu.org/licenses/>.
19  */
20 
26 #if !defined(_CLPI_DATA_H_)
27 #define _CLPI_DATA_H_
28 
29 #include <stdint.h>
30 
31 typedef struct
32 {
33  uint16_t pcr_pid;
34  uint32_t spn_stc_start;
35  uint32_t presentation_start_time;
36  uint32_t presentation_end_time;
37 } CLPI_STC_SEQ;
38 
39 typedef struct
40 {
41  uint32_t spn_atc_start;
42  uint8_t num_stc_seq;
43  uint8_t offset_stc_id;
44  CLPI_STC_SEQ *stc_seq;
45 } CLPI_ATC_SEQ;
46 
47 typedef struct
48 {
49  uint8_t num_atc_seq;
50  CLPI_ATC_SEQ *atc_seq;
52 
53 typedef struct
54 {
55  uint8_t validity;
56  char format_id[5];
57 } CLPI_TS_TYPE;
58 
59 typedef struct
60 {
61  uint32_t delta;
62  char file_id[6];
63  char file_code[5];
65 
66 typedef struct {
67  char file_id[6];
68 } CLPI_FONT;
69 
70 typedef struct {
71  uint8_t font_count;
72  CLPI_FONT *font;
74 
75 typedef struct
76 {
77  uint8_t clip_stream_type;
78  uint8_t application_type;
79  uint8_t is_atc_delta;
80  uint32_t ts_recording_rate;
81  uint32_t num_source_packets;
82  CLPI_TS_TYPE ts_type_info;
83  uint8_t atc_delta_count;
84  CLPI_ATC_DELTA *atc_delta;
85  CLPI_FONT_INFO font_info; /* Text subtitle stream font files */
87 
88 typedef struct
89 {
90  uint16_t pid;
91  uint8_t coding_type;
92  uint8_t format;
93  uint8_t rate;
94  uint8_t aspect;
95  uint8_t oc_flag;
96  uint8_t char_code;
97  char lang[4];
98  uint8_t cr_flag;
99  uint8_t dynamic_range_type;
100  uint8_t color_space;
101  uint8_t hdr_plus_flag;
102  uint8_t isrc[12]; /* International Standard Recording Code (usually empty or all zeroes) */
104 
105 typedef struct
106 {
107  uint32_t spn_program_sequence_start;
108  uint16_t program_map_pid;
109  uint8_t num_streams;
110  uint8_t num_groups;
111  CLPI_PROG_STREAM *streams;
112 } CLPI_PROG;
113 
114 typedef struct
115 {
116  uint8_t num_prog;
117  CLPI_PROG *progs;
119 
120 typedef struct
121 {
122  int ref_ep_fine_id;
123  int pts_ep;
124  uint32_t spn_ep;
126 
127 typedef struct
128 {
129  uint8_t is_angle_change_point;
130  uint8_t i_end_position_offset;
131  int pts_ep;
132  int spn_ep;
133 } CLPI_EP_FINE;
134 
135 typedef struct
136 {
137  uint16_t pid;
138  uint8_t ep_stream_type;
139  int num_ep_coarse;
140  int num_ep_fine;
141  uint32_t ep_map_stream_start_addr;
142  CLPI_EP_COARSE *coarse;
143  CLPI_EP_FINE *fine;
145 
146 typedef struct
147 {
148  uint8_t type;
149  // ep_map
150  uint8_t num_stream_pid;
151  CLPI_EP_MAP_ENTRY *entry;
152 } CLPI_CPI;
153 
154 /* Extent start points (profile 5 / version 2.4) */
155 typedef struct {
156  uint32_t num_point;
157  uint32_t *point;
159 
160 typedef struct clpi_cl {
161  uint32_t type_indicator;
162  uint32_t type_indicator2;
163  uint32_t sequence_info_start_addr;
164  uint32_t program_info_start_addr;
165  uint32_t cpi_start_addr;
166  uint32_t clip_mark_start_addr;
167  uint32_t ext_data_start_addr;
168  CLPI_CLIP_INFO clip;
169  CLPI_SEQ_INFO sequence;
170  CLPI_PROG_INFO program;
171  CLPI_CPI cpi;
172  // skip clip mark & extension data
173 
174  // extensions for 3D
175 
176  CLPI_EXTENT_START extent_start; /* extent start points (.ssif interleaving) */
177  CLPI_PROG_INFO program_ss;
178  CLPI_CPI cpi_ss;
179 } CLPI_CL;
180 
181 #endif // _CLPI_DATA_H_
Definition: clpi_data.h:59
Definition: clpi_data.h:31
Definition: clpi_data.h:160
Definition: clpi_data.h:127
Definition: clpi_data.h:70
Definition: clpi_data.h:135
Definition: clpi_data.h:75
Definition: clpi_data.h:88
Definition: clpi_data.h:66
Definition: clpi_data.h:53
Definition: clpi_data.h:155
Definition: clpi_data.h:114
Definition: clpi_data.h:105
Definition: clpi_data.h:120
Definition: clpi_data.h:39
Definition: clpi_data.h:146
Definition: clpi_data.h:47