Open alper-batioglu opened 2 years ago
Thanks for posting. This fixes that issue: https://github.com/jonobr1/two.js/pull/661
If you're using an NPM version of Two.js. An interim fix you can make on your end (until the latest version is published to NPM) is to also pass a z component where z = 1
.
E.g: console.log(JSON.stringify(zui.surfaceToClient({ x: 10, y: 10, z: 1 })));
omg, how did I not try that. Thanks. :)
Describe the bug surfaceToClient of ZUI does not get affected by prior translateSurface (aka. panning)
To Reproduce Steps to reproduce the behavior:
console.log(JSON.stringify(zui.surfaceToClient({x:10, y:10})))
on line 62 (belowzui.translateSurface(dx, dy);
)Expected behavior surfaceToClient calculation should be affected by translateSurface (aka. panning)
Environment (please select one):
Desktop (please complete the following information):