1
\$\begingroup\$

I have been looking at the source code of various commercial games, and I have noticed that a lot of them load video card/input DLLs directly using LoadLibrary().

I wanted to mod one, but also make my own engine, so I was wondering what would be the benefits of loading DirectX 11 DLLs directly, as opposed to link the program with .libs?

\$\endgroup\$

1 Answer 1

3
\$\begingroup\$

If the DLLs are loaded using a .lib your game will fail to launch if the DLLs are missing.

Loading DLLs using LoadLibrary lets you display a friendlier message on failure and allows you implement a fallback system to a previous version of DirectX if the latest is unavailable.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .