VLC  4.0.0-dev
Modules | Files | Data Structures | Macros | Enumerations | Functions
Collaboration diagram for Video output:


 Sub-picture channels
 Video sub-pictures
 Video output display
 Video output display: output buffers and rendering.
 Video window


file  vlc_vout.h

Data Structures

struct  vout_thread_t
 Video output thread descriptor. More...


#define VOUT_ALIGN_LEFT   0x0001
#define VOUT_ALIGN_RIGHT   0x0002
#define VOUT_ALIGN_HMASK   0x0003
#define VOUT_ALIGN_TOP   0x0004
#define VOUT_ALIGN_BOTTOM   0x0008
#define VOUT_ALIGN_VMASK   0x000C
#define VOUT_SPU_CHANNEL_INVALID   (-1) /* Always fails in comparison */
#define VOUT_SPU_CHANNEL_OSD   0 /* OSD channel is automatically cleared */
#define vout_FlushAll(vout)   vout_Flush( vout, VLC_TICK_INVALID )
 Empty all the pending pictures in the vout. More...


 vout or spu_channel order More...


VLC_EXPORT void vout_Close (vout_thread_t *vout)
 Destroys a vout. More...
VLC_EXPORT int vout_GetSnapshot (vout_thread_t *p_vout, block_t **pp_image, picture_t **pp_picture, video_format_t *p_fmt, const char *psz_format, vlc_tick_t i_timeout)
 This function will handle a snapshot request. More...
VLC_EXPORT picture_tvout_GetPicture (vout_thread_t *)
 Allocates a video output picture buffer. More...
VLC_EXPORT void vout_PutPicture (vout_thread_t *, picture_t *)
 It gives to the vout a picture to be displayed. More...
VLC_EXPORT void vout_PutSubpicture (vout_thread_t *, subpicture_t *)
VLC_EXPORT ssize_t vout_RegisterSubpictureChannel (vout_thread_t *)
VLC_EXPORT void vout_UnregisterSubpictureChannel (vout_thread_t *, size_t)
VLC_EXPORT void vout_FlushSubpictureChannel (vout_thread_t *, size_t)
VLC_EXPORT void vout_Flush (vout_thread_t *p_vout, vlc_tick_t i_date)
 This function will ensure that all ready/displayed pictures have at most the provided date. More...

Detailed Description

Video rendering, output and window management

This module describes the programming interface for video output threads. It includes functions allowing to open a new thread, send pictures to a thread, and destroy a previously opened video output thread.

Macro Definition Documentation


#define VOUT_ALIGN_BOTTOM   0x0008


#define VOUT_ALIGN_HMASK   0x0003


#define VOUT_ALIGN_LEFT   0x0001


#define VOUT_ALIGN_RIGHT   0x0002


#define VOUT_ALIGN_TOP   0x0004


#define VOUT_ALIGN_VMASK   0x000C

◆ vout_FlushAll

#define vout_FlushAll (   vout)    vout_Flush( vout, VLC_TICK_INVALID )

Empty all the pending pictures in the vout.


#define VOUT_SPU_CHANNEL_INVALID   (-1) /* Always fails in comparison */


#define VOUT_SPU_CHANNEL_OSD   0 /* OSD channel is automatically cleared */







Enumeration Type Documentation

◆ vlc_vout_order

vout or spu_channel order


There is only one primary vout/spu_channel For vouts: this is the first vout, probably embedded in the UI.

For spu channels: main and first SPU channel.


There can be several secondary vouts or spu_channels For vouts: a secondary vout using its own window.

For spu channels: a secondary spu channel that is placed in function of the primary one. See "secondary-sub-margin" and "secondary-sub-alignment".

Function Documentation

◆ vout_Close()

VLC_EXPORT void vout_Close ( vout_thread_t vout)

◆ vout_Flush()

VLC_EXPORT void vout_Flush ( vout_thread_t p_vout,
vlc_tick_t  i_date 

This function will ensure that all ready/displayed pictures have at most the provided date.

References vout_thread_sys_t::control, vout_thread_sys_t::dummy, vout_control_Hold(), vout_control_Release(), vout_FlushUnlocked(), and VOUT_THREAD_TO_SYS.

Referenced by ModuleThread_PlayVideo().

◆ vout_FlushSubpictureChannel()

VLC_EXPORT void vout_FlushSubpictureChannel ( vout_thread_t ,

◆ vout_GetPicture()

VLC_EXPORT picture_t* vout_GetPicture ( vout_thread_t vout)

Allocates a video output picture buffer.

Either vout_PutPicture() or picture_Release() must be used to return the buffer to the video output free buffer pool.

You may use picture_Hold() (paired with picture_Release()) to keep a read-only reference.

References vout_thread_private_t::display_pool, vout_thread_sys_t::dummy, picture_t::format, likely, vout_thread_sys_t::original, picture_pool_Wait(), picture_Reset(), vout_thread_sys_t::private, video_format_CopyCropAr(), and VOUT_THREAD_TO_SYS.

◆ vout_GetSnapshot()

VLC_EXPORT int vout_GetSnapshot ( vout_thread_t p_vout,
block_t **  pp_image,
picture_t **  pp_picture,
video_format_t p_fmt,
const char *  psz_format,
vlc_tick_t  i_timeout 

This function will handle a snapshot request.

pp_image, pp_picture and p_fmt can be NULL otherwise they will be set with returned value in case of success.

pp_image will hold an encoded picture in psz_format format.

p_fmt can be NULL otherwise it will be set with the format used for the picture before encoding.

i_timeout specifies the time the function will wait for a snapshot to be available.

References vout_thread_sys_t::dummy, image_Type2Fourcc(), msg_Err, picture_Export(), picture_Release(), vout_thread_sys_t::snapshot, var_InheritInteger(), VLC_CODEC_PNG, VLC_EGENERIC, VLC_OBJECT, VLC_SUCCESS, vout_snapshot_Get(), and VOUT_THREAD_TO_SYS.

Referenced by VoutSaveSnapshot().

◆ vout_PutPicture()

VLC_EXPORT void vout_PutPicture ( vout_thread_t vout,
picture_t picture 

It gives to the vout a picture to be displayed.

The given picture MUST comes from vout_GetPicture.

Becareful, after vout_PutPicture is called, picture_t::p_next cannot be read/used.

References vout_thread_sys_t::control, vout_thread_sys_t::decoder_fifo, vout_thread_sys_t::dummy, picture_fifo_Push(), picture_HasChainedPics(), vout_control_Wake(), and VOUT_THREAD_TO_SYS.

Referenced by ModuleThread_PlayVideo().

◆ vout_PutSubpicture()

VLC_EXPORT void vout_PutSubpicture ( vout_thread_t ,

◆ vout_RegisterSubpictureChannel()

VLC_EXPORT ssize_t vout_RegisterSubpictureChannel ( vout_thread_t )

◆ vout_UnregisterSubpictureChannel()

VLC_EXPORT void vout_UnregisterSubpictureChannel ( vout_thread_t ,