FFmpeg
Macros | Functions
swscale.c File Reference
#include "config.h"
#include "libavutil/attributes.h"
#include "libswscale/swscale.h"
#include "libswscale/swscale_internal.h"
#include "libavutil/aarch64/cpu.h"

Go to the source code of this file.

Macros

#define SCALE_FUNC(filter_n, from_bpc, to_bpc, opt)
 
#define SCALE_FUNCS(filter_n, opt)
 
#define ALL_SCALE_FUNCS(opt)
 
#define ASSIGN_SCALE_FUNC2(hscalefn, filtersize, opt)
 
#define ASSIGN_SCALE_FUNC(hscalefn, filtersize, opt)
 
#define ASSIGN_VSCALE_FUNC(vscalefn, opt)
 

Functions

void ff_hscale16to15_4_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
void ff_hscale16to15_X8_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
void ff_hscale16to15_X4_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
void ff_hscale16to19_4_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
void ff_hscale16to19_X8_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
void ff_hscale16to19_X4_neon_asm (int shift, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to15_4_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to15_X8_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to15_X4_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to19_4_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to19_X8_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
static void ff_hscale16to19_X4_neon (SwsContext *c, int16_t *_dst, int dstW, const uint8_t *_src, const int16_t *filter, const int32_t *filterPos, int filterSize)
 
 ALL_SCALE_FUNCS (neon)
 
void ff_yuv2planeX_8_neon (const int16_t *filter, int filterSize, const int16_t **src, uint8_t *dest, int dstW, const uint8_t *dither, int offset)
 
void ff_yuv2plane1_8_neon (const int16_t *src, uint8_t *dest, int dstW, const uint8_t *dither, int offset)
 
av_cold void ff_sws_init_swscale_aarch64 (SwsContext *c)
 

Macro Definition Documentation

◆ SCALE_FUNC

#define SCALE_FUNC (   filter_n,
  from_bpc,
  to_bpc,
  opt 
)
Value:
void ff_hscale ## from_bpc ## to ## to_bpc ## _ ## filter_n ## _ ## opt( \
SwsContext *c, int16_t *data, \
int dstW, const uint8_t *src, \
const int16_t *filter, \
const int32_t *filterPos, int filterSize)

Definition at line 145 of file swscale.c.

◆ SCALE_FUNCS

#define SCALE_FUNCS (   filter_n,
  opt 
)
Value:
SCALE_FUNC(filter_n, 8, 15, opt); \
SCALE_FUNC(filter_n, 8, 19, opt);

Definition at line 151 of file swscale.c.

◆ ALL_SCALE_FUNCS

#define ALL_SCALE_FUNCS (   opt)
Value:
SCALE_FUNCS(4, opt); \
SCALE_FUNCS(X8, opt); \
SCALE_FUNCS(X4, opt)

Definition at line 154 of file swscale.c.

◆ ASSIGN_SCALE_FUNC2

#define ASSIGN_SCALE_FUNC2 (   hscalefn,
  filtersize,
  opt 
)
Value:
do { \
if (c->srcBpc == 8) { \
if(c->dstBpc <= 14) { \
hscalefn = \
ff_hscale8to15_ ## filtersize ## _ ## opt; \
} else \
hscalefn = \
ff_hscale8to19_ ## filtersize ## _ ## opt; \
} else { \
if (c->dstBpc <= 14) \
hscalefn = \
ff_hscale16to15_ ## filtersize ## _ ## opt; \
else \
hscalefn = \
ff_hscale16to19_ ## filtersize ## _ ## opt; \
} \
} while (0)

Definition at line 171 of file swscale.c.

◆ ASSIGN_SCALE_FUNC

#define ASSIGN_SCALE_FUNC (   hscalefn,
  filtersize,
  opt 
)
Value:
do { \
if (filtersize == 4) \
ASSIGN_SCALE_FUNC2(hscalefn, 4, opt); \
else if (filtersize % 8 == 0) \
ASSIGN_SCALE_FUNC2(hscalefn, X8, opt); \
else if (filtersize % 4 == 0 && filtersize % 8 != 0) \
ASSIGN_SCALE_FUNC2(hscalefn, X4, opt); \
} while (0)

Definition at line 189 of file swscale.c.

◆ ASSIGN_VSCALE_FUNC

#define ASSIGN_VSCALE_FUNC (   vscalefn,
  opt 
)
Value:
switch (c->dstBpc) { \
case 8: vscalefn = ff_yuv2plane1_8_ ## opt; break; \
default: break; \
}

Definition at line 198 of file swscale.c.

Function Documentation

◆ ff_hscale16to15_4_neon_asm()

void ff_hscale16to15_4_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to15_4_neon().

◆ ff_hscale16to15_X8_neon_asm()

void ff_hscale16to15_X8_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to15_X8_neon().

◆ ff_hscale16to15_X4_neon_asm()

void ff_hscale16to15_X4_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to15_X4_neon().

◆ ff_hscale16to19_4_neon_asm()

void ff_hscale16to19_4_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to19_4_neon().

◆ ff_hscale16to19_X8_neon_asm()

void ff_hscale16to19_X8_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to19_X8_neon().

◆ ff_hscale16to19_X4_neon_asm()

void ff_hscale16to19_X4_neon_asm ( int  shift,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)

Referenced by ff_hscale16to19_X4_neon().

◆ ff_hscale16to15_4_neon()

static void ff_hscale16to15_4_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 44 of file swscale.c.

◆ ff_hscale16to15_X8_neon()

static void ff_hscale16to15_X8_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 60 of file swscale.c.

◆ ff_hscale16to15_X4_neon()

static void ff_hscale16to15_X4_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 76 of file swscale.c.

◆ ff_hscale16to19_4_neon()

static void ff_hscale16to19_4_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 91 of file swscale.c.

◆ ff_hscale16to19_X8_neon()

static void ff_hscale16to19_X8_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 109 of file swscale.c.

◆ ff_hscale16to19_X4_neon()

static void ff_hscale16to19_X4_neon ( SwsContext c,
int16_t *  _dst,
int  dstW,
const uint8_t *  _src,
const int16_t *  filter,
const int32_t filterPos,
int  filterSize 
)
static

Definition at line 127 of file swscale.c.

◆ ALL_SCALE_FUNCS()

ALL_SCALE_FUNCS ( neon  )

◆ ff_yuv2planeX_8_neon()

void ff_yuv2planeX_8_neon ( const int16_t *  filter,
int  filterSize,
const int16_t **  src,
uint8_t *  dest,
int  dstW,
const uint8_t *  dither,
int  offset 
)

◆ ff_yuv2plane1_8_neon()

void ff_yuv2plane1_8_neon ( const int16_t *  src,
uint8_t *  dest,
int  dstW,
const uint8_t *  dither,
int  offset 
)

◆ ff_sws_init_swscale_aarch64()

av_cold void ff_sws_init_swscale_aarch64 ( SwsContext c)

Definition at line 204 of file swscale.c.

Referenced by ff_sws_init_scale().

data
const char data[16]
Definition: mxf.c:148
filter
filter_frame For filters that do not use the this method is called when a frame is pushed to the filter s input It can be called at any time except in a reentrant way If the input frame is enough to produce then the filter should push the output frames on the output link immediately As an exception to the previous rule if the input frame is enough to produce several output frames then the filter needs output only at least one per link The additional frames can be left buffered in the filter
Definition: filter_design.txt:228
SCALE_FUNCS
#define SCALE_FUNCS(filter_n, opt)
Definition: swscale.c:151
SCALE_FUNC
#define SCALE_FUNC(filter_n, from_bpc, to_bpc, opt)
Definition: swscale.c:145
to
const char * to
Definition: webvttdec.c:35
c
Undefined Behavior In the C some operations are like signed integer dereferencing freed accessing outside allocated Undefined Behavior must not occur in a C it is not safe even if the output of undefined operations is unused The unsafety may seem nit picking but Optimizing compilers have in fact optimized code on the assumption that no undefined Behavior occurs Optimizing code based on wrong assumptions can and has in some cases lead to effects beyond the output of computations The signed integer overflow problem in speed critical code Code which is highly optimized and works with signed integers sometimes has the problem that often the output of the computation does not c
Definition: undefined.txt:32
_
#define _
src
INIT_CLIP pixel * src
Definition: h264pred_template.c:418
int32_t
int32_t
Definition: audioconvert.c:56
SwsContext
Definition: swscale_internal.h:299