- Home /
Question by
Dankey_Kang · May 09, 2019 at 06:14 AM ·
c#editor-scriptingeditor scriptingonscenegui
How do I draw mesh geometry in the Scene Viewport in OnSceneGUI using Graphics?
I am making an editor and I am trying to use Graphics.DrawMesh(mesh, position, rotation, material, 0); to draw a cursor mesh on an EventType.Repaint event. My mesh flashes quickly then disappears. How do I draw my mesh to screen? I would have thought that a Repaint event would be the time to draw editor geometry but it doesn't persist. How can I draw a mesh to screen in an Editor class without creating an arbitrary hidden GameObject?
Comment
Your answer

Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
Custom Inspector to Load Instance Values 0 Answers
[solved]Using WWW instead of resources.load causes hang 1 Answer
When do the Attributes get set? 1 Answer