Blender  V3.3
Macros | Functions
GHOST_ContextGLX.cpp File Reference
#include "GHOST_ContextGLX.h"
#include "GHOST_SystemX11.h"
#include <vector>
#include <cassert>
#include <cstdio>
#include <cstring>

Go to the source code of this file.

Macros

#define USE_GLXEW_INIT_WORKAROUND
 

Functions

static GLuint _glewStrLen (const GLubyte *s)
 
static GLboolean _glewSearchExtension (const char *name, const GLubyte *start, const GLubyte *end)
 
int GHOST_X11_GL_GetAttributes (int *attribs, int attribs_max, bool is_stereo_visual, bool need_alpha, bool for_fb_config)
 
static GLuint _glewStrCLen (const GLubyte *s, GLubyte c)
 
static GLboolean _glewStrSame (const GLubyte *a, const GLubyte *b, GLuint n)
 

Detailed Description

Definition of GHOST_ContextGLX class.

Definition in file GHOST_ContextGLX.cpp.

Macro Definition Documentation

◆ USE_GLXEW_INIT_WORKAROUND

#define USE_GLXEW_INIT_WORKAROUND

Definition at line 20 of file GHOST_ContextGLX.cpp.

Function Documentation

◆ _glewSearchExtension()

static GLboolean _glewSearchExtension ( const char *  name,
const GLubyte *  start,
const GLubyte *  end 
)
static

◆ _glewStrCLen()

static GLuint _glewStrCLen ( const GLubyte *  s,
GLubyte  c 
)
static

Definition at line 412 of file GHOST_ContextGLX.cpp.

References Freestyle::c.

Referenced by _glewSearchExtension().

◆ _glewStrLen()

static GLuint _glewStrLen ( const GLubyte *  s)
static

◆ _glewStrSame()

static GLboolean _glewStrSame ( const GLubyte *  a,
const GLubyte *  b,
GLuint  n 
)
static

Definition at line 424 of file GHOST_ContextGLX.cpp.

References Freestyle::a, and usdtokens::b().

Referenced by _glewSearchExtension().

◆ GHOST_X11_GL_GetAttributes()

int GHOST_X11_GL_GetAttributes ( int *  attribs,
int  attribs_max,
bool  is_stereo_visual,
bool  need_alpha,
bool  for_fb_config 
)

Utility function to get GLX attributes.

Parameters
for_fb_configThere are some small differences in #glXChooseVisual and #glXChooseFBConfig's attribute encoding.
Note
Similar to SDL's 'X11_GL_GetAttributes'

Definition at line 350 of file GHOST_ContextGLX.cpp.

References GHOST_ASSERT, and void.

Referenced by GHOST_ContextGLX::initializeDrawingContext(), and x11_visualinfo_from_glx().