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.

189 lines
6.2 KiB

  1. MaterialSystem_Config_t& CPs3NonVirt_IShaderUtil::GetConfig()
  2. {
  3. return g_MaterialSystem.CMaterialSystem::GetConfig();
  4. }
  5. bool CPs3NonVirt_IShaderUtil::ConvertImageFormat( unsigned char *src, enum ImageFormat srcImageFormat, unsigned char *dst, enum ImageFormat dstImageFormat, int width, int height, int srcStride, int dstStride)
  6. {
  7. return g_MaterialSystem.CMaterialSystem::ConvertImageFormat(src,srcImageFormat,dst,dstImageFormat,width,height,srcStride,dstStride);
  8. }
  9. int CPs3NonVirt_IShaderUtil::GetMemRequired( int width, int height, int depth, ImageFormat format, bool mipmap )
  10. {
  11. return g_MaterialSystem.CMaterialSystem::GetMemRequired(width,height,depth,format,mipmap);
  12. }
  13. const ImageFormatInfo_t& CPs3NonVirt_IShaderUtil::ImageFormatInfo( ImageFormat fmt )
  14. {
  15. return g_MaterialSystem.CMaterialSystem::ImageFormatInfo(fmt);
  16. }
  17. void CPs3NonVirt_IShaderUtil::BindStandardTexture( Sampler_t sampler, TextureBindFlags_t nBindFlags, StandardTextureId_t id )
  18. {
  19. g_MaterialSystem.CMaterialSystem::BindStandardTexture(sampler, nBindFlags, id);
  20. }
  21. void CPs3NonVirt_IShaderUtil::GetLightmapDimensions( int *w, int *h )
  22. {
  23. g_MaterialSystem.CMaterialSystem::GetLightmapDimensions(w,h);
  24. }
  25. void CPs3NonVirt_IShaderUtil::ReleaseShaderObjects( int nChangeFlags)
  26. {
  27. g_MaterialSystem.CMaterialSystem::ReleaseShaderObjects(nChangeFlags);
  28. }
  29. void CPs3NonVirt_IShaderUtil::RestoreShaderObjects( CreateInterfaceFn shaderFactory, int nChangeFlags)
  30. {
  31. g_MaterialSystem.CMaterialSystem::RestoreShaderObjects(shaderFactory,nChangeFlags);
  32. }
  33. bool CPs3NonVirt_IShaderUtil::IsInStubMode()
  34. {
  35. return g_MaterialSystem.CMaterialSystem::IsInStubMode();
  36. }
  37. bool CPs3NonVirt_IShaderUtil::InFlashlightMode()
  38. {
  39. return g_MaterialSystem.CMaterialSystem::InFlashlightMode();
  40. }
  41. bool CPs3NonVirt_IShaderUtil::IsRenderingPaint()
  42. {
  43. return g_MaterialSystem.CMaterialSystem::IsRenderingPaint();
  44. }
  45. void CPs3NonVirt_IShaderUtil::NoteAnisotropicLevel( int currentLevel )
  46. {
  47. g_MaterialSystem.CMaterialSystem::NoteAnisotropicLevel(currentLevel);
  48. }
  49. bool CPs3NonVirt_IShaderUtil::InEditorMode()
  50. {
  51. return g_MaterialSystem.CMaterialSystem::InEditorMode();
  52. }
  53. ITexture * CPs3NonVirt_IShaderUtil::GetRenderTargetEx( int nRenderTargetID )
  54. {
  55. return g_MaterialSystem.CMaterialSystem::GetRenderTargetEx(nRenderTargetID);
  56. }
  57. void CPs3NonVirt_IShaderUtil::DrawClearBufferQuad( unsigned char r, unsigned char g, unsigned char b, unsigned char a, bool bClearColor, bool bClearAlpha, bool bClearDepth )
  58. {
  59. g_MaterialSystem.CMaterialSystem::DrawClearBufferQuad(r,g,b,a,bClearColor,bClearAlpha,bClearDepth);
  60. }
  61. void CPs3NonVirt_IShaderUtil::DrawReloadZcullQuad()
  62. {
  63. g_MaterialSystem.CMaterialSystem::DrawReloadZcullQuad();
  64. }
  65. bool CPs3NonVirt_IShaderUtil::OnDrawMesh( IMesh *pMesh, int firstIndex, int numIndices )
  66. {
  67. return g_MaterialSystem.CMaterialSystem::OnDrawMesh(pMesh,firstIndex,numIndices);
  68. }
  69. bool CPs3NonVirt_IShaderUtil::OnDrawMesh( IMesh *pMesh, CPrimList *pLists, int nLists )
  70. {
  71. return g_MaterialSystem.CMaterialSystem::OnDrawMesh(pMesh,pLists,nLists);
  72. }
  73. bool CPs3NonVirt_IShaderUtil::OnSetFlexMesh( IMesh *pStaticMesh, IMesh *pMesh, int nVertexOffsetInBytes )
  74. {
  75. return g_MaterialSystem.CMaterialSystem::OnSetFlexMesh(pStaticMesh,pMesh,nVertexOffsetInBytes);
  76. }
  77. bool CPs3NonVirt_IShaderUtil::OnSetColorMesh( IMesh *pStaticMesh, IMesh *pMesh, int nVertexOffsetInBytes )
  78. {
  79. return g_MaterialSystem.CMaterialSystem::OnSetColorMesh(pStaticMesh,pMesh,nVertexOffsetInBytes);
  80. }
  81. bool CPs3NonVirt_IShaderUtil::OnSetPrimitiveType( IMesh *pMesh, MaterialPrimitiveType_t type )
  82. {
  83. return g_MaterialSystem.CMaterialSystem::OnSetPrimitiveType(pMesh,type);
  84. }
  85. void CPs3NonVirt_IShaderUtil::SyncMatrices()
  86. {
  87. g_MaterialSystem.CMaterialSystem::SyncMatrices();
  88. }
  89. void CPs3NonVirt_IShaderUtil::SyncMatrix( MaterialMatrixMode_t mmm )
  90. {
  91. g_MaterialSystem.CMaterialSystem::SyncMatrix(mmm);
  92. }
  93. void CPs3NonVirt_IShaderUtil::BindStandardVertexTexture( VertexTextureSampler_t sampler, StandardTextureId_t id )
  94. {
  95. g_MaterialSystem.CMaterialSystem::BindStandardVertexTexture(sampler,id);
  96. }
  97. ShaderAPITextureHandle_t CPs3NonVirt_IShaderUtil::GetStandardTexture( StandardTextureId_t id )
  98. {
  99. return g_MaterialSystem.CMaterialSystem::GetStandardTexture(id);
  100. }
  101. void CPs3NonVirt_IShaderUtil::GetStandardTextureDimensions( int *pWidth, int *pHeight, StandardTextureId_t id )
  102. {
  103. g_MaterialSystem.CMaterialSystem::GetStandardTextureDimensions(pWidth,pHeight,id);
  104. }
  105. int CPs3NonVirt_IShaderUtil::MaxHWMorphBatchCount()
  106. {
  107. return g_MaterialSystem.CMaterialSystem::MaxHWMorphBatchCount();
  108. }
  109. void CPs3NonVirt_IShaderUtil::GetCurrentColorCorrection( ShaderColorCorrectionInfo_t* pInfo )
  110. {
  111. g_MaterialSystem.CMaterialSystem::GetCurrentColorCorrection(pInfo);
  112. }
  113. ShaderAPITextureHandle_t CPs3NonVirt_IShaderUtil::GetShaderAPITextureBindHandle( ITexture *pTexture, int nFrame, int nTextureChannel )
  114. {
  115. return g_MaterialSystem.CMaterialSystem::GetShaderAPITextureBindHandle(pTexture,nFrame,nTextureChannel);
  116. }
  117. float CPs3NonVirt_IShaderUtil::GetSubDHeight()
  118. {
  119. return g_MaterialSystem.CMaterialSystem::GetSubDHeight();
  120. }
  121. bool CPs3NonVirt_IShaderUtil::OnDrawMeshModulated( IMesh *pMesh, const Vector4D &diffuseModulation, int firstIndex, int numIndices )
  122. {
  123. return g_MaterialSystem.CMaterialSystem::OnDrawMeshModulated(pMesh,diffuseModulation,firstIndex,numIndices);
  124. }
  125. void CPs3NonVirt_IShaderUtil::OnThreadEvent( uint32 threadEvent )
  126. {
  127. g_MaterialSystem.CMaterialSystem::OnThreadEvent(threadEvent);
  128. }
  129. MaterialThreadMode_t CPs3NonVirt_IShaderUtil::GetThreadMode()
  130. {
  131. return g_MaterialSystem.CMaterialSystem::GetThreadMode();
  132. }
  133. void CPs3NonVirt_IShaderUtil::UncacheUnusedMaterials( bool bRecomputeStateSnapshots)
  134. {
  135. g_MaterialSystem.CMaterialSystem::UncacheUnusedMaterials(bRecomputeStateSnapshots);
  136. }
  137. bool CPs3NonVirt_IShaderUtil::IsInFrame( )
  138. {
  139. return g_MaterialSystem.CMaterialSystem::IsInFrame();
  140. }
  141. ShaderAPITextureHandle_t CPs3NonVirt_IShaderUtil::GetLightmapTexture( int nLightmapPage )
  142. {
  143. return g_MaterialSystem.CMaterialSystem::GetLightmapTexture( nLightmapPage );
  144. }
  145. ShaderAPITextureHandle_t CPs3NonVirt_IShaderUtil::GetPaintmapTexture( int nLightmapPage )
  146. {
  147. return g_MaterialSystem.CMaterialSystem::GetPaintmapTexture( nLightmapPage );
  148. }
  149. bool CPs3NonVirt_IShaderUtil::IsCascadedShadowMapping()
  150. {
  151. return g_MaterialSystem.CMaterialSystem::IsCascadedShadowMapping();
  152. }