Jump to content
  • Advertisement

tristan1333

Member
  • Content Count

    17
  • Joined

  • Last visited

Community Reputation

154 Neutral

About tristan1333

  • Rank
    Member

Personal Information

  • Interests
    Education
    Programming

Recent Profile Visitors

1404 profile views
  1. No matter what I do, I can't figure out a way to convert the mouse position to a world coordinate. SDL_GetMouseState gives the window position, but doesn't take into account the logical size. It's got me completely lost and frustrated, I just keep thinking of a way to fix it, and completely mind blanking. I need to click a place on the window, convert it into a place within the 640x480 size I've set, then convert it into a world position, but I just can't convert the position down to the 640x480 size
  2. When using SDL_setlogicalsize to have the screen be resizable, it works fine. Using SDL_GetMouseState(&x, &y); to poll the mouse position, it's based on the position of the screen, I'm using 640x480 for the base screen size to resize from. I'm wondering how to convert it down to what I need?
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!