Re: [Interest] Issue with concurrent QNetworkRequests

2017-10-04 Thread Jani Tykka
Actually it wasn't :)

Found out it was QTBUG in 5.6.2 https://bugreports.qt.io/browse/QTBUG-56616

On Wed, Sep 27, 2017 at 1:13 AM, Thiago Macieira <thiago.macie...@intel.com>
wrote:

> On terça-feira, 26 de setembro de 2017 13:12:43 PDT Jani Tykka wrote:
> > No special reason why I couldnt use 1 nam instance, I will try and see if
> > it makes any difference.
>
> Unlikely. The problem is most likely in your own code.
>
> --
> Thiago Macieira - thiago.macieira (AT) https://urldefense.proofpoint.
> com/v2/url?u=http-3A__intel.com=DwIFAw=uiYkEnhlQB0H-gDwErXr4Q=wvIt_
> JuLp9axQq3NQWhY0UHgd4iE-wQTwUWS6jf3nRM=vToAl6GAypyPc21hVu7JR2_
> 6PNunRPJ4u8Ywj7foFZw=9hfynwA_b-U8B5qZ_XijgqDpfp_S27bXLrgfdPxegNI=
>   Software Architect - Intel Open Source Technology Center
>
> ___
> Interest mailing list
> Interest@qt-project.org
> https://urldefense.proofpoint.com/v2/url?u=http-3A__lists.
> qt-2Dproject.org_mailman_listinfo_interest=DwIFAw=
> uiYkEnhlQB0H-gDwErXr4Q=wvIt_JuLp9axQq3NQWhY0UHgd4iE-wQTwUWS6jf3nRM=
> vToAl6GAypyPc21hVu7JR2_6PNunRPJ4u8Ywj7foFZw=
> EiazDpCklShK7bqmMfo25Iy9VeeQytm87HRFnr2yGUU=
>



-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.

Ce message confidentiel  et les éventuelles pièces jointes sont à l’usage 
exclusif de son ou de sa destinataire. Il est interdit, pour toute autre 
personne, de le distribuer, d’en dévoiler le contenu ou de le reproduire. 
Si vous avez reçu cette communication par erreur, veuillez en informer 
immédiatement l’expéditeur par courrier électronique et détruire l’original 
de ce message ainsi que toute copie.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Issue with concurrent QNetworkRequests

2017-09-26 Thread Jani Tykka
No special reason why I couldnt use 1 nam instance, I will try and see if
it makes any difference.

Thanks

ti 26.9.2017 klo 22.04 Thiago Macieira <thiago.macie...@intel.com>
kirjoitti:

> On terça-feira, 26 de setembro de 2017 11:55:35 PDT Jani Tykka wrote:
> > Hi,
> >
> > I'd ask if the following issues would ring anyones bells, before I start
> > doing more deeper investigation and create test application to reproduce
> > the issue. Basically the issue in our application is reproduced following
> > way.
> >
> > 1. Have 1 big download (https) 100MB (It uses own QNam instance)
> >  - file is being written from the data got from QNetworkReply::readyRead
> > 2. During the download execute other requests (https) using different
> QNam
> > instance
>
> Why are you using a separate instance?
>
> > What is experienced that if during download other requests are executed
> the
> > data received from readyRead contains extra bytes in the middle of
> chunked
> > responses. It can be that the total file size received grows to 120MB.
> > Those extra bytes are always zeros.
>
> If they were the same instance, I could maybe see how there could be a
> problem. With separate instances, I'm doubting there could be a problem in
> Qt.
>
> Anyway, please make sure by packet sniffing that the transfer sizes are
> correct.
> You don't need to decode the transfer, you just need to compare the size of
> the transfer during a correct write to the size of the transfer during an
> incorrect one.
>
> > Any help or ideas on this are warmly welcome, thanks.
>
> The most likely scenario is that your slot is doing stupid things.
>
> --
> Thiago Macieira - thiago.macieira (AT)
> https://urldefense.proofpoint.com/v2/url?u=http-3A__intel.com=DwIFAw=uiYkEnhlQB0H-gDwErXr4Q=wvIt_JuLp9axQq3NQWhY0UHgd4iE-wQTwUWS6jf3nRM=JZQbjY6e3maVFM0dGfDn-LDG5oLBQn8Gk3Gg2IkOilw=Lkmzg50z7jqtNsRMBPBWTS9T0uGAWzRK5LZ-BlNl-bQ=
>   Software Architect - Intel Open Source Technology Center
>
> ___
> Interest mailing list
> Interest@qt-project.org
>
> https://urldefense.proofpoint.com/v2/url?u=http-3A__lists.qt-2Dproject.org_mailman_listinfo_interest=DwIFAw=uiYkEnhlQB0H-gDwErXr4Q=wvIt_JuLp9axQq3NQWhY0UHgd4iE-wQTwUWS6jf3nRM=JZQbjY6e3maVFM0dGfDn-LDG5oLBQn8Gk3Gg2IkOilw=VT-NTaxmjcbiOPGiMabQ83hcoxb8AZBFwu5At5WMfZ4=
>
-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.

Ce message confidentiel  et les éventuelles pièces jointes sont à l’usage 
exclusif de son ou de sa destinataire. Il est interdit, pour toute autre 
personne, de le distribuer, d’en dévoiler le contenu ou de le reproduire. 
Si vous avez reçu cette communication par erreur, veuillez en informer 
immédiatement l’expéditeur par courrier électronique et détruire l’original 
de ce message ainsi que toute copie.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Issue with concurrent QNetworkRequests

2017-09-26 Thread Jani Tykka
Hi,

I'd ask if the following issues would ring anyones bells, before I start
doing more deeper investigation and create test application to reproduce
the issue. Basically the issue in our application is reproduced following
way.

1. Have 1 big download (https) 100MB (It uses own QNam instance)
 - file is being written from the data got from QNetworkReply::readyRead
2. During the download execute other requests (https) using different QNam
instance

What is experienced that if during download other requests are executed the
data received from readyRead contains extra bytes in the middle of chunked
responses. It can be that the total file size received grows to 120MB.
Those extra bytes are always zeros.

If there are no other request executed at the same time the download will
always be successful. This issue is only reproducible on Windows, not on
MacOS. There is no code relation (other than inside Qt) on those modules
where concurrent requests are being made.

Any help or ideas on this are warmly welcome, thanks.

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.

Ce message confidentiel  et les éventuelles pièces jointes sont à l’usage 
exclusif de son ou de sa destinataire. Il est interdit, pour toute autre 
personne, de le distribuer, d’en dévoiler le contenu ou de le reproduire. 
Si vous avez reçu cette communication par erreur, veuillez en informer 
immédiatement l’expéditeur par courrier électronique et détruire l’original 
de ce message ainsi que toute copie.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] WebEngineView memory cache

2017-04-05 Thread Jani Tykka
Thanks Kai,

Created https://bugreports.qt.io/browse/QTBUG-59951

Jani

On Wed, Apr 5, 2017 at 1:06 PM, Kai Koehne  wrote:
>> -Original Message-
>
>> [...]
>
>> WebEngineViews has possibility to set:
>
>> profile.httpCacheType: WebEngineProfile.MemoryHttpCache
>
>>
>
>> Even though memory cache is set I can see that WebCache directory is
>
>> created and data written there. Is this a bug or do you think it works as
>
>> expected?
>
>
>
> Hi Jani,
>
>
>
> This is at least something we should investigate. Feel free to file a bug at 
> https://urldefense.proofpoint.com/v2/url?u=http-3A__bugreports.qt.io=DwIGaQ=uiYkEnhlQB0H-gDwErXr4Q=wvIt_JuLp9axQq3NQWhY0UHgd4iE-wQTwUWS6jf3nRM=nWABsxGfesREmsD0CiPNr6P_03Qetpz5z0TbWyzCzoo=_BN9xhx5G4vtJz0klbtAq4xxo0OpVcF3BA77XhP7m58=
>   (Project:Qt, Component: WebEngine) , including the Qt version you're using.
>
>
>
> Regards
>
>
>
> Kai
>



-- 
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 | jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.

Ce message confidentiel  et les éventuelles pièces jointes sont à l’usage 
exclusif de son ou de sa destinataire. Il est interdit, pour toute autre 
personne, de le distribuer, d’en dévoiler le contenu ou de le reproduire. 
Si vous avez reçu cette communication par erreur, veuillez en informer 
immédiatement l’expéditeur par courrier électronique et détruire l’original 
de ce message ainsi que toute copie.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] WebEngineView memory cache

2017-04-04 Thread Jani Tykka
Hi,

WebEngineViews has possibility to set:
profile.httpCacheType: WebEngineProfile.MemoryHttpCache

Even though memory cache is set I can see that WebCache directory is
created and data written there. Is this a bug or do you think it works
as expected?

Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.

Ce message confidentiel  et les éventuelles pièces jointes sont à l’usage 
exclusif de son ou de sa destinataire. Il est interdit, pour toute autre 
personne, de le distribuer, d’en dévoiler le contenu ou de le reproduire. 
Si vous avez reçu cette communication par erreur, veuillez en informer 
immédiatement l’expéditeur par courrier électronique et détruire l’original 
de ce message ainsi que toute copie.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] QML WebEngineView and CPU usage

2017-02-10 Thread Jani Tykka
Hi,

It seems that QML WebEngineView is quite beast in eating CPU. I think
the cause for this is Chromium behind the WebEngine not yielding CPU
cycles? Is there any suggestions available how to improve the
situation?

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Suppressing Q_ASSERT on release builds

2017-01-12 Thread Jani Tykka
Thanks Thiago,

I Created two reports out of this: QTBUG-58103 and QTBUG-58104. After
digging more found out that the reason for assertion was because of
how the Qt build was configured.

Jani

On Wed, Jan 11, 2017 at 7:20 PM, Thiago Macieira
<thiago.macie...@intel.com> wrote:
> On quarta-feira, 11 de janeiro de 2017 10:58:29 PST Jani Tykka wrote:
>> The fact that delegated_frame_node.cpp is asserting in release build
>> is an issue in Qt that should be fixed. I ended up explicitly removing
>> Q_ASSERTs from that file. We have been receiving these crash reports
>> to our system from customers. The assert location is:
>>
>> 2016-11-22 08:41:04,791 QtLogger [0x70117000] FATAL ASSERT:
>> "texture->hasAlphaChannel() || !quadNeedsBlending" in file
>> /opt/jenkins/workspace/qt5_git_osx_64/qt5/qtwebengine/src/core/delegated_fra
>> me_node.cpp, line 382
>
> Please report this.
>
> I can't do anything because I don't check out and don't compile qtwebengine.
>
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>   Software Architect - Intel Open Source Technology Center
>
> ___
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest



-- 
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 | jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Suppressing Q_ASSERT on release builds

2017-01-11 Thread Jani Tykka
...Continuing (accidentally sent the mail)

The fact that delegated_frame_node.cpp is asserting in release build
is an issue in Qt that should be fixed. I ended up explicitly removing
Q_ASSERTs from that file. We have been receiving these crash reports
to our system from customers. The assert location is:

2016-11-22 08:41:04,791 QtLogger [0x70117000] FATAL ASSERT:
"texture->hasAlphaChannel() || !quadNeedsBlending" in file
/opt/jenkins/workspace/qt5_git_osx_64/qt5/qtwebengine/src/core/delegated_frame_node.cpp,
line 382

Next we'll see what happens when that assert is not triggered, will it
cause issues somewhere else? Any ideas about that? There is no way to
reproduce the issue.

Thanks

On Wed, Jan 11, 2017 at 10:52 AM, Jani Tykka <jty...@broadsoft.com> wrote:
> On Tue, Jan 10, 2017 at 5:35 PM, Thiago Macieira
> <thiago.macie...@intel.com> wrote:
>> Em terça-feira, 10 de janeiro de 2017, às 15:23:32 PST, Jani Tykka escreveu:
>>> It seems that QT_NO_DEBUG doesn't get defined when 3rd party libraries
>>> are built. Which means that if any 3rd party component includes
>>> qglobal.h will then end up defining Q_ASSERT in a way which is not
>>> desired for release builds.
>>
>> Are you talking about 3rdparty components that are used inside Qt? Which one
>> is including qglobal.h?
>>
>
> Yes, in qtbase:
>
> In file included from src/hb-blob.cc:32:
> In file included from src/hb-private.hh:33:
> In file included from ./config.h:25:
> In file included from ../../../include/QtCore/qatomic.h:1:
> In file included from
> ../../../include/QtCore/../../src/corelib/thread/qatomic.h:34:
> In file included from ../../../include/QtCore/qglobal.h:1:
>
>>> If I explicitly define precompiler macro during "configure" then that
>>> will be seen by 3rd party components.
>>>
>>> I think this is problem in Qt build system. QT_NO_DEBUG should end up
>>> to all components being build. Any thoughts, ideas, experience on this
>>> area? How to get this fixed? Of course I can define QT_NO_DEBUG in
>>> configure, but then in case when I want to build with
>>> --debug-and-release I'd need to make to separate builds to allow
>>> assertions on with debug builds.
>>
>> QT_NO_DEBUG is defined if you compile in release mode. It's right there in
>> qt.prf:
>>
>> CONFIG(release, debug|release):DEFINES += QT_NO_DEBUG
>>
>> The macro wouldn't get defined if the .pro file does CONFIG -= qt. Can you 
>> point
>> to which one(s) those are?
>>
>
> Actually I was confused about the above hb-blob compiled without
> QT_NO_DEBUG and started blaming that qtwebengine does the same, but
> then I found that there is a bit different story:
>
> src/core/delegated_frame_node.cpp asserts in release builds since:
>
> #undef __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES
> #define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
> #endif
>
> Then see 
> https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/AssertMacros.h
>
>
>
>
>
>
>>
>> --
>> Thiago Macieira - thiago.macieira (AT) intel.com
>>   Software Architect - Intel Open Source Technology Center
>>
>> ___
>> Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
>
>
>
> --
> Jani Tykkä
> Development Manager | BroadSoft, Inc. | +358 44 596 0587 | 
> jty...@broadsoft.com



-- 
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 | jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Suppressing Q_ASSERT on release builds

2017-01-11 Thread Jani Tykka
On Tue, Jan 10, 2017 at 5:35 PM, Thiago Macieira
<thiago.macie...@intel.com> wrote:
> Em terça-feira, 10 de janeiro de 2017, às 15:23:32 PST, Jani Tykka escreveu:
>> It seems that QT_NO_DEBUG doesn't get defined when 3rd party libraries
>> are built. Which means that if any 3rd party component includes
>> qglobal.h will then end up defining Q_ASSERT in a way which is not
>> desired for release builds.
>
> Are you talking about 3rdparty components that are used inside Qt? Which one
> is including qglobal.h?
>

Yes, in qtbase:

In file included from src/hb-blob.cc:32:
In file included from src/hb-private.hh:33:
In file included from ./config.h:25:
In file included from ../../../include/QtCore/qatomic.h:1:
In file included from
../../../include/QtCore/../../src/corelib/thread/qatomic.h:34:
In file included from ../../../include/QtCore/qglobal.h:1:

>> If I explicitly define precompiler macro during "configure" then that
>> will be seen by 3rd party components.
>>
>> I think this is problem in Qt build system. QT_NO_DEBUG should end up
>> to all components being build. Any thoughts, ideas, experience on this
>> area? How to get this fixed? Of course I can define QT_NO_DEBUG in
>> configure, but then in case when I want to build with
>> --debug-and-release I'd need to make to separate builds to allow
>> assertions on with debug builds.
>
> QT_NO_DEBUG is defined if you compile in release mode. It's right there in
> qt.prf:
>
> CONFIG(release, debug|release):DEFINES += QT_NO_DEBUG
>
> The macro wouldn't get defined if the .pro file does CONFIG -= qt. Can you 
> point
> to which one(s) those are?
>

Actually I was confused about the above hb-blob compiled without
QT_NO_DEBUG and started blaming that qtwebengine does the same, but
then I found that there is a bit different story:

src/core/delegated_frame_node.cpp asserts in release builds since:

#undef __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES
#define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
#endif

Then see 
https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/AssertMacros.h






>
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>   Software Architect - Intel Open Source Technology Center
>
> ___
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest



-- 
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 | jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Suppressing Q_ASSERT on release builds

2017-01-10 Thread Jani Tykka
Hi,

I'm trying to suppress Q_ASSERT to trigger assertion from qtwebengine
on release build.

It seems that QT_NO_DEBUG doesn't get defined when 3rd party libraries
are built. Which means that if any 3rd party component includes
qglobal.h will then end up defining Q_ASSERT in a way which is not
desired for release builds.

If I explicitly define precompiler macro during "configure" then that
will be seen by 3rd party components.

I think this is problem in Qt build system. QT_NO_DEBUG should end up
to all components being build. Any thoughts, ideas, experience on this
area? How to get this fixed? Of course I can define QT_NO_DEBUG in
configure, but then in case when I want to build with
--debug-and-release I'd need to make to separate builds to allow
assertions on with debug builds.

Thanks

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Crash in QSGOpaqueTextureMaterial::compare

2016-12-12 Thread Jani Tykka
Thanks Gunnar, will definitely look into this. Also noticed that it's
possible to give the texture ownership to node to simplify the case.

Jani

On Mon, Dec 12, 2016 at 11:39 AM, Gunnar Sletta <gun...@sletta.org> wrote:
> Hi Jani,
>
> If you have a dangling texture pointer in one of the nodes, then this will 
> most likely not crash during updatePaintNode() but rather during rendering 
> when the texture is taken into use. So I suggest you look at your nodes and 
> textures. The important bit is that no node is referencing a texture after 
> that texture has been deleted.
>
> A tool such as valgrind or similar memory debugger will greatly help you to 
> pinpoint the source of the deleted texture.
>
> cheers,
> Gunnar
>
>> On 12 Dec 2016, at 08:39, Jani Tykka <jty...@broadsoft.com> wrote:
>>
>> Actually QSGSimpleTextureNode is used. Just that crashes does rarely
>> or never occur when that part of code is being executed. They might
>> occur much later when that code has been already executed and deleted
>> or then the code is not related at all (really unsure about the steps
>> that produces the crash).
>>
>> Here is the code which is used in QQuickItem. Do you see anything
>> suspicious here? Thanks.
>>
>> QSGNode * VideoItem::updatePaintNode( QSGNode * node,
>> UpdatePaintNodeData * /*data*/ )
>> {
>> QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >( node );
>> if ( !n )
>>   n = new QSGSimpleTextureNode;
>> n->setRect( 0, 0, width(), height() );
>>
>> delete m_Texture;
>> m_Texture = window()->createTextureFromImage( m_Renderer->getImage() );
>> n->setTexture( m_Texture );
>> n->markDirty( QSGNode::DirtyGeometry );
>>
>> return n;
>> }
>>
>> On Fri, Dec 9, 2016 at 8:17 PM, Gunnar Sletta <gun...@sletta.org 
>> <mailto:gun...@sletta.org>> wrote:
>>> Is the application using QSGSimpleTextureNode and QSGTexture or is this a 
>>> plain QML application? If so, are you deleting textures at the right time 
>>> and updating nodes accordingly?
>>>
>>> We did have issues with textures being deleted out of turn on the render 
>>> thread, but that was fixed back in 5.1-days or so and I haven't seen 
>>> backtraces like this since then.
>>>
>>> cheers,
>>> Gunnar
>>>
>>>> On 09 Dec 2016, at 12:16, Jani Tykka <jty...@broadsoft.com> wrote:
>>>>
>>>> Hi,
>>>>
>>>> I'm experiencing a crash that is quite common, but no idea about steps
>>>> how to reproduce it (I have never been able to reproduce it myself,
>>>> but various users sees it time after time). I think it's not directly
>>>> a Qt bug, instead it might be something I do incorrectly. The crash
>>>> seems to be most common after the application had been idling for a
>>>> while or the computer is resumed from the sleep mode. Basically when
>>>> the scene needs to be rendered again. I'd appreciate any hints that
>>>> would help me to track this issue. See clipped crash stack traces
>>>> below (Qt 5.6.2 on Windows), thanks.
>>>>
>>>> Case 1
>>>> QSGOpaqueTextureMaterial::compare
>>>> qt5\qtdeclarative\src\quick\scenegraph\util\qsgtexturematerial.cpp:295
>>>> QSGBatchRenderer::Renderer::prepareOpaqueBatches
>>>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:1520
>>>> Qt5Core.dll Qt5Core.dll@0x1afb0
>>>> Qt5Quick.dll QSGBatchRenderer::Renderer::render
>>>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:2615
>>>> Qt5Quick.dll QSGRenderer::renderScene
>>>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgrenderer.cpp:217
>>>> Qt5Quick.dll QSGRenderer::renderScene
>>>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgrenderer.cpp:177
>>>> Qt5Quick.dll QSGRenderContext::renderNextFrame
>>>> qt5\qtdeclarative\src\quick\scenegraph\qsgcontext.cpp:555
>>>> Qt5Quick.dll QQuickWindowPrivate::renderSceneGraph
>>>> qt5\qtdeclarative\src\quick\items\qquickwindow.cpp:424
>>>> Qt5Quick.dll QSGWindowsRenderLoop::renderWindow
>>>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:452
>>>> Qt5Quick.dll QSGWindowsRenderLoop::render
>>>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:371
>>>> Qt5Quick.dll QSGWindowsRenderLoop::event
>>>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:350
&g

Re: [Interest] Crash in QSGOpaqueTextureMaterial::compare

2016-12-11 Thread Jani Tykka
Actually QSGSimpleTextureNode is used. Just that crashes does rarely
or never occur when that part of code is being executed. They might
occur much later when that code has been already executed and deleted
or then the code is not related at all (really unsure about the steps
that produces the crash).

Here is the code which is used in QQuickItem. Do you see anything
suspicious here? Thanks.

QSGNode * VideoItem::updatePaintNode( QSGNode * node,
UpdatePaintNodeData * /*data*/ )
{
QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >( node );
if ( !n )
   n = new QSGSimpleTextureNode;
n->setRect( 0, 0, width(), height() );

delete m_Texture;
m_Texture = window()->createTextureFromImage( m_Renderer->getImage() );
n->setTexture( m_Texture );
n->markDirty( QSGNode::DirtyGeometry );

return n;
}

On Fri, Dec 9, 2016 at 8:17 PM, Gunnar Sletta <gun...@sletta.org> wrote:
> Is the application using QSGSimpleTextureNode and QSGTexture or is this a 
> plain QML application? If so, are you deleting textures at the right time and 
> updating nodes accordingly?
>
> We did have issues with textures being deleted out of turn on the render 
> thread, but that was fixed back in 5.1-days or so and I haven't seen 
> backtraces like this since then.
>
> cheers,
> Gunnar
>
>> On 09 Dec 2016, at 12:16, Jani Tykka <jty...@broadsoft.com> wrote:
>>
>> Hi,
>>
>> I'm experiencing a crash that is quite common, but no idea about steps
>> how to reproduce it (I have never been able to reproduce it myself,
>> but various users sees it time after time). I think it's not directly
>> a Qt bug, instead it might be something I do incorrectly. The crash
>> seems to be most common after the application had been idling for a
>> while or the computer is resumed from the sleep mode. Basically when
>> the scene needs to be rendered again. I'd appreciate any hints that
>> would help me to track this issue. See clipped crash stack traces
>> below (Qt 5.6.2 on Windows), thanks.
>>
>> Case 1
>> QSGOpaqueTextureMaterial::compare
>> qt5\qtdeclarative\src\quick\scenegraph\util\qsgtexturematerial.cpp:295
>> QSGBatchRenderer::Renderer::prepareOpaqueBatches
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:1520
>> Qt5Core.dll Qt5Core.dll@0x1afb0
>> Qt5Quick.dll QSGBatchRenderer::Renderer::render
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:2615
>> Qt5Quick.dll QSGRenderer::renderScene
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgrenderer.cpp:217
>> Qt5Quick.dll QSGRenderer::renderScene
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgrenderer.cpp:177
>> Qt5Quick.dll QSGRenderContext::renderNextFrame
>> qt5\qtdeclarative\src\quick\scenegraph\qsgcontext.cpp:555
>> Qt5Quick.dll QQuickWindowPrivate::renderSceneGraph
>> qt5\qtdeclarative\src\quick\items\qquickwindow.cpp:424
>> Qt5Quick.dll QSGWindowsRenderLoop::renderWindow
>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:452
>> Qt5Quick.dll QSGWindowsRenderLoop::render
>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:371
>> Qt5Quick.dll QSGWindowsRenderLoop::event
>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:350
>> Qt5Widgets.dll QApplicationPrivate::notify_helper
>> qt5\qtbase\src\widgets\kernel\qapplication.cpp:3804
>> 
>>
>> Case 2
>> Qt5Quick.dll QSGOpaqueTextureMaterial::compare
>> qt5\qtdeclarative\src\quick\scenegraph\util\qsgtexturematerial.cpp:295
>> Qt5Quick.dll QSGBatchRenderer::Batch::isMaterialCompatible
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:620
>> Qt5Quick.dll QSGBatchRenderer::Renderer::nodeChanged
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgbatchrenderer.cpp:1212
>> Qt5Quick.dll QSGNode::markDirty
>> qt5\qtdeclarative\src\quick\scenegraph\coreapi\qsgnode.cpp:672
>> Qt5Quick.dll QSGDefaultImageNode::setTexture
>> qt5\qtdeclarative\src\quick\scenegraph\qsgdefaultimagenode.cpp:244
>> Qt5Quick.dll QQuickImage::updatePaintNode
>> qt5\qtdeclarative\src\quick\items\qquickimage.cpp:724
>> Qt5Quick.dll QQuickWindowPrivate::updateDirtyNode
>> qt5\qtdeclarative\src\quick\items\qquickwindow.cpp:3061
>> Qt5Quick.dll QQuickWindowPrivate::updateDirtyNodes
>> qt5\qtdeclarative\src\quick\items\qquickwindow.cpp:2806
>> Qt5Quick.dll QQuickWindowPrivate::syncSceneGraph
>> qt5\qtdeclarative\src\quick\items\qquickwindow.cpp:379
>> Qt5Quick.dll QSGWindowsRenderLoop::renderWindow
>> qt5\qtdeclarative\src\quick\scenegraph\qsgwindowsrenderloop.cpp:448
>> Qt5Quick.dll QSGWindowsRenderLoop::render
>> qt5\qtdeclara

Re: [Interest] Detecting container app on web page

2016-11-02 Thread Jani Tykka
The webpage would need to signal to it's container to do something.
With other non-Qt containers this is achieved by registering the
container as event listener. In case of Qt the webpage would instead
of postMessage just try to open url with some special scheme: like
custom://go.to/settings, then in WebEngineView we'd handle that in
"navigationRequested".

Using Qt web channel this could in theory would work by registering
custom object to receive the event, but since we have multiple web
views I'd like to avoid this approach.

Thanks,
Jani



On Wed, Nov 2, 2016 at 10:19 AM, Kai Koehne <kai.koe...@qt.io> wrote:
>
>
>> -Original Message-
>> From: Interest [mailto:interest-bounces+kai.koehne=qt...@qt-project.org]
>> On Behalf Of Jani Tykka
>> Sent: Wednesday, November 02, 2016 7:09 AM
>> To: interest@qt-project.org Interest <interest@qt-project.org>
>> Subject: [Interest] Detecting container app on web page
>>
>> Hi,
>>
>> I load web page to QML WebEngineView. Is there any method in Javascript
>> that can be used to detect on webpage that the container app is Qt
>> application?
>>
>>Of course I could use special HTTP user-agent header or give the information
>> in URL params when requesting the web page, but I'm curious if this can be
>> done in Javascript.
>
> You could indeed check the user agent, e.g.
>
>  navigator.userAgent.includes('QtWebEngine')
>
> Anyhow, may I ask why you need to know this? Ideally you'd check for the 
> API/functionality
> you're after, not the browser.
>
> Regards
>
> Kai
>



-- 
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 | jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Detecting container app on web page

2016-11-02 Thread Jani Tykka
Hi,

I load web page to QML WebEngineView. Is there any method in
Javascript that can be used to detect on webpage that the container
app is Qt application?

Of course I could use special HTTP user-agent header or give the
information in URL params when requesting the web page, but I'm
curious if this can be done in Javascript.

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] OSX Services menu

2016-05-25 Thread Jani Tykka
Hi,

Qt seems to lack support for Services menu, the menu appears but it misses
the content (only has link to system services). I could not find any Qt
reports related. Is this known issue? I can see this on any Qt app
including Creator.

Thanks,
Jani


-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] OSX system services with Qt

2016-05-09 Thread Jani Tykka
Hi,

Has anyone experience in providing system service on OS X according
https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/SysServices/introduction.html#//apple_ref/doc/uid/1101-SW1

Tried to follow the guide without success. Could there be something in
the Qt app that prevents this to work? Please let me know what are the
steps if you have managed to set the service provider.

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] QML and Cocoa based text edit

2016-04-28 Thread Jani Tykka
Hi,

I'm investigating whether it'd be possible to enable native dictation on
QML editors on OS X. I have found that to be able to enable dictation the
editor control needs to be Cocoa based. All ideas are welcome on how to
enable dictation on editor controls on QML.

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Quick2 OpenGL inefficiency?

2016-04-06 Thread Jani Tykka
Thank you for your suggestions.
We did implement rendering with using two FBOs, using glTexSubImage2D and
OpenGL directly without Qt wrappers.
The performance is quite good in most cases.

Noticed that there is still a huge performance difference between
MacBookPro Retina (wo/ external GPU) and
Mac Air with even slower CPU and Intel integrated. On Air the rendering is
really fast and it uses lot less CPU.
( Same video call on Air ~120% and ~340% on MBP. ) The only difference
seems to be the Retina.
 Is there anything that can be done to improve FBO based rendering on
Retina?
Something like disabling 'the retina awareness' for FBOs? We can´t do that
for the whole application for obvious reasons.

 Thanks


On Tue, Mar 8, 2016 at 9:40 AM, Filip Piechocki <fpiecho...@gmail.com>
wrote:

> I don't know how you produce the video frames, but check that the software
> you are using might be able to produce OpenGL texture directly (not the
> buffer data). If not then here are some useful links:
>
> http://stackoverflow.com/questions/9863969/updating-a-texture-in-opengl-with-glteximage2d
> http://www.gamedev.net/topic/641283-fastest-way-to-stream-video-to-texture/
>
> So basically you'll need to use glTexSubImage2D directly (and you probably
> do not need QImage at all) and for custom OpenGL rendering you can use
> QQuickFramebufferObject as your DisplayItem:
>
> http://blog.qt.io/blog/2015/05/11/integrating-custom-opengl-rendering-with-qt-quick-via-qquickframebufferobject/
>
> On Tue, Mar 8, 2016 at 7:00 AM, Jani Tykka <jty...@broadsoft.com> wrote:
>
>> I'm creating the image from buffer which is unsigned char buffer
>> containing video frame data
>> QImage( buffer, width, height, QImage::Format_RGB32 );
>>
>>
>>
>> On Mon, Mar 7, 2016 at 10:05 PM, Filip Piechocki <fpiecho...@gmail.com>
>> wrote:
>> >
>> > How are you generating those images? What do they represent?
>> >
>> > On Mar 7, 2016 20:55, "Jani Tykka" <jty...@broadsoft.com> wrote:
>> >>
>> >> Images are passed from another thread in rate 15-30 fps. Is there an
>> example available how to achieve Image to OpenGL texture and use it in
>> scene graph?
>> >>
>> >> On Mon, Mar 7, 2016 at 5:11 PM, Filip Piechocki <fpiecho...@gmail.com>
>> wrote:
>> >>>
>> >>> And where it comes from? How frequent it happens? Probably the best
>> thing here would be to generate this image as an OpenGL texture and then
>> use in the Qt's scene graph.
>> >>>
>> >>> On Mon, Mar 7, 2016 at 4:04 PM, Jani Tykka <jty...@broadsoft.com>
>> wrote:
>> >>>>
>> >>>> Yes, the image is always changed when the update is invoked.
>> >>>>
>> >>>> On Mon, Mar 7, 2016 at 4:43 PM, Filip Piechocki <
>> fpiecho...@gmail.com> wrote:
>> >>>>>
>> >>>>> Hi,
>> >>>>>
>> >>>>> Why are you re-creating the texture on every node update? Does the
>> m_Renderer->getImage() really changes? My first guess would be that the
>> texture creation from image is the most costly part here (uploading the
>> texture to GPU?) and I would do this only if necessary (the image really
>> changes).
>> >>>>>
>> >>>>> BR,
>> >>>>> Filip
>> >>>>>
>> >>>>> On Mon, Mar 7, 2016 at 3:04 PM, Jani Tykka <jty...@broadsoft.com>
>> wrote:
>> >>>>>>
>> >>>>>> Hi,
>> >>>>>>
>> >>>>>> We are rendering QImages on QQuickItem as following:
>> >>>>>>
>> >>>>>> QSGNode * DisplayItem::updatePaintNode( QSGNode * node,
>> UpdatePaintNodeData * /*data*/ )
>> >>>>>>
>> >>>>>> {
>> >>>>>>
>> >>>>>> QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >(
>> node );
>> >>>>>>
>> >>>>>> if ( !n )
>> >>>>>>
>> >>>>>> n = new QSGSimpleTextureNode;
>> >>>>>>
>> >>>>>>
>> >>>>>> n->setRect( 0, 0, width(), height() );
>> >>>>>>
>> >>>>>>
>> >>>>>> delete m_Texture;
>> >>>>>>
>> >>>>>>
>> >>>>>> m_Texture = window()->createTextureFromIm

[Interest] Lost OpenGL context and crash

2016-03-30 Thread Jani Tykka
Hi,

We are using Qt 5.5.1, D3D9 and ANGLE renderer. Rarely on some machines
after resuming from Windows lock screen we see the following error logged
"QWindowsEGLContext::swapBuffers: eglError: 12302, this: 0xf791378 ", that
error keeps repeating and usually after some time the application crashes:

crashing thread:
0libGLESv2.dlllibGLESv2.dll@0x52d17
1libGLESv2.dlllibGLESv2.dll@0x527c1
2libGLESv2.dlllibGLESv2.dll@0x526a4
3user32.dlluser32.dll@0x384f3
4user32.dlluser32.dll@0x16c40
5user32.dlluser32.dll@0x16820
6user32.dlluser32.dll@0x1d169
7ntdll.dllntdll.dll@0x78e76
8user32.dlluser32.dll@0x14f25
9user32.dlluser32.dll@0x1480a
10uxtheme.dlluxtheme.dll@0x27306
11uxtheme.dlluxtheme.dll@0x26148
12user32.dlluser32.dll@0x14c16
13qwindows.dllqwindows.dll@0xde6b
14icuuc54.dllicuuc54.dll@0x8033a
15qwindows.dllqwindows.dll@0xdc80

Found this QT-BUG https://bugreports.qt.io/browse/QTBUG-29223 which looks
exactly what we are seeing. Any thoughts what can be done? We cannot use
D3D11 which I suspect could fix this issue since we are seeing too many
other random crashes and strange UI behaviour with it compared to D3D9.

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] QML Image

2016-03-19 Thread Jani Tykka
Hi,

I'm using Qt 5.5.1. When quick2 window renders png-image defined in QML
Image element it seems that colors are not rendered exactly as defined in
source png-image. This seems to happen on images which have more
complicated color fills, like gradients. Is there anything that can be done
to achieve exact presentation from source image? Any explanation what is
causing the difference?

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] QML Image

2016-03-19 Thread Jani Tykka
Source size was already set as the original image size. When mipmap is set
colors seems to be even more distorted.

On Wed, Mar 16, 2016 at 10:45 PM, Jason H <jh...@gmx.com> wrote:

> Since you mention gradients, try setting source size or the mipmap
> properties. I wonder if you're getting some subsampling issue.
>
>
> *Sent:* Wednesday, March 16, 2016 at 8:26 AM
> *From:* "Jani Tykka" <jty...@broadsoft.com>
> *To:* "interest@qt-project.org Interest" <interest@qt-project.org>
> *Subject:* [Interest] QML Image
> Hi,
>
> I'm using Qt 5.5.1. When quick2 window renders png-image defined in QML
> Image element it seems that colors are not rendered exactly as defined in
> source png-image. This seems to happen on images which have more
> complicated color fills, like gradients. Is there anything that can be done
> to achieve exact presentation from source image? Any explanation what is
> causing the difference?
>
> Thanks,
> Jani
>
>
> This email is intended solely for the person or entity to which it is
> addressed and may contain confidential and/or privileged information. If
> you are not the intended recipient and have received this email in error,
> please notify BroadSoft, Inc. immediately by replying to this message, and
> destroy all copies of this message, along with any attachment, prior to
> reading, distributing or copying it.
> ___ Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>



-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] QML Image

2016-03-19 Thread Jani Tykka
Attached original image + comparison.

On Thu, Mar 17, 2016 at 4:28 PM, Jason H <jh...@gmx.com> wrote:

> A picture would help
>
> *Sent:* Thursday, March 17, 2016 at 1:15 AM
> *From:* "Jani Tykka" <jty...@broadsoft.com>
> *To:* "Jason H" <jh...@gmx.com>
> *Cc:* "interest@qt-project.org Interest" <interest@qt-project.org>
> *Subject:* Re: [Interest] QML Image
> Source size was already set as the original image size. When mipmap is set
> colors seems to be even more distorted.
>
> On Wed, Mar 16, 2016 at 10:45 PM, Jason H <jh...@gmx.com> wrote:
>>
>> Since you mention gradients, try setting source size or the mipmap
>> properties. I wonder if you're getting some subsampling issue.
>>
>>
>> *Sent:* Wednesday, March 16, 2016 at 8:26 AM
>> *From:* "Jani Tykka" <jty...@broadsoft.com>
>> *To:* "interest@qt-project.org Interest" <interest@qt-project.org>
>> *Subject:* [Interest] QML Image
>> Hi,
>>
>> I'm using Qt 5.5.1. When quick2 window renders png-image defined in QML
>> Image element it seems that colors are not rendered exactly as defined in
>> source png-image. This seems to happen on images which have more
>> complicated color fills, like gradients. Is there anything that can be done
>> to achieve exact presentation from source image? Any explanation what is
>> causing the difference?
>>
>> Thanks,
>> Jani
>>
>> This email is intended solely for the person or entity to which it is
>> addressed and may contain confidential and/or privileged information. If
>> you are not the intended recipient and have received this email in error,
>> please notify BroadSoft, Inc. immediately by replying to this message, and
>> destroy all copies of this message, along with any attachment, prior to
>> reading, distributing or copying it.
>> ___ Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
>>
>
>
> --
> *Jani Tykkä*
> Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
> jty...@broadsoft.com
>
>
> This email is intended solely for the person or entity to which it is
> addressed and may contain confidential and/or privileged information. If
> you are not the intended recipient and have received this email in error,
> please notify BroadSoft, Inc. immediately by replying to this message, and
> destroy all copies of this message, along with any attachment, prior to
> reading, distributing or copying it.
>



-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Quick2 OpenGL inefficiency?

2016-03-08 Thread Jani Tykka
Thanks a lot for the info! Will check that out.

Jani

On Tue, Mar 8, 2016 at 9:40 AM, Filip Piechocki <fpiecho...@gmail.com>
wrote:

> I don't know how you produce the video frames, but check that the software
> you are using might be able to produce OpenGL texture directly (not the
> buffer data). If not then here are some useful links:
>
> http://stackoverflow.com/questions/9863969/updating-a-texture-in-opengl-with-glteximage2d
> http://www.gamedev.net/topic/641283-fastest-way-to-stream-video-to-texture/
>
> So basically you'll need to use glTexSubImage2D directly (and you probably
> do not need QImage at all) and for custom OpenGL rendering you can use
> QQuickFramebufferObject as your DisplayItem:
>
> http://blog.qt.io/blog/2015/05/11/integrating-custom-opengl-rendering-with-qt-quick-via-qquickframebufferobject/
>
> On Tue, Mar 8, 2016 at 7:00 AM, Jani Tykka <jty...@broadsoft.com> wrote:
>
>> I'm creating the image from buffer which is unsigned char buffer
>> containing video frame data
>> QImage( buffer, width, height, QImage::Format_RGB32 );
>>
>>
>>
>> On Mon, Mar 7, 2016 at 10:05 PM, Filip Piechocki <fpiecho...@gmail.com>
>> wrote:
>> >
>> > How are you generating those images? What do they represent?
>> >
>> > On Mar 7, 2016 20:55, "Jani Tykka" <jty...@broadsoft.com> wrote:
>> >>
>> >> Images are passed from another thread in rate 15-30 fps. Is there an
>> example available how to achieve Image to OpenGL texture and use it in
>> scene graph?
>> >>
>> >> On Mon, Mar 7, 2016 at 5:11 PM, Filip Piechocki <fpiecho...@gmail.com>
>> wrote:
>> >>>
>> >>> And where it comes from? How frequent it happens? Probably the best
>> thing here would be to generate this image as an OpenGL texture and then
>> use in the Qt's scene graph.
>> >>>
>> >>> On Mon, Mar 7, 2016 at 4:04 PM, Jani Tykka <jty...@broadsoft.com>
>> wrote:
>> >>>>
>> >>>> Yes, the image is always changed when the update is invoked.
>> >>>>
>> >>>> On Mon, Mar 7, 2016 at 4:43 PM, Filip Piechocki <
>> fpiecho...@gmail.com> wrote:
>> >>>>>
>> >>>>> Hi,
>> >>>>>
>> >>>>> Why are you re-creating the texture on every node update? Does the
>> m_Renderer->getImage() really changes? My first guess would be that the
>> texture creation from image is the most costly part here (uploading the
>> texture to GPU?) and I would do this only if necessary (the image really
>> changes).
>> >>>>>
>> >>>>> BR,
>> >>>>> Filip
>> >>>>>
>> >>>>> On Mon, Mar 7, 2016 at 3:04 PM, Jani Tykka <jty...@broadsoft.com>
>> wrote:
>> >>>>>>
>> >>>>>> Hi,
>> >>>>>>
>> >>>>>> We are rendering QImages on QQuickItem as following:
>> >>>>>>
>> >>>>>> QSGNode * DisplayItem::updatePaintNode( QSGNode * node,
>> UpdatePaintNodeData * /*data*/ )
>> >>>>>>
>> >>>>>> {
>> >>>>>>
>> >>>>>> QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >(
>> node );
>> >>>>>>
>> >>>>>> if ( !n )
>> >>>>>>
>> >>>>>> n = new QSGSimpleTextureNode;
>> >>>>>>
>> >>>>>>
>> >>>>>> n->setRect( 0, 0, width(), height() );
>> >>>>>>
>> >>>>>>
>> >>>>>> delete m_Texture;
>> >>>>>>
>> >>>>>>
>> >>>>>> m_Texture = window()->createTextureFromImage(
>> m_Renderer->getImage() );
>> >>>>>>
>> >>>>>> n->setTexture( m_Texture );
>> >>>>>>
>> >>>>>>
>> >>>>>> return n;
>> >>>>>>
>> >>>>>> }
>> >>>>>>
>> >>>>>>
>> >>>>>>
>> >>>>>> It seems that computers with separate GPU there is a decent amount
>> of CPU utilised. We are running into problems if the machine lacks GPU,
>> then with large images the CPU usage grows drastically. Any suggestions

Re: [Interest] Quick2 OpenGL inefficiency?

2016-03-07 Thread Jani Tykka
I'm creating the image from buffer which is unsigned char buffer containing
video frame data
QImage( buffer, width, height, QImage::Format_RGB32 );


On Mon, Mar 7, 2016 at 10:05 PM, Filip Piechocki <fpiecho...@gmail.com>
wrote:
>
> How are you generating those images? What do they represent?
>
> On Mar 7, 2016 20:55, "Jani Tykka" <jty...@broadsoft.com> wrote:
>>
>> Images are passed from another thread in rate 15-30 fps. Is there an
example available how to achieve Image to OpenGL texture and use it in
scene graph?
>>
>> On Mon, Mar 7, 2016 at 5:11 PM, Filip Piechocki <fpiecho...@gmail.com>
wrote:
>>>
>>> And where it comes from? How frequent it happens? Probably the best
thing here would be to generate this image as an OpenGL texture and then
use in the Qt's scene graph.
>>>
>>> On Mon, Mar 7, 2016 at 4:04 PM, Jani Tykka <jty...@broadsoft.com> wrote:
>>>>
>>>> Yes, the image is always changed when the update is invoked.
>>>>
>>>> On Mon, Mar 7, 2016 at 4:43 PM, Filip Piechocki <fpiecho...@gmail.com>
wrote:
>>>>>
>>>>> Hi,
>>>>>
>>>>> Why are you re-creating the texture on every node update? Does the
m_Renderer->getImage() really changes? My first guess would be that the
texture creation from image is the most costly part here (uploading the
texture to GPU?) and I would do this only if necessary (the image really
changes).
>>>>>
>>>>> BR,
>>>>> Filip
>>>>>
>>>>> On Mon, Mar 7, 2016 at 3:04 PM, Jani Tykka <jty...@broadsoft.com>
wrote:
>>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> We are rendering QImages on QQuickItem as following:
>>>>>>
>>>>>> QSGNode * DisplayItem::updatePaintNode( QSGNode * node,
UpdatePaintNodeData * /*data*/ )
>>>>>>
>>>>>> {
>>>>>>
>>>>>> QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >(
node );
>>>>>>
>>>>>> if ( !n )
>>>>>>
>>>>>> n = new QSGSimpleTextureNode;
>>>>>>
>>>>>>
>>>>>> n->setRect( 0, 0, width(), height() );
>>>>>>
>>>>>>
>>>>>> delete m_Texture;
>>>>>>
>>>>>>
>>>>>> m_Texture = window()->createTextureFromImage( m_Renderer->getImage()
);
>>>>>>
>>>>>> n->setTexture( m_Texture );
>>>>>>
>>>>>>
>>>>>> return n;
>>>>>>
>>>>>> }
>>>>>>
>>>>>>
>>>>>>
>>>>>> It seems that computers with separate GPU there is a decent amount
of CPU utilised. We are running into problems if the machine lacks GPU,
then with large images the CPU usage grows drastically. Any suggestions how
to improve large image painting on QQuickItem? With Quick1 and painting
directly on HWND/CocoaWindow we didn't experience this high CPU usage.
>>>>>>
>>>>>>
>>>>>>
>>>>>> This email is intended solely for the person or entity to which it
is addressed and may contain confidential and/or privileged information. If
you are not the intended recipient and have received this email in error,
please notify BroadSoft, Inc. immediately by replying to this message, and
destroy all copies of this message, along with any attachment, prior to
reading, distributing or copying it.
>>>>>>
>>>>>> ___
>>>>>> Interest mailing list
>>>>>> Interest@qt-project.org
>>>>>> http://lists.qt-project.org/mailman/listinfo/interest
>>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Jani Tykkä
>>>> Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com
>>>>
>>>>
>>>> This email is intended solely for the person or entity to which it is
addressed and may contain confidential and/or privileged information. If
you are not the intended recipient and have received this email in error,
please notify BroadSoft, Inc. immediately by replying to this message, and
destroy all copies of this message, along with any attachment, prior to
reading, distributing or copying it.
>>>
>>>
>>
>>
>>
>> --
>> Jani Tykkä
>> Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com
>>
>>
>> This email is intended solely for the person or entity to which it is
addressed and may contain confidential and/or privileged information. If
you are not the intended recipient and have received this email in error,
please notify BroadSoft, Inc. immediately by replying to this message, and
destroy all copies of this message, along with any attachment, prior to
reading, distributing or copying it.




--
Jani Tykkä
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Quick2 OpenGL inefficiency?

2016-03-07 Thread Jani Tykka
Images are passed from another thread in rate 15-30 fps. Is there an
example available how to achieve Image to OpenGL texture and use it in
scene graph?

On Mon, Mar 7, 2016 at 5:11 PM, Filip Piechocki <fpiecho...@gmail.com>
wrote:

> And where it comes from? How frequent it happens? Probably the best thing
> here would be to generate this image as an OpenGL texture and then use in
> the Qt's scene graph.
>
> On Mon, Mar 7, 2016 at 4:04 PM, Jani Tykka <jty...@broadsoft.com> wrote:
>
>> Yes, the image is always changed when the update is invoked.
>>
>> On Mon, Mar 7, 2016 at 4:43 PM, Filip Piechocki <fpiecho...@gmail.com>
>> wrote:
>>
>>> Hi,
>>>
>>> Why are you re-creating the texture on every node update? Does the
>>> m_Renderer->getImage() really changes? My first guess would be that the
>>> texture creation from image is the most costly part here (uploading the
>>> texture to GPU?) and I would do this only if necessary (the image really
>>> changes).
>>>
>>> BR,
>>> Filip
>>>
>>> On Mon, Mar 7, 2016 at 3:04 PM, Jani Tykka <jty...@broadsoft.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> We are rendering QImages on QQuickItem as following:
>>>>
>>>> QSGNode * DisplayItem::updatePaintNode( QSGNode * node, 
>>>> UpdatePaintNodeData * /*data*/ )
>>>>
>>>> {
>>>>
>>>>QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >( node );
>>>>
>>>>if ( !n )
>>>>
>>>>n = new QSGSimpleTextureNode;
>>>>
>>>>
>>>>n->setRect( 0, 0, width(), height() );
>>>>
>>>>
>>>>delete m_Texture;
>>>>
>>>>
>>>>m_Texture = window()->createTextureFromImage( m_Renderer->getImage() );
>>>>
>>>>n->setTexture( m_Texture );
>>>>
>>>>
>>>>return n;
>>>>
>>>> }
>>>>
>>>>
>>>>
>>>> It seems that computers with separate GPU there is a decent amount of CPU 
>>>> utilised. We are running into problems if the machine lacks GPU, then with 
>>>> large images the CPU usage grows drastically. Any suggestions how to 
>>>> improve large image painting on QQuickItem? With Quick1 and painting 
>>>> directly on HWND/CocoaWindow we didn't experience this high CPU usage.
>>>>
>>>>
>>>>
>>>> This email is intended solely for the person or entity to which it is
>>>> addressed and may contain confidential and/or privileged information. If
>>>> you are not the intended recipient and have received this email in error,
>>>> please notify BroadSoft, Inc. immediately by replying to this message, and
>>>> destroy all copies of this message, along with any attachment, prior to
>>>> reading, distributing or copying it.
>>>>
>>>> ___
>>>> Interest mailing list
>>>> Interest@qt-project.org
>>>> http://lists.qt-project.org/mailman/listinfo/interest
>>>>
>>>>
>>>
>>
>>
>> --
>> *Jani Tykkä*
>> Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
>> jty...@broadsoft.com
>>
>>
>> This email is intended solely for the person or entity to which it is
>> addressed and may contain confidential and/or privileged information. If
>> you are not the intended recipient and have received this email in error,
>> please notify BroadSoft, Inc. immediately by replying to this message, and
>> destroy all copies of this message, along with any attachment, prior to
>> reading, distributing or copying it.
>>
>
>


-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Quick2 OpenGL inefficiency?

2016-03-07 Thread Jani Tykka
Yes, the image is always changed when the update is invoked.

On Mon, Mar 7, 2016 at 4:43 PM, Filip Piechocki <fpiecho...@gmail.com>
wrote:

> Hi,
>
> Why are you re-creating the texture on every node update? Does the
> m_Renderer->getImage() really changes? My first guess would be that the
> texture creation from image is the most costly part here (uploading the
> texture to GPU?) and I would do this only if necessary (the image really
> changes).
>
> BR,
> Filip
>
> On Mon, Mar 7, 2016 at 3:04 PM, Jani Tykka <jty...@broadsoft.com> wrote:
>
>> Hi,
>>
>> We are rendering QImages on QQuickItem as following:
>>
>> QSGNode * DisplayItem::updatePaintNode( QSGNode * node, UpdatePaintNodeData 
>> * /*data*/ )
>>
>> {
>>
>>  QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >( node );
>>
>>  if ( !n )
>>
>>  n = new QSGSimpleTextureNode;
>>
>>
>>  n->setRect( 0, 0, width(), height() );
>>
>>
>>  delete m_Texture;
>>
>>
>>  m_Texture = window()->createTextureFromImage( m_Renderer->getImage() );
>>
>>  n->setTexture( m_Texture );
>>
>>
>>  return n;
>>
>> }
>>
>>
>>
>> It seems that computers with separate GPU there is a decent amount of CPU 
>> utilised. We are running into problems if the machine lacks GPU, then with 
>> large images the CPU usage grows drastically. Any suggestions how to improve 
>> large image painting on QQuickItem? With Quick1 and painting directly on 
>> HWND/CocoaWindow we didn't experience this high CPU usage.
>>
>>
>>
>> This email is intended solely for the person or entity to which it is
>> addressed and may contain confidential and/or privileged information. If
>> you are not the intended recipient and have received this email in error,
>> please notify BroadSoft, Inc. immediately by replying to this message, and
>> destroy all copies of this message, along with any attachment, prior to
>> reading, distributing or copying it.
>>
>> ___
>> Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
>>
>>
>


-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Quick2 OpenGL inefficiency?

2016-03-07 Thread Jani Tykka
Hi,

We are rendering QImages on QQuickItem as following:

QSGNode * DisplayItem::updatePaintNode( QSGNode * node,
UpdatePaintNodeData * /*data*/ )

{

QSGSimpleTextureNode * n = static_cast< QSGSimpleTextureNode* >( node );

if ( !n )

n = new QSGSimpleTextureNode;


n->setRect( 0, 0, width(), height() );


delete m_Texture;


m_Texture = window()->createTextureFromImage( m_Renderer->getImage() );

n->setTexture( m_Texture );


return n;

}



It seems that computers with separate GPU there is a decent amount of
CPU utilised. We are running into problems if the machine lacks GPU,
then with large images the CPU usage grows drastically. Any
suggestions how to improve large image painting on QQuickItem? With
Quick1 and painting directly on HWND/CocoaWindow we didn't experience
this high CPU usage.

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Multiple QML WebEngineView instances on one QQmlEngine

2016-01-29 Thread Jani Tykka
https://bugreports.qt.io/browse/QTBUG-50768 created. Please let me know if
you have any ideas what could be the root cause for this issue.

Thanks,
Jani

On Thu, Jan 28, 2016 at 6:51 PM, Joerg Bornemann <
joerg.bornem...@theqtcompany.com> wrote:

> On 27-Jan-16 13:24, Jani Tykka wrote:
>
> I have one QQmlEngine instance which holds multiple QML WebEngine
>> instances. Is this supported approach? I'm experiencing random WebEngine
>> crashes which makes me think this could be the culprit.
>>
>
> Could you please create a bug report for those crashes on bugreports.qt.io?
> Preferably with a small example that exhibits the issue and the backtrace.
>
>
> Thanks,
>
> Joerg
>



-- 
*Jani Tykkä*
Development Manager | BroadSoft, Inc. | +358 44 596 0587 |
jty...@broadsoft.com

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Multiple QML WebEngineView instances on one QQmlEngine

2016-01-27 Thread Jani Tykka
I have one QQmlEngine instance which holds multiple QML WebEngine
instances. Is this supported approach? I'm experiencing random WebEngine
crashes which makes me think this could be the culprit.

Thanks,
Jani

-- 


This email is intended solely for the person or entity to which it is 
addressed and may contain confidential and/or privileged information. If 
you are not the intended recipient and have received this email in error, 
please notify BroadSoft, Inc. immediately by replying to this message, and 
destroy all copies of this message, along with any attachment, prior to 
reading, distributing or copying it.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest