VLC 4.0.0-dev
Loading...
Searching...
No Matches
opengl.c File Reference
Include dependency graph for opengl.c:

Data Structures

struct  vlc_gl_priv_t
 
struct  vlc_gl_surface
 

Typedefs

typedef struct vlc_gl_surface vlc_gl_surface_t
 

Functions

static int vlc_gl_start (void *func, bool forced, va_list ap)
 
vlc_gl_tvlc_gl_Create (const struct vout_display_cfg *restrict cfg, unsigned flags, const char *name, const struct vlc_gl_cfg *gl_cfg)
 
vlc_gl_tvlc_gl_CreateOffscreen (vlc_object_t *parent, struct vlc_decoder_device *device, unsigned width, unsigned height, unsigned flags, const char *name, const struct vlc_gl_cfg *gl_cfg)
 
void vlc_gl_Delete (vlc_gl_t *gl)
 
static void vlc_gl_surface_ResizeNotify (vlc_window_t *surface, unsigned width, unsigned height, vlc_window_ack_cb cb, void *opaque)
 
vlc_gl_tvlc_gl_surface_Create (vlc_object_t *obj, const vlc_window_cfg_t *cfg, struct vlc_window **restrict wp, const struct vlc_gl_cfg *gl_cfg)
 
bool vlc_gl_surface_CheckSize (vlc_gl_t *gl, unsigned *restrict width, unsigned *restrict height)
 Checks if the dimensions of the surface used by the OpenGL context have changed (since the previous call), and the OpenGL viewport should be updated.
 
void vlc_gl_surface_Destroy (vlc_gl_t *gl)
 

Variables

static const struct vlc_gl_cfg gl_cfg_default
 

Typedef Documentation

◆ vlc_gl_surface_t

Function Documentation

◆ vlc_gl_Create()

◆ vlc_gl_CreateOffscreen()

◆ vlc_gl_Delete()

◆ vlc_gl_start()

static int vlc_gl_start ( void *  func,
bool  forced,
va_list  ap 
)
static

◆ vlc_gl_surface_CheckSize()

bool vlc_gl_surface_CheckSize ( vlc_gl_t gl,
unsigned *restrict  width,
unsigned *restrict  height 
)

Checks if the dimensions of the surface used by the OpenGL context have changed (since the previous call), and the OpenGL viewport should be updated.

Returns
true if at least one dimension has changed, false otherwise
Warning
This function is intrinsically race-prone. The dimensions can change asynchronously.

References vlc_gl_surface::height, vlc_gl_surface::lock, vlc_window::owner, vlc_gl_t::surface, vlc_window_owner::sys, vlc_gl_Resize(), vlc_mutex_lock(), vlc_mutex_unlock(), and vlc_gl_surface::width.

◆ vlc_gl_surface_Create()

◆ vlc_gl_surface_Destroy()

◆ vlc_gl_surface_ResizeNotify()

static void vlc_gl_surface_ResizeNotify ( vlc_window_t surface,
unsigned  width,
unsigned  height,
vlc_window_ack_cb  cb,
void *  opaque 
)
static

Variable Documentation

◆ gl_cfg_default

const struct vlc_gl_cfg gl_cfg_default
static
Initial value:
= {
.need_alpha = false
}

Referenced by vlc_gl_Create(), and vlc_gl_CreateOffscreen().