[154] | 1 | #ifndef _OcclusionQueriesQueryManager_H__ |
---|
| 2 | #define _OcclusionQueriesQueryManager_H__ |
---|
| 3 | |
---|
| 4 | #include "OgrePlatformQueryManager.h" |
---|
| 5 | |
---|
| 6 | namespace Ogre {
|
---|
| 7 |
|
---|
| 8 | /**
|
---|
[159] | 9 | Class which implements the QueryManager for Ogre scene queries using occlusion queries.
|
---|
[154] | 10 | */
|
---|
| 11 | class __declspec(dllexport) OcclusionQueriesQueryManager: public PlatformQueryManager
|
---|
| 12 | {
|
---|
| 13 | public:
|
---|
| 14 | /** Constructor taking a hierarchy interface as an argument. This allows to operate
|
---|
[159] | 15 | on different hierarchy types, while reusing the implementation of the query methods.
|
---|
[154] | 16 | */
|
---|
| 17 | OcclusionQueriesQueryManager(PlatformHierarchyInterface *hierarchyInterface, Viewport *vp);
|
---|
| 18 |
|
---|
| 19 | void ComputeCameraVisibility(const Camera &camera,
|
---|
| 20 | InfoContainer<GtpVisibility::NodeInfo> *visibleNodes,
|
---|
| 21 | InfoContainer<GtpVisibility::MeshInfo> *visibleGeometry,
|
---|
[159] | 22 | InfoContainer<GtpVisibility::PatchInfo> *visiblePatches,
|
---|
[154] | 23 | bool relativeVisibility = false);
|
---|
| 24 |
|
---|
| 25 | /**
|
---|
| 26 | Uses the specified point to execute the visibility query in all directions.
|
---|
| 27 | @sa ComputeCameraVisibility()
|
---|
| 28 | */
|
---|
| 29 | void ComputeFromPointVisibility(const Vector3 &point,
|
---|
| 30 | InfoContainer<GtpVisibility::NodeInfo> *visibleNodes,
|
---|
| 31 | InfoContainer<GtpVisibility::MeshInfo> *visibleGeometry,
|
---|
[159] | 32 | InfoContainer<GtpVisibility::PatchInfo> *visiblePatches,
|
---|
[154] | 33 | bool relativeVisibility = false);
|
---|
| 34 |
|
---|
| 35 | bool ShootRay(const Ray &ray, std::vector<Mesh *> *visibleMeshes, bool isGlobalLine = false);
|
---|
| 36 | };
|
---|
| 37 |
|
---|
| 38 | } // namespace Ogre
|
---|
| 39 |
|
---|
| 40 | #endif // OcclusionQueriesQueryManager
|
---|