aboutsummaryrefslogtreecommitdiffstats
path: root/src/declarative/scenegraph
diff options
context:
space:
mode:
authorKim Motoyoshi Kalland <kim.kalland@nokia.com>2011-08-15 14:46:23 +0200
committerQt by Nokia <qt-info@nokia.com>2011-08-17 13:19:47 +0200
commit326ed5767e5d09ed3bf2177d5de17d4e07edf226 (patch)
treee434f2d4139d6ccf5a04632fd7e64fd0e76f6ffe /src/declarative/scenegraph
parent2e59a4415240d00a31b1c327007539a58c2d11bb (diff)
Implemented minimum FBO size on the ShaderEffectSource.
Task-number: QTBUG-20193 Change-Id: I45020c094c4a4892c055700f084fde7b219cdc10 Reviewed-on: http://codereview.qt.nokia.com/2972 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
Diffstat (limited to 'src/declarative/scenegraph')
-rw-r--r--src/declarative/scenegraph/qsgcontext.cpp15
-rw-r--r--src/declarative/scenegraph/qsgcontext_p.h1
2 files changed, 16 insertions, 0 deletions
diff --git a/src/declarative/scenegraph/qsgcontext.cpp b/src/declarative/scenegraph/qsgcontext.cpp
index 1f6f6e1e2a..2a9e007264 100644
--- a/src/declarative/scenegraph/qsgcontext.cpp
+++ b/src/declarative/scenegraph/qsgcontext.cpp
@@ -398,6 +398,21 @@ QSGTexture *QSGContext::createTexture(const QImage &image) const
/*!
+ Returns the minimum supported framebuffer object size.
+ */
+
+QSize QSGContext::minimumFBOSize() const
+{
+#ifdef Q_WS_MAC
+ return QSize(33, 33);
+#else
+ return QSize(1, 1);
+#endif
+}
+
+
+
+/*!
Returns a material shader for the given material.
*/
diff --git a/src/declarative/scenegraph/qsgcontext_p.h b/src/declarative/scenegraph/qsgcontext_p.h
index be7dff880a..29a5aac4b9 100644
--- a/src/declarative/scenegraph/qsgcontext_p.h
+++ b/src/declarative/scenegraph/qsgcontext_p.h
@@ -102,6 +102,7 @@ public:
QSize *size,
const QSize &requestSize);
virtual QSGTexture *createTexture(const QImage &image = QImage()) const;
+ virtual QSize minimumFBOSize() const;
static QSGContext *createDefaultContext();