diff options
author | Aurelien Jacobs <aurel@gnuage.org> | 2011-06-13 19:02:50 +0200 |
---|---|---|
committer | Aurelien Jacobs <aurel@gnuage.org> | 2011-06-13 19:02:50 +0200 |
commit | e6ba3d428105edbd3c1a468ece619f801151eea2 (patch) | |
tree | db9fa2e985890dffc8e93122240f0925d3836859 | |
parent | 7ebaa967a2c5b038023409179ca3c56f5b4f4ed3 (diff) | |
download | ffmpeg-e6ba3d428105edbd3c1a468ece619f801151eea2.tar.gz |
replace remaining usage of deprecated av_metadata_set2() by av_dict_set()
-rw-r--r-- | libavformat/aiffdec.c | 2 | ||||
-rw-r--r-- | libavformat/matroskadec.c | 6 | ||||
-rw-r--r-- | libavformat/mov.c | 2 | ||||
-rw-r--r-- | libavformat/wav.c | 10 | ||||
-rw-r--r-- | libavformat/wtvdec.c | 6 |
5 files changed, 13 insertions, 13 deletions
diff --git a/libavformat/aiffdec.c b/libavformat/aiffdec.c index 21f28e384f..9608910340 100644 --- a/libavformat/aiffdec.c +++ b/libavformat/aiffdec.c @@ -78,7 +78,7 @@ static void get_meta(AVFormatContext *s, const char *key, int size) } size += (size&1)-res; str[res] = 0; - av_metadata_set2(&s->metadata, key, str, AV_METADATA_DONT_STRDUP_VAL); + av_dict_set(&s->metadata, key, str, AV_METADATA_DONT_STRDUP_VAL); }else size+= size&1; diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 8fafbb33bf..bd71befcf9 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -1515,7 +1515,7 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap) /* export stereo mode flag as metadata tag */ if (track->video.stereo_mode && track->video.stereo_mode < MATROSKA_VIDEO_STEREO_MODE_COUNT) - av_metadata_set2(&st->metadata, "stereo_mode", matroska_video_stereo_mode[track->video.stereo_mode], 0); + av_dict_set(&st->metadata, "stereo_mode", matroska_video_stereo_mode[track->video.stereo_mode], 0); /* if we have virtual track, mark the real tracks */ for (j=0; j < track->operation.combine_planes.nb_elem; j++) { @@ -1526,8 +1526,8 @@ static int matroska_read_header(AVFormatContext *s, AVFormatParameters *ap) matroska_video_stereo_plane[planes[j].type], i); for (k=0; k < matroska->tracks.nb_elem; k++) if (planes[j].uid == tracks[k].uid) { - av_metadata_set2(&s->streams[k]->metadata, - "stereo_mode", buf, 0); + av_dict_set(&s->streams[k]->metadata, + "stereo_mode", buf, 0); break; } } diff --git a/libavformat/mov.c b/libavformat/mov.c index 6a49f37741..088df2cb4c 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -1928,7 +1928,7 @@ static int mov_read_tkhd(MOVContext *c, AVIOContext *pb, MOVAtom atom) sc->height = height >> 16; if (display_matrix[0][0] == -65536 && display_matrix[1][1] == -65536) { - av_metadata_set2(&st->metadata, "rotate", "180", 0); + av_dict_set(&st->metadata, "rotate", "180", 0); } // transform the display width/height according to the matrix diff --git a/libavformat/wav.c b/libavformat/wav.c index 5c4b7d3a6b..c5dbd631b4 100644 --- a/libavformat/wav.c +++ b/libavformat/wav.c @@ -216,7 +216,7 @@ static inline int wav_parse_bext_string(AVFormatContext *s, const char *key, int temp[length] = 0; if (strlen(temp)) - return av_metadata_set2(&s->metadata, key, temp, 0); + return av_dict_set(&s->metadata, key, temp, 0); return 0; } @@ -237,7 +237,7 @@ static int wav_parse_bext_tag(AVFormatContext *s, int64_t size) time_reference = avio_rl64(s->pb); snprintf(temp, sizeof(temp), "%"PRIu64, time_reference); - if ((ret = av_metadata_set2(&s->metadata, "time_reference", temp, 0)) < 0) + if ((ret = av_dict_set(&s->metadata, "time_reference", temp, 0)) < 0) return ret; /* check if version is >= 1, in which case an UMID may be present */ @@ -259,7 +259,7 @@ static int wav_parse_bext_tag(AVFormatContext *s, int64_t size) umid_parts[4], umid_parts[5], umid_parts[6], umid_parts[7]); } - if ((ret = av_metadata_set2(&s->metadata, "umid", temp, 0)) < 0) + if ((ret = av_dict_set(&s->metadata, "umid", temp, 0)) < 0) return ret; } @@ -278,8 +278,8 @@ static int wav_parse_bext_tag(AVFormatContext *s, int64_t size) return ret; coding_history[size] = 0; - if ((ret = av_metadata_set2(&s->metadata, "coding_history", coding_history, - AV_METADATA_DONT_STRDUP_VAL)) < 0) + if ((ret = av_dict_set(&s->metadata, "coding_history", coding_history, + AV_METADATA_DONT_STRDUP_VAL)) < 0) return ret; } diff --git a/libavformat/wtvdec.c b/libavformat/wtvdec.c index 5cbec0576a..5fe7e9fe12 100644 --- a/libavformat/wtvdec.c +++ b/libavformat/wtvdec.c @@ -431,7 +431,7 @@ static void get_attachment(AVFormatContext *s, AVIOContext *pb, int length) st = av_new_stream(s, 0); if (!st) goto done; - av_metadata_set2(&st->metadata, "title", description, 0); + av_dict_set(&st->metadata, "title", description, 0); st->codec->codec_id = CODEC_ID_MJPEG; st->codec->codec_type = AVMEDIA_TYPE_ATTACHMENT; st->codec->extradata = av_mallocz(filesize); @@ -494,7 +494,7 @@ static void get_tag(AVFormatContext *s, AVIOContext *pb, const char *key, int ty return; } - av_metadata_set2(&s->metadata, key, buf, 0); + av_dict_set(&s->metadata, key, buf, 0); av_freep(&buf); } @@ -818,7 +818,7 @@ static int parse_chunks(AVFormatContext *s, int mode, int64_t seekts, int *len_p avio_read(pb, language, 3); if (language[0]) { language[3] = 0; - av_metadata_set2(&st->metadata, "language", language, 0); + av_dict_set(&st->metadata, "language", language, 0); if (!strcmp(language, "nar") || !strcmp(language, "NAR")) st->disposition |= AV_DISPOSITION_VISUAL_IMPAIRED; } |