Search Issue Tracker
Not Reproducible
Votes
0
Found in
5.4.0p3
Issue ID
829122
Regression
Yes
[FrameDebugger] Frame debugging, while it is possible to draw trees on terrain, causes errors
How to reproduce:
1. Open the attached project
2. Open ErrorScene2.unity
3. Open Frame Debugger (Window -> Frame Debugger) and click Enable.
4. Notice the console is flooded with the following message:
"PPtr cast failed when dereferencing! Casting from Mesh to Renderer!"
5. Select the "Terrain" object in scene, go to settings and turn off Draw under Tree & Details Objects
or
Select the "Terrain" object in scene, go to Place Trees, select the tree and remove it
6. Clear the Console, notice no further error
Not reproducible: 5.3.6p5, 5.5.0b3
Reproducible: 5.4.0f1, 5.4.1p1
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
icinema
Feb 20, 2017 04:17
Encountered exactly the same issue (frame-debugging a Unity scene containing only a Unity Terrain object with trees placed):
Number of errors reported is directly proportional to number of active tree instances within the current view frustum at the moment the debugger's 'Enable' button is clicked.
[Unity version 5.4.2f2] - Unity console trace as follows:
PPtr cast failed when dereferencing! Casting from Mesh to Renderer!
UnityEditorInternal.FrameDebuggerUtility:GetFrameEventGameObject(Int32)
UnityEditorInternal.FDTreeViewDataSource:FetchData() (at C:/buildslave/unity/build/Editor/Mono/PerformanceTools/FrameDebuggerTreeView.cs:248)
UnityEditor.TreeViewDataSource:ReloadData()
UnityEditorInternal.FDTreeViewDataSource:SetEvents(FrameDebuggerEvent[]) (at C:/buildslave/unity/build/Editor/Mono/PerformanceTools/FrameDebuggerTreeView.cs:171)
UnityEditor.DockArea:OnGUI()