summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/avformat.h4
-rw-r--r--libavformat/ffmdec.c1
-rw-r--r--libavformat/ffmenc.c1
-rw-r--r--libavformat/version.h3
4 files changed, 6 insertions, 3 deletions
diff --git a/libavformat/avformat.h b/libavformat/avformat.h
index 12490c1209..9011099a21 100644
--- a/libavformat/avformat.h
+++ b/libavformat/avformat.h
@@ -523,12 +523,14 @@ typedef struct AVStream {
int stream_copy; /**< If set, just copy stream. */
enum AVDiscard discard; ///< Selects which packets can be discarded at will and do not need to be demuxed.
+#if FF_API_AVSTREAM_QUALITY
//FIXME move stuff to a flags field?
/**
* Quality, as it has been removed from AVCodecContext and put in AVVideoFrame.
* MN: dunno if that is the right place for it
*/
- float quality;
+ attribute_deprecated float quality;
+#endif
/**
* Decoding: pts of the first frame of the stream, in stream time base.
diff --git a/libavformat/ffmdec.c b/libavformat/ffmdec.c
index 91ab2e4370..ed932703a2 100644
--- a/libavformat/ffmdec.c
+++ b/libavformat/ffmdec.c
@@ -301,7 +301,6 @@ static int ffm_read_header(AVFormatContext *s, AVFormatParameters *ap)
codec->codec_id = avio_rb32(pb);
codec->codec_type = avio_r8(pb); /* codec_type */
codec->bit_rate = avio_rb32(pb);
- st->quality = avio_rb32(pb);
codec->flags = avio_rb32(pb);
codec->flags2 = avio_rb32(pb);
codec->debug = avio_rb32(pb);
diff --git a/libavformat/ffmenc.c b/libavformat/ffmenc.c
index 9a3eb40ad7..a31ac8e1d0 100644
--- a/libavformat/ffmenc.c
+++ b/libavformat/ffmenc.c
@@ -114,7 +114,6 @@ static int ffm_write_header(AVFormatContext *s)
avio_wb32(pb, codec->codec_id);
avio_w8(pb, codec->codec_type);
avio_wb32(pb, codec->bit_rate);
- avio_wb32(pb, st->quality);
avio_wb32(pb, codec->flags);
avio_wb32(pb, codec->flags2);
avio_wb32(pb, codec->debug);
diff --git a/libavformat/version.h b/libavformat/version.h
index 3cc1718f2b..0cf383fcc1 100644
--- a/libavformat/version.h
+++ b/libavformat/version.h
@@ -74,5 +74,8 @@
#ifndef FF_API_FLAG_RTP_HINT
#define FF_API_FLAG_RTP_HINT (LIBAVFORMAT_VERSION_MAJOR < 54)
#endif
+#ifndef FF_API_AVSTREAM_QUALITY
+#define FF_API_AVSTREAM_QUALITY (LIBAVFORMAT_VERSION_MAJOR < 54)
+#endif
#endif /* AVFORMAT_VERSION_H */