Using SDL_image in Visual studio 2010, with error “application was unable to start correctly 0xc000007b”

时光总嘲笑我的痴心妄想 提交于 2019-11-28 11:37:40

If you have placed SDL.dll under C:\Windows\system32 or \SysWOW64 like the tutorial says, doing this may work:

Download SDL.dll (Runtime Libraries > Win32, not the 64-bit version*) and place it in the project folder where the .exe file is located.

E.g. if the project location is C:\myproject, place the SDL.dll at C:\myproject\Debug.

Then you can remove SDL.dll from \system32 or \SysWOW64. This can also prevent version conflicts, like the tutorial suggests.

*) I'm on 64-bit Windows 7, and the 64-bit version of SDL.dll didn't work for me.

Camille Goudeseune

Ensure that the SDL.dll (or SDL2.dll) that the .exe loads (from its own directory, or from a Windows system directory) matches the SDL.lib that it was linked with. Examples:

This applies to any version of Visual Studio, 32 or 64 bit, and any of Lazyfoo's tutorials.

Also what helped me - ensure you are using x86 .dll for the x86 application and not x64 dll files for the x86 app and vice versa.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!