unknown-horizons / godot-port

Unknown Horizons Godot Engine Port
https://www.unknown-horizons.org
GNU General Public License v2.0
665 stars 83 forks source link

Which renderer will be default? GLES 2, GLES 3 or Vulkan? #32

Closed qarmin closed 5 years ago

qarmin commented 5 years ago

Now with Godot 3.0.6 we don't have any choice, so for now UH use GLES 3. When Godot 3.1 will arrive, I would recommend moving immediately to GLES 2. Even if Godot will support Vulkan, UH should stay with GLES 2.

Changing renderer when project will be advanced, probably will need a lot of work to customize it with it.

YeldhamDev commented 5 years ago

Considering that Godot will automatically fallback to GLES 2 if needed, I don't see why not default with GLES 3/Vulkan.

aaronfranke commented 5 years ago

We can examine which performs better for our use case. UH is very simple graphically, so maybe GLES 2 would work better, and many users on Discord have old GPUs.

However, as Yeldham said, Godot should automatically fall back to GLES 2 if GLES 3 is not available, so that last point shouldn't matter except for developers.

Calinou commented 5 years ago

While still technically possible, the automatic fallback is no longer officially supported in 3.1 stable, so it would be wise to default to GLES2 to get consistent results on all platforms.

PS: If you don't make use of any 3D elements, you can get slightly better performance by setting the Framebuffer Allocation to 2D Without Sampling in the Project Settings.

aaronfranke commented 5 years ago

gles2

@Calinou Any idea how to fix this? The borders between tiles are very visible in GLES2. Even if I scale the tiles to be much bigger, there are still gaps.

Calinou commented 5 years ago

@aaronfranke Are these still visible if you enable 2D Pixel Snap in the Project Settings?

YeldhamDev commented 5 years ago

@Calinou This is in 3D. Also, "2D Without Sampling" still affects 2D, as Polygon2Ds will not render their texture for example.

clayjohn commented 5 years ago

@aaronfranke Those artifacts are a result of mip-mapping. I suggest turning it off in import for projects like this.

aaronfranke commented 5 years ago

@clayjohn As far as I can tell, that's already disabled:

1

clayjohn commented 5 years ago

You still need to do it on the import settings of the actual textures.

YeldhamDev commented 5 years ago

Done. Looks pretty better: Screenshot at 2019-04-01 03-09-23

aaronfranke commented 5 years ago

But now there's flickering when I zoom out and move the camera around... Even after enabling MSAA in the project settings, it doesn't seem that it affects these textures anymore with the mipmaps disabled.

clayjohn commented 5 years ago

@aaronfranke yea. MSAA wont help for texture artifacts like that. Also its not working in GLES2.

The reason you are getting the lines is that the tiles arent exactly the same on the edges. In short, they are not repeating tiles, they just look like they are because they are pixelated. Unfortunately, I think the only real solution is to redesign the assets.

I will experiment tomorrow to see if I can come up with a better solution.

aaronfranke commented 5 years ago

I'm going to close this with the resolution of "We'll use only GLES 2".

The flickering is a minor problem that we can deal with later if it's still an issue.