Beispiel #1
0
GlContext* GlContext::New()
{
    GlContext* context = new ContextType(sharedContext);
    context->Initialize();

    return context;
}
Beispiel #2
0
GlContext* GlContext::New(const ContextSettings& settings, unsigned int width, unsigned int height)
{
    // Make sure that there's an active context (context creation may need extensions, and thus a valid context)
    EnsureContext();

    // Create the context
    GlContext* context = new ContextType(sharedContext, settings, width, height);
    context->Initialize();

    return context;
}
Beispiel #3
0
GlContext* GlContext::New(const ContextSettings& settings, const WindowImpl* owner, unsigned int bitsPerPixel)
{
    // Make sure that there's an active context (context creation may need extensions, and thus a valid context)
    EnsureContext();

    // Create the context
    GlContext* context = new ContextType(sharedContext, settings, owner, bitsPerPixel);
    context->Initialize();

    return context;
}