uniform caching

This topic contains 1 reply, has 2 voices, and was last updated by  Joe Davis 3 years, 12 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #31589

    dgu
    Member

    Dear Team

    what is the motivation behind the cache that you use in the deferred rending demo ?
    CPVRTMap *m_pUniformMapping;
    should it be handled by the TOOLS ( if i remember , you were doing the same caching technique in the POWERVR Engine).

    if it is part of best practice on performance , why it is not use everywhere else ?
    🙂

    regards
    david

    #38323

    Joe Davis
    Member

    Hi David,

    It’s a good practice to cache values in your app to keep calls into GL to a minimum. Although the Get operations are very cheap, not doing them at all is even better 🙂

    The DeferredRendering demo used this technique as it has to manage multiple effects. In other demos (e.g. the Water demo), the values are cached, but a map hasn’t been used.
    You’re right that we should use techniques like this consistently. When we move to an updated tools framework in the future, it will be a good opportunity to clean up a bit.

    Thanks,
    Joe

Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic.