🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

How to use ID3D11Predicate for occlusion testing?

Started by
0 comments, last by DKrz 2 years, 1 month ago

Hello, can anyone help me with setting up ID3D11Predicate for occlusion testing? I know how to do it for ID3D11Query, e.g. create an ID3D11Query object then every frame I render meshes/AABBs to depth buffer - then on the next pass I wrap Begin and End methods of immediate context around the method of drawing each of the same meshes and 2 frames down the line I retrieve the result from GetData per mesh by which I decide whether to add those meshes to render queue this frame or not. Simple. But with that latency of 2 frames.

As I take it ID3D11Predicate does away with the latency but how to set it up? MSDN docs aren't clear enough to me and there are no examples on the Internet that I could find.

So I create an ID3D11Predicate object with CreatePredication but what then?

This topic is closed to new replies.

Advertisement