Jump to content
  • Advertisement

Archived

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

This topic is 5452 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 am working on a project that uses OpenGL and I want to port it to Linux using SDL, however without including windows.h all the typedefs, #defines and functions I use (like QueryPerformanceCounter and LONGLONG) are unavailable. What can I do? Should I #define and typedef what I need and use other alternative for the APIs? "C lets you shoot yourself in the foot rather easily. C++ allows you to reuse the bullet!"

Share this post


Link to post
Share on other sites
Advertisement
SDL has its own types that you can use so that it will compile on any system. You''re better off changing to those instead of writing your own defines. That way, you could still compile it on Windows without much source changing.

Share this post


Link to post
Share on other sites
Go to http://www.libsdl.org/ , and click on "Documentation"
Alternatively, look at the SDL header files to see what they do.

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!