| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Matroska muxer | 2  * Matroska muxer | 
| 3  * Copyright (c) 2007 David Conrad | 3  * Copyright (c) 2007 David Conrad | 
| 4  * | 4  * | 
| 5  * This file is part of FFmpeg. | 5  * This file is part of FFmpeg. | 
| 6  * | 6  * | 
| 7  * FFmpeg is free software; you can redistribute it and/or | 7  * FFmpeg is free software; you can redistribute it and/or | 
| 8  * modify it under the terms of the GNU Lesser General Public | 8  * modify it under the terms of the GNU Lesser General Public | 
| 9  * License as published by the Free Software Foundation; either | 9  * License as published by the Free Software Foundation; either | 
| 10  * version 2.1 of the License, or (at your option) any later version. | 10  * version 2.1 of the License, or (at your option) any later version. | 
| (...skipping 734 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 745 | 745 | 
| 746     end_ebml_master(s->pb, tag); | 746     end_ebml_master(s->pb, tag); | 
| 747     return 0; | 747     return 0; | 
| 748 } | 748 } | 
| 749 | 749 | 
| 750 static int mkv_write_tags(AVFormatContext *s) | 750 static int mkv_write_tags(AVFormatContext *s) | 
| 751 { | 751 { | 
| 752     ebml_master tags = {0}; | 752     ebml_master tags = {0}; | 
| 753     int i, ret; | 753     int i, ret; | 
| 754 | 754 | 
|  | 755     ff_metadata_conv_ctx(s, ff_mkv_metadata_conv, NULL); | 
|  | 756 | 
| 755     if (av_metadata_get(s->metadata, "", NULL, AV_METADATA_IGNORE_SUFFIX)) { | 757     if (av_metadata_get(s->metadata, "", NULL, AV_METADATA_IGNORE_SUFFIX)) { | 
| 756         ret = mkv_write_tag(s, s->metadata, 0, 0, &tags); | 758         ret = mkv_write_tag(s, s->metadata, 0, 0, &tags); | 
| 757         if (ret < 0) return ret; | 759         if (ret < 0) return ret; | 
| 758     } | 760     } | 
| 759 | 761 | 
| 760     for (i = 0; i < s->nb_streams; i++) { | 762     for (i = 0; i < s->nb_streams; i++) { | 
| 761         AVStream *st = s->streams[i]; | 763         AVStream *st = s->streams[i]; | 
| 762 | 764 | 
| 763         if (!av_metadata_get(st->metadata, "", 0, AV_METADATA_IGNORE_SUFFIX)) | 765         if (!av_metadata_get(st->metadata, "", 0, AV_METADATA_IGNORE_SUFFIX)) | 
| 764             continue; | 766             continue; | 
| (...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1179     "mkv", | 1181     "mkv", | 
| 1180     sizeof(MatroskaMuxContext), | 1182     sizeof(MatroskaMuxContext), | 
| 1181     CODEC_ID_MP2, | 1183     CODEC_ID_MP2, | 
| 1182     CODEC_ID_MPEG4, | 1184     CODEC_ID_MPEG4, | 
| 1183     mkv_write_header, | 1185     mkv_write_header, | 
| 1184     mkv_write_packet, | 1186     mkv_write_packet, | 
| 1185     mkv_write_trailer, | 1187     mkv_write_trailer, | 
| 1186     .flags = AVFMT_GLOBALHEADER | AVFMT_VARIABLE_FPS, | 1188     .flags = AVFMT_GLOBALHEADER | AVFMT_VARIABLE_FPS, | 
| 1187     .codec_tag = (const AVCodecTag* const []){ff_codec_bmp_tags, ff_codec_wav_ta
      gs, 0}, | 1189     .codec_tag = (const AVCodecTag* const []){ff_codec_bmp_tags, ff_codec_wav_ta
      gs, 0}, | 
| 1188     .subtitle_codec = CODEC_ID_TEXT, | 1190     .subtitle_codec = CODEC_ID_TEXT, | 
| 1189     .metadata_conv = ff_mkv_metadata_conv, |  | 
| 1190 }; | 1191 }; | 
| 1191 #endif | 1192 #endif | 
| 1192 | 1193 | 
| 1193 #if CONFIG_WEBM_MUXER | 1194 #if CONFIG_WEBM_MUXER | 
| 1194 AVOutputFormat webm_muxer = { | 1195 AVOutputFormat webm_muxer = { | 
| 1195     "webm", | 1196     "webm", | 
| 1196     NULL_IF_CONFIG_SMALL("WebM file format"), | 1197     NULL_IF_CONFIG_SMALL("WebM file format"), | 
| 1197     "video/webm", | 1198     "video/webm", | 
| 1198     "webm", | 1199     "webm", | 
| 1199     sizeof(MatroskaMuxContext), | 1200     sizeof(MatroskaMuxContext), | 
| (...skipping 13 matching lines...) Expand all  Loading... | 
| 1213     "audio/x-matroska", | 1214     "audio/x-matroska", | 
| 1214     "mka", | 1215     "mka", | 
| 1215     sizeof(MatroskaMuxContext), | 1216     sizeof(MatroskaMuxContext), | 
| 1216     CODEC_ID_MP2, | 1217     CODEC_ID_MP2, | 
| 1217     CODEC_ID_NONE, | 1218     CODEC_ID_NONE, | 
| 1218     mkv_write_header, | 1219     mkv_write_header, | 
| 1219     mkv_write_packet, | 1220     mkv_write_packet, | 
| 1220     mkv_write_trailer, | 1221     mkv_write_trailer, | 
| 1221     .flags = AVFMT_GLOBALHEADER, | 1222     .flags = AVFMT_GLOBALHEADER, | 
| 1222     .codec_tag = (const AVCodecTag* const []){ff_codec_wav_tags, 0}, | 1223     .codec_tag = (const AVCodecTag* const []){ff_codec_wav_tags, 0}, | 
| 1223     .metadata_conv = ff_mkv_metadata_conv, |  | 
| 1224 }; | 1224 }; | 
| 1225 #endif | 1225 #endif | 
| OLD | NEW | 
|---|