godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.6k stars 21.28k forks source link

Physic 2D lag on Mac #17859

Closed bbcbreno closed 4 years ago

bbcbreno commented 6 years ago

Godot version: Godot 3.0.2

OS/device including version: MacOS 10.13.2 Radeon Pro 455 2 GB

Issue description: Any object that's moved with physic lag every second and in the same time. I uploaded this video to show the problem: https://www.dropbox.com/s/olylyeq1iq0k0nh/bug%20godot%20lag.mov

Steps to reproduce: Create a new project with a RigidBody2D and run the project.

More info:

chjhong commented 6 years ago

In my case. on pc and android, If turn Vsync on , it will lag. on android , if use light2D, specially with shadow enable, it lag.

Calinou commented 6 years ago

This looks similar to https://github.com/godotengine/godot/issues/2043.

bbcbreno commented 6 years ago

@Calinou , yes, it's similar! But here works fine on Godot 2 and I don't think it's a GPU issue.

bojidar-bg commented 6 years ago

@bbcbreno Likely jitter, see #15270. Basically, it sometimes manages to squeeze two physics frames between two display frames, thus causing a perceived jump (body moving too quickly). Or, more often, it would draw twice before the next physics frame comes, thus causing a slight stall (a frame without movement).

Calinou commented 4 years ago

Duplicate of #2043 and #15270. See also Fixing jitter and stutter in the documentation.