Ignore:
Timestamp:
May 5, 2011, 5:36:53 AM (14 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.7.2 sources from branches/vendor/nokia/qt.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/opengl/qgl_wince.cpp

    r769 r846  
    11/****************************************************************************
    22**
    3 ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
     3** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
    44** All rights reserved.
    55** Contact: Nokia Corporation (qt-info@nokia.com)
     
    5555#include <windows.h>
    5656
    57 #include <private/qegl_p.h>
     57#include <private/qeglproperties_p.h>
     58#include <private/qeglcontext_p.h>
    5859#include <private/qgl_egl_p.h>
    59 #include <private/qgl_cl_p.h>
    6060
    6161
     
    121121  QGLFormat Win32/WGL-specific code
    122122 *****************************************************************************/
    123 
    124 void qt_egl_add_platform_config(QEglProperties& props, QPaintDevice *device)
    125 {
    126     int devType = device->devType();
    127     if (devType == QInternal::Image)
    128         props.setPixelFormat(static_cast<QImage *>(device)->format());
    129     else
    130         props.setPixelFormat(QImage::Format_RGB16);
    131 }
    132 
    133123
    134124static bool opengl32dll = false;
     
    155145    // Get the display and initialize it.
    156146    d->eglContext = new QEglContext();
     147    d->ownsEglContext = true;
    157148    d->eglContext->setApi(QEgl::OpenGL);
    158149
    159150    // Construct the configuration we need for this surface.
    160151    QEglProperties configProps;
    161     qt_egl_add_platform_config(configProps, device());
    162     qt_egl_set_format(configProps, devType, d->glFormat);
     152    qt_eglproperties_set_glformat(configProps, d->glFormat);
     153    configProps.setDeviceType(devType);
     154    configProps.setPaintDeviceFormat(device());
    163155    configProps.setRenderableType(QEgl::OpenGL);
    164156
     
    172164
    173165    // Inform the higher layers about the actual format properties.
    174     qt_egl_update_format(*(d->eglContext), d->glFormat);
     166    qt_glformat_from_eglconfig(d->glFormat, d->eglContext->config());
    175167
    176168    // Create a new context for the configuration.
Note: See TracChangeset for help on using the changeset viewer.