diff options
author | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2015-01-14 12:00:56 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2015-01-16 12:46:52 +0100 |
commit | 291aea14636a0e779d874a01630524facb1397dd (patch) | |
tree | 044ff4131a9b3f5a3edb00e6a807d0609c04a182 /src/quick/scenegraph | |
parent | 39f1e0d66dc434e764731fbfed29c8fd98d217aa (diff) | |
parent | 88e87647c3b7d651dba2c8e61f945d47ecdd02c4 (diff) |
Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
.qmake.conf
src/qml/jsruntime/qv4context_p.h
src/qml/jsruntime/qv4debugging.cpp
src/qml/jsruntime/qv4engine.cpp
src/qml/jsruntime/qv4functionobject_p.h
src/qml/jsruntime/qv4qobjectwrapper.cpp
src/quick/scenegraph/shaders/visualization.frag
tests/auto/qml/qjsengine/tst_qjsengine.cpp
Change-Id: I492e8546c278f80a300a2129e9a29d861e144a30
Diffstat (limited to 'src/quick/scenegraph')
-rw-r--r-- | src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp | 5 | ||||
-rw-r--r-- | src/quick/scenegraph/qsgwindowsrenderloop.cpp | 2 | ||||
-rw-r--r-- | src/quick/scenegraph/shaders/visualization.frag | 2 |
3 files changed, 6 insertions, 3 deletions
diff --git a/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp b/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp index aef5b4ee79..fd9b2a4480 100644 --- a/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp +++ b/src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp @@ -2828,7 +2828,10 @@ void Renderer::visualizeBatch(Batch *b) g = gn->geometry(); shader->setUniformValue(shader->matrix, matrix * *gn->matrix()); glVertexAttribPointer(a.position, a.tupleSize, a.type, false, g->sizeOfVertex(), (void *) (qintptr) offset); - glDrawElements(g->drawingMode(), g->indexCount(), g->indexType(), g->indexData()); + if (g->indexCount()) + glDrawElements(g->drawingMode(), g->indexCount(), g->indexType(), g->indexData()); + else + glDrawArrays(g->drawingMode(), 0, g->vertexCount()); offset += g->sizeOfVertex() * g->vertexCount(); e = e->nextInBatch; } diff --git a/src/quick/scenegraph/qsgwindowsrenderloop.cpp b/src/quick/scenegraph/qsgwindowsrenderloop.cpp index 58d618a049..9f74e259e3 100644 --- a/src/quick/scenegraph/qsgwindowsrenderloop.cpp +++ b/src/quick/scenegraph/qsgwindowsrenderloop.cpp @@ -437,7 +437,7 @@ void QSGWindowsRenderLoop::renderWindow(QQuickWindow *window) d->fireFrameSwapped(); qCDebug(QSG_LOG_TIME_RENDERLOOP()).nospace() - << "Frame rendered with 'windows' renderloop in: " << time_swapped << "ms" + << "Frame rendered with 'windows' renderloop in: " << (time_swapped - time_start) / 1000000 << "ms" << ", polish=" << (time_polished - time_start) / 1000000 << ", sync=" << (time_synced - time_polished) / 1000000 << ", render=" << (time_rendered - time_synced) / 1000000 diff --git a/src/quick/scenegraph/shaders/visualization.frag b/src/quick/scenegraph/shaders/visualization.frag index 6cfeac1985..458d9dde14 100644 --- a/src/quick/scenegraph/shaders/visualization.frag +++ b/src/quick/scenegraph/shaders/visualization.frag @@ -6,6 +6,6 @@ varying mediump vec2 pos; void main(void) { lowp vec4 c = color; - c.xyz += pow(max(sin(pos.x + pos.y), 0.0), 2.0) * pattern * 0.1; + c.xyz += pow(max(sin(pos.x + pos.y), 0.0), 2.0) * pattern * 0.25; gl_FragColor = c; } |