[Interest] [qt3d] Few questions about shader management with custom materials

Xavier Bigand flamaros.xavier at gmail.com
Tue Jun 21 00:03:31 CEST 2016


Thank you, it's super nice.

Does qt3d cache the compilation of shaders between two executions of the
application?

2016-06-20 22:54 GMT+02:00 Sean Harmer <sean.harmer at kdab.com>:

> Hi,
>
> On 20/06/2016 17:17, Xavier Bigand wrote:
>
> Hi,
>
> I am planning to use our custom materials with Qt3D, because will already
> have an uber shader for the lighting and shadowing of objects.
> I think that I'll create one material called LightingMaterial that can
> change the shader's sources depending of his properties, but in this case
> it seems that I'll instanciate too much shader programs.
> Are shaderprograms automatically managed in sense of I can instanciate
> many program with the same code?
>
>
> Yes, the OpenGL shader programs are cached and hashed by the renderer.
>
> Cheers,
>
> Sean
>
>
>
> --
> Xavier
>
>
> _______________________________________________
> Interest mailing listInterest at qt-project.orghttp://lists.qt-project.org/mailman/listinfo/interest
>
>
>
> --
> Dr Sean Harmer | sean.harmer at kdab.com | Managing Director UK
> KDAB (UK) Ltd, a KDAB Group company
> Tel. +44 (0)1625 809908; Sweden (HQ) +46-563-540090
> Mobile: +44 (0)7545 140604
> KDAB - Qt Experts
>
>
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
>


-- 
Xavier
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160621/6a6b1f1f/attachment.html>


More information about the Interest mailing list