VLC 4.0.0-dev
Loading...
Searching...
No Matches
vlc_filter.h
Go to the documentation of this file.
1/*****************************************************************************
2 * vlc_filter.h: filter related structures and functions
3 *****************************************************************************
4 * Copyright (C) 1999-2014 VLC authors and VideoLAN
5 *
6 * Authors: Gildas Bazin <gbazin@videolan.org>
7 * Antoine Cellerier <dionoea at videolan dot org>
8 * RĂ©mi Denis-Courmont
9 *
10 * This program is free software; you can redistribute it and/or modify it
11 * under the terms of the GNU Lesser General Public License as published by
12 * the Free Software Foundation; either version 2.1 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public License
21 * along with this program; if not, write to the Free Software Foundation,
22 * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
23 *****************************************************************************/
24
25#ifndef VLC_FILTER_H
26#define VLC_FILTER_H 1
27
28#include <vlc_es.h>
29#include <vlc_picture.h>
30#include <vlc_codec.h>
31
34
35/**
36 * \defgroup filter Filters
37 * \ingroup output
38 * Audio, video, text filters
39 * @{
40 * \file
41 * Filter modules interface
42 */
43
46 picture_t *(*buffer_new)(filter_t *);
47 vlc_decoder_device * (*hold_device)(vlc_object_t *, void *sys);
48};
49
52 struct
53 {
54 void (*on_changed)(filter_t *,
55 const struct vlc_audio_loudness *loudness);
57};
58
61 subpicture_t *(*buffer_new)(filter_t *);
62};
63
64typedef struct filter_owner_t
66 union
67 {
68 const struct filter_video_callbacks *video;
71 };
72
73 /* Input attachments
74 * XXX use filter_GetInputAttachments */
75 int (*pf_get_attachments)( filter_t *, input_attachment_t ***, int * );
77 void *sys;
80struct vlc_mouse_t;
81
84 /* Operation depending on the type of filter. */
85 union
86 {
87 /** Filter a picture (video filter) */
88 picture_t * (*filter_video)(filter_t *, picture_t *);
90 /** Filter an audio block (audio filter) */
91 block_t * (*filter_audio)(filter_t *, block_t *);
93 /** Blend a subpicture onto a picture (video blending) */
94 void (*blend_video)(filter_t *, picture_t *, const picture_t *,
95 int, int, int);
96
97 /** Generate a subpicture (sub source) */
98 subpicture_t *(*source_sub)(filter_t *, vlc_tick_t);
100 /** Filter a subpicture (sub filter) */
101 subpicture_t *(*filter_sub)(filter_t *, subpicture_t *);
103 /** Render text (text renderer)
104 *
105 * \return a picture-based region or NULL
106 */
107 subpicture_region_t * (*render)(filter_t *,
109 };
110
111 union
112 {
113 /* TODO: video filter drain */
114 /** Drain (audio filter) */
115 block_t *(*drain_audio)(filter_t *);
116 };
117
118 /** Flush
119 *
120 * Flush (i.e. discard) any internal buffer in a video or audio filter.
121 */
122 void (*flush)(filter_t *);
124 /** Change viewpoint
125 *
126 * Pass a new viewpoint to audio filters. Filters like the spatialaudio one
127 * used for Ambisonics rendering will change its output according to this
128 * viewpoint.
129 */
130 void (*change_viewpoint)(filter_t *, const vlc_viewpoint_t *);
132 /** Filter mouse state (video filter).
133 *
134 * If non-NULL, you must convert from output to input formats:
135 * - If VLC_SUCCESS is returned, the mouse state is propagated.
136 * - Otherwise, the mouse change is not propagated.
137 * If NULL, the mouse state is considered unchanged and will be
138 * propagated. */
139 int (*video_mouse)(filter_t *, struct vlc_mouse_t *,
140 const struct vlc_mouse_t *p_old);
141
142 /** Close the filter and release its resources. */
143 void (*close)(filter_t *);
145
146typedef int (*vlc_open_deinterlace)(filter_t *);
154
155#define set_deinterlace_callback( activate ) \
156 { \
157 vlc_open_deinterlace open__ = activate; \
158 (void) open__; \
159 set_callback(activate) \
160 } \
161 set_capability( "video filter", 0 ) \
162 add_shortcut( "deinterlace" )
163
164#define set_callback_video_filter( activate ) \
165 { \
166 vlc_video_filter_open open__ = activate; \
167 (void) open__; \
168 set_callback(activate) \
169 } \
170 set_capability( "video filter", 0 )
171
172#define set_callback_video_converter( activate, priority ) \
173 { \
174 vlc_video_converter_open open__ = activate; \
175 (void) open__; \
176 set_callback(activate) \
177 } \
178 set_capability( "video converter", priority )
179
180#define set_callback_text_renderer( activate, priority ) \
181 { \
182 vlc_video_text_renderer_open open__ = activate; \
183 (void) open__; \
184 set_callback(activate) \
185 } \
186 set_capability( "text renderer", priority )
187
188#define set_callback_sub_filter( activate ) \
189 { \
190 vlc_video_sub_filter_open open__ = activate; \
191 (void) open__; \
192 set_callback(activate) \
193 } \
194 set_capability( "sub filter", 0 )
195
196#define set_callback_sub_source( activate, priority ) \
197 { \
198 vlc_video_sub_source_open open__ = activate; \
199 (void) open__; \
200 set_callback(activate) \
201 } \
202 set_capability( "sub source", priority )
203
204#define set_callback_video_blending( activate, priority ) \
205 { \
206 vlc_video_blending_open open__ = activate; \
207 (void) open__; \
208 set_callback(activate) \
209 } \
210 set_capability( "video blending", priority )
211
212/** Structure describing a filter
213 * @warning BIG FAT WARNING : the code relies on the first 4 members of
214 * filter_t and decoder_t to be the same, so if you have anything to add,
215 * do it at the end of the structure.
216 */
217struct filter_t
219 struct vlc_object_t obj;
221 /* Module properties */
223 void *p_sys;
225 /* Input format */
227 vlc_video_context *vctx_in; // video filter, set by owner
229 /* Output format of filter */
231 vlc_video_context *vctx_out; // video filter, handled by the filter
234 /* Name of the "video filter" shortcut that is requested, can be NULL */
235 const char * psz_name;
236 /* Filter configuration */
237 const config_chain_t *p_cfg;
239 /* Implementation of filter API */
240 const struct vlc_filter_operations *ops;
242 /** Private structure for the owner of the filter */
245
246static inline void filter_Close( filter_t *p_filter )
248 if ( p_filter->ops->close )
249 p_filter->ops->close( p_filter );
250}
251
252/**
253 * This function will return a new picture usable by p_filter as an output
254 * buffer. You have to release it using picture_Release or by returning
255 * it to the caller as a ops->filter_video return value.
256 * Provided for convenience.
257 *
258 * \param p_filter filter_t object
259 * \return new picture on success or NULL on failure
260 */
261static inline picture_t *filter_NewPicture( filter_t *p_filter )
263 picture_t *pic = NULL;
264 if ( p_filter->owner.video != NULL && p_filter->owner.video->buffer_new != NULL)
265 pic = p_filter->owner.video->buffer_new( p_filter );
266 if ( pic == NULL )
267 {
268 // legacy filter owners not setting a default filter_allocator
269 pic = picture_NewFromFormat( &p_filter->fmt_out.video );
270 }
271 if( pic == NULL )
272 msg_Warn( p_filter, "can't get output picture" );
273 return pic;
274}
275
276/**
277 * Flush a filter
278 *
279 * This function will flush the state of a filter (audio or video).
280 */
281static inline void filter_Flush( filter_t *p_filter )
283 if( p_filter->ops->flush != NULL )
284 p_filter->ops->flush( p_filter );
285}
286
287static inline void filter_ChangeViewpoint( filter_t *p_filter,
289{
290 if( p_filter->ops->change_viewpoint != NULL )
291 p_filter->ops->change_viewpoint( p_filter, vp );
292}
293
294static inline vlc_decoder_device * filter_HoldDecoderDevice( filter_t *p_filter )
296 if ( !p_filter->owner.video || !p_filter->owner.video->hold_device )
297 return NULL;
298
299 return p_filter->owner.video->hold_device( VLC_OBJECT(p_filter), p_filter->owner.sys );
300}
301
304{
305 if ( !p_filter->owner.video || !p_filter->owner.video->hold_device )
306 return NULL;
307
308 vlc_decoder_device *dec_dev = p_filter->owner.video->hold_device( VLC_OBJECT(p_filter),
309 p_filter->owner.sys );
310 if ( dec_dev != NULL )
311 {
312 if ( dec_dev->type == type )
313 return dec_dev;
315 }
316 return NULL;
317}
318
319/**
320 * This function will drain, then flush an audio filter.
321 */
322static inline block_t *filter_DrainAudio( filter_t *p_filter )
324 if( p_filter->ops->drain_audio )
325 return p_filter->ops->drain_audio( p_filter );
326 else
327 return NULL;
328}
329
330static inline void filter_SendAudioLoudness(filter_t *filter,
331 const struct vlc_audio_loudness *loudness)
332{
333 assert(filter->owner.audio->meter_loudness.on_changed);
334 filter->owner.audio->meter_loudness.on_changed(filter, loudness);
335}
336
337/**
338 * This function will return a new subpicture usable by p_filter as an output
339 * buffer. You have to release it using subpicture_Delete or by returning it to
340 * the caller as a ops->sub_source return value.
341 * Provided for convenience.
342 *
343 * \param p_filter filter_t object
344 * \return new subpicture
345 */
346static inline subpicture_t *filter_NewSubpicture( filter_t *p_filter )
348 subpicture_t *subpic = p_filter->owner.sub->buffer_new( p_filter );
349 if( subpic == NULL )
350 msg_Warn( p_filter, "can't get output subpicture" );
351 return subpic;
352}
353
354/**
355 * This function gives all input attachments at once.
356 *
357 * You MUST release the returned values
358 */
359static inline int filter_GetInputAttachments( filter_t *p_filter,
360 input_attachment_t ***ppp_attachment,
361 int *pi_attachment )
362{
363 if( !p_filter->owner.pf_get_attachments )
364 return VLC_EGENERIC;
365 return p_filter->owner.pf_get_attachments( p_filter,
366 ppp_attachment, pi_attachment );
367}
368
369/**
370 * This function duplicates every variables from the filter, and adds a proxy
371 * callback to trigger filter events from obj.
372 *
373 * \param obj the object to add the callback proxy to
374 * \param filter the filter object for which the callback will be proxified
375 * \param restart_cb a vlc_callback_t to call if the event means restarting the
376 * filter (i.e. an event on a non-command variable)
377 */
379 vlc_callback_t restart_cb );
380# define filter_AddProxyCallbacks(a, b, c) \
381 filter_AddProxyCallbacks(VLC_OBJECT(a), b, c)
382
383/**
384 * This function removes the callbacks previously added to every duplicated
385 * variables, and removes them afterward.
386 *
387 * \param obj the object to remove the callback proxy from
388 * \param filter the filter object for which the callback was proxified
389 * \param restart_cb the same vlc_callback_t passed to filter_AddProxyCallbacks
390 */
392 vlc_callback_t restart_cb);
393# define filter_DelProxyCallbacks(a, b, c) \
394 filter_DelProxyCallbacks(VLC_OBJECT(a), b, c)
395
396typedef filter_t vlc_blender_t;
398/**
399 * It creates a blend filter.
400 *
401 * Only the chroma properties of the dest format is used (chroma
402 * type, rgb masks and shifts)
403 */
405
406/**
407 * It configures blend filter parameters that are allowed to changed
408 * after the creation.
409 */
410VLC_API int filter_ConfigureBlend( vlc_blender_t *, int i_dst_width, int i_dst_height, const video_format_t *p_src );
411
412/**
413 * It blends a picture into another one.
414 *
415 * The input picture is not modified and not released.
416 */
417VLC_API int filter_Blend( vlc_blender_t *, picture_t *p_dst, int i_dst_x, int i_dst_y, const picture_t *p_src, int i_alpha );
418
419/**
420 * It destroys a blend filter created by filter_NewBlend.
421 */
423
424/**
425 * Create a picture_t *(*)( filter_t *, picture_t * ) compatible wrapper
426 * using a void (*)( filter_t *, picture_t *, picture_t * ) function
427 *
428 * Currently used by the chroma video filters
429 */
430#define VIDEO_FILTER_WRAPPER_CLOSE_FILT( name, close_cb ) \
431 static picture_t *name ## _Filter ( filter_t *p_filter, \
432 picture_t *p_pic ) \
433 { \
434 picture_t *p_outpic = filter_NewPicture( p_filter ); \
435 if( p_outpic ) \
436 { \
437 name( p_filter, p_pic, p_outpic ); \
438 picture_CopyProperties( p_outpic, p_pic ); \
439 } \
440 picture_Release( p_pic ); \
441 return p_outpic; \
442 } \
443 static const struct vlc_filter_operations name ## _ops = { \
444 .filter_video = name ## _Filter, .close = close_cb, \
445 };
446
447#define VIDEO_FILTER_WRAPPER_CLOSE( name, close_cb ) \
448 static void name (filter_t *, picture_t *, picture_t *); \
449 static void close_cb (filter_t *); \
450 VIDEO_FILTER_WRAPPER_CLOSE_FILT( name, close_cb )
451
452#define VIDEO_FILTER_WRAPPER( name ) \
453 static void name (filter_t *, picture_t *, picture_t *); \
454 VIDEO_FILTER_WRAPPER_CLOSE_FILT( name, NULL )
455
456/**
457 * Wrappers to use when the filter function is not a static function
458 */
459#define VIDEO_FILTER_WRAPPER_EXT( name ) \
460 void name (filter_t *, picture_t *, picture_t *); \
461 VIDEO_FILTER_WRAPPER_CLOSE_FILT( name, NULL )
462
463#define VIDEO_FILTER_WRAPPER_CLOSE_EXT( name, close_cb ) \
464 void name (filter_t *, picture_t *, picture_t *); \
465 static void close_cb (filter_t *); \
466 VIDEO_FILTER_WRAPPER_CLOSE_FILT( name, close_cb )
467
468/**
469 * Filter chain management API
470 * The filter chain management API is used to dynamically construct filters
471 * and add them in a chain.
472 */
473
474typedef struct filter_chain_t filter_chain_t;
476/**
477 * Create new filter chain
478 *
479 * \param obj pointer to a vlc object
480 * \param psz_capability vlc capability of filters in filter chain
481 * \return pointer to a filter chain
482 */
483filter_chain_t * filter_chain_NewSPU(vlc_object_t *obj, const char *psz_capability)
485#define filter_chain_NewSPU( a, b ) filter_chain_NewSPU( VLC_OBJECT( a ), b )
487/**
488 * Creates a new video filter chain.
489 *
490 * \param obj pointer to parent VLC object
491 * \param change whether to allow changing the output format
492 * \param owner owner video buffer callbacks
493 * \return new filter chain, or NULL on error
494 */
496 const filter_owner_t *owner )
498#define filter_chain_NewVideo( a, b, c ) \
499 filter_chain_NewVideo( VLC_OBJECT( a ), b, c )
500
501/**
502 * Delete filter chain will delete all filters in the chain and free all
503 * allocated data. The pointer to the filter chain is then no longer valid.
504 *
505 * \param chain pointer to filter chain
506 */
508
509/**
510 * Reset filter chain will delete all filters in the chain and
511 * reset p_fmt_in and p_fmt_out to the new values.
512 *
513 * \param p_chain pointer to filter chain
514 * \param p_fmt_in new fmt_in params
515 * \param vctx_in new input video context
516 * \param p_fmt_out new fmt_out params
517 */
519 const es_format_t *p_fmt_in,
521 const es_format_t *p_fmt_out );
522
523/**
524 * Remove all existing filters
525 *
526 * \param p_chain pointer to filter chain
527 */
529
530/**
531 * Append a filter to the chain.
532 *
533 * \param chain filter chain to append a filter to
534 * \param name filter name
535 * \param cfg the configuration chain for the filter
536 * \param fmt_out filter output format
537 * \return a pointer to the filter or NULL on error
538 */
540 const char *name, const config_chain_t *cfg,
541 const es_format_t *fmt_out);
542
543/**
544 * Append a conversion to the chain.
545 *
546 * \param chain filter chain to append a filter to
547 * \param fmt_out filter output format
548 * \retval VLC_SUCCESS on success
549 */
551 const es_format_t *fmt_out);
552
553/**
554 * Append new filter to filter chain from string.
555 *
556 * \param chain filter chain to append a filter to
557 * \param str filters chain nul-terminated string
558 */
560 const char *str);
561
562/**
563 * Delete filter from filter chain. This function also releases the filter
564 * object and unloads the filter modules. The pointer to p_filter is no
565 * longer valid after this function successfully returns.
566 *
567 * \param chain filter chain to remove the filter from
568 * \param filter filter to remove from the chain and delete
569 *
570 * \note the filter must be created with filter_chain_AppendConverter() or
571 * filter_chain_AppendFilter().
572 */
574 filter_t *filter);
575
576/**
577 * Checks if the filter chain is empty.
578 *
579 * \param chain pointer to filter chain
580 * \return true if and only if there are no filters in this filter chain
581 */
583
584/**
585 * Get last output format of the last element in the filter chain.
586 *
587 * \param chain filter chain
588 */
590
591/**
592 * Get last output video context of the last element in the filter chain.
593 * \note doesn't create change the reference count
594 *
595 * \param chain filter chain
596 */
598
599/**
600 * Apply the filter chain to a video picture.
601 *
602 * \param chain pointer to filter chain
603 * \param pic picture to apply filters to
604 * \return modified picture after applying all video filters
605 */
607 picture_t *pic);
608
609/**
610 * Flush a video filter chain.
611 */
613
614/**
615 * Apply the filter chain to a mouse state.
616 *
617 * It will be applied from the output to the input. It makes sense only
618 * for a video filter chain.
619 *
620 * The vlc_mouse_t* pointers may be the same.
621 */
623 const struct vlc_mouse_t * );
624
626 int (*cb)( filter_t *, void * ), void *opaque );
627
628/** @} */
629#endif /* _VLC_FILTER_H */
#define VLC_USED
Definition fourcc_gen.c:32
#define VLC_API
Definition fourcc_gen.c:31
uint32_t vlc_fourcc_t
Definition fourcc_gen.c:33
void vlc_decoder_device_Release(vlc_decoder_device *device)
Release a decoder device.
Definition decoder_device.c:82
vlc_decoder_device_type
Decoder device type.
Definition vlc_codec.h:585
#define VLC_EGENERIC
Unspecified error.
Definition vlc_common.h:480
static void filter_ChangeViewpoint(filter_t *p_filter, const vlc_viewpoint_t *vp)
Definition vlc_filter.h:288
filter_t * filter_chain_AppendFilter(filter_chain_t *chain, const char *name, const config_chain_t *cfg, const es_format_t *fmt_out)
Append a filter to the chain.
Definition filter_chain.c:281
static void filter_Close(filter_t *p_filter)
Definition vlc_filter.h:247
int(* vlc_video_blending_open)(filter_t *)
Definition vlc_filter.h:153
filter_t vlc_blender_t
Definition vlc_filter.h:397
int(* vlc_video_filter_open)(filter_t *)
Definition vlc_filter.h:149
static vlc_decoder_device * filter_HoldDecoderDeviceType(filter_t *p_filter, enum vlc_decoder_device_type type)
Definition vlc_filter.h:303
int filter_chain_AppendConverter(filter_chain_t *chain, const es_format_t *fmt_out)
Append a conversion to the chain.
Definition filter_chain.c:289
int filter_Blend(vlc_blender_t *, picture_t *p_dst, int i_dst_x, int i_dst_y, const picture_t *p_src, int i_alpha)
It blends a picture into another one.
Definition filter.c:160
#define filter_AddProxyCallbacks(a, b, c)
Definition vlc_filter.h:381
static int filter_GetInputAttachments(filter_t *p_filter, input_attachment_t ***ppp_attachment, int *pi_attachment)
This function gives all input attachments at once.
Definition vlc_filter.h:360
static subpicture_t * filter_NewSubpicture(filter_t *p_filter)
This function will return a new subpicture usable by p_filter as an output buffer.
Definition vlc_filter.h:347
vlc_video_context * filter_chain_GetVideoCtxOut(const filter_chain_t *chain)
Get last output video context of the last element in the filter chain.
Definition filter_chain.c:393
int filter_chain_ForEach(filter_chain_t *chain, int(*cb)(filter_t *, void *), void *opaque)
Definition filter_chain.c:364
static void filter_SendAudioLoudness(filter_t *filter, const struct vlc_audio_loudness *loudness)
Definition vlc_filter.h:331
int filter_ConfigureBlend(vlc_blender_t *, int i_dst_width, int i_dst_height, const video_format_t *p_src)
It configures blend filter parameters that are allowed to changed after the creation.
Definition filter.c:126
int filter_chain_AppendFromString(filter_chain_t *chain, const char *str)
Append new filter to filter chain from string.
Definition filter_chain.c:317
int filter_chain_MouseFilter(filter_chain_t *, struct vlc_mouse_t *, const struct vlc_mouse_t *)
Apply the filter chain to a mouse state.
vlc_blender_t * filter_NewBlend(vlc_object_t *, const video_format_t *p_dst_chroma)
It creates a blend filter.
Definition filter.c:105
int(* vlc_video_converter_open)(filter_t *)
Definition vlc_filter.h:148
int(* vlc_video_sub_filter_open)(filter_t *)
Definition vlc_filter.h:151
#define filter_chain_NewSPU(a, b)
Definition vlc_filter.h:486
#define filter_chain_NewVideo(a, b, c)
Definition vlc_filter.h:499
static picture_t * filter_NewPicture(filter_t *p_filter)
This function will return a new picture usable by p_filter as an output buffer.
Definition vlc_filter.h:262
static vlc_decoder_device * filter_HoldDecoderDevice(filter_t *p_filter)
Definition vlc_filter.h:295
void filter_DeleteBlend(vlc_blender_t *)
It destroys a blend filter created by filter_NewBlend.
Definition filter.c:171
void filter_chain_VideoFlush(filter_chain_t *)
Flush a video filter chain.
Definition filter_chain.c:461
int(* vlc_open_deinterlace)(filter_t *)
Definition vlc_filter.h:147
static block_t * filter_DrainAudio(filter_t *p_filter)
This function will drain, then flush an audio filter.
Definition vlc_filter.h:323
void filter_chain_Reset(filter_chain_t *p_chain, const es_format_t *p_fmt_in, vlc_video_context *vctx_in, const es_format_t *p_fmt_out)
Reset filter chain will delete all filters in the chain and reset p_fmt_in and p_fmt_out to the new v...
Definition filter_chain.c:181
picture_t * filter_chain_VideoFilter(filter_chain_t *chain, picture_t *pic)
Apply the filter chain to a video picture.
Definition filter_chain.c:421
void filter_chain_Clear(filter_chain_t *)
Remove all existing filters.
Definition filter_chain.c:160
static void filter_Flush(filter_t *p_filter)
Flush a filter.
Definition vlc_filter.h:282
#define filter_DelProxyCallbacks(a, b, c)
Definition vlc_filter.h:394
int(* vlc_video_sub_source_open)(filter_t *)
Definition vlc_filter.h:152
void filter_chain_Delete(filter_chain_t *chain)
Delete filter chain will delete all filters in the chain and free all allocated data.
Definition filter_chain.c:167
int(* vlc_video_text_renderer_open)(filter_t *)
Definition vlc_filter.h:150
void filter_chain_DeleteFilter(filter_chain_t *chain, filter_t *filter)
Delete filter from filter chain.
Definition filter_chain.c:296
const es_format_t * filter_chain_GetFmtOut(const filter_chain_t *chain)
Get last output format of the last element in the filter chain.
Definition filter_chain.c:382
bool filter_chain_IsEmpty(const filter_chain_t *chain)
Checks if the filter chain is empty.
Definition filter_chain.c:377
#define msg_Warn(p_this,...)
Definition vlc_messages.h:104
int(* vlc_callback_t)(vlc_object_t *, char const *, vlc_value_t, vlc_value_t, void *)
Definition vlc_variables.h:135
#define VLC_OBJECT(x)
Type-safe vlc_object_t cast.
Definition vlc_objects.h:83
const char name[16]
Definition httpd.c:1298
picture_t * picture_NewFromFormat(const video_format_t *restrict fmt)
Definition picture.c:270
Definition vlc_configuration.h:320
Definition vlc_es.h:633
video_format_t video
description of video format
Definition vlc_es.h:661
Definition vlc_filter.h:52
struct filter_audio_callbacks::@221 meter_loudness
void(* on_changed)(filter_t *, const struct vlc_audio_loudness *loudness)
Definition vlc_filter.h:55
Definition filter_chain.c:47
es_format_t fmt_out
Chain output format (constant)
Definition filter_chain.c:55
vlc_object_t * obj
Definition filter_chain.c:48
vlc_video_context * vctx_in
Chain input video context (set on Reset)
Definition filter_chain.c:54
Definition vlc_filter.h:66
void * sys
Definition vlc_filter.h:78
const struct filter_video_callbacks * video
Definition vlc_filter.h:69
int(* pf_get_attachments)(filter_t *, input_attachment_t ***, int *)
Definition vlc_filter.h:76
const struct filter_subpicture_callbacks * sub
Definition vlc_filter.h:71
const struct filter_audio_callbacks * audio
Definition vlc_filter.h:70
Definition vlc_filter.h:61
subpicture_t *(* buffer_new)(filter_t *)
Definition vlc_filter.h:62
Structure describing a filter.
Definition vlc_filter.h:219
es_format_t fmt_in
Definition vlc_filter.h:227
vlc_video_context * vctx_out
Definition vlc_filter.h:232
module_t * p_module
Definition vlc_filter.h:223
const char * psz_name
Definition vlc_filter.h:236
filter_owner_t owner
Private structure for the owner of the filter.
Definition vlc_filter.h:244
vlc_video_context * vctx_in
Definition vlc_filter.h:228
const struct vlc_filter_operations * ops
Definition vlc_filter.h:241
void * p_sys
Definition vlc_filter.h:224
bool b_allow_fmt_out_change
Definition vlc_filter.h:233
const config_chain_t * p_cfg
Definition vlc_filter.h:238
struct vlc_object_t obj
Definition vlc_filter.h:220
es_format_t fmt_out
Definition vlc_filter.h:231
Definition vlc_filter.h:46
vlc_decoder_device *(* hold_device)(vlc_object_t *, void *sys)
Definition vlc_filter.h:48
picture_t *(* buffer_new)(filter_t *)
Definition vlc_filter.h:47
Definition vlc_input.h:169
Internal module descriptor.
Definition modules.h:76
Video picture.
Definition vlc_picture.h:130
Video subtitle region.
Definition vlc_subpicture.h:72
Video subtitle.
Definition vlc_subpicture.h:234
video format description
Definition vlc_es.h:356
Audio loudness measurement.
Definition vlc_aout.h:673
Decoder context struct.
Definition vlc_codec.h:606
enum vlc_decoder_device_type type
Must be set from the "decoder device" module open entry point.
Definition vlc_codec.h:616
Definition vlc_filter.h:84
void(* flush)(filter_t *)
Flush.
Definition vlc_filter.h:123
void(* change_viewpoint)(filter_t *, const vlc_viewpoint_t *)
Change viewpoint.
Definition vlc_filter.h:131
block_t *(* drain_audio)(filter_t *)
Drain (audio filter)
Definition vlc_filter.h:116
void(* blend_video)(filter_t *, picture_t *, const picture_t *, int, int, int)
Blend a subpicture onto a picture (video blending)
Definition vlc_filter.h:95
void(* close)(filter_t *)
Close the filter and release its resources.
Definition vlc_filter.h:144
int(* video_mouse)(filter_t *, struct vlc_mouse_t *, const struct vlc_mouse_t *p_old)
Filter mouse state (video filter).
Definition vlc_filter.h:140
Definition vlc_frame.h:123
Mouse state.
Definition vlc_mouse.h:46
VLC object common members.
Definition vlc_objects.h:53
Definition decoder_device.c:98
Viewpoints.
Definition vlc_viewpoint.h:41
Decoder and encoder modules interface.
This file is a collection of common definitions and types.
This file defines the elementary streams format types.
This file defines picture structures and functions in vlc.
int64_t vlc_tick_t
High precision date or time interval.
Definition vlc_tick.h:48