Jump to content
  • Advertisement

Archived

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

Ichigo

Dev-C++ and images

This topic is 5866 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''m wrighting a simple program in SDL in Dev-C++ , all it realy does is draw one .BMP over another one, as an extra feature it draws some nlue pixels too! I''ve run in to a small problem. When I run the .EXE file from a textpromt or from explorer, everyting works just fine. The strange thing is that when I push the "Run project" button in Dev-C++ the program runns.. But none of the imagefiles (.BMP) are loaded.

Share this post


Link to post
Share on other sites
Advertisement
Check the image paths... Maybe the working directory that the IDE runs the program from is different from wherever you''re running it when you''re at the command prompt.

Share this post


Link to post
Share on other sites
Which version are you using? I had this problem in 4.9.3.0 (beta3) but it went away in 4.9.4.0 (beta4).

Share this post


Link to post
Share on other sites
quote:
Original post by Melraidin
Check the image paths... Maybe the working directory that the IDE runs the program from is different from wherever you''re running it when you''re at the command prompt.


I changed


  
bg = SDL_LoadBMP("Asuka.bmp");
img = SDL_LoadBMP("eva03.bmp");


to


  
bg = SDL_LoadBMP("C:/Documents and Settings/Jakob/Mina dokument/my tests/Asuka.bmp");
img = SDL_LoadBMP("C:/Documents and Settings/Jakob/Mina dokument/my tests/eva03.bmp");


And now it works jsut fine.

But there should be a better way to do it.

Maybe I shoud just update to the latest Dev-C++ vertion.

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!