Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

gommo

Changing my engine from a .dll to an .exe

This topic is 5392 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have my engine as a dll (hooge.dll) and one renderer so far (hoogeD3D9.dll). I have a Test Application called TestApp.exe etc.. I''d like to change this around so my engine is the entry point and it basically loads up the testapp.dll as a plugin the same way it loads the directx renderer. No problem. However, Most of my classes currently in the hooge.dll are declared as such class HOOGE_API IRenderSystem { et.c.. where HOOGE_API = __declspec(dllexport) or __declspec(dllimport) depending on if HOOGE_API is declared. Pretty standard stuff. However, if I try change hooge.dll to an .exe, And remove the HOOGE_API from the classes, my DirectX dll doesnt compile due to incorrect dll usage. I''m stumped how to do this? Do I need to redesign everything? I guess my real question comes down to, if I have my interfaces in my .exe, how do I extend them from dll''s?

Share this post


Link to post
Share on other sites
Advertisement
I think that in the .exe, you would have to use __declspec(dllimport). Make sure that you''re using dllimport in the exe, and dllexport in the dll. Since you removed HOOGE_API from your classes, both the DLL and the EXE think that the classes are just local to the EXE, and so doesn''t work properly.
I know that''s not the answer to why it doesn''t compile, but removing HOOGE_API wasn''t the way to go.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!