Skip to content

Commit

Permalink
DrawUtils: Replace GLUtils by D3DUtils.
Browse files Browse the repository at this point in the history
  • Loading branch information
CrossVR committed Nov 24, 2015
1 parent ada231a commit d1678e9
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 79 deletions.
4 changes: 3 additions & 1 deletion src/Layers/xrRender/D3DUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ u32 m_ColorSafeRect = 0xffB040B0;

void SPrimitiveBuffer::CreateFromData(D3DPRIMITIVETYPE _pt, u32 _p_cnt, u32 FVF, LPVOID vertices, u32 _v_cnt, u16* indices, u32 _i_cnt)
{
#if defined(USE_DX10) || defined(USE_DX11)
#if defined(USE_DX10) || defined(USE_DX11) || defined(USE_OGL)
// TODO: DX10: Implement SPrimitiveBuffer::CreateFromData for DX10
// VERIFY(!"SPrimitiveBuffer::CreateFromData not implemented for dx10");
#else // USE_DX10
Expand Down Expand Up @@ -130,13 +130,15 @@ void SPrimitiveBuffer::CreateFromData(D3DPRIMITIVETYPE _pt, u32 _p_cnt, u32 FVF,
}
void SPrimitiveBuffer::Destroy()
{
#ifndef USE_OGL
if (pGeom){
HW.stats_manager.decrement_stats_vb (pGeom->vb);
HW.stats_manager.decrement_stats_ib (pGeom->ib);
_RELEASE (pGeom->vb);
_RELEASE (pGeom->ib);
pGeom.destroy ();
}
#endif // !USE_OGL
}

void CDrawUtilities::UpdateGrid(int number_of_cell, float square_size, int subdiv){
Expand Down
4 changes: 0 additions & 4 deletions src/Layers/xrRenderPC_GL/GLUtils.cpp

This file was deleted.

66 changes: 0 additions & 66 deletions src/Layers/xrRenderPC_GL/GLUtils.h

This file was deleted.

4 changes: 2 additions & 2 deletions src/Layers/xrRenderPC_GL/xrRender_GL.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@
<ClCompile Include="..\xrRenderGL\glState.cpp" />
<ClCompile Include="..\xrRenderGL\glStateUtils.cpp" />
<ClCompile Include="..\xrRenderGL\glTextureUtils.cpp" />
<ClCompile Include="..\xrRender\D3DUtils.cpp" />
<ClCompile Include="..\xrRender\DetailManager_VS.cpp" />
<ClCompile Include="..\xrRender\du_box.cpp" />
<ClCompile Include="..\xrRender\du_cone.cpp" />
Expand Down Expand Up @@ -356,7 +357,6 @@
<ClCompile Include="glResourceManager_Scripting.cpp" />
<ClCompile Include="glr_constants.cpp" />
<ClCompile Include="glTexture.cpp" />
<ClCompile Include="GLUtils.cpp" />
<ClCompile Include="GL_DStreams.cpp" />
<ClCompile Include="gl_R_render.cpp" />
<ClCompile Include="r2_R_calculate.cpp" />
Expand Down Expand Up @@ -402,6 +402,7 @@
<ClInclude Include="..\xrRenderGL\glState.h" />
<ClInclude Include="..\xrRenderGL\glStateUtils.h" />
<ClInclude Include="..\xrRenderGL\glTextureUtils.h" />
<ClInclude Include="..\xrRender\D3DUtils.h" />
<ClInclude Include="..\xrRender\D3DXRenderBase.h" />
<ClInclude Include="..\xrRender\du_box.h" />
<ClInclude Include="..\xrRender\du_cone.h" />
Expand Down Expand Up @@ -508,7 +509,6 @@
<ClInclude Include="..\xrRender\uber_deffer.h" />
<ClInclude Include="..\xrRender\WallmarksEngine.h" />
<ClInclude Include="..\xrRender\xrRender_console.h" />
<ClInclude Include="GLUtils.h" />
<ClInclude Include="gl_rendertarget_wallmarks.h" />
<ClInclude Include="r2_types.h" />
<ClInclude Include="gl_rendertarget.h" />
Expand Down
12 changes: 6 additions & 6 deletions src/Layers/xrRenderPC_GL/xrRender_GL.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -177,9 +177,6 @@
<ClCompile Include="..\xrRender\xrRender_console.cpp">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="GLUtils.cpp">
<Filter>Refactored\Execution &amp; 3D\DebugDraw</Filter>
</ClCompile>
<ClCompile Include="..\xrRender\PSLibrary.cpp">
<Filter>Core</Filter>
</ClCompile>
Expand Down Expand Up @@ -639,6 +636,9 @@
<ClCompile Include="glTexture.cpp">
<Filter>Core</Filter>
</ClCompile>
<ClCompile Include="..\xrRender\D3DUtils.cpp">
<Filter>Refactored\Execution &amp; 3D\DebugDraw</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="stdafx.h">
Expand All @@ -650,9 +650,6 @@
<ClInclude Include="..\..\include\xrRender\DrawUtils.h">
<Filter>Refactored\Execution &amp; 3D\DebugDraw</Filter>
</ClInclude>
<ClInclude Include="GLUtils.h">
<Filter>Refactored\Execution &amp; 3D\DebugDraw</Filter>
</ClInclude>
<ClInclude Include="..\xrRender\PSLibrary.h">
<Filter>Core</Filter>
</ClInclude>
Expand Down Expand Up @@ -1067,5 +1064,8 @@
<ClInclude Include="..\xrRender\D3DXRenderBase.h">
<Filter>Core</Filter>
</ClInclude>
<ClInclude Include="..\xrRender\D3DUtils.h">
<Filter>Refactored\Execution &amp; 3D\DebugDraw</Filter>
</ClInclude>
</ItemGroup>
</Project>

0 comments on commit d1678e9

Please sign in to comment.