MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / alloc_set_opts

Function alloc_set_opts

libswscale/utils.c:74–96  ·  view source on GitHub ↗

* Allocate and return an SwsContext without performing initialization. */

Source from the content-addressed store, hash-verified

72 * Allocate and return an SwsContext without performing initialization.
73 */
74static SwsContext *alloc_set_opts(int srcW, int srcH, enum AVPixelFormat srcFormat,
75 int dstW, int dstH, enum AVPixelFormat dstFormat,
76 int flags, const double *param)
77{
78 SwsContext *sws = sws_alloc_context();
79 if (!sws)
80 return NULL;
81
82 sws->flags = flags;
83 sws->src_w = srcW;
84 sws->src_h = srcH;
85 sws->dst_w = dstW;
86 sws->dst_h = dstH;
87 sws->src_format = srcFormat;
88 sws->dst_format = dstFormat;
89
90 if (param) {
91 sws->scaler_params[0] = param[0];
92 sws->scaler_params[1] = param[1];
93 }
94
95 return sws;
96}
97
98int ff_shuffle_filter_coefficients(SwsInternal *c, int *filterPos,
99 int filterSize, int16_t *filter,

Callers 3

sws_setColorspaceDetailsFunction · 0.85
sws_getContextFunction · 0.85

Calls 1

sws_alloc_contextFunction · 0.85

Tested by

no test coverage detected