Table Of Contents

Previous topic

9.12. The RenderTarget Object

Next topic

9.14. The DrawParameters Object

This Page

9.13. The OcclusionQuery Object

An OcclusionQuery object collects from the GPU how many fragments passed the depth test from draw commands executed between graphicsDevice.beginOcclusionQuery and graphicsDevice.endOcclusionQuery for the given OcclusionQuery.

9.13.1. Properties

9.13.1.1. pixelCount

Summary

Number of fragments that passed the depth test.

Syntax

var pixelCount = occlusionQuery.pixelCount;

Calling this property would stall the CPU waiting for the GPU if the query results are not ready.

Note

Read Only