You are not logged in.
Pages: 1
Basicly i was running throught a tutorial on sdl in c++. i was trying to use
hello = SDL_Load("arch.png");at one point to load a png image. this function is included in SDL_image. I added the correct header but still this happened:
fatal error: SDL/SDL_image.so: No such file or directory|
I saw that the libsdl_image.a file was missing and according to package search is not included in the package. is this intentional?
Last edited by dogjaw2233 (2016-07-20 17:01:49)
Offline
If you're not wedded to SDL then there is SFML which is just as portable as SDL and is in the official repos. SFML is primarily 2D only but you can get an OpenGL context out of it if you want. The library doesn't give you much more than that though for OpenGL. For 2D it's a great library.
Last edited by headkase (2016-07-17 17:19:54)
Offline
See the sdl_image package.
A .so file is not a static library.
Offline
See the sdl_image package.
A .so file is not a static library.
What am i looking for in the sdl_image package? and how would i go about compiling with a shared object?
Offline
Do you have sdl_image installed ?
you get that error when trying to compile with gcc ?
please post the full output .
Something i find weird : the file should be called libSDL_image.so .
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Lazy Foo Productions has a great deal of SDL 1 and 2 tutorials. This is how I learned SDL before switching to SFML. Good luck! ![]()
I am diagnosed with bipolar disorder. As it turns out, what I thought was my greatest weakness is now my greatest strength.
Everyday, I make a conscious choice to overcome my challenges and my problems. It's not easy, but its better than the alternative...
Offline
Lazy Foo Productions has a great deal of SDL 1 and 2 tutorials. This is how I learned SDL before switching to SFML. Good luck!
Thanks! ill give that a look.
Do you have sdl_image installed ?
you get that error when trying to compile with gcc ?
please post the full output .Something i find weird : the file should be called libSDL_image.so .
I get it when compiling with GCC. the headers are:
#include "SDL/SDL.h"
#include "SDL/SDL_image.h"It just spits out a file not found error if i dont include the "SDL/".
The location and name of the .so is: "usr/lib64/libSDL_image.so"
The full output is:
||=== Build: Debug in fgh (compiler: GNU GCC Compiler) ===|
/home/dogjaw2233/projects/fgh/main.cpp||In function ‘int main(int, char**)’:|
/home/dogjaw2233/projects/fgh/main.cpp|13|error: ‘SDL_Load’ was not declared in this scope|
||=== Build failed: 1 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
Offline
hello = SDL_Load("arch.png");dogjaw2233, i think the error is that SDL_Load is not a valid function.
SDL appears to have a SDL_LoadBMP() function for BMP graphics , and also a IMG_Load() function that can handle many graphic formats.
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Thank you lone_wolf. that worked perfectly!
Offline
Pages: 1