12 #ifndef OSXGRAPHICSSTATEGUARDIAN_H 13 #define OSXGRAPHICSSTATEGUARDIAN_H 14 #include <Carbon/Carbon.h> 15 #include <ApplicationServices/ApplicationServices.h> 18 #include <OpenGL/gl.h> 48 virtual void *do_get_extension_func(
const char *name);
52 AGLContext get_context() {
return _aglcontext; };
54 const AGLPixelFormat get_agl_pixel_format()
const {
return _aglPixFmt; };
62 AGLPixelFormat _aglPixFmt;
63 AGLContext _aglcontext;
64 CGGammaValue _gOriginalRedTable[ 256 ];
65 CGGammaValue _gOriginalGreenTable[ 256 ];
66 CGGammaValue _gOriginalBlueTable[ 256 ];
67 uint32_t _sampleCount;
77 static void init_type() {
78 GLGraphicsStateGuardian::init_type();
80 GLGraphicsStateGuardian::get_class_type());
83 return get_class_type();
85 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
bool set_gamma(PN_stdfloat gamma)
Non static version of setting gamma.
An offscreen buffer in the OSX environment.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void draw_resize_box()
Draws an OSX-style resize icon in the bottom right corner of the current display region.
A tiny specialization on GLGraphicsStateGuardian to add some wgl-specific information.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void atexit_function()
This function is passed to the atexit function.
bool static_set_gamma(bool restore, PN_stdfloat gamma)
Static function for setting gamma which is needed for atexit.
An interface to the osx/ system for managing GL windows under X.
An object to create GraphicsOutputs that share a particular 3-D API.
void restore_gamma()
Restore original gamma.
OSStatus build_gl(bool full_screen, bool pbuffer, FrameBufferProperties &fb_props)
This function will build up a context for a gsg.
This class is the main interface to controlling the render process.
TypeHandle is the identifier used to differentiate C++ class types.
A container for the various kinds of properties we might ask to have on a graphics frameBuffer before...
virtual void reset()
Resets all internal state as if the gsg were newly created.
bool get_gamma_table()
Static function for getting the orig gamma tables.