Every extension libary has 3 essential parts:
- The header file.
- The lib file.
- The *.dll file(s)
They're all set up pretty much the same way no matter which extension you're setting up.
Open up the zip archive and there should be a folder inside.
Open the folder and it'll contain 2 subfolders.
First, open the include subfolder in the archive and you should see a header file. Put that header file in the directory with all the other header files in the SDL folder you extracted in lesson 1.
For example, I extracted the SDL version 1.2.12 folder to "C:\", so I put the SDL_image.h (or SDL_ttf.h or SDL_mixer.h) header in C:\SDL-1.2.12\include\.
Now find the lib folder from the archive. Take the library file(s) from the archive and put them with the rest of the SDL library files. In my case the rest of the SDL library files were in C:\SDL-1.2.12\lib\.
For certain versions of SDL_image, there will be a x86 folder and a x64 folder inside of the lib folder from the archive. The x86 folder contains the 32bit *.lib files and the x64 bit folder contains the 64bit versions of the library files. If you're compiling a 32bit program, copy the library file(s) from the x86 folder and if you're compiling a 64bit version copy the library file(s) from the x64 folder. By default Visual Studio compiles in 32bit so if you're not sure how you're compiling, try the 32bit libraries first. What matters here is not whether you have 32/64bit windows, but what type of program you're compiling.
If you don't see a x86 or x64 folder inside of the lib directory from the archive, just copy the library file(s) from the lib folder from the archive.
4)Now extract all of the *.dll file(s) from the archive and put them in the same directory as your exe.
Like before, you can copy them to C:\WINDOWS\SYSTEM32 (or C:\Windows\SysWOW64 on 64bit Windows) so your SDL app will find the *.dll(s) even if they're not in the same directory. The problem with this method is if you have multiple SDL apps that use different versions of SDL, you'll have version conflicts. If you have an old version in SYSTEM32 when the app uses the new version you're going to run into problems. Generally you want to have your the *.dll(s) in the same directory as your executable developing and you'll always want to have *.dll(s) in the same directory as the exe when distributing your app.
Now open up your SDL project and go to the project properties.