• Advertisement
Sign in to follow this  

directx function call cycle

This topic is 4858 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, for a complete scene render which involves rendering some render targets, I was wondering which is the correct way of calling some functions... I'm thinking of two possible ways: way 1: For every Frame - Check Cooperative level - BeginScene - SetRenderTarget - Render Something - SetRenderTarget - Render Something - SetRenderTarget - Render Something - EndScene way 2: - Check Cooperative level - BeginScene - SetRenderTarget - Render Something - EndScene - BeginScene - SetRenderTarget - Render Something - EndScene - BeginScene - SetRenderTarget - Render Something - EndScene so, which is the fastest/safest way?

Share this post


Link to post
Share on other sites
Advertisement
You should only be calling BeginScene() / EndScene() once per frame. Specifically, there should be at most one BeginScene() / EndScene() pair between any successive calls to Present(). To maintain maximum parallelism, it is advantageous to call EndScene() as far ahead of calling Present() as possible.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement