FFmpeg
avf_abitscope.c
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2016 Paul B Mahol
3  *
4  * This file is part of FFmpeg.
5  *
6  * FFmpeg is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * FFmpeg is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with FFmpeg; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19  */
20 
21 #include "libavutil/avstring.h"
22 #include "libavutil/intreadwrite.h"
23 #include "libavutil/mem.h"
24 #include "libavutil/opt.h"
25 #include "libavutil/parseutils.h"
26 #include "avfilter.h"
27 #include "filters.h"
28 #include "formats.h"
29 #include "audio.h"
30 #include "video.h"
31 #include "internal.h"
32 
33 typedef struct AudioBitScopeContext {
34  const AVClass *class;
35  int w, h;
37  char *colors;
38  int mode;
39 
42  int depth;
44  uint8_t *fg;
45 
46  uint64_t counter[64];
47 
50 
51 #define OFFSET(x) offsetof(AudioBitScopeContext, x)
52 #define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM
53 
54 static const AVOption abitscope_options[] = {
55  { "rate", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS },
56  { "r", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS },
57  { "size", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="1024x256"}, 0, 0, FLAGS },
58  { "s", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="1024x256"}, 0, 0, FLAGS },
59  { "colors", "set channels colors", OFFSET(colors), AV_OPT_TYPE_STRING, {.str = "red|green|blue|yellow|orange|lime|pink|magenta|brown" }, 0, 0, FLAGS },
60  { "mode", "set output mode", OFFSET(mode), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 1, FLAGS, .unit = "mode" },
61  { "m", "set output mode", OFFSET(mode), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 1, FLAGS, .unit = "mode" },
62  { "bars", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = 0 }, 0, 0, FLAGS, .unit = "mode" },
63  { "trace", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = 1 }, 0, 0, FLAGS, .unit = "mode" },
64  { NULL }
65 };
66 
67 AVFILTER_DEFINE_CLASS(abitscope);
68 
70 {
73  AVFilterLink *inlink = ctx->inputs[0];
74  AVFilterLink *outlink = ctx->outputs[0];
79  static const enum AVPixelFormat pix_fmts[] = { AV_PIX_FMT_RGBA, AV_PIX_FMT_NONE };
80  int ret;
81 
83  if ((ret = ff_formats_ref(formats, &inlink->outcfg.formats)) < 0)
84  return ret;
85 
87  if (!layouts)
88  return AVERROR(ENOMEM);
89  if ((ret = ff_channel_layouts_ref(layouts, &inlink->outcfg.channel_layouts)) < 0)
90  return ret;
91 
93  if ((ret = ff_formats_ref(formats, &inlink->outcfg.samplerates)) < 0)
94  return ret;
95 
97  if ((ret = ff_formats_ref(formats, &outlink->incfg.formats)) < 0)
98  return ret;
99 
100  return 0;
101 }
102 
104 {
105  AVFilterContext *ctx = inlink->dst;
106  AudioBitScopeContext *s = ctx->priv;
107  int ch;
108  char *colors, *saveptr = NULL;
109 
110  s->nb_samples = FFMAX(1, av_rescale(inlink->sample_rate, s->frame_rate.den, s->frame_rate.num));
111  s->nb_channels = inlink->ch_layout.nb_channels;
112  s->depth = inlink->format == AV_SAMPLE_FMT_S16P ? 16 : 32;
113 
114  s->fg = av_malloc_array(s->nb_channels, 4 * sizeof(*s->fg));
115  if (!s->fg)
116  return AVERROR(ENOMEM);
117 
118  colors = av_strdup(s->colors);
119  if (!colors)
120  return AVERROR(ENOMEM);
121 
122  for (ch = 0; ch < s->nb_channels; ch++) {
123  uint8_t fg[4] = { 0xff, 0xff, 0xff, 0xff };
124  char *color;
125 
126  color = av_strtok(ch == 0 ? colors : NULL, " |", &saveptr);
127  if (color)
128  av_parse_color(fg, color, -1, ctx);
129  s->fg[4 * ch + 0] = fg[0];
130  s->fg[4 * ch + 1] = fg[1];
131  s->fg[4 * ch + 2] = fg[2];
132  s->fg[4 * ch + 3] = fg[3];
133  }
134  av_free(colors);
135 
136  return 0;
137 }
138 
139 static int config_output(AVFilterLink *outlink)
140 {
141  AudioBitScopeContext *s = outlink->src->priv;
142 
143  outlink->w = s->w;
144  outlink->h = s->h;
145  outlink->sample_aspect_ratio = (AVRational){1,1};
146  outlink->frame_rate = s->frame_rate;
147  outlink->time_base = av_inv_q(outlink->frame_rate);
148 
149  return 0;
150 }
151 
152 #define BITCOUNTER(type, depth, one) \
153  memset(counter, 0, sizeof(s->counter)); \
154  for (int i = 0; i < nb_samples; i++) { \
155  const type x = in[i]; \
156  for (int j = 0; j < depth && x; j++) \
157  counter[j] += !!(x & (one << j)); \
158  }
159 
160 #define BARS(type, depth, one) \
161  for (int ch = 0; ch < inlink->ch_layout.nb_channels; ch++) { \
162  const int nb_samples = insamples->nb_samples; \
163  const type *in = (const type *)insamples->extended_data[ch]; \
164  const int w = outpicref->width / inlink->ch_layout.nb_channels; \
165  const int h = outpicref->height / depth; \
166  const uint32_t color = AV_RN32(&s->fg[4 * ch]); \
167  uint64_t *counter = s->counter; \
168  \
169  BITCOUNTER(type, depth, one) \
170  \
171  for (int b = 0; b < depth; b++) { \
172  for (int j = 1; j < h - 1; j++) { \
173  uint8_t *dst = outpicref->data[0] + (b * h + j) * outpicref->linesize[0] + w * ch * 4; \
174  const int ww = (counter[depth - b - 1] / (float)nb_samples) * (w - 1); \
175  \
176  for (int i = 0; i < ww; i++) { \
177  AV_WN32(&dst[i * 4], color); \
178  } \
179  } \
180  } \
181  }
182 
183 #define DO_TRACE(type, depth, one) \
184  for (int ch = 0; ch < inlink->ch_layout.nb_channels; ch++) { \
185  const int nb_samples = insamples->nb_samples; \
186  const int w = outpicref->width / inlink->ch_layout.nb_channels; \
187  const type *in = (const type *)insamples->extended_data[ch]; \
188  uint64_t *counter = s->counter; \
189  const int wb = w / depth; \
190  int wv; \
191  \
192  BITCOUNTER(type, depth, one) \
193  \
194  for (int b = 0; b < depth; b++) { \
195  uint8_t colors[4]; \
196  uint32_t color; \
197  uint8_t *dst = outpicref->data[0] + w * ch * 4 + wb * b * 4 + \
198  s->current_vpos * outpicref->linesize[0]; \
199  wv = (counter[depth - b - 1] * 255) / nb_samples; \
200  colors[0] = (wv * s->fg[ch * 4 + 0] + 127) / 255; \
201  colors[1] = (wv * s->fg[ch * 4 + 1] + 127) / 255; \
202  colors[2] = (wv * s->fg[ch * 4 + 2] + 127) / 255; \
203  colors[3] = (wv * s->fg[ch * 4 + 3] + 127) / 255; \
204  color = AV_RN32(colors); \
205  \
206  for (int x = 0; x < wb; x++) \
207  AV_WN32(&dst[x * 4], color); \
208  } \
209  }
210 
211 static int filter_frame(AVFilterLink *inlink, AVFrame *insamples)
212 {
213  AVFilterContext *ctx = inlink->dst;
214  AVFilterLink *outlink = ctx->outputs[0];
215  AudioBitScopeContext *s = ctx->priv;
216  AVFrame *outpicref;
217  int ret;
218 
219  if (s->mode == 0 || !s->outpicref) {
220  outpicref = ff_get_video_buffer(outlink, outlink->w, outlink->h);
221  if (!outpicref) {
222  av_frame_free(&insamples);
223  return AVERROR(ENOMEM);
224  }
225 
226  for (int i = 0; i < outlink->h; i++)
227  memset(outpicref->data[0] + i * outpicref->linesize[0], 0, outlink->w * 4);
228  if (!s->outpicref && s->mode == 1)
229  s->outpicref = outpicref;
230  }
231 
232  if (s->mode == 1) {
233  ret = ff_inlink_make_frame_writable(outlink, &s->outpicref);
234  if (ret < 0) {
235  av_frame_free(&insamples);
236  return ret;
237  }
238  outpicref = av_frame_clone(s->outpicref);
239  if (!outpicref) {
240  av_frame_free(&insamples);
241  return AVERROR(ENOMEM);
242  }
243  }
244 
245  outpicref->pts = av_rescale_q(insamples->pts, inlink->time_base, outlink->time_base);
246  outpicref->duration = 1;
247  outpicref->sample_aspect_ratio = (AVRational){1,1};
248 
249  switch (insamples->format) {
250  case AV_SAMPLE_FMT_U8P:
251  if (s->mode == 0) { BARS(uint8_t, 8, 1) } else { DO_TRACE(uint8_t, 8, 1) }
252  break;
253  case AV_SAMPLE_FMT_S16P:
254  if (s->mode == 0) { BARS(uint16_t, 16, 1) } else { DO_TRACE(uint16_t, 16, 1) }
255  break;
256  case AV_SAMPLE_FMT_FLTP:
257  case AV_SAMPLE_FMT_S32P:
258  if (s->mode == 0) { BARS(uint32_t, 32, 1U) } else { DO_TRACE(uint32_t, 32, 1U) }
259  break;
260  case AV_SAMPLE_FMT_DBLP:
261  case AV_SAMPLE_FMT_S64P:
262  if (s->mode == 0) { BARS(uint64_t, 64, 1ULL) } else { DO_TRACE(uint64_t, 64, 1ULL) }
263  break;
264  }
265 
266  s->current_vpos++;
267  if (s->current_vpos >= outlink->h)
268  s->current_vpos = 0;
269  av_frame_free(&insamples);
270 
271  return ff_filter_frame(outlink, outpicref);
272 }
273 
275 {
276  AVFilterLink *inlink = ctx->inputs[0];
277  AVFilterLink *outlink = ctx->outputs[0];
278  AudioBitScopeContext *s = ctx->priv;
279  AVFrame *in;
280  int ret;
281 
283 
284  ret = ff_inlink_consume_samples(inlink, s->nb_samples, s->nb_samples, &in);
285  if (ret < 0)
286  return ret;
287  if (ret > 0)
288  return filter_frame(inlink, in);
289 
292 
293  return FFERROR_NOT_READY;
294 }
295 
297 {
298  AudioBitScopeContext *s = ctx->priv;
299 
300  av_frame_free(&s->outpicref);
301 }
302 
303 static const AVFilterPad inputs[] = {
304  {
305  .name = "default",
306  .type = AVMEDIA_TYPE_AUDIO,
307  .config_props = config_input,
308  },
309 };
310 
311 static const AVFilterPad outputs[] = {
312  {
313  .name = "default",
314  .type = AVMEDIA_TYPE_VIDEO,
315  .config_props = config_output,
316  },
317 };
318 
320  .name = "abitscope",
321  .description = NULL_IF_CONFIG_SMALL("Convert input audio to audio bit scope video output."),
322  .priv_size = sizeof(AudioBitScopeContext),
326  .uninit = uninit,
327  .activate = activate,
328  .priv_class = &abitscope_class,
329 };
formats
formats
Definition: signature.h:48
ff_get_video_buffer
AVFrame * ff_get_video_buffer(AVFilterLink *link, int w, int h)
Request a picture buffer with a specific set of permissions.
Definition: video.c:112
AV_SAMPLE_FMT_FLTP
@ AV_SAMPLE_FMT_FLTP
float, planar
Definition: samplefmt.h:66
AVFilterChannelLayouts
A list of supported channel layouts.
Definition: formats.h:85
AVPixelFormat
AVPixelFormat
Pixel format.
Definition: pixfmt.h:71
AVERROR
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
opt.h
ff_make_format_list
AVFilterFormats * ff_make_format_list(const int *fmts)
Create a list of supported formats.
Definition: formats.c:436
color
Definition: vf_paletteuse.c:512
ff_filter_frame
int ff_filter_frame(AVFilterLink *link, AVFrame *frame)
Send a frame of data to the next filter.
Definition: avfilter.c:1015
sample_fmts
static enum AVSampleFormat sample_fmts[]
Definition: adpcmenc.c:948
AudioBitScopeContext::nb_samples
int nb_samples
Definition: avf_abitscope.c:41
AVFrame::duration
int64_t duration
Duration of the frame, in the same units as pts.
Definition: frame.h:781
ff_channel_layouts_ref
int ff_channel_layouts_ref(AVFilterChannelLayouts *f, AVFilterChannelLayouts **ref)
Add *ref as a new reference to f.
Definition: formats.c:674
layouts
enum MovChannelLayoutTag * layouts
Definition: mov_chan.c:337
av_parse_color
int av_parse_color(uint8_t *rgba_color, const char *color_string, int slen, void *log_ctx)
Put the RGBA values that correspond to color_string in rgba_color.
Definition: parseutils.c:356
FFERROR_NOT_READY
return FFERROR_NOT_READY
Definition: filter_design.txt:204
AV_OPT_TYPE_VIDEO_RATE
@ AV_OPT_TYPE_VIDEO_RATE
offset must point to AVRational
Definition: opt.h:248
inlink
The exact code depends on how similar the blocks are and how related they are to the and needs to apply these operations to the correct inlink or outlink if there are several Macros are available to factor that when no extra processing is inlink
Definition: filter_design.txt:212
av_frame_free
void av_frame_free(AVFrame **frame)
Free the frame and any dynamically allocated objects in it, e.g.
Definition: frame.c:160
ff_all_channel_counts
AVFilterChannelLayouts * ff_all_channel_counts(void)
Construct an AVFilterChannelLayouts coding for any channel layout, with known or unknown disposition.
Definition: formats.c:622
AVFrame
This structure describes decoded (raw) audio or video data.
Definition: frame.h:375
AVFrame::pts
int64_t pts
Presentation timestamp in time_base units (time when frame should be shown to user).
Definition: frame.h:487
w
uint8_t w
Definition: llviddspenc.c:38
AVOption
AVOption.
Definition: opt.h:346
FILTER_QUERY_FUNC
#define FILTER_QUERY_FUNC(func)
Definition: internal.h:159
AV_SAMPLE_FMT_S32P
@ AV_SAMPLE_FMT_S32P
signed 32 bits, planar
Definition: samplefmt.h:65
FFMAX
#define FFMAX(a, b)
Definition: macros.h:47
AVFilter::name
const char * name
Filter name.
Definition: avfilter.h:170
OFFSET
#define OFFSET(x)
Definition: avf_abitscope.c:51
video.h
FF_FILTER_FORWARD_STATUS_BACK
#define FF_FILTER_FORWARD_STATUS_BACK(outlink, inlink)
Forward the status on an output link to an input link.
Definition: filters.h:199
abitscope_options
static const AVOption abitscope_options[]
Definition: avf_abitscope.c:54
AVFrame::data
uint8_t * data[AV_NUM_DATA_POINTERS]
pointer to the picture/channel planes.
Definition: frame.h:396
AudioBitScopeContext::frame_rate
AVRational frame_rate
Definition: avf_abitscope.c:36
AVFilterFormats
A list of supported formats for one end of a filter link.
Definition: formats.h:64
formats.h
FLAGS
#define FLAGS
Definition: avf_abitscope.c:52
AudioBitScopeContext::fg
uint8_t * fg
Definition: avf_abitscope.c:44
AVFilterContext::priv
void * priv
private data for use by the filter
Definition: avfilter.h:422
AV_SAMPLE_FMT_S64P
@ AV_SAMPLE_FMT_S64P
signed 64 bits, planar
Definition: samplefmt.h:69
AVFilterPad
A filter pad used for either input or output.
Definition: internal.h:33
av_cold
#define av_cold
Definition: attributes.h:90
intreadwrite.h
s
#define s(width, name)
Definition: cbs_vp9.c:198
AudioBitScopeContext::outpicref
AVFrame * outpicref
Definition: avf_abitscope.c:48
AVMEDIA_TYPE_AUDIO
@ AVMEDIA_TYPE_AUDIO
Definition: avutil.h:202
ff_formats_ref
int ff_formats_ref(AVFilterFormats *f, AVFilterFormats **ref)
Add *ref as a new reference to formats.
Definition: formats.c:679
av_strtok
char * av_strtok(char *s, const char *delim, char **saveptr)
Split the string into several tokens which can be accessed by successive calls to av_strtok().
Definition: avstring.c:178
filters.h
pix_fmts
static enum AVPixelFormat pix_fmts[]
Definition: libkvazaar.c:304
ctx
AVFormatContext * ctx
Definition: movenc.c:49
av_frame_clone
AVFrame * av_frame_clone(const AVFrame *src)
Create a new frame that references the same data as src.
Definition: frame.c:593
av_rescale_q
int64_t av_rescale_q(int64_t a, AVRational bq, AVRational cq)
Rescale a 64-bit integer by 2 rational numbers.
Definition: mathematics.c:142
AVFILTER_DEFINE_CLASS
AVFILTER_DEFINE_CLASS(abitscope)
FILTER_INPUTS
#define FILTER_INPUTS(array)
Definition: internal.h:182
filter_frame
static int filter_frame(AVFilterLink *inlink, AVFrame *insamples)
Definition: avf_abitscope.c:211
AV_PIX_FMT_RGBA
@ AV_PIX_FMT_RGBA
packed RGBA 8:8:8:8, 32bpp, RGBARGBA...
Definition: pixfmt.h:100
ff_inlink_make_frame_writable
int ff_inlink_make_frame_writable(AVFilterLink *link, AVFrame **rframe)
Make sure a frame is writable.
Definition: avfilter.c:1489
AVClass
Describe the class of an AVClass context structure.
Definition: log.h:66
ff_inlink_consume_samples
int ff_inlink_consume_samples(AVFilterLink *link, unsigned min, unsigned max, AVFrame **rframe)
Take samples from the link's FIFO and update the link's stats.
Definition: avfilter.c:1462
NULL
#define NULL
Definition: coverity.c:32
AVRational
Rational number (pair of numerator and denominator).
Definition: rational.h:58
AudioBitScopeContext
Definition: avf_abitscope.c:33
uninit
static av_cold void uninit(AVFilterContext *ctx)
Definition: avf_abitscope.c:296
AV_OPT_TYPE_IMAGE_SIZE
@ AV_OPT_TYPE_IMAGE_SIZE
offset must point to two consecutive integers
Definition: opt.h:245
parseutils.h
AudioBitScopeContext::counter
uint64_t counter[64]
Definition: avf_abitscope.c:46
AudioBitScopeContext::mode
int mode
Definition: avf_abitscope.c:38
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:94
AV_SAMPLE_FMT_U8P
@ AV_SAMPLE_FMT_U8P
unsigned 8 bits, planar
Definition: samplefmt.h:63
query_formats
static int query_formats(AVFilterContext *ctx)
Definition: avf_abitscope.c:69
inputs
static const AVFilterPad inputs[]
Definition: avf_abitscope.c:303
AV_SAMPLE_FMT_NONE
@ AV_SAMPLE_FMT_NONE
Definition: samplefmt.h:56
color
static const uint32_t color[16+AV_CLASS_CATEGORY_NB]
Definition: log.c:94
ff_avf_abitscope
const AVFilter ff_avf_abitscope
Definition: avf_abitscope.c:319
AVFrame::format
int format
format of the frame, -1 if unknown or unset Values correspond to enum AVPixelFormat for video frames,...
Definition: frame.h:462
AudioBitScopeContext::w
int w
Definition: avf_abitscope.c:35
FF_FILTER_FORWARD_WANTED
FF_FILTER_FORWARD_WANTED(outlink, inlink)
outputs
static const AVFilterPad outputs[]
Definition: avf_abitscope.c:311
AV_SAMPLE_FMT_S16P
@ AV_SAMPLE_FMT_S16P
signed 16 bits, planar
Definition: samplefmt.h:64
internal.h
AudioBitScopeContext::h
int h
Definition: avf_abitscope.c:35
i
#define i(width, name, range_min, range_max)
Definition: cbs_h2645.c:256
av_malloc_array
#define av_malloc_array(a, b)
Definition: tableprint_vlc.h:31
AudioBitScopeContext::depth
int depth
Definition: avf_abitscope.c:42
AVSampleFormat
AVSampleFormat
Audio sample formats.
Definition: samplefmt.h:55
av_inv_q
static av_always_inline AVRational av_inv_q(AVRational q)
Invert a rational.
Definition: rational.h:159
AVFilterPad::name
const char * name
Pad name.
Definition: internal.h:39
av_rescale
int64_t av_rescale(int64_t a, int64_t b, int64_t c)
Rescale a 64-bit integer with rounding to nearest.
Definition: mathematics.c:129
DO_TRACE
#define DO_TRACE(type, depth, one)
Definition: avf_abitscope.c:183
AVFilter
Filter definition.
Definition: avfilter.h:166
ret
ret
Definition: filter_design.txt:187
AudioBitScopeContext::nb_channels
int nb_channels
Definition: avf_abitscope.c:40
AVFrame::sample_aspect_ratio
AVRational sample_aspect_ratio
Sample aspect ratio for the video frame, 0/1 if unknown/unspecified.
Definition: frame.h:482
U
#define U(x)
Definition: vpx_arith.h:37
config_input
static int config_input(AVFilterLink *inlink)
Definition: avf_abitscope.c:103
ff_all_samplerates
AVFilterFormats * ff_all_samplerates(void)
Definition: formats.c:607
activate
static int activate(AVFilterContext *ctx)
Definition: avf_abitscope.c:274
mode
mode
Definition: ebur128.h:83
AV_PIX_FMT_NONE
@ AV_PIX_FMT_NONE
Definition: pixfmt.h:72
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Definition: opt.h:235
avfilter.h
AV_SAMPLE_FMT_DBLP
@ AV_SAMPLE_FMT_DBLP
double, planar
Definition: samplefmt.h:67
AVFilterContext
An instance of a filter.
Definition: avfilter.h:407
av_strdup
char * av_strdup(const char *s)
Duplicate a string.
Definition: mem.c:272
AudioBitScopeContext::current_vpos
int current_vpos
Definition: avf_abitscope.c:43
AVMEDIA_TYPE_VIDEO
@ AVMEDIA_TYPE_VIDEO
Definition: avutil.h:201
config_output
static int config_output(AVFilterLink *outlink)
Definition: avf_abitscope.c:139
mem.h
audio.h
AVFilterFormatsConfig::formats
AVFilterFormats * formats
List of supported formats (pixel or sample).
Definition: avfilter.h:510
av_free
#define av_free(p)
Definition: tableprint_vlc.h:33
FF_FILTER_FORWARD_STATUS
FF_FILTER_FORWARD_STATUS(inlink, outlink)
FILTER_OUTPUTS
#define FILTER_OUTPUTS(array)
Definition: internal.h:183
AudioBitScopeContext::colors
char * colors
Definition: avf_abitscope.c:37
AVFrame::linesize
int linesize[AV_NUM_DATA_POINTERS]
For video, a positive or negative value, which is typically indicating the size in bytes of each pict...
Definition: frame.h:420
avstring.h
AV_OPT_TYPE_STRING
@ AV_OPT_TYPE_STRING
Definition: opt.h:239
BARS
#define BARS(type, depth, one)
Definition: avf_abitscope.c:160
AV_OPT_TYPE_CONST
@ AV_OPT_TYPE_CONST
Definition: opt.h:244