Go to the documentation of this file.
33 #define READ_PIXELS(a, b, c) \
35 val = av_le2ne32(*src++); \
37 *b++ = (val >> 10) & 0x3FF; \
38 *c++ = (val >> 20) & 0x3FF; \
88 int slice_start = (avctx->
height * jobnr) /
s->thread_count;
93 y = (uint16_t*)
frame->data[0] + slice_start *
frame->linesize[0] / 2;
94 u = (uint16_t*)
frame->data[1] + slice_start *
frame->linesize[1] / 2;
95 v = (uint16_t*)
frame->data[2] + slice_start *
frame->linesize[2] / 2;
97 const uint32_t *
src = (
const uint32_t*)psrc;
100 w = (avctx->
width / 12) * 12;
101 s->unpack_frame(
src, y,
u, v,
w);
108 if (w < avctx->
width - 5) {
116 if (w < avctx->
width - 1) {
121 if (w < avctx->
width - 3) {
122 *
u++ = (
val >> 10) & 0x3FF;
123 *y++ = (
val >> 20) & 0x3FF;
127 *y++ = (
val >> 10) & 0x3FF;
134 v +=
frame->linesize[2] / 2 - avctx->
width / 2;
150 if (
s->custom_stride )
153 int aligned_width = ((avctx->
width + 47) / 48) * 48;
154 stride = aligned_width * 8 / 3;
158 if ((((avctx->
width + 23) / 24) * 24 * 8) / 3 * avctx->
height == avpkt->
size) {
160 if (!
s->stride_warning_shown)
162 s->stride_warning_shown = 1;
175 aligned_input = !((uintptr_t)psrc & 0x1f) && !(
stride & 0x1f);
176 if (aligned_input !=
s->aligned_input) {
177 s->aligned_input = aligned_input;
203 #define V210DEC_FLAGS AV_OPT_FLAG_DECODING_PARAM | AV_OPT_FLAG_VIDEO_PARAM
static const AVOption v210dec_options[]
#define AV_LOG_WARNING
Something somehow does not look correct.
static av_cold int init(AVCodecContext *avctx)
static void v210_planar_unpack_c(const uint32_t *src, uint16_t *y, uint16_t *u, uint16_t *v, int width)
#define u(width, name, range_min, range_max)
#define MKTAG(a, b, c, d)
static av_cold int decode_init(AVCodecContext *avctx)
This structure describes decoded (raw) audio or video data.
enum AVFieldOrder field_order
Field order.
int top_field_first
If the content is interlaced, is top field displayed first.
#define READ_PIXELS(a, b, c)
av_cold void ff_v210dec_init(V210DecContext *s)
int thread_count
thread count is used to decide how many independent tasks should be passed to execute()
the pkt_dts and pkt_pts fields in AVFrame will work as usual Restrictions on codec whose streams don t reset across will not work because their bitstreams cannot be decoded in parallel *The contents of buffers must not be read before as well as code calling up to before the decode process starts Call have so the codec calls ff_thread_report set FF_CODEC_CAP_ALLOCATE_PROGRESS in AVCodec caps_internal and use ff_thread_get_buffer() to allocate frames. The frames must then be freed with ff_thread_release_buffer(). Otherwise decode directly into the user-supplied frames. Call ff_thread_report_progress() after some part of the current picture has decoded. A good place to put this is where draw_horiz_band() is called - add this if it isn 't called anywhere
int key_frame
1 -> keyframe, 0-> not
static double val(void *priv, double ch)
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
static void decode(AVCodecContext *dec_ctx, AVPacket *pkt, AVFrame *frame, FILE *outfile)
static int slice_end(AVCodecContext *avctx, AVFrame *pict)
Handle slice ends.
int bits_per_raw_sample
Bits per sample/pixel of internal libavcodec pixel/sample format.
#define AV_CODEC_CAP_FRAME_THREADS
Codec supports frame-level multithreading.
#define LIBAVUTIL_VERSION_INT
Describe the class of an AVClass context structure.
const char * av_default_item_name(void *ptr)
Return the context name.
@ AV_PICTURE_TYPE_I
Intra.
#define AV_PIX_FMT_YUV422P10
static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
enum AVPictureType pict_type
Picture type of the frame.
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
#define AV_CODEC_CAP_SLICE_THREADS
Codec supports slice-based (or partition-based) multithreading.
static const AVClass v210dec_class
int interlaced_frame
The content of the picture is interlaced.
#define i(width, name, range_min, range_max)
Used for passing data between threads.
const char * name
Name of the codec implementation.
enum AVPixelFormat pix_fmt
Pixel format, see AV_PIX_FMT_xxx.
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
these buffered frames must be flushed immediately if a new input produces new the filter must not call request_frame to get more It must just process the frame or queue it The task of requesting more frames is left to the filter s request_frame method or the application If a filter has several the filter must be ready for frames arriving randomly on any input any filter with several inputs will most likely require some kind of queuing mechanism It is perfectly acceptable to have a limited queue and to drop frames when the inputs are too unbalanced request_frame For filters that do not use the this method is called when a frame is wanted on an output For a it should directly call filter_frame on the corresponding output For a if there are queued frames already one of these frames should be pushed If the filter should request a frame on one of its repeatedly until at least one frame has been pushed Return or at least make progress towards producing a frame
FFmpeg Automated Testing Environment ************************************Introduction Using FATE from your FFmpeg source directory Submitting the results to the FFmpeg result aggregation server Uploading new samples to the fate suite FATE makefile targets and variables Makefile targets Makefile variables Examples Introduction **************FATE is an extended regression suite on the client side and a means for results aggregation and presentation on the server side The first part of this document explains how you can use FATE from your FFmpeg source directory to test your ffmpeg binary The second part describes how you can run FATE to submit the results to FFmpeg’s FATE server In any way you can have a look at the publicly viewable FATE results by visiting this as it can be seen if some test on some platform broke with their recent contribution This usually happens on the platforms the developers could not test on The second part of this document describes how you can run FATE to submit your results to FFmpeg’s FATE server If you want to submit your results be sure to check that your combination of OS and compiler is not already listed on the above mentioned website In the third part you can find a comprehensive listing of FATE makefile targets and variables Using FATE from your FFmpeg source directory **********************************************If you want to run FATE on your machine you need to have the samples in place You can get the samples via the build target fate rsync Use this command from the top level source this will cause FATE to fail NOTE To use a custom wrapper to run the pass ‘ target exec’ to ‘configure’ or set the TARGET_EXEC Make variable Submitting the results to the FFmpeg result aggregation server ****************************************************************To submit your results to the server you should run fate through the shell script ‘tests fate sh’ from the FFmpeg sources This script needs to be invoked with a configuration file as its first argument tests fate sh path to fate_config A configuration file template with comments describing the individual configuration variables can be found at ‘doc fate_config sh template’ Create a configuration that suits your based on the configuration template The ‘slot’ configuration variable can be any string that is not yet but it is suggested that you name it adhering to the following pattern ‘ARCH OS COMPILER COMPILER VERSION’ The configuration file itself will be sourced in a shell therefore all shell features may be used This enables you to setup the environment as you need it for your build For your first test runs the ‘fate_recv’ variable should be empty or commented out This will run everything as normal except that it will omit the submission of the results to the server The following files should be present in $workdir as specified in the configuration it may help to try out the ‘ssh’ command with one or more ‘ v’ options You should get detailed output concerning your SSH configuration and the authentication process The only thing left is to automate the execution of the fate sh script and the synchronisation of the samples directory Uploading new samples to the fate suite *****************************************If you need a sample uploaded send a mail to samples request This is for developers who have an account on the fate suite server If you upload new please make sure they are as small as space on each network bandwidth and so on benefit from smaller test cases Also keep in mind older checkouts use existing sample that means in practice generally do not remove or overwrite files as it likely would break older checkouts or releases Also all needed samples for a commit should be ideally before the push If you need an account for frequently uploading samples or you wish to help others by doing that send a mail to ffmpeg devel rsync vauL Duo ug o o w
main external API structure.
void ff_v210_x86_init(V210DecContext *s)
unsigned int codec_tag
fourcc (LSB first, so "ABCD" -> ('D'<<24) + ('C'<<16) + ('B'<<8) + 'A').
This structure stores compressed data.
static int v210_decode_slice(AVCodecContext *avctx, void *arg, int jobnr, int threadnr)
int width
picture width / height.
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
int(* execute2)(struct AVCodecContext *c, int(*func)(struct AVCodecContext *c2, void *arg, int jobnr, int threadnr), void *arg2, int *ret, int count)
The codec may call this to execute several independent things.