Panda3D
|
A tiny specialization on GLGraphicsStateGuardian to add some glx-specific information. More...
#include "glxGraphicsStateGuardian.h"
Public Member Functions | |
glxGraphicsStateGuardian (GraphicsEngine *engine, GraphicsPipe *pipe, glxGraphicsStateGuardian *share_with) | |
void | choose_pixel_format (const FrameBufferProperties &properties, X11_Display *_display, int _screen, bool need_pbuffer, bool need_pixmap) |
Selects a visual or fbconfig for all the windows and buffers that use this gsg. More... | |
virtual TypeHandle | force_init_type () |
const FrameBufferProperties & | get_fb_properties () const |
Gets the FrameBufferProperties for all windows and buffers that use this GSG. More... | |
void | get_properties (FrameBufferProperties &properties, XVisualInfo *visual) |
Gets the FrameBufferProperties to match the indicated visual. More... | |
void | get_properties_advanced (FrameBufferProperties &properties, bool &context_has_pbuffer, bool &pixmap_supported, bool &slow, GLXFBConfig config) |
Gets the FrameBufferProperties to match the indicated GLXFBConfig. More... | |
virtual TypeHandle | get_type () const |
bool | glx_is_at_least_version (int major_version, int minor_version) const |
Returns true if the runtime GLX version number is at least the indicated value, false otherwise. More... | |
![]() | |
PosixGraphicsStateGuardian (GraphicsEngine *engine, GraphicsPipe *pipe) | |
Static Public Member Functions | |
static TypeHandle | get_class_type () |
static void | init_type () |
![]() | |
static TypeHandle | get_class_type () |
static void | init_type () |
Public Attributes | |
GLXContext | _context |
bool | _context_has_pbuffer |
bool | _context_has_pixmap |
X11_Display * | _display |
GLXFBConfig | _fbconfig |
FrameBufferProperties | _fbprops |
PFNGLXCHOOSEFBCONFIGPROC | _glXChooseFBConfig |
PFNGLXCREATECONTEXTATTRIBSARBPROC | _glXCreateContextAttribs |
PFNGLXCREATEGLXPBUFFERSGIXPROC | _glXCreateGLXPbufferSGIX |
PFNGLXCREATENEWCONTEXTPROC | _glXCreateNewContext |
PFNGLXCREATEPBUFFERPROC | _glXCreatePbuffer |
PFNGLXCREATEPIXMAPPROC | _glXCreatePixmap |
PFNGLXDESTROYPBUFFERPROC | _glXDestroyPbuffer |
PFNGLXGETFBCONFIGATTRIBPROC | _glXGetFBConfigAttrib |
PFNGLXGETVISUALFROMFBCONFIGPROC | _glXGetVisualFromFBConfig |
PFNGLXSWAPINTERVALSGIPROC | _glXSwapIntervalSGI |
int | _screen |
GLXContext | _share_context |
bool | _slow |
bool | _supports_fbconfig |
bool | _supports_pbuffer |
bool | _supports_swap_control |
bool | _uses_sgix_pbuffer |
XVisualInfo * | _visual |
XVisualInfo * | _visuals |
A tiny specialization on GLGraphicsStateGuardian to add some glx-specific information.
Definition at line 78 of file glxGraphicsStateGuardian.h.
void glxGraphicsStateGuardian::choose_pixel_format | ( | const FrameBufferProperties & | properties, |
X11_Display * | display, | ||
int | screen, | ||
bool | need_pbuffer, | ||
bool | need_pixmap | ||
) |
Selects a visual or fbconfig for all the windows and buffers that use this gsg.
Also creates the GL context and obtains the visual.
Definition at line 235 of file glxGraphicsStateGuardian.cxx.
References FrameBufferProperties::get_quality(), and glx_is_at_least_version().
Referenced by glxGraphicsWindow::end_flip(), glxGraphicsBuffer::end_frame(), glxGraphicsPixmap::end_frame(), and get_properties_advanced().
|
inline |
Gets the FrameBufferProperties for all windows and buffers that use this GSG.
Definition at line 22 of file glxGraphicsStateGuardian.I.
Referenced by glxGraphicsWindow::begin_frame(), glxGraphicsWindow::end_flip(), glxGraphicsBuffer::end_frame(), and glxGraphicsPixmap::end_frame().
void glxGraphicsStateGuardian::get_properties | ( | FrameBufferProperties & | properties, |
XVisualInfo * | visual | ||
) |
Gets the FrameBufferProperties to match the indicated visual.
Definition at line 87 of file glxGraphicsStateGuardian.cxx.
References FrameBufferProperties::clear(), get_properties_advanced(), and FrameBufferProperties::set_rgba_bits().
void glxGraphicsStateGuardian::get_properties_advanced | ( | FrameBufferProperties & | properties, |
bool & | context_has_pbuffer, | ||
bool & | pixmap_supported, | ||
bool & | slow, | ||
GLXFBConfig | config | ||
) |
Gets the FrameBufferProperties to match the indicated GLXFBConfig.
Definition at line 147 of file glxGraphicsStateGuardian.cxx.
References choose_pixel_format(), FrameBufferProperties::clear(), and FrameBufferProperties::set_rgba_bits().
Referenced by get_properties().
bool glxGraphicsStateGuardian::glx_is_at_least_version | ( | int | major_version, |
int | minor_version | ||
) | const |
Returns true if the runtime GLX version number is at least the indicated value, false otherwise.
Definition at line 432 of file glxGraphicsStateGuardian.cxx.
References GraphicsOutput::get_pipe(), FrameBufferProperties::get_quality(), and x11GraphicsPipe::get_root().
Referenced by choose_pixel_format().