diff options
Diffstat (limited to 'src/gui/opengl')
23 files changed, 31 insertions, 1 deletions
diff --git a/src/gui/opengl/qopenglfunctions_1_0.cpp b/src/gui/opengl/qopenglfunctions_1_0.cpp index 84db0f2d65..b618dcb5cf 100644 --- a/src/gui/opengl/qopenglfunctions_1_0.cpp +++ b/src/gui/opengl/qopenglfunctions_1_0.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_0 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_0 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_1_1.cpp b/src/gui/opengl/qopenglfunctions_1_1.cpp index b4860bcec7..bf032b5cf9 100644 --- a/src/gui/opengl/qopenglfunctions_1_1.cpp +++ b/src/gui/opengl/qopenglfunctions_1_1.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_1 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_1 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_1_2.cpp b/src/gui/opengl/qopenglfunctions_1_2.cpp index 064980bebe..2b14900680 100644 --- a/src/gui/opengl/qopenglfunctions_1_2.cpp +++ b/src/gui/opengl/qopenglfunctions_1_2.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_2 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_2 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_1_3.cpp b/src/gui/opengl/qopenglfunctions_1_3.cpp index ace7507e35..94605f8638 100644 --- a/src/gui/opengl/qopenglfunctions_1_3.cpp +++ b/src/gui/opengl/qopenglfunctions_1_3.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_3 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_3 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_1_4.cpp b/src/gui/opengl/qopenglfunctions_1_4.cpp index a27b81d6d8..e3035eeb55 100644 --- a/src/gui/opengl/qopenglfunctions_1_4.cpp +++ b/src/gui/opengl/qopenglfunctions_1_4.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_4 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_4 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_1_5.cpp b/src/gui/opengl/qopenglfunctions_1_5.cpp index ceb004b02c..581ed14aac 100644 --- a/src/gui/opengl/qopenglfunctions_1_5.cpp +++ b/src/gui/opengl/qopenglfunctions_1_5.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_1_5 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_1_5 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_2_0.cpp b/src/gui/opengl/qopenglfunctions_2_0.cpp index 15c042177d..2736d4a030 100644 --- a/src/gui/opengl/qopenglfunctions_2_0.cpp +++ b/src/gui/opengl/qopenglfunctions_2_0.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_2_0 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_2_0 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_2_1.cpp b/src/gui/opengl/qopenglfunctions_2_1.cpp index 143ac206ed..ed94131e33 100644 --- a/src/gui/opengl/qopenglfunctions_2_1.cpp +++ b/src/gui/opengl/qopenglfunctions_2_1.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_2_1 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_2_1 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_0.cpp b/src/gui/opengl/qopenglfunctions_3_0.cpp index e13122e683..e80235b957 100644 --- a/src/gui/opengl/qopenglfunctions_3_0.cpp +++ b/src/gui/opengl/qopenglfunctions_3_0.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_0 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_0 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_1.cpp b/src/gui/opengl/qopenglfunctions_3_1.cpp index 104029177c..ab48658bfc 100644 --- a/src/gui/opengl/qopenglfunctions_3_1.cpp +++ b/src/gui/opengl/qopenglfunctions_3_1.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_1 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_1 class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp b/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp index f808f2e6dd..171b7454f4 100644 --- a/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_2_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_2_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_2_core.cpp b/src/gui/opengl/qopenglfunctions_3_2_core.cpp index 0e1af4c28b..48dec29962 100644 --- a/src/gui/opengl/qopenglfunctions_3_2_core.cpp +++ b/src/gui/opengl/qopenglfunctions_3_2_core.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_2_Core \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_2_Core class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp b/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp index aa53b7d03b..8bebc7d0bc 100644 --- a/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_3_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_3_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_3_3_core.cpp b/src/gui/opengl/qopenglfunctions_3_3_core.cpp index d355a466c1..941f9c38b6 100644 --- a/src/gui/opengl/qopenglfunctions_3_3_core.cpp +++ b/src/gui/opengl/qopenglfunctions_3_3_core.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_3_3_Core \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_3_3_Core class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp index af5d3eccc1..7ab0688084 100644 --- a/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_0_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_0_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_0_core.cpp b/src/gui/opengl/qopenglfunctions_4_0_core.cpp index b018531b37..a4bf66a44b 100644 --- a/src/gui/opengl/qopenglfunctions_4_0_core.cpp +++ b/src/gui/opengl/qopenglfunctions_4_0_core.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_0_Core \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_0_Core class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp index 27c90adc5a..a0ea4a052a 100644 --- a/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_1_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_1_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp index a415b24f33..6d19fff92b 100644 --- a/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_2_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_2_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_2_core.cpp b/src/gui/opengl/qopenglfunctions_4_2_core.cpp index 3600c20a41..51ba3e8097 100644 --- a/src/gui/opengl/qopenglfunctions_4_2_core.cpp +++ b/src/gui/opengl/qopenglfunctions_4_2_core.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_2_Core \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_2_Core class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp index 75bcef1562..de6cc185c6 100644 --- a/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp +++ b/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_3_Compatibility \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_3_Compatibility class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_4_3_core.cpp b/src/gui/opengl/qopenglfunctions_4_3_core.cpp index bfe1bcc9c4..29fc8368aa 100644 --- a/src/gui/opengl/qopenglfunctions_4_3_core.cpp +++ b/src/gui/opengl/qopenglfunctions_4_3_core.cpp @@ -57,6 +57,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_4_3_Core \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_4_3_Core class provides all functions for this version and profile of OpenGL. \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglfunctions_es2.cpp b/src/gui/opengl/qopenglfunctions_es2.cpp index afac017d53..20a4b50994 100644 --- a/src/gui/opengl/qopenglfunctions_es2.cpp +++ b/src/gui/opengl/qopenglfunctions_es2.cpp @@ -48,6 +48,7 @@ QT_BEGIN_NAMESPACE \class QOpenGLFunctions_ES2 \inmodule QtGui \since 5.1 + \wrapper \brief The QOpenGLFunctions_ES2 class provides all functions for OpenGL ES 2 \sa QAbstractOpenGLFunctions diff --git a/src/gui/opengl/qopenglpaintengine.cpp b/src/gui/opengl/qopenglpaintengine.cpp index 555c47f265..0782e42531 100644 --- a/src/gui/opengl/qopenglpaintengine.cpp +++ b/src/gui/opengl/qopenglpaintengine.cpp @@ -226,9 +226,17 @@ void QOpenGL2PaintEngineExPrivate::updateBrushTexture() if (currentBrushPixmap.width() > max_texture_size || currentBrushPixmap.height() > max_texture_size) currentBrushPixmap = currentBrushPixmap.scaled(max_texture_size, max_texture_size, Qt::KeepAspectRatio); +#if defined(QT_OPENGL_ES_2) + // OpenGL ES does not support GL_REPEAT wrap modes for NPOT textures. So instead, + // we emulate GL_REPEAT by only taking the fractional part of the texture coords + // in the qopenglslTextureBrushSrcFragmentShader program. + GLuint wrapMode = GL_CLAMP_TO_EDGE; +#else + GLuint wrapMode = GL_REPEAT; +#endif funcs.glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT); QOpenGLTextureCache::cacheForContext(ctx)->bindTexture(ctx, currentBrushPixmap); - updateTextureFilter(GL_TEXTURE_2D, GL_REPEAT, q->state()->renderHints & QPainter::SmoothPixmapTransform); + updateTextureFilter(GL_TEXTURE_2D, wrapMode, q->state()->renderHints & QPainter::SmoothPixmapTransform); textureInvertedY = false; } brushTextureDirty = false; |