Skip to content

Conversation

@divinity76
Copy link
Contributor

@divinity76 divinity76 commented Nov 9, 2025

Made a "DirectX-QuickCompile" profile for Visual Studio.
Sometimes I just want to compile fast, and don't need the compiler optimizations.

With this, on my Ryzen 9 7950X:
DirectX build from scratch: 50 seconds
DirectX incremental build: N/A
DirectX-QuickCompile from scratch: 20 seconds
DirectX-QuickCompile incremental: 16 seconds

On my Zap-hosting VPS (4 cores Xeon E5-2640v4):
DirectX build from scratch: 8 minutes
DirectX incremental build: N/A
DirectX-QuickCompile from scratch: 3 minutes
DirectX-QuickCompile incremental: 2 minutes

(PS, incremental build is not 100% incremental, some files from vcpkg gets compiled every time, don't know why)

Also my Zap-Hosting VPS does not have a GPU, runs on the "Microsoft Basic Display Adapter", where both the OpenGL and debug crash on startup, so OpenGL is not an alternative for me atm.

@divinity76 divinity76 force-pushed the directx-quickcompile branch from 28f0c96 to 0f64f4f Compare November 9, 2025 06:53
@sonarqubecloud
Copy link

sonarqubecloud bot commented Nov 9, 2025

@majestyotbr majestyotbr changed the title Visual Studio DirectX-QuickCompile profile feat: Visual Studio DirectX-QuickCompile profile Nov 9, 2025
@mehah
Copy link
Owner

mehah commented Nov 9, 2025

So you need to clone the debug profile, rename it to debug - opengl, and in the clone, add the flags to compile in DirectX and rename it to debug - dx.

If the profile you created is already a clone of the debug profile, then just keep the same naming convention.

@divinity76
Copy link
Contributor Author

@mehah for me to get a functional debug client? yes that should work, thanks.

But regardless, I want a DirectX-QuickCompile profile. And if the upstream mehah/otclient has a QuickCompile profile, I won't have to mess with gitignore for a customized vc17/otclient.sln and vc17/otclient.vcxproj

  • would make it slightly easier for me to contribute if the upstream vc17/otclient.sln has a QuickCompile profile.

@mehah
Copy link
Owner

mehah commented Nov 10, 2025

@divinity76
You are mixing concepts. If the goal is to compile without optimizations, what you want is the Debug mode. Debug mode disables compiler optimizations, which is exactly what we are already doing. However, the current debugger uses OpenGL. What I am asking is: clone the Debug profile and apply the DirectX flags so that the Debug build runs via EGL on DirectX.

@divinity76
Copy link
Contributor Author

@divinity76 You are mixing concepts. If the goal is to compile without optimizations, what you want is the Debug mode. Debug mode disables compiler optimizations, which is exactly what we are already doing. However, the current debugger uses OpenGL. What I am asking is: clone the Debug profile and apply the DirectX flags so that the Debug build runs via EGL on DirectX.

Oh now I see. Would you be interested in a PR changing the Debug profile into "Debug-OpenGL" + "Debug-DirectX" ?

@mehah
Copy link
Owner

mehah commented Nov 10, 2025

@divinity76
The idea is for you to copy the debug configuration, add the DirectX flags, and rename it to debug-dx and the old one to debug-gl.

@divinity76 divinity76 marked this pull request as draft November 10, 2025 16:56
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.

2 participants