pfalstad / circuitjs1

Electronic Circuit Simulator in the Browser
GNU General Public License v2.0
1.64k stars 279 forks source link

low frame rate when speed is too high #63

Closed TishSerg closed 3 months ago

TishSerg commented 7 months ago

Same circuit, same circumstances, same settings, but heavy difference:

2.8.1: image

2.7.4: image

pfalstad commented 7 months ago

It's not slower, it's actually slightly faster! In 2.8.0, we have a minimum framerate of 20 fps. In 2.8.1 I lowered the minimum to 2 fps. According to my test, the simulation runs faster but the display is much choppier. That's because we're running the simulation longer before stopping to update the display. Someone requested this (#54). Reduce the simulation speed to make the display less choppy.

TishSerg commented 7 months ago

Reduce the simulation speed to make the display less choppy.

That did the trick. Thank you.

In 2.8.0, we have a minimum framerate of 20 fps. In 2.8.1 I lowered the minimum to 2 fps.

How about making this adjustable? Say in "Other Options"...

pfalstad commented 7 months ago

probably a good idea to make it adjustable. 2 fps is too low.

pfalstad commented 3 months ago

It's adjustable now and is higher by default.