Search Issue Tracker
Fixed in 2020.2.X
Votes
0
Found in
2019.3.0a11
2019.4
2019.4.1f1
2020.1
Issue ID
1257165
Regression
Yes
Camera.ScreenToWorldPoint returns incorrect values when built in WebGL
How to reproduce:
1. Open user's attached "ProgrammingAssignment2.zip" project
2. Open "SampleScene" Scene
3. Enter Play Mode
4. Move the "Paddle" GameObject with WASD keys in the Game view so the ball would hit the side of the screen
5. Go to File -> Build Settings
6. Make sure the platform is set to WebGL
7. Press Build And Run
8. Repeat step 4 when the application is loaded in the browser
9. Observe the console in the browser
Expected result: The ball collides with the side of the screen, "Bottom Left: (-8.9, -5.0, 0.0)" is printed in the console
Actual result: The ball goes outside of the screen, "Bottom Left: (-10.0, -5.0, 0.0)" is printed in the console
Reproducible with: 2019.3.0a11, 2019.4.2f1, 2020.1.0a4
Not reproducible with: 2018.4.24f1, 2019.3.0a10, 2020.2.0a14, 2020.2.0a15
Could not test with: 2020.1.0a5 - 2020.2.0a13 ("Screen position out of view frustum (screen pos 0.000000, 0.000000, 10.000000)" error message is thrown)
Notes:
- The issue is not reproducible in the Editor and on Windows, Mac build
- Expected, Actual result values of "Bottom Left" are from building the application in 1280x720 resolution
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note (fix version 2020.2):
Fixed in: 2020.2.0a14