Projected position is wrong
See original GitHub issueDescribe the Bug
After making use of react-dnd
and adding simple drag and drop support, i found that the projected position I am getting is completely off. What makes it even more irregular is that it doesnt always happen. So when not moving the camera/view at all, sometimes it would project correctly sometimes not. But as soon as you move around and the transform changes form [0,0,1], the projected position starts to jump around.
I’ve included a sandbox, just open it up and try dropping. If it doesnt happen, try refreshing once or twice and try again. Its very irregular and doesnt always happen.
Your Example Website or App
https://codesandbox.io/s/sandpack-project-forked-2pwdnu?file=/App.js
Steps to Reproduce the Bug or Issue
- Open sandbox
- Try dropping once
- If it doesnt project wrong, refresh
- Try again
- Repeat from steps 2-4 with diferent usecases, such as first panning or zooming then dropping.
Expected behavior
It should calculate the correct position
Screenshots or Videos
Platform
- OS: [e.g. macOS, Windows, Linux]
- Browser: [e.g. Chrome, Safari, Firefox]
- Version: [e.g. 91.1]
Additional context
No response
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Fix data when it appears in the wrong place - Learn ArcGIS
The only way to undo the tool is to run it again and redefine the original coordinate system. Click Run.
Read more >Wrong position when reprojecting layers from EPSG:32651 ...
I solved it. I used the define projection tool to solve the problem where the layer has same projection but different extent.
Read more >Projection Error When Evaluating True Position of Threaded ...
My quality team is telling me there is projection error when evaluating the .030" true position on the opposite end of the part...
Read more >Tissue Projection Errors - Practical Panoramic Imaging
Hard Tissue Projection Errors. 1. Spine – The first hard tissue error can occur when the patient assumes the “head extended” position.
Read more >Do your projected views in a Solidworks drawing seem to be ...
Do your projected views in a Solidworks drawing seem to be wrong? Here's how you can solve it. Report ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yeah, was about to update the issue with this. Did not notice the
react-dnd
hook was memoized. Works as expected.Seems like your position calculation is not correct.
This works completely fine for me in the sandbox you linked: