The first object creation operation I do in a newly opened blank document always has a slight delay in execution - which is a bit unnerving when I try do do something fast.
For example, I open a new blank file, then draw a rectangle. Everything is perfectly responsive to click the first point and draw the rectangle on screen, but after I click the second point, Rhino freezes for about a half second, then finishes the command. After that, it’s perfectly fine. Same would happen with a box or other object creation command, the first object creation in any blank document exhibits this. And on all 3 of my computers.
If I open a previously-saved document that already has at least one object in it, it doesn’t happen. From this I infer that Rhino may be doing something to set up the object table in the document or some other preparatory operation behind the scenes which causes the delay…
Has anyone else experienced this? Just curious. Here is a quick video with a box - note the slight delay after the 3rd point click and the apparition of the box shaded - note this is not a mesh creation issue, it also happens with curves, etc.
@Helvetosaur and @wim, try running the command “TestShaderCache”, make sure the command line reads “Cache Enabled” and restart Rhino. Does this fix the issue with slow refresh on the first curve drawn? I may have messed up the default setting for this feature.
Yep, looks like the shader cache is working just fine. I’m suspecting it is the initial loading of environment textures. I can break Rhino during the pause and end up inside of CRhGLEnvironmentV2::GetReflectionEnvironmentData
I don’t think we have a good way to cache that routine at the moment. Maybe @DavidEranen has some ideas on improving the performance of that routine.