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 - AlekseiF

Pages: [1]
1
Graphics / Re: Fullscreen artifacts
« on: April 16, 2020, 11:08:09 am »
 :o I think I became a bit smarter now. Thank you so much!

2
Graphics / Re: Fullscreen artifacts
« on: April 16, 2020, 10:07:45 am »
I did, I really did :) About GPU and Monitor refresh rate being out of sync.
Different approaches to fix that etc.

What I meant behind the "reason" - why I am seeing this in fullscreen only.

3
Graphics / Re: Fullscreen artifacts
« on: April 16, 2020, 08:32:10 am »
Thank you for the answer. Does that mean, I should stop trying to find the reason and rely totally on VSync?

4
Graphics / [SOLVED] Fullscreen artifacts
« on: April 15, 2020, 11:03:02 pm »
Hello everyone.

Sorry if failed to find a solution in the topics, I did try the search.
For the past 3 days I've been trying to find a reason for an issue I've been facing when running project in fullscreen mode.

I've tried to make a video and a screenshot, but for whatever reason that does not capture the artifacts, so I will try to explain that + add a screenshot with a small drawing.

Using .net SFML

I reduced everything in the project to have a sprite and a view for movement.
View is getting updated every frame and under certain conditions I move the view to have the effect of scrolling the world.

Whenever I set the fullscreen style:

_window = new RenderWindow(VideoMode.DesktopMode, "", Styles.Fullscreen);

I get strange behavior as if I see the previos frame buffer (kinda tried to draw that on screenshot)
What bothers me is that happens ONLY in fullscreen and I can not understand the reason behind that.

So I try to limit the framerate like this - update and render ~60 times a second:

private float _timePerFrame = 1.0f / 60.0f;
 
......................

 while(_window.IsOpen)
      {
        _timeSinceLastUpdate += clock.Restart().AsSeconds();
        if (_timeSinceLastUpdate > _timePerFrame)
        {
          _timeSinceLastUpdate -= _timePerFrame;
          _window.DispatchEvents();
          Update(_timePerFrame);
          Render();
        }
      }


Now setting VSync makes the problem dissapear, but I would still like to understand why this happens.
My monitors refresh rate is 60 (well 59 by looking into display settings).

Any ideas are very appreciated.

Pages: [1]
anything