Re: [Interest] Running code in the scene graph renderer thread

2013-04-11 Thread Sletta Gunnar
Hi! I'm implementing a plugin for Qt Multimedia for playing video and audio using hardware acceleration. When opening a content which includes video, I need to instantiate an OpenGL texture and an EGLImageKHR. To do this I need to be in the thread with the current OpenGL context, which should

Re: [Interest] Rotating objects in QML are killing performance

2013-04-12 Thread Sletta Gunnar
On Apr 11, 2013, at 8:43 PM, Alan Alpert 4163654...@gmail.com wrote: On Thu, Apr 11, 2013 at 10:08 AM, Michael Andersen mich...@steelcode.com wrote: Forgot list in reply. So no hope of it being fixed in 5.2 then... oh well. I'll go file a bug report. Does this happen on windows too or is

Re: [Interest] Rotating objects in QML are killing performance

2013-04-12 Thread Sletta Gunnar
On Apr 12, 2013, at 9:26 AM, Michael Andersen mich...@steelcode.com wrote: Is vsync enabled in your driver? Sounds like it might not be. If not, then Qt Quick 2.0 will render at 100% cpu rendering maybe many thousands of frames per second, even though you only see 60 of them.

Re: [Interest] Qt5 QML OpenGL and black texture problem

2013-05-02 Thread Sletta Gunnar
You are at least not setting the required texture parameters which will make the texture incomplete. You typically need to set the textures wrap and min/mag filters at least once: glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); glTexParameteri(GL_TEXTURE_2D,

Re: [Interest] Anti-aliasing for QML Canvas on Windows?

2013-05-02 Thread Sletta Gunnar
Antialiasing on an FBO requires FBO multisampling and framebuffer blit support. Do you have these extensions available? Cheers, Gunnar On 3. mai 2013, at 00:04, Mark mark...@gmail.com wrote: On Thu, May 2, 2013 at 11:47 PM, Mark mark...@gmail.com wrote: On Tue, Mar 12, 2013 at 12:22 AM,

Re: [Interest] QtQuick2 image rendering and custom shader overhead

2013-05-06 Thread Sletta Gunnar
On May 5, 2013, at 11:47 AM, Sean Harmer sean.har...@kdab.com wrote: On 04/05/2013 19:30, Preet wrote: Hi, ... 2. I'd like to use ShaderEffects to apply a somewhat trivial shader to most of the images in my application. The images are black and white icons, and I'd like to use

Re: [Interest] Particles Emitter, emit signal when particle life is expired?

2013-05-16 Thread Sletta Gunnar
On May 14, 2013, at 9:58 AM, Mark mark...@gmail.com wrote: On Sun, May 12, 2013 at 2:08 PM, Mark mark...@gmail.com wrote: Hi, I'm browsing through the Emitter API while searching for some way to get notified when a particle is expired. What i'm having is one emitter that emits 1

Re: [Interest] Apply shader effect from QtGraphicalEffects to QSGGeometryNode?

2013-06-12 Thread Sletta Gunnar
/qtdeclarative/trees/stable/examples/quick/scenegraph/openglunderqml [2] http://www.codeproject.com/Articles/226569/Drawing-polylines-by-tessellation On Mon, Jun 10, 2013 at 10:07 AM, Sletta Gunnar gunnar.sle...@digia.com wrote: On Jun 8, 2013, at 11:33 PM, Mark mark...@gmail.com wrote: Hi

Re: [Interest] Set shader on QSGFlatColorMaterial?

2013-06-12 Thread Sletta Gunnar
On Jun 9, 2013, at 12:59 AM, Mark mark...@gmail.com wrote: Hi, Yet another scene graph related question :) I have to say, the documentation in the scene graph department could really use some more docs and advanced examples! The code leaves a lot of guess work and there isn't much to find

Re: [Interest] Apply shader effect from QtGraphicalEffects to QSGGeometryNode?

2013-06-12 Thread Sletta Gunnar
, Mark mark...@gmail.com wrote: On Wed, Jun 12, 2013 at 8:29 AM, Sletta Gunnar gunnar.sle...@digia.com wrote: This graph concept might be a good usecase for a more complex example down the line though.. I'll keep it in mind and maybe it will be included in Qt in the future :) Oh... that sucks

Re: [Interest] QQuickWindow::update to render custom OpenGL in QtQuick2

2013-06-17 Thread Sletta Gunnar
On Jun 17, 2013, at 2:38 AM, Preet prismatic.proj...@gmail.com wrote: Hi I want to render things with OpenGL directly in a QQuickItem (like http://doc-snapshot.qt-project.org/qt5-dev/qtquick/scenegraph-openglunderqml.html shows) but I get the impression that doing so means every other

Re: [Interest] QML Presentation System, detailed docs roadmap?

2013-09-09 Thread Sletta Gunnar
Hi Charley, Thanks you for your interest in this project :) The original idea I had for the presentation system was to make it convenient to mix a slide deck with live QML. It makes the assumption that the user understands QML. I agree with you that there are tons of improvements that could

Re: [Interest] QML Presentation System, detailed docs roadmap?

2013-09-09 Thread Sletta Gunnar
On Sep 7, 2013, at 12:23 AM, Alan Alpert 4163654...@gmail.com wrote: *actually I still use its precedessor, https://gitorious.org/qt-qml-demo-playground/qt-qml-demo-playground/source/708de53727032441efd63f4ac24d13079fe82c52:qml-presentation , because while it's less user-friendly and less

Re: [Interest] Qt 5.1.1 render with both - OpenGL and QPainter - in one window?

2013-09-25 Thread Sletta Gunnar
This is very possible :) The classes you are looking for are: QWindow - to create the window QOpenGLContext - to get the OpenGL context QOpenGLPaintDevice - to make the opengl context renderable with QPainter QPainter - to draw the text. cheers, Gunnar On Sep 24, 2013, at 4:15 PM, Thomas

Re: [Interest] use custom fragment shader for Quick2 Image item

2013-10-22 Thread Sletta Gunnar
You can use a ShaderEffect element. It does not use an FBO for plain Image types. Image { id: myImage visible: false } ShaderEffect { property variant source: myImage anchors.fill: myImage fragmentShader: varying highp vec2 qt_TexCoord0; uniform lowp vec4

Re: [Interest] Turning on MSAA on a Qml-created Window

2013-11-04 Thread Sletta Gunnar
Hi Josh, This should be possible, but there are a few things to keep in mind. In Qt 5.1 the QQuickWindows all share the same OpenGL context, so you need to request multisampling on the first window you show, before you show it. As a result, all QQuickWindows will get multisampling. If you

Re: [Interest] Qt 5.2 scenegraph does not draw anything for our MIPS cpu/VIVANTE GPU platform

2013-11-06 Thread Sletta Gunnar
I find it very strange that qmlscene without an input file would produce the same apitrace as a qmlscene with a file. The apitrace is a reflection what we try to draw after all and that is highly dependent on what the input is. What does the trace look like? It is a long-shot, but you could

Re: [Interest] Qt 5.2 scenegraph does not draw anything for our MIPS cpu/VIVANTE GPU platform

2013-11-06 Thread Sletta Gunnar
A buffer offset of 0 is correct since it is relative to VBO's memory which is bound just above the lines you pasted down below. Fra: Narayanarao Rao [nar...@gmail.com] Sendt: 6. november 2013 11:02 To: Sletta Gunnar Cc: Interest@qt-project.org Emne: Re

Re: [Interest] Qt 5.2 scenegraph does not draw anything for our MIPS cpu/VIVANTE GPU platform

2013-11-06 Thread Sletta Gunnar
is unchanged. It will be a small overall additional cost, and if it is needed, it is needed. cheers, Gunnar Fra: Narayanarao Rao [nar...@gmail.com] Sendt: 6. november 2013 13:10 To: Sletta Gunnar Cc: Interest@qt-project.org Emne: Re: [Interest] Qt 5.2 scenegraph

Re: [Interest] Performance of Qt 5.2 much slower than Qt 5.1?

2013-11-06 Thread Sletta Gunnar
Is the time spent rendering gone up or is it something else? Generally, I see improved rendering performance across the board. If you run the code with QSG_RENDER_TIMING=1 you get some indication of the breakdown of where time is being spent. Performance of javascript has gone down some since

Re: [Interest] Quick2 ShaderEffect: source or provider missing when binding textures

2013-11-07 Thread Sletta Gunnar
The error message has been quite helpful with tracking down errors in the past, but I guess we can at least remove it from release builds and limit it a bit :) Added https://bugreports.qt-project.org/browse/QTBUG-34676 to track this. But why are you showing ShaderEffects which lack their image

Re: [Interest] Tearing in Quick2 flickable-based items with clipping enabled

2013-11-13 Thread Sletta Gunnar
If this consistently reproducible across desktop and device, then I would appreciate a bugreport with an example that reproduces it. It is not a known issue to me at least. (bugreports.qt-project.org) Clipping is implemented using scissor or stencil depending on the complexity of the mask, no

Re: [Interest] Tearing in Quick2 flickable-based items with clipping enabled

2013-11-19 Thread Sletta Gunnar
. - VStevenP On Thu, 11/14/13, Ola Røer Thorsen o...@silentwings.no wrote: Subject: Re: [Interest] Tearing in Quick2 flickable-based items with clipping enabled To: Sletta Gunnar gunnar.sle...@digia.com Cc: interest@qt-project.org interest@qt-project.org

Re: [Interest] QtQuick - ColorAnimation issue with colors that have alpha

2013-11-25 Thread Sletta Gunnar
I am unsure if it is intended or not, but the problem seems to be that you don't have a well defined base state to return to when you exit the pressed state. The result is that the transition will go from the pressed state to undefined and only after it completes does it apply the original

Re: [Interest] Implications of fractional x, y, width, height of QML Items?

2013-11-27 Thread Sletta Gunnar
In Qt Quick 2.0, there is no difference in performance, but there are some visual aspects you will have to consider. Once you start placing things on subpixel positions that also means you get antialiased edges on images and rects, texture sampling in images is no longer pixel-to-pixel, etc.

[Interest] OpenGL drivers

2013-11-29 Thread Sletta Gunnar
Hi, As many of you might already have noticed, OpenGL drivers are not always working as well as would like. This has always been a problem, but since Qt Creator 3.0 is using Qt Quick 2.0 and Qt Quick 2.0 is also being used in more and more places, the problem is becoming more mainstream. We

Re: [Interest] Qt5.2 OpenGL error

2013-12-04 Thread Sletta Gunnar
I suspect that those warnings are indicators of an underlying problem. They should not be fatal on their own. How does other OpenGL apps work on they system? Fra: interest-bounces+gunnar.sletta=digia@qt-project.org

Re: [Interest] Loader seems to be blocking animation

2013-12-10 Thread Sletta Gunnar
You want to have a look at the new Animator types introduced in Qt 5.2. These run on the render thread and won't be blocked when the loader is running. http://doc-snapshot.qt-project.org/qt5-stable/qtquick-statesanimations-topic.html#animators cheers, Gunnar

Re: [Interest] Loader seems to be blocking animation

2013-12-11 Thread Sletta Gunnar
the Yanimation to work for animating the highlighted background from icon to icon. - VStevenP - Original Message - From: Sletta Gunnar gunnar.sle...@digia.com To: VStevenP vstevenpa...@yahoo.com; interest@qt-project.org interest@qt-project.org Cc: Sent: Tuesday, December 10, 2013 8:43 AM Subject: SV

Re: [Interest] QOpenGLFramebufferObject, render to FBO using texture from another Image item?

2013-12-13 Thread Sletta Gunnar
Getting the Image element's textureProvider at the time of QQuickFrameBufferObject::synchronize should give you a QSGTextureProvider for that image, assuming that the Image.status == Ready. This is the same mechanism that ShaderEffect uses internally as well. You are not supposed to use the

Re: [Interest] Loader seems to be blocking animation

2013-12-13 Thread Sletta Gunnar
You also need to update your code to start the toplevel animation :) Fra: VStevenP [vstevenpa...@yahoo.com] Sendt: 12. desember 2013 15:22 To: Sletta Gunnar; interest Emne: Re: SV: [Interest] Loader seems to be blocking animation When I try to use this new