History

Simplify writing stream metadata.

Patch by Anton Khirnov <wyskas gmail com>. Originally committed as revision 22809 to svn://svn.ffmpeg.org/ffmpeg/trunk

Anton Khirnov committed 16 years ago

Commit 46e6fb41 parent 1a6498d1 file · +2 −6Browse files

Unified · Split

ffmpeg.c+2−6
@@ -1914,7 +1914,7 @@ static int av_transcode(AVFormatContext **output_files, · 1913 unmodified lines
19141914
19151915 /* for each output stream, we compute the right encoding parameters */
19161916 for(i=0;i<nb_ostreams;i++) {
1917− AVMetadataTag *t = NULL, *lang = NULL;
1917+ AVMetadataTag *t = NULL;
19181918 ost = ost_table[i];
19191919 os = output_files[ost->file_index];
19201920 ist = ist_table[ost->source_index];
@@ -1922,12 +1922,8 @@ static int av_transcode(AVFormatContext **output_files, · 1 unmodified line
19221922 codec = ost->st->codec;
19231923 icodec = ist->st->codec;
19241924
1925− if (av_metadata_get(ist->st->metadata, "language", NULL, 0))
1926− lang = av_metadata_get(ost->st->metadata, "language", NULL, 0);
19271925 while ((t = av_metadata_get(ist->st->metadata, "", t, AV_METADATA_IGNORE_SUFFIX))) {
1928− if (lang && !strcmp(t->key, "language"))
1929− continue;
1930− av_metadata_set2(&ost->st->metadata, t->key, t->value, 0);
1926+ av_metadata_set2(&ost->st->metadata, t->key, t->value, AV_METADATA_DONT_OVERWRITE);
19311927 }
19321928
19331929 ost->st->disposition = ist->st->disposition;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t