I’m a bit lost with the whole expiring and recompute/redraw of grasshopper. I have the following situation roughly like this.
for (var i = 0; i < Population; i++)
{
Go through all sliders and set tick value (foreach loop)
{
//This should set the new slider values and at the end
//of this loop it should recalculate the solution without redrawing ever the canvas
sliders.SetTickValue(value)
}
//Here it should redraw the canvas once.
Doc.NewSolution(false);
// Doc.ExpirePreview(false);
// Doc.ExpireSolution(false);
}
The goal of all this is to improve the time it takes to calculate all of the options. Would anyone have some pointers on that.
Thank you for sharing all these topics! Turns out i didt do my homework properly, i just had a deeper look into the grasshopper api and turns out this was excactly what i was searching for…