| Absolute File Name: | /home/qt/qt5_coco/qt5/qtbase/src/gui/opengl/qopenglfunctions_3_0.cpp |
| Switch to Source code | Preprocessed file |
| Line | Source | Count | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | - | |||||||||||||||||||
| 2 | - | |||||||||||||||||||
| 3 | QOpenGLFunctions_3_0::QOpenGLFunctions_3_0() | - | ||||||||||||||||||
| 4 | : QAbstractOpenGLFunctions() | - | ||||||||||||||||||
| 5 | , d_1_0_Core(0) | - | ||||||||||||||||||
| 6 | , d_1_1_Core(0) | - | ||||||||||||||||||
| 7 | , d_1_2_Core(0) | - | ||||||||||||||||||
| 8 | , d_1_3_Core(0) | - | ||||||||||||||||||
| 9 | , d_1_4_Core(0) | - | ||||||||||||||||||
| 10 | , d_1_5_Core(0) | - | ||||||||||||||||||
| 11 | , d_2_0_Core(0) | - | ||||||||||||||||||
| 12 | , d_2_1_Core(0) | - | ||||||||||||||||||
| 13 | , d_3_0_Core(0) | - | ||||||||||||||||||
| 14 | , d_1_0_Deprecated(0) | - | ||||||||||||||||||
| 15 | , d_1_1_Deprecated(0) | - | ||||||||||||||||||
| 16 | , d_1_2_Deprecated(0) | - | ||||||||||||||||||
| 17 | , d_1_3_Deprecated(0) | - | ||||||||||||||||||
| 18 | , d_1_4_Deprecated(0) | - | ||||||||||||||||||
| 19 | , m_reserved_2_0_Deprecated(nullptr) | - | ||||||||||||||||||
| 20 | , m_reserved_3_0_Deprecated(nullptr) | - | ||||||||||||||||||
| 21 | { | - | ||||||||||||||||||
| 22 | } | - | ||||||||||||||||||
| 23 | - | |||||||||||||||||||
| 24 | QOpenGLFunctions_3_0::~QOpenGLFunctions_3_0() | - | ||||||||||||||||||
| 25 | { | - | ||||||||||||||||||
| 26 | if (d_1_0_Core&& !
| 0 | ||||||||||||||||||
| 27 | d_1_0_Core->refs.deref()) { never executed: d_1_0_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_0_Core->refs.deref();never executed: ();d_1_0_Core->refs.deref();never executed: d_1_0_Core->refs.deref(); | ||||||||||||||||||||
| 28 | ((!(d_1_0_Core->contextrefs.load())) ? qt_assert("d_1_0_Core->refs.load()",QOpenGLFunctions_1_0_CoreBackend::versionStatus__FILE__,93) : qt_noop()); | - | ||||||||||||||||||
| 29 | delete d_1_0_Core; | 0 | ||||||||||||||||||
}if (d_1_1_Core&& !
| ||||||||||||||||||||
| 30 | d_1_1_Core->refs.deref()) { never executed: d_1_1_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_1_Core->refs.deref();never executed: ();d_1_1_Core->refs.deref();never executed: d_1_1_Core->refs.deref(); | ||||||||||||||||||||
| 31 | ((!(d_1_1_Core->contextrefs.load())) ? qt_assert("d_1_1_Core->refs.load()",QOpenGLFunctions_1_1_CoreBackend::versionStatus__FILE__,96) : qt_noop()); | - | ||||||||||||||||||
| 32 | delete d_1_1_Core; | 0 | ||||||||||||||||||
}if (d_1_2_Core&& !
| ||||||||||||||||||||
| 33 | d_1_2_Core->refs.deref()) { never executed: d_1_2_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_2_Core->refs.deref();never executed: ();d_1_2_Core->refs.deref();never executed: d_1_2_Core->refs.deref(); | ||||||||||||||||||||
| 34 | ((!(d_1_2_Core->contextrefs.load())) ? qt_assert("d_1_2_Core->refs.load()",QOpenGLFunctions_1_2_CoreBackend::versionStatus__FILE__,99) : qt_noop()); | - | ||||||||||||||||||
| 35 | delete d_1_2_Core; | 0 | ||||||||||||||||||
}if (d_1_3_Core&& !
| ||||||||||||||||||||
| 36 | d_1_3_Core->refs.deref()) { never executed: d_1_3_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_3_Core->refs.deref();never executed: ();d_1_3_Core->refs.deref();never executed: d_1_3_Core->refs.deref(); | ||||||||||||||||||||
| 37 | ((!(d_1_3_Core->contextrefs.load())) ? qt_assert("d_1_3_Core->refs.load()",QOpenGLFunctions_1_3_CoreBackend::versionStatus__FILE__,102) : qt_noop()); | - | ||||||||||||||||||
| 38 | delete d_1_3_Core; | 0 | ||||||||||||||||||
}if (d_1_4_Core&& !
| ||||||||||||||||||||
| 39 | d_1_4_Core->refs.deref()) { never executed: d_1_4_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_4_Core->refs.deref();never executed: ();d_1_4_Core->refs.deref();never executed: d_1_4_Core->refs.deref(); | ||||||||||||||||||||
| 40 | ((!(d_1_4_Core->contextrefs.load())) ? qt_assert("d_1_4_Core->refs.load()",QOpenGLFunctions_1_4_CoreBackend::versionStatus__FILE__,105) : qt_noop()); | - | ||||||||||||||||||
| 41 | delete d_1_4_Core; | 0 | ||||||||||||||||||
}if (d_1_5_Core&& !
| ||||||||||||||||||||
| 42 | d_1_5_Core->refs.deref()) { never executed: d_1_5_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_5_Core->refs.deref();never executed: ();d_1_5_Core->refs.deref();never executed: d_1_5_Core->refs.deref(); | ||||||||||||||||||||
| 43 | ((!(d_1_5_Core->contextrefs.load())) ? qt_assert("d_1_5_Core->refs.load()",QOpenGLFunctions_1_5_CoreBackend::versionStatus__FILE__,108) : qt_noop()); | - | ||||||||||||||||||
| 44 | delete d_1_5_Core; | 0 | ||||||||||||||||||
}if (d_2_0_Core&& !
| ||||||||||||||||||||
| 45 | d_2_0_Core->refs.deref()) { never executed: d_2_0_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_2_0_Core->refs.deref();never executed: ();d_2_0_Core->refs.deref();never executed: d_2_0_Core->refs.deref(); | ||||||||||||||||||||
| 46 | ((!(d_2_0_Core->contextrefs.load())) ? qt_assert("d_2_0_Core->refs.load()",QOpenGLFunctions_2_0_CoreBackend::versionStatus__FILE__,111) : qt_noop()); | - | ||||||||||||||||||
| 47 | delete d_2_0_Core; | 0 | ||||||||||||||||||
}if (d_2_1_Core&& !
| ||||||||||||||||||||
| 48 | d_2_1_Core->refs.deref()) { never executed: d_2_1_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_2_1_Core->refs.deref();never executed: ();d_2_1_Core->refs.deref();never executed: d_2_1_Core->refs.deref(); | ||||||||||||||||||||
| 49 | ((!(d_2_1_Core->contextrefs.load())) ? qt_assert("d_2_1_Core->refs.load()",QOpenGLFunctions_2_1_CoreBackend::versionStatus__FILE__,114) : qt_noop()); | - | ||||||||||||||||||
| 50 | delete d_2_1_Core; | 0 | ||||||||||||||||||
}if (d_3_0_Core&& !
| ||||||||||||||||||||
| 51 | d_3_0_Core->refs.deref()) { never executed: d_3_0_Core->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_3_0_Core->refs.deref();never executed: ();d_3_0_Core->refs.deref();never executed: d_3_0_Core->refs.deref(); | ||||||||||||||||||||
| 52 | ((!(d_3_0_Core->contextrefs.load())) ? qt_assert("d_3_0_Core->refs.load()",QOpenGLFunctions_3_0_CoreBackend::versionStatus__FILE__,117) : qt_noop()); | - | ||||||||||||||||||
| 53 | delete d_3_0_Core; | 0 | ||||||||||||||||||
}if (d_1_0_Deprecated&& !
| ||||||||||||||||||||
| 54 | d_1_0_Deprecated->refs.deref()) { never executed: d_1_0_Deprecated->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_0_Deprecated->refs.deref();never executed: ();d_1_0_Deprecated->refs.deref();never executed: d_1_0_Deprecated->refs.deref(); | ||||||||||||||||||||
| 55 | ((!(d_1_0_Deprecated->contextrefs.load())) ? qt_assert("d_1_0_Deprecated->refs.load()",QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus__FILE__,120) : qt_noop()); | - | ||||||||||||||||||
| 56 | delete d_1_0_Deprecated; | 0 | ||||||||||||||||||
}if (d_1_1_Deprecated&& !
| ||||||||||||||||||||
| 57 | d_1_1_Deprecated->refs.deref()) { never executed: d_1_1_Deprecated->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_1_Deprecated->refs.deref();never executed: ();d_1_1_Deprecated->refs.deref();never executed: d_1_1_Deprecated->refs.deref(); | ||||||||||||||||||||
| 58 | ((!(d_1_1_Deprecated->contextrefs.load())) ? qt_assert("d_1_1_Deprecated->refs.load()",QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus__FILE__,123) : qt_noop()); | - | ||||||||||||||||||
| 59 | delete d_1_1_Deprecated; | 0 | ||||||||||||||||||
}if (d_1_2_Deprecated&& !
| ||||||||||||||||||||
| 60 | d_1_2_Deprecated->refs.deref()) { never executed: d_1_2_Deprecated->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_2_Deprecated->refs.deref();never executed: ();d_1_2_Deprecated->refs.deref();never executed: d_1_2_Deprecated->refs.deref(); | ||||||||||||||||||||
| 61 | ((!(d_1_2_Deprecated->contextrefs.load())) ? qt_assert("d_1_2_Deprecated->refs.load()",QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus__FILE__,126) : qt_noop()); | - | ||||||||||||||||||
| 62 | delete d_1_2_Deprecated; | 0 | ||||||||||||||||||
}if (d_1_3_Deprecated&& !
| ||||||||||||||||||||
| 63 | d_1_3_Deprecated->refs.deref()) { never executed: d_1_3_Deprecated->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_3_Deprecated->refs.deref();never executed: ();d_1_3_Deprecated->refs.deref();never executed: d_1_3_Deprecated->refs.deref(); | ||||||||||||||||||||
| 64 | ((!(d_1_3_Deprecated->contextrefs.load())) ? qt_assert("d_1_3_Deprecated->refs.load()",QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus__FILE__,129) : qt_noop()); | - | ||||||||||||||||||
| 65 | delete d_1_3_Deprecated; | 0 | ||||||||||||||||||
}if (d_1_4_Deprecated&& !
| ||||||||||||||||||||
| 66 | d_1_4_Deprecated->refs.deref()) { never executed: d_1_4_Deprecated->refs.deref(); | 0 | ||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend( never executed: d_1_4_Deprecated->refs.deref();never executed: ();d_1_4_Deprecated->refs.deref();never executed: d_1_4_Deprecated->refs.deref(); | ||||||||||||||||||||
| 67 | ((!(d_1_4_Deprecated->contextrefs.load())) ? qt_assert("d_1_4_Deprecated->refs.load()",QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus__FILE__,132) : qt_noop()); | - | ||||||||||||||||||
| delete d_1_4_Deprecated; | ||||||||||||||||||||
| }} never executed: end of block | ||||||||||||||||||||
| 69 | - | |||||||||||||||||||
| 70 | bool QOpenGLFunctions_3_0::initializeOpenGLFunctions() | - | ||||||||||||||||||
| 71 | { | - | ||||||||||||||||||
| 72 | if ( isInitialized()
| 0 | ||||||||||||||||||
| 73 | return never executed: true;return true;never executed: return true; | 0 | ||||||||||||||||||
| 74 | - | |||||||||||||||||||
| 75 | QOpenGLContext* context = QOpenGLContext::currentContext(); | - | ||||||||||||||||||
| 76 | - | |||||||||||||||||||
| 77 | - | |||||||||||||||||||
| 78 | - | |||||||||||||||||||
| 79 | if (((owningContext()
| 0 | ||||||||||||||||||
| 80 | && QOpenGLFunctions_3_0::isContextCompatible(context)
| 0 | ||||||||||||||||||
| 81 | { | - | ||||||||||||||||||
| 82 | - | |||||||||||||||||||
| 83 | - | |||||||||||||||||||
| 84 | QOpenGLVersionFunctionsBackend* d = 0; | - | ||||||||||||||||||
| 85 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 86 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_0_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d); | ||||||||||||||||||||
| 87 | d->refs.ref(); | - | ||||||||||||||||||
| 88 | - | |||||||||||||||||||
| 89 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 90 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_1_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d); | ||||||||||||||||||||
| 91 | d->refs.ref(); | - | ||||||||||||||||||
| 92 | - | |||||||||||||||||||
| 93 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 94 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_2_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d); | ||||||||||||||||||||
| 95 | d->refs.ref(); | - | ||||||||||||||||||
| 96 | - | |||||||||||||||||||
| 97 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 98 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_3_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d); | ||||||||||||||||||||
| 99 | d->refs.ref(); | - | ||||||||||||||||||
| 100 | - | |||||||||||||||||||
| 101 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 102 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_4_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d); | ||||||||||||||||||||
| 103 | d->refs.ref(); | - | ||||||||||||||||||
| 104 | - | |||||||||||||||||||
| 105 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 106 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_5_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d); | ||||||||||||||||||||
| 107 | d->refs.ref(); | - | ||||||||||||||||||
| 108 | - | |||||||||||||||||||
| 109 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 110 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_2_0_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d); | ||||||||||||||||||||
| 111 | d->refs.ref(); | - | ||||||||||||||||||
| 112 | - | |||||||||||||||||||
| 113 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 114 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_2_1_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d); | ||||||||||||||||||||
| 115 | d->refs.ref(); | - | ||||||||||||||||||
| 116 | - | |||||||||||||||||||
| 117 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus()); | - | ||||||||||||||||||
| 118 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_3_0_CoreBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d); | ||||||||||||||||||||
| 119 | d->refs.ref(); | - | ||||||||||||||||||
| 120 | - | |||||||||||||||||||
| 121 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus()); | - | ||||||||||||||||||
| 122 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_0_DeprecatedBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d); | ||||||||||||||||||||
| 123 | d->refs.ref(); | - | ||||||||||||||||||
| 124 | - | |||||||||||||||||||
| 125 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus()); | - | ||||||||||||||||||
| 126 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_1_DeprecatedBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d); | ||||||||||||||||||||
| 127 | d->refs.ref(); | - | ||||||||||||||||||
| 128 | - | |||||||||||||||||||
| 129 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus()); | - | ||||||||||||||||||
| 130 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_2_DeprecatedBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d); | ||||||||||||||||||||
| 131 | d->refs.ref(); | - | ||||||||||||||||||
| 132 | - | |||||||||||||||||||
| 133 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus()); | - | ||||||||||||||||||
| 134 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_3_DeprecatedBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d); | ||||||||||||||||||||
| 135 | d->refs.ref(); | - | ||||||||||||||||||
| 136 | - | |||||||||||||||||||
| 137 | d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus()); | - | ||||||||||||||||||
| 138 | if (!d) { | - | ||||||||||||||||||
| d = new QOpenGLFunctions_1_4_DeprecatedBackend(context); | ||||||||||||||||||||
| QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d); | ||||||||||||||||||||
| }d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d); | ||||||||||||||||||||
| 139 | d->refs.ref(); | - | ||||||||||||||||||
| 140 | - | |||||||||||||||||||
| 141 | QAbstractOpenGLFunctions::initializeOpenGLFunctions(); | - | ||||||||||||||||||
| 142 | } never executed: end of block | 0 | ||||||||||||||||||
| 143 | return never executed: isInitialized();return isInitialized();never executed: return isInitialized(); | 0 | ||||||||||||||||||
| 144 | } | - | ||||||||||||||||||
| 145 | - | |||||||||||||||||||
| 146 | bool QOpenGLFunctions_3_0::isContextCompatible(QOpenGLContext *context) | - | ||||||||||||||||||
| 147 | { | - | ||||||||||||||||||
| 148 | ((!(context)) ? qt_assert("context",__FILE__,277213) : qt_noop()); | - | ||||||||||||||||||
| 149 | QSurfaceFormat f = context->format(); | - | ||||||||||||||||||
| 150 | const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion()); | - | ||||||||||||||||||
| 151 | if (v < qMakePair(3, 0)) | - | ||||||||||||||||||
| 152 | return false; | - | ||||||||||||||||||
| 153 | - | |||||||||||||||||||
| 154 | if (f.profile() == QSurfaceFormat::CoreProfile) | - | ||||||||||||||||||
| 155 | return false; | - | ||||||||||||||||||
| 156 | - | |||||||||||||||||||
| 157 | return true; | - | ||||||||||||||||||
| 158 | } | - | ||||||||||||||||||
| 159 | - | |||||||||||||||||||
| 160 | QOpenGLVersionProfile QOpenGLFunctions_3_0::versionProfile() | - | ||||||||||||||||||
| 161 | { | - | ||||||||||||||||||
| 162 | QOpenGLVersionProfile v; | - | ||||||||||||||||||
| 163 | v.setVersion(3, 0); | - | ||||||||||||||||||
| 164 | return v; | - | ||||||||||||||||||
| 165 | } | - | ||||||||||||||||||
| 166 | - | |||||||||||||||||||
| 167 | - | |||||||||||||||||||
| Switch to Source code | Preprocessed file |