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.

43 lines
1.5 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $Workfile: $
  6. // $Date: $
  7. // $NoKeywords: $
  8. //=============================================================================//
  9. #ifndef UTILMATLIB_H
  10. #define UTILMATLIB_H
  11. #ifdef _WIN32
  12. #pragma once
  13. #endif
  14. #include "interfaces/interfaces.h"
  15. #define MATERIAL_NOT_FOUND NULL
  16. class IMaterialSystem;
  17. DECLARE_TIER2_INTERFACE( IMaterialSystem, g_pMaterialSystem );
  18. typedef void *MaterialSystemMaterial_t;
  19. #define UTILMATLIB_NEEDS_BUMPED_LIGHTMAPS 0
  20. #define UTILMATLIB_NEEDS_LIGHTMAP 1
  21. #define UTILMATLIB_OPACITY 2
  22. enum { UTILMATLIB_ALPHATEST = 0, UTILMATLIB_OPAQUE, UTILMATLIB_TRANSLUCENT };
  23. void InitMaterialSystem( const char *materialBaseDirPath, CreateInterfaceFn fileSystemFactory );
  24. void ShutdownMaterialSystem( );
  25. MaterialSystemMaterial_t FindMaterial( const char *materialName, bool *pFound, bool bComplain = true );
  26. void GetMaterialDimensions( MaterialSystemMaterial_t materialHandle, int *width, int *height );
  27. int GetMaterialShaderPropertyBool( MaterialSystemMaterial_t materialHandle, int propID );
  28. int GetMaterialShaderPropertyInt( MaterialSystemMaterial_t materialHandle, int propID );
  29. const char *GetMaterialVar( MaterialSystemMaterial_t materialHandle, const char *propertyName );
  30. void GetMaterialReflectivity( MaterialSystemMaterial_t materialHandle, float *reflectivityVect );
  31. const char *GetMaterialShaderName( MaterialSystemMaterial_t materialHandle );
  32. #endif // UTILMATLIB_H