Go to the documentation of this file.
23 #if AV_GCC_VERSION_AT_LEAST(4, 4)
24 #pragma GCC optimize ("finite-math-only")
29 #ifndef SWS_BLOCK_SIZE
30 # define SWS_BLOCK_SIZE 32
63 &
bitfn(op_table_int, u8),
64 &
bitfn(op_table_int, u16),
65 &
bitfn(op_table_int, u32),
66 &
bitfn(op_table_float, f32),
static int compile(SwsContext *ctx, SwsOpList *ops, SwsCompiledOp *out)
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later. That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another. Frame references ownership and permissions
float f32block_t[SWS_BLOCK_SIZE]
const SwsOpBackend backend_c
Copyright (C) 2025 Niklas Haas.
SwsPixelType
Copyright (C) 2025 Niklas Haas.
Writing a table generator This documentation is preliminary Parts of the API are not good and should be changed Basic concepts A table generator consists of two *_tablegen c and *_tablegen h The h file will provide the variable declarations and initialization code for the tables
#define FF_ARRAY_ELEMS(a)
uint8_t u8block_t[SWS_BLOCK_SIZE]
SwsOpChain * ff_sws_op_chain_alloc(void)
uint16_t u16block_t[SWS_BLOCK_SIZE]
#define av_assert0(cond)
assert() equivalent, that is always enabled.
static AVFormatContext * ctx
uint32_t u32block_t[SWS_BLOCK_SIZE]
#define SWS_BLOCK_SIZE
Copyright (C) 2025 Niklas Haas.
Compiled "chain" of operations, which can be dispatched efficiently.
int ff_sws_op_compile_tables(const SwsOpTable *const tables[], int num_tables, SwsOpList *ops, const int block_size, SwsOpChain *chain)
"Compile" a single op by looking it up in a list of fixed size op tables.
#define av_unreachable(msg)
Asserts that are used as compiler optimization hints depending upon ASSERT_LEVEL and NBDEBUG.
void ff_sws_op_chain_free_cb(void *ptr)
void(* free[SWS_MAX_OPS+1])(void *)
static void ff_sws_op_chain_free(SwsOpChain *chain)
Helper struct for representing a list of operations.
Main external API structure.