Hi everyone,
I'm doing the CS50's youtube courses and in the early chapter 1 I've noticed that a simply task, like a make two images to scroll in parallax, is giving me a glitchy result. As you could see in the file attached, the background image is making some glitch while moving (you could see more clearly at the end on image).
I think is related to the Push library so I've tried to do it manually and I can't see this behavior. So I want to ask you guys if to manage the virtual resolutions are you using this library or another and why do you think this glitch happens.
Thanks!
Virtual Resolution Management
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Re: Virtual Resolution Management
I can't see any glitch.
Re: Virtual Resolution Management
I do see one glitch - not sure if it's the same as what you're seeing.
I've highlighted the issue which reminds me of screen tearing caused by Vsync, but it's happening diagonally. I've looked at the code and it seems to happen when the canvas (or "virtual screen") is drawn to the actual screen at 250% scale (which is what the game starts in if you don't resize the window). When resizing the window the glitch usually disappears but not at all window sizes.
Maybe there's a rounding issue somewhere in LÖVE or OpenGL, as I don't find anything weird in the push library that would cause this. All push is doing is allowing you to draw to a canvas which is then drawn to the screen at a certain position and with a certain scale. It's weird.
I've highlighted the issue which reminds me of screen tearing caused by Vsync, but it's happening diagonally. I've looked at the code and it seems to happen when the canvas (or "virtual screen") is drawn to the actual screen at 250% scale (which is what the game starts in if you don't resize the window). When resizing the window the glitch usually disappears but not at all window sizes.
Maybe there's a rounding issue somewhere in LÖVE or OpenGL, as I don't find anything weird in the push library that would cause this. All push is doing is allowing you to draw to a canvas which is then drawn to the screen at a certain position and with a certain scale. It's weird.
Tools: Hot Particles, LuaPreprocess, InputField, (more) Games: Momento Temporis
"If each mistake being made is a new one, then progress is being made."
"If each mistake being made is a new one, then progress is being made."
Re: Virtual Resolution Management
Ah, I could see it by taking a snapshot. Thanks, ReFreezed. Indeed it looks like a rounding problem. That triangle is most likely the dividing line between the upper and the lower triangle of the quad (rectangles are drawn as two triangles).
I guess the main problem is the 50% part of the 250%. Rounding errors are more visible at the halves. I've had trouble drawing regular images at or near positions with a decimal part of 0.5.
https://bitbucket.org/rude/love/issues/ ... ing-images
Anyway, unless you work with integral multiples, those rounding errors are likely to appear.
I guess the main problem is the 50% part of the 250%. Rounding errors are more visible at the halves. I've had trouble drawing regular images at or near positions with a decimal part of 0.5.
https://bitbucket.org/rude/love/issues/ ... ing-images
Anyway, unless you work with integral multiples, those rounding errors are likely to appear.
Re: Virtual Resolution Management
Thanks guys! It's true you can solve the problem changing the display size to any virtual sizer round variations (x2, x3, x4) and not the current scale.
Who is online
Users browsing this forum: Amazon [Bot], Bing [Bot], Google [Bot] and 9 guests