22 #include "libavutil/parseutils.h"
23 #include "libavutil/pixdesc.h"
24 #include "libavutil/opt.h"
81 pkt->
pts = pkt->
dts = pkt->
pos / packet_size;
89 #define OFFSET(x) offsetof(RawVideoDemuxerContext, x)
90 #define DEC AV_OPT_FLAG_DECODING_PARAM
112 .extensions =
"yuv,cif,qcif,rgb",
114 .priv_class = &rawvideo_demuxer_class,
#define LIBAVUTIL_VERSION_INT
int64_t pos
byte position in stream, -1 if unknown
AVCodecContext * codec
Codec context associated with this stream.
void av_log(void *avcl, int level, const char *fmt,...) av_printf_format(3
Send the specified message to the log if the level is less than or equal to the current av_log_level...
enum AVPixelFormat pix_fmt
Pixel format, see AV_PIX_FMT_xxx.
static const AVOption rawvideo_options[]
static const AVClass rawvideo_demuxer_class
static int rawvideo_read_packet(AVFormatContext *s, AVPacket *pkt)
enum AVPixelFormat av_get_pix_fmt(const char *name)
Return the pixel format corresponding to name.
const char * av_default_item_name(void *ctx)
Return the context name.
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
AVRational framerate
AVRational describing framerate, set by a private option.
enum AVPixelFormat pix_fmt
AVStream * avformat_new_stream(AVFormatContext *s, const AVCodec *c)
Add a new stream to a media file.
int64_t av_rescale_q(int64_t a, AVRational bq, AVRational cq) av_const
Rescale a 64-bit integer by 2 rational numbers.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
void * priv_data
Format private data.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
struct AVInputFormat * iformat
Can only be iformat or oformat, not both at the same time.
AVPixelFormat
Pixel format.
int bit_rate
the average bitrate
int width
picture width / height.
static int rawvideo_read_header(AVFormatContext *ctx)
static int read_header(FFV1Context *f)
enum AVMediaType codec_type
int height
Integers describing video size, set by a private option.
AVInputFormat ff_rawvideo_demuxer
AVIOContext * pb
I/O context.
static int read_packet(AVFormatContext *ctx, AVPacket *pkt)
BYTE int const BYTE int int int height
Describe the class of an AVClass context structure.
rational number numerator/denominator
offset must point to AVRational
char * pixel_format
Set by a private option.
offset must point to two consecutive integers
int avpicture_get_size(enum AVPixelFormat pix_fmt, int width, int height)
Calculate the size in bytes that a picture of the given width and height would occupy if stored in th...
int64_t dts
Decompression timestamp in AVStream->time_base units; the time at which the packet is decompressed...
This structure stores compressed data.
int64_t pts
Presentation timestamp in AVStream->time_base units; the time at which the decompressed packet will b...