Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: First VideoMode is larger than my screen  (Read 4917 times)

0 Members and 1 Guest are viewing this topic.

Gubidonius

  • Newbie
  • *
  • Posts: 2
    • View Profile
    • Email
First VideoMode is larger than my screen
« on: December 01, 2020, 10:47:11 pm »
Hi,
In the list of video modes, the first one is larger than my screen

Is there any way to not to manually select the screen size mode?

Now I do it like this:
auto window = make_shared<sf::RenderWindow>();
window->create(sf::VideoMode::getFullscreenModes()[0], "window", sf::Style::Fullscreen);

width and height of sf::VideoMode::getFullscreenModes()[0] are 3620 and 2036 but my screen size is 2560x1440, i use SFML v2.5.1

help me please
« Last Edit: December 01, 2020, 11:13:17 pm by Gubidonius »

G.

  • Hero Member
  • *****
  • Posts: 1593
    • View Profile
Re: First VideoMode is larger than my screen
« Reply #1 on: December 02, 2020, 09:16:53 am »
getFullscreenModes is the list of the video modes supported by your screen.
getDesktopMode is the current video mode of your screen.

Gubidonius

  • Newbie
  • *
  • Posts: 2
    • View Profile
    • Email
Re: First VideoMode is larger than my screen
« Reply #2 on: December 02, 2020, 12:43:39 pm »
Thanks, it works!