Segfault while loading sprites

Hello, when I try to load the sprite I get a segmentation fault when the compiler finds the file, I tried also setting an incorrect path, or inexistent name file, and it compiles, but if the path and name are correct, there pops up the segfault. Anyone other has the same problem, and/or a solution?
Thanks in advance

7 Likes

Hi, I had the same issue, then found this example code for loading a texture, loading... .

In the comments in the code it says "// NOTE: Textures MUST be loaded after Window initialization "

I moved my “InitWindow(…” line of code above the LoadTextures and it solved the segmentation fault for me.

12 Likes

that hit the spot, thanks.

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms