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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - FreNeS1

Pages: [1]
1
Window / Re: Fullscreen at non-screen resolutions causes desktop to show.
« on: October 18, 2016, 10:15:03 pm »
Ok, this has cost me a bit of a headacke, but I finally figured it out.

Windows 10 has a special scaling feature that seems to affect the window. In Config -> System -> Display (first option) there's a scaling of aplications, text and other elements. This aplies to everything on screen, but when the game is launched, it seems to default it at 100%.

When you change it manualy to 125% (my default) after launching the game it "fixes" the fullscreen. When exiting the game after manualy changing it, it goes up to 150%.

When asking the window to display at desktop resolution, my guess is that it leaves the scaling alone because it doesn't have to change anything.

If there could be some way to access the scaling factor previous to creating the screen, you could manualy scale the window, but I have no idea how to do that. Honestly I have no idea how to fix this.

EDIT1:
Right now I'm "solving" the problem by making fullscreen mode only avaliable to the user as (sf::VideoMode::getDesktopMode()), but I'd prefer if there was a way of making fullscreen reliable in windows 10.

2
Window / Re: Fullscreen at non-screen resolutions causes desktop to show.
« on: October 18, 2016, 07:57:45 pm »
I had SFML 2.3.2. But now I have updated it to 2.4.0 and the issue is still there.

NVIDIA Geforce 750M - Lattest drivers (373.06)

3
Window / Fullscreen at non-screen resolutions causes desktop to show.
« on: October 18, 2016, 05:55:59 pm »
Hi, I started a project a while now, and I just now realized a problem with the fullscreen.

When I ask the window to display at fullscreen with the videomode set as the screen resolution, it shows correctly, but if I ask the window to display at fullscreen with a videomode lower than the screen resolution (even being valid) It shows, displays and updates correctly, but part of the desktop is shown. I can even interact with the desktop while the program is fullscreen.

Here's an image of that: https://s9.postimg.org/9lg8onzqn/Error.png

I don't think the code has anything to do with it but here goes anyway:

m_Window = new sf::RenderWindow();
                if (m_Options.getFullscreen())
                {
                        sf::VideoMode vm = sf::VideoMode(m_Options.getWidth(), m_Options.getHeight());
                        if (vm.isValid())
                                m_Window->create(vm, title, sf::Style::Fullscreen);
                        else
                        {
                                utils::FileLogger::Log(utils::FileLogger::LogType::LOG_WARNING, "Window mode not suported, starting windowed");
                                m_Window->create(vm, title, sf::Style::Close);
                        }
                }
                else
                        m_Window->create(sf::VideoMode(m_Options.getWidth(), m_Options.getHeight()), title, sf::Style::Close);

Pages: [1]
anything