lavc: add format field to AVFrame
The format is a per-frame property, having it in AVFrame simplify the operation of extraction of that information, since avoids the need to access the codec/stream context.
This commit is contained in:
committed by
Anton Khirnov
parent
3a2ddf7c2c
commit
8a4a5f6ff7
@@ -1272,6 +1272,15 @@ typedef struct AVFrame {
|
||||
* - decoding: Read by user.
|
||||
*/
|
||||
int width, height;
|
||||
|
||||
/**
|
||||
* format of the frame, -1 if unknown or unset
|
||||
* Values correspond to enum PixelFormat for video frames,
|
||||
* enum AVSampleFormat for audio)
|
||||
* - encoding: unused
|
||||
* - decoding: Read by user.
|
||||
*/
|
||||
int format;
|
||||
} AVFrame;
|
||||
|
||||
struct AVCodecInternal;
|
||||
|
||||
Reference in New Issue
Block a user