BlueMap icon indicating copy to clipboard operation
BlueMap copied to clipboard

Float-Precision issues on extreme distances from 0,0

Open WenXin20 opened this issue 4 years ago • 5 comments

BlueMap Version: v1.3.1-forge

I am using:

  • [x] mods (on the rendered world)
  • [x] resourcepacks (in bluemaps config/resourcepack folder)

Description:

  • Traveling to extreme distances causes map jerkiness and block disconnections. (based on chunks maybe?)

Capture

WenXin20 avatar Feb 06 '21 00:02 WenXin20

I also have this issue without any mods and using BlueMap Verison 1.3.1-spigot chrome_2021-02-16_13-30-40 PM if you want a link

Toys0125 avatar Feb 16 '21 19:02 Toys0125

Kind of related (and copied from Discord):

Ok so there's two different "symptoms" that start happening at different distances:

  • The tiles start "shaking" slightly when rotating or tilting the camera This starts very early at around 100k but only very slightly. At 200k-300k it is easily noticeable especially when zoomed in. At really high coordinates, tiles start flickering randomly.

  • The camera starts "jumping" instead of moving smoothly Starts at around 500k and gets really bad at around 1m-2m.

(Tested with Firefox on Bluemap Spigot 1.3.1 with a mod that allows for an infinite repeating hires map)

Mark-225 avatar Mar 06 '21 11:03 Mark-225

I noticed this too :)

DuckyBlender avatar Mar 30 '21 10:03 DuckyBlender

This is just a guess but I believe that the 3D engine for the WebGL is using floating-point so as we go further out the precision worsens. So my opinion is to use a local cord system based on the current position of the camera or find a BigInt implementation for WebGL.

Toys0125 avatar Apr 05 '21 04:04 Toys0125

Just wanted to show that it still has a similar issue with 1.4.2 at extreme distance. It no longer keeping the blocks uniform. chrome_2021-04-19_14-40-20

Toys0125 avatar Apr 19 '21 19:04 Toys0125