VLC 4.0.0-dev
Loading...
Searching...
No Matches
vlc_picture_fifo.h File Reference

This file defines picture fifo structures and functions in vlc. More...

Include dependency graph for vlc_picture_fifo.h:

Go to the source code of this file.

Typedefs

typedef struct picture_fifo_t picture_fifo_t
 Picture fifo handle.
 

Functions

picture_fifo_tpicture_fifo_New (void)
 It creates an empty picture_fifo_t.
 
void picture_fifo_Delete (picture_fifo_t *)
 It destroys a fifo created by picture_fifo_New.
 
picture_tpicture_fifo_Pop (picture_fifo_t *)
 It retrieves a picture_t from the fifo.
 
bool picture_fifo_IsEmpty (picture_fifo_t *)
 It returns whether the fifo is empty or not.
 
void picture_fifo_Push (picture_fifo_t *, picture_t *)
 It saves a picture_t into the fifo.
 
void picture_fifo_Flush (picture_fifo_t *, vlc_tick_t date, bool flush_before)
 It release all picture inside the fifo that have a lower or equal date if flush_before or higher or equal to if not flush_before than the given one.
 

Detailed Description

This file defines picture fifo structures and functions in vlc.

Typedef Documentation

◆ picture_fifo_t

Picture fifo handle.

It is thread safe (push/pop).

Function Documentation

◆ picture_fifo_Delete()

void picture_fifo_Delete ( picture_fifo_t fifo)

It destroys a fifo created by picture_fifo_New.

All pictures inside the fifo will be released by picture_Release.

References picture_fifo_Flush(), and VLC_TICK_INVALID.

Referenced by image_HandlerDelete(), vout_ReleaseDisplay(), and vout_Start().

◆ picture_fifo_Flush()

void picture_fifo_Flush ( picture_fifo_t fifo,
vlc_tick_t  date,
bool  flush_before 
)

It release all picture inside the fifo that have a lower or equal date if flush_before or higher or equal to if not flush_before than the given one.

Passing VLC_TICK_INVALID on the date releases all the pictures.

All pictures inside the fifo will be released by picture_Release.

References picture_t::date, picture_fifo_t::lock, picture_fifo_t::pics, picture_Release(), PictureFifoPush(), vlc_mutex_lock(), vlc_mutex_unlock(), vlc_picture_chain_Append(), vlc_picture_chain_GetAndClear(), vlc_picture_chain_Init(), vlc_picture_chain_IsEmpty(), vlc_picture_chain_PopFront(), and VLC_TICK_INVALID.

Referenced by picture_fifo_Delete(), and vout_FlushUnlocked().

◆ picture_fifo_IsEmpty()

bool picture_fifo_IsEmpty ( picture_fifo_t fifo)

It returns whether the fifo is empty or not.

References picture_fifo_t::lock, picture_fifo_t::pics, vlc_mutex_lock(), vlc_mutex_unlock(), and vlc_picture_chain_IsEmpty().

Referenced by vout_IsEmpty().

◆ picture_fifo_New()

picture_fifo_t * picture_fifo_New ( void  )

◆ picture_fifo_Pop()

picture_t * picture_fifo_Pop ( picture_fifo_t fifo)

It retrieves a picture_t from the fifo.

If the fifo is empty, it return NULL without waiting.

References picture_fifo_t::lock, PictureFifoPop(), vlc_mutex_lock(), and vlc_mutex_unlock().

Referenced by ImageRead(), and PreparePicture().

◆ picture_fifo_Push()

void picture_fifo_Push ( picture_fifo_t fifo,
picture_t picture 
)