Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

39 lines
1.0 KiB

  1. //========= Copyright � 1996-2009, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose: used to cross section maps ( i.e. displacements ) to do fast occlusion against
  4. //
  5. // $NoKeywords: $
  6. //=====================================================================================//
  7. #ifndef FOW_HORIZONTALSLICE_H
  8. #define FOW_HORIZONTALSLICE_H
  9. #if defined( COMPILER_MSVC )
  10. #pragma once
  11. #endif
  12. #include "utlvector.h"
  13. #include "utlspheretree.h"
  14. #include "mathlib/vector.h"
  15. #include "fow_lineoccluder.h"
  16. class CFoW;
  17. class CFoW_Viewer;
  18. class CFoW_HorizontalSlice
  19. {
  20. public:
  21. CFoW_HorizontalSlice( void );
  22. // clears the sphere tree of all line occluders
  23. void Clear( void );
  24. // adds a line occluder to the sphere tree
  25. void AddHorizontalOccluder( CFoW_LineOccluder *pLineOccluder );
  26. // tests the viewer against all line occluders that are near the viewer
  27. void ObstructViewer( CFoW *pFoW, CFoW_Viewer *pViewer );
  28. private:
  29. CUtlSphereTree m_SphereTree; // spherical tree to quickly find line occulders near a given point
  30. };
  31. #endif // FOW_HORIZONTALSLICE_H