Search Issue Tracker
By Design
Votes
0
Found in
2019.1.0a10
2019.4
2020.1
2020.1.3f1
2020.2
Issue ID
1273183
Regression
Yes
[Metal] Crash on glEnable when calling glEnable(GL_POINT_SMOOTH) in OnPreRender
Steps to reproduce:
1. Open the attached project ("StrippedScene.zip")
2. Open "SampleScene"
3. Enter Play mode
Reproducible with: 2019.1.0a10, 2019.4.8f1, 2020.1.4f1, 2020.2.0b2
Not reproducible with: 2018.4.23f1, 2019.1.0a9
Notes:
- Doesn't reproduce on OSX with OpenGLCore
- Doesn't reproduce on Windows with DX11, DX12, Vulkan
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
- [Mobile] Developer Console does not appear when an error is thrown
- [HDRP] Game view renders artifacts when Camera's Component "Post Anti-aliasing" is set to "TAA" and Dynamic Resolution's "Forced Screen Percentage" is changed
- A deactivated Prefab's name color becomes white when a GameObject in the scene is deactivated
- The Game view becomes blank when using Frame Debugger with MSAA and Texture binding enabled in Play Mode
- NullReferenceException is thrown when changing the Inspector preview selection
Resolution Note (2020.2.X):
You can't expect to lookup glEnable function manually from a system OpenGL library, store the current OpenGL renderer status into a boolean, and then call glEnable without the check in question. Some OpenGL driver implementations might give a free pass on this if there is no OpenGL context set available at all, but don't count on it.
void OnPreRender()
{
if (mIsOpenGL)
glEnable(GL_VERTEX_PROGRAM_POINT_SIZE);
glEnable(GL_POINT_SMOOTH);
}