texture2DProj performance

This topic contains 2 replies, has 2 voices, and was last updated by  Joe Davis 4 years, 10 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #31136

    lefty
    Member

    I am rendering a scene with a static shadow map (i.e. the shadow texture is rendered just once at the start of the level). I use the same technique as the shadow mapping example from the SDK. When I render my scene the render time increases from 30ms (with no shadows) to 50ms. It seems that the texture2DProj function in the shader is responsible for the extra 20ms render time. Is that to be expected?

    #36644

    lefty
    Member

    Actually, nevermind that post. I was stupidly multiplying matrices in the shader. When I premultplied matices on CPU the render time drastically decreased.

    #36645

    Joe Davis
    Member

    Hi Lefty,

    Glad to hear you found the cause of the performance difference 🙂

    Joe

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