Mercurial > libavcodec.hg
comparison mpeg12.c @ 6992:082bb10acbd4 libavcodec
print correct mpeg-2 broken_link value, and print closed_gop
| author | bcoudurier |
|---|---|
| date | Mon, 02 Jun 2008 19:04:14 +0000 |
| parents | 213852a36370 |
| children | e943e1409077 |
comparison
equal
deleted
inserted
replaced
| 6991:3a148660d0be | 6992:082bb10acbd4 |
|---|---|
| 2154 MpegEncContext *s = &s1->mpeg_enc_ctx; | 2154 MpegEncContext *s = &s1->mpeg_enc_ctx; |
| 2155 | 2155 |
| 2156 int drop_frame_flag; | 2156 int drop_frame_flag; |
| 2157 int time_code_hours, time_code_minutes; | 2157 int time_code_hours, time_code_minutes; |
| 2158 int time_code_seconds, time_code_pictures; | 2158 int time_code_seconds, time_code_pictures; |
| 2159 int broken_link; | 2159 int closed_gop, broken_link; |
| 2160 | 2160 |
| 2161 init_get_bits(&s->gb, buf, buf_size*8); | 2161 init_get_bits(&s->gb, buf, buf_size*8); |
| 2162 | 2162 |
| 2163 drop_frame_flag = get_bits1(&s->gb); | 2163 drop_frame_flag = get_bits1(&s->gb); |
| 2164 | 2164 |
| 2166 time_code_minutes = get_bits(&s->gb,6); | 2166 time_code_minutes = get_bits(&s->gb,6); |
| 2167 skip_bits1(&s->gb);//marker bit | 2167 skip_bits1(&s->gb);//marker bit |
| 2168 time_code_seconds = get_bits(&s->gb,6); | 2168 time_code_seconds = get_bits(&s->gb,6); |
| 2169 time_code_pictures = get_bits(&s->gb,6); | 2169 time_code_pictures = get_bits(&s->gb,6); |
| 2170 | 2170 |
| 2171 closed_gop = get_bits1(&s->gb); | |
| 2171 /*broken_link indicate that after editing the | 2172 /*broken_link indicate that after editing the |
| 2172 reference frames of the first B-Frames after GOP I-Frame | 2173 reference frames of the first B-Frames after GOP I-Frame |
| 2173 are missing (open gop)*/ | 2174 are missing (open gop)*/ |
| 2174 broken_link = get_bits1(&s->gb); | 2175 broken_link = get_bits1(&s->gb); |
| 2175 | 2176 |
| 2176 if(s->avctx->debug & FF_DEBUG_PICT_INFO) | 2177 if(s->avctx->debug & FF_DEBUG_PICT_INFO) |
| 2177 av_log(s->avctx, AV_LOG_DEBUG, "GOP (%2d:%02d:%02d.[%02d]) broken_link=%d\n", | 2178 av_log(s->avctx, AV_LOG_DEBUG, "GOP (%2d:%02d:%02d.[%02d]) closed_gop=%d broken_link=%d\n", |
| 2178 time_code_hours, time_code_minutes, time_code_seconds, | 2179 time_code_hours, time_code_minutes, time_code_seconds, |
| 2179 time_code_pictures, broken_link); | 2180 time_code_pictures, closed_gop, broken_link); |
| 2180 } | 2181 } |
| 2181 /** | 2182 /** |
| 2182 * finds the end of the current frame in the bitstream. | 2183 * finds the end of the current frame in the bitstream. |
| 2183 * @return the position of the first byte of the next frame, or -1 | 2184 * @return the position of the first byte of the next frame, or -1 |
| 2184 */ | 2185 */ |
