Interestingly, the performance on my machine (Mac M1) is worse on SC 3.12.2 vs. 3.13/14-dev.
3.12.2: beach ball for 10 seconds
3.13/14-dev: a couple of annoying seconds of pause.
You’d need to run this through a profiler to see where the bottle neck is. Without this, we can only speculate.
That being said, Qt widgets (which is the gui system used in sc) doesn’t support GPU rendering, and is very slow when drawing lots of things. It not really made heavy graphics use so there is a limit you cannot improve upon.
It might be worth trying to improve envelope view instead.
(
v = UserView(nil, Rect(0, 0, 1000, 500)).front;
v.drawFunc = { |view|
var bounds = view.bounds;
var n = 50;
var step = bounds.width / n;
Pen.use {
Pen.moveTo(0@0);
n.do { |i|
var x = i * step;
var y = if(i.odd, bounds.height, 0);
Pen.lineTo(x@y);
};
Pen.stroke;
};
};
)
It’s not a complex GUI at all… is that the limit now? There is a bug somewhere. If not, the GUI should not redraw everything until the user reaches the new size.