FFmpeg
Macros | Functions
ops_chain.c File Reference
#include "libavutil/avassert.h"
#include "libavutil/mem.h"
#include "libavutil/rational.h"
#include "ops_chain.h"

Go to the source code of this file.

Macros

#define Q(N)   ((AVRational) { N, 1 })
 Copyright (C) 2025 Niklas Haas. More...
 
#define q2pixel(type, q)   ((q).den ? (type) (q).num / (q).den : 0)
 

Functions

SwsOpChainff_sws_op_chain_alloc (void)
 
void ff_sws_op_chain_free_cb (void *ptr)
 
int ff_sws_op_chain_append (SwsOpChain *chain, SwsFuncPtr func, void(*free)(SwsOpPriv *), const SwsOpPriv *priv)
 
int ff_sws_setup_scale (const SwsImplParams *params, SwsImplResult *out)
 
int ff_sws_setup_clamp (const SwsImplParams *params, SwsImplResult *out)
 
int ff_sws_setup_clear (const SwsImplParams *params, SwsImplResult *out)
 
int ff_sws_uop_lookup (SwsContext *ctx, const SwsUOpTable *const tables[], int num_tables, const SwsUOp *uop, const int block_size, SwsOpChain *chain)
 "Compile" a single uop by looking it up in a list of fixed size uop tables, in decreasing order of preference. More...
 
int ff_sws_setup_scalar (const SwsImplParams *params, SwsImplResult *out)
 
int ff_sws_setup_vec4 (const SwsImplParams *params, SwsImplResult *out)
 

Macro Definition Documentation

◆ Q

#define Q (   N)    ((AVRational) { N, 1 })

Copyright (C) 2025 Niklas Haas.

This file is part of FFmpeg.

FFmpeg is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

FFmpeg is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with FFmpeg; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Definition at line 27 of file ops_chain.c.

◆ q2pixel

#define q2pixel (   type,
 
)    ((q).den ? (type) (q).num / (q).den : 0)

Definition at line 63 of file ops_chain.c.

Function Documentation

◆ ff_sws_op_chain_alloc()

SwsOpChain* ff_sws_op_chain_alloc ( void  )

Definition at line 29 of file ops_chain.c.

Referenced by aarch64_compile(), and compile().

◆ ff_sws_op_chain_free_cb()

void ff_sws_op_chain_free_cb ( void *  ptr)

Definition at line 34 of file ops_chain.c.

Referenced by aarch64_compile(), compile(), and ff_sws_op_chain_free().

◆ ff_sws_op_chain_append()

int ff_sws_op_chain_append ( SwsOpChain chain,
SwsFuncPtr  func,
void(*)(SwsOpPriv *)  free,
const SwsOpPriv priv 
)

Definition at line 48 of file ops_chain.c.

Referenced by aarch64_compile(), and ff_sws_uop_lookup().

◆ ff_sws_setup_scale()

int ff_sws_setup_scale ( const SwsImplParams params,
SwsImplResult out 
)

Definition at line 65 of file ops_chain.c.

Referenced by aarch64_setup().

◆ ff_sws_setup_clamp()

int ff_sws_setup_clamp ( const SwsImplParams params,
SwsImplResult out 
)

Definition at line 80 of file ops_chain.c.

Referenced by aarch64_setup().

◆ ff_sws_setup_clear()

int ff_sws_setup_clear ( const SwsImplParams params,
SwsImplResult out 
)

Definition at line 97 of file ops_chain.c.

Referenced by aarch64_setup().

◆ ff_sws_uop_lookup()

int ff_sws_uop_lookup ( SwsContext ctx,
const SwsUOpTable *const  tables[],
int  num_tables,
const SwsUOp uop,
const int  block_size,
SwsOpChain chain 
)

"Compile" a single uop by looking it up in a list of fixed size uop tables, in decreasing order of preference.

Returns 0 or a negative error code.

Definition at line 116 of file ops_chain.c.

Referenced by compile().

◆ ff_sws_setup_scalar()

int ff_sws_setup_scalar ( const SwsImplParams params,
SwsImplResult out 
)

Definition at line 185 of file ops_chain.c.

◆ ff_sws_setup_vec4()

int ff_sws_setup_vec4 ( const SwsImplParams params,
SwsImplResult out 
)

Definition at line 200 of file ops_chain.c.