qopenglfunctions_1_3.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/gui/opengl/qopenglfunctions_1_3.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3QOpenGLFunctions_1_3::QOpenGLFunctions_1_3()-
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_0_Deprecated(0)-
10 , d_1_1_Deprecated(0)-
11 , d_1_2_Deprecated(0)-
12 , d_1_3_Deprecated(0)-
13{-
14}
never executed: end of block
0
15-
16QOpenGLFunctions_1_3::~QOpenGLFunctions_1_3()-
17{-
18 if (d_1_0_Core
d_1_0_CoreDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
19 d_1_0_Core->refs.deref();
never executed: d_1_0_Core->refs.deref();
0
20 ((!(d_1_0_Core->refs.load())) ? qt_assert("d_1_0_Core->refs.load()",__FILE__,85) : qt_noop());-
21 if (d_1_1_Core
d_1_1_CoreDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
22 d_1_1_Core->refs.deref();
never executed: d_1_1_Core->refs.deref();
0
23 ((!(d_1_1_Core->refs.load())) ? qt_assert("d_1_1_Core->refs.load()",__FILE__,88) : qt_noop());-
24 if (d_1_2_Core
d_1_2_CoreDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
25 d_1_2_Core->refs.deref();
never executed: d_1_2_Core->refs.deref();
0
26 ((!(d_1_2_Core->refs.load())) ? qt_assert("d_1_2_Core->refs.load()",__FILE__,91) : qt_noop());-
27 if (d_1_3_Core
d_1_3_CoreDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
28 d_1_3_Core->refs.deref();
never executed: d_1_3_Core->refs.deref();
0
29 ((!(d_1_3_Core->refs.load())) ? qt_assert("d_1_3_Core->refs.load()",__FILE__,94) : qt_noop());-
30 if (d_1_0_Deprecated
d_1_0_DeprecatedDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
31 d_1_0_Deprecated->refs.deref();
never executed: d_1_0_Deprecated->refs.deref();
0
32 ((!(d_1_0_Deprecated->refs.load())) ? qt_assert("d_1_0_Deprecated->refs.load()",__FILE__,97) : qt_noop());-
33 if (d_1_1_Deprecated
d_1_1_DeprecatedDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
34 d_1_1_Deprecated->refs.deref();
never executed: d_1_1_Deprecated->refs.deref();
0
35 ((!(d_1_1_Deprecated->refs.load())) ? qt_assert("d_1_1_Deprecated->refs.load()",__FILE__,100) : qt_noop());-
36 if (d_1_2_Deprecated
d_1_2_DeprecatedDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
37 d_1_2_Deprecated->refs.deref();
never executed: d_1_2_Deprecated->refs.deref();
0
38 ((!(d_1_2_Deprecated->refs.load())) ? qt_assert("d_1_2_Deprecated->refs.load()",__FILE__,103) : qt_noop());-
39 if (d_1_3_Deprecated
d_1_3_DeprecatedDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
40 d_1_3_Deprecated->refs.deref();
never executed: d_1_3_Deprecated->refs.deref();
0
41 ((!(d_1_3_Deprecated->refs.load())) ? qt_assert("d_1_3_Deprecated->refs.load()",__FILE__,106) : qt_noop());-
42}
never executed: end of block
0
43-
44bool QOpenGLFunctions_1_3::initializeOpenGLFunctions()-
45{-
46 if ( isInitialized()
isInitialized()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
47 return
never executed: return true;
true;
never executed: return true;
0
48-
49 QOpenGLContext* context = QOpenGLContext::currentContext();-
50-
51-
52-
53 if (((owningContext()
owningContext()Description
TRUEnever evaluated
FALSEnever evaluated
&& owningContext() == context
owningContext() == contextDescription
TRUEnever evaluated
FALSEnever evaluated
) || !owningContext()
!owningContext()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
54 && QOpenGLFunctions_1_3::isContextCompatible(context)
QOpenGLFunctio...tible(context)Description
TRUEnever evaluated
FALSEnever evaluated
)
0
55 {-
56-
57-
58 QOpenGLVersionFunctionsBackend* d = 0;-
59 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());-
60 d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);-
61 d->refs.ref();-
62-
63 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());-
64 d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);-
65 d->refs.ref();-
66-
67 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());-
68 d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);-
69 d->refs.ref();-
70-
71 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());-
72 d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);-
73 d->refs.ref();-
74-
75 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());-
76 d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);-
77 d->refs.ref();-
78-
79 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());-
80 d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);-
81 d->refs.ref();-
82-
83 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());-
84 d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);-
85 d->refs.ref();-
86-
87 d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());-
88 d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);-
89 d->refs.ref();-
90-
91 QAbstractOpenGLFunctions::initializeOpenGLFunctions();-
92 }
never executed: end of block
0
93 return
never executed: return isInitialized();
isInitialized();
never executed: return isInitialized();
0
94}-
95-
96bool QOpenGLFunctions_1_3::isContextCompatible(QOpenGLContext *context)-
97{-
98 ((!(context)) ? qt_assert("context",__FILE__,163) : qt_noop());-
99 QSurfaceFormat f = context->format();-
100 const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());-
101 if (v < qMakePair(1, 3)
v < qMakePair(1, 3)Description
TRUEnever evaluated
FALSEnever evaluated
)
0
102 return
never executed: return false;
false;
never executed: return false;
0
103-
104 if (f.profile() == QSurfaceFormat::CoreProfile
f.profile() ==...t::CoreProfileDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
105 return
never executed: return false;
false;
never executed: return false;
0
106-
107 return
never executed: return true;
true;
never executed: return true;
0
108}-
109-
110QOpenGLVersionProfile QOpenGLFunctions_1_3::versionProfile()-
111{-
112 QOpenGLVersionProfile v;-
113 v.setVersion(1, 3);-
114 return
never executed: return v;
v;
never executed: return v;
0
115}-
116-
117-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9