Skip to content

refactor(ww3d2): Route render-target binding via IRenderBackend - #3424

Draft
bobtista wants to merge 8 commits into
TheSuperHackers:mainfrom
bobtista:bobtista/refactor/route-render-targets
Draft

bobtista wants to merge 8 commits into
TheSuperHackers:mainfrom
bobtista:bobtista/refactor/route-render-targets

Conversation

@bobtista

@bobtista bobtista commented Oct 4, 2026 •

Copy link
Copy Markdown

Water reflection, texture projection and the WorldBuilder object preview render into a texture with Set_Render_Target_With_Z. They then go back to the back buffer by passing a null IDirect3DSurface8 to Set_Render_Target.

Now IRenderBackend has Set_Render_Target_With_Z, Set_Default_Render_Target and Is_Render_To_Texture. Set_Default_Render_Target replaces the null surface call. W3DProfilerFrameCapture stays on DX8Wrapper because it renders with the D3D device directly. texproject.cpp no longer uses DX8Wrapper and drops its include.

Todo:

  • Build win32, including W3DView and WorldBuilder
  • Load two skirmish saves and the shell map, open W3DView through its device dialog, and open WorldBuilder. Same result as main
  • Water reflection
  • WorldBuilder object preview
  • Replicate to Generals

@coderabbitai

coderabbitai Bot commented Oct 4, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 37 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 4 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 508aaafa-6215-4e9a-838d-1e000ff13cac
📥 Commits

Reviewing files that changed from the base of the PR and between f8ba7eb and 5ac061d.

📒 Files selected for processing (54)
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/BaseHeightMap.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/FlatHeightMap.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/HeightMap.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DDebugIcons.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DScorch.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DShaderManager.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DSmudge.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DSnow.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DTerrainBackground.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DTerrainTracks.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DTreeBuffer.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/W3DView.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/Water/W3DWater.cpp
  • Core/GameEngineDevice/Source/W3DDevice/GameClient/Water/W3DWaterTracks.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/Backend/DX8Backend.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/Backend/DX8Backend.h
  • Core/Libraries/Source/WWVegas/WW3D2/IRenderBackend.h
  • Core/Libraries/Source/WWVegas/WW3D2/dx8polygonrenderer.h
  • Core/Libraries/Source/WWVegas/WW3D2/dx8renderer.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/dx8wrapper.h
  • Core/Libraries/Source/WWVegas/WW3D2/dynamesh.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/line3d.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/matpass.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/pointgr.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/ringobj.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/seglinerenderer.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/sphereobj.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/streakRender.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/texproject.cpp
  • Core/Libraries/Source/WWVegas/WW3D2/ww3d.cpp
  • Core/Tools/W3DView/GammaDialog.cpp
  • Core/Tools/W3DView/MainFrm.cpp
  • Core/Tools/W3DView/ScreenCursor.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/Shadow/W3DProjectedShadow.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/Shadow/W3DVolumetricShadow.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DBibBuffer.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DBridgeBuffer.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DInGameUI.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DRoadBuffer.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DScene.cpp
  • GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DStatusCircle.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/boxrobj.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/camera.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dazzle.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/decalmsh.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/linegrp.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/mapper.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/mesh.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/render2d.cpp
  • GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/scene.cpp
  • GeneralsMD/Code/Tools/WorldBuilder/src/DrawObject.cpp
  • GeneralsMD/Code/Tools/WorldBuilder/src/ObjectPreview.cpp
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@bobtista
bobtista force-pushed the bobtista/refactor/route-render-targets branch from f826a89 to 5ac061d Compare October 4, 2026 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant