BVB Source Codes

CRYENGINE Show ClipVolumeManager.h Source code

Return Download CRYENGINE: download ClipVolumeManager.h Source code - Download CRYENGINE Source code - Type:.h
  1. // Copyright 2001-2016 Crytek GmbH / Crytek Group. All rights reserved.
  2.  
  3. #ifndef __INCLUDE_CRY3DENGINE_CLIPVOLUMEMANAGER_H
  4. #define __INCLUDE_CRY3DENGINE_CLIPVOLUMEMANAGER_H
  5.  
  6. class CClipVolume;
  7.  
  8. class CClipVolumeManager : public Cry3DEngineBase
  9. {
  10.         struct SClipVolumeInfo
  11.         {
  12.                 CClipVolume* m_pVolume;
  13.                 bool         m_bActive;
  14.  
  15.                 SClipVolumeInfo()
  16.                         : m_pVolume(nullptr)
  17.                         , m_bActive(false) {}
  18.  
  19.                 SClipVolumeInfo(CClipVolume* pVolume)
  20.                         : m_pVolume(pVolume)
  21.                         , m_bActive(false) {}
  22.  
  23.                 bool operator==(const SClipVolumeInfo& other) const { return m_pVolume == other.m_pVolume; }
  24.         };
  25.  
  26. public:
  27.         static const uint8 InactiveVolumeStencilRef = 0xFD;
  28.         static const uint8 AffectsEverythingStencilRef = 0xFE;
  29.  
  30.         virtual ~CClipVolumeManager();
  31.  
  32.         virtual IClipVolume* CreateClipVolume();
  33.         virtual bool         DeleteClipVolume(IClipVolume* pClipVolume);
  34.         virtual bool         UpdateClipVolume(IClipVolume* pClipVolume, _smart_ptr<IRenderMesh> pRenderMesh, IBSPTree3D* pBspTree, const Matrix34& worldTM, bool bActive, uint32 flags, const char* szName);
  35.  
  36.         void                 PrepareVolumesForRendering(const SRenderingPassInfo& passInfo);
  37.  
  38.         void                 UpdateEntityClipVolume(const Vec3& pos, IRenderNode* pRenderNode);
  39.         void                 UnregisterRenderNode(IRenderNode* pRenderNode);
  40.  
  41.         bool                 IsClipVolumeRequired(IRenderNode* pRenderNode) const;
  42.         CClipVolume*         GetClipVolumeByPos(const Vec3& pos, const IClipVolume* pIgnoreVolume = NULL) const;
  43.  
  44.         void GetMemoryUsage(class ICrySizer* pSizer) const;
  45.         size_t GetClipVolumeCount() const { return m_ClipVolumes.size(); }
  46.  
  47. private:
  48.         PodArray<SClipVolumeInfo> m_ClipVolumes;
  49. };
  50.  
  51. #endif //__INCLUDE_CRY3DENGINE_CLIPVOLUMEMANAGER_H
  52.  
downloadClipVolumeManager.h Source code - Download CRYENGINE Source code
Related Source Codes/Software:
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top