From 3bf9df6b2785fa6d951086978a3e66f49427166a Mon Sep 17 00:00:00 2001 From: FluorescentCIAAfricanAmerican <0934gj3049fk@protonmail.com> Date: Wed, 22 Apr 2020 12:56:21 -0400 Subject: 1 --- engine/IOcclusionSystem.h | 55 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 engine/IOcclusionSystem.h (limited to 'engine/IOcclusionSystem.h') diff --git a/engine/IOcclusionSystem.h b/engine/IOcclusionSystem.h new file mode 100644 index 0000000..1b65f4c --- /dev/null +++ b/engine/IOcclusionSystem.h @@ -0,0 +1,55 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: +// +// $NoKeywords: $ +// +//=============================================================================// + +#ifndef IOCCLUSIONSYSTEM_H +#define IOCCLUSIONSYSTEM_H + +#ifdef _WIN32 +#pragma once +#endif + + +class Vector; +class VMatrix; +struct model_t; +class VPlane; +class CUtlBuffer; + + +//----------------------------------------------------------------------------- +// Occlusion system interface +//----------------------------------------------------------------------------- +class IOcclusionSystem +{ +public: + // Activate/deactivate an occluder brush model + virtual void ActivateOccluder( int nOccluderIndex, bool bActive ) = 0; + + // Sets the view transform + virtual void SetView( const Vector &vecCameraPos, float flFOV, const VMatrix &worldToCamera, + const VMatrix &cameraToProjection, const VPlane &nearClipPlane ) = 0; + + // Test for occlusion (bounds specified in abs space) + virtual bool IsOccluded( const Vector &vecAbsMins, const Vector &vecAbsMaxs ) = 0; + + // Sets global occlusion parameters + virtual void SetOcclusionParameters( float flMaxOccludeeArea, float flMinOccluderArea ) = 0; + virtual float MinOccluderArea() const = 0; + + // Render debugging overlay + virtual void DrawDebugOverlays() = 0; +}; + + +//----------------------------------------------------------------------------- +// Singleton accessor +//----------------------------------------------------------------------------- +IOcclusionSystem *OcclusionSystem(); + + +#endif // IOCCLUSIONSYSTEM_H -- cgit v1.2.3