Swordfish90 / cool-retro-term

A good looking terminal emulator which mimics the old cathode display...
22.14k stars 843 forks source link

Improving performance #235

Open shmerl opened 9 years ago

shmerl commented 9 years ago

Thanks for the project! (I have just discovered it).

So far I see that running even one terminal loads X, kwin and plasma-desktop in KDE noticeably (CPU). Is there any way to reduce CPU load and use GPU as much as possible? In theory it sounds like most of the effects can happen on the GPU, so CPU should not be significantly loaded, so why does it happen? Or it's some X deficiency which can for example be better addressed with Wayland?

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

Swordfish90 commented 9 years ago

@shmerl Glad you are enjoying it. In theory both the terminal texture and the effects are drawn by the GPU. During my tests I always found the CPU consumption to be quite low (1-3% on a haswell i5 laptop). Something I actually noticed in the last weeks is that the CPU consumption of CRT (together with X), climbs up when the settings and the menus are used and never gets down. Could you please test if this is the case for you? Try running an instance of CRT without touching the menubar or the right click button.

Moreover could you please include some details regarding your machine and your OS?

gc1o1 commented 4 years ago

I'd like to confirm the CPU usage is very high on Ubuntu 20 under WSL (Windows 10), unless the frames per second are reduced a lot (under 10 fps), or the window size is reduced to about a quarter of a 1920x1080 display.

The GPU doesn't show any signs of usage in the Windows10 Task Manager. That could be simply because WSL1 doesn't currently use the GPUs.
All the work is done by the CPUs, where the usage can reach 40-50% on a i7-8700K 3.70GHz with 12 cores.

This happens even if I turn off all the effects! Just rendering the image is enough to spin up the CPU. It has no connection to opening the settings menu or not.

Sch-LikA commented 3 years ago

I just tried it on a Raspberry 4 and a Jetson Nano (had to install Armbian, wouldn't work on official nvidia Ubuntu distro) and CPU load is extremely high on both (close to 100% of all the 4 cores). xdpyinfo tells me I have direct rendering. Getting FPS down to 10 is better, but experience is quite laggy unfortunately. The project itself is seriously amazing anyways, thanks a lot !

My plan was to use it in a 3d printed Callisto 2 case as a terminal to a pidp-11 ...

wile1411 commented 1 year ago

Awesome project @Swordfish90 - brings back great nostalgia. I'm running this on a Raspberry Pi4 with OS lite. As an update for this ticket - I installed this via the apt-get install cool-retro-term and it worked fine.

CPU hovers around 45-56%. You can drop it down to <10% by turning the effects FPS down to 1FPS. I've added the Pi cooling heatsink tower to keep the device cool when it's running both the CRT terminal and anything else so my temp stays around 45C.

Any other specific information you'd like in detail that might help in changes to trim the CPU usage?

ngocphamm commented 1 year ago

This is my observation for resource (CPU & GPU?) usage on my laptop (Intel macbook 2019 core i9 with Radeon graphics).

CRT's Performance Settings: Default at 20 FPS, 100 % Textual Quality, 50% Bloom and BurnIn Quality.

Using an app to monitor various stuff in the machine (iStat Menus), I'm looking at wattage use of the graphic cards.

I figure CRT needs to render the special effects, so it must use more energy, and that's reasonable. However above is my observation for how interesting (to me) its visibility affects the resource use.

Also, this is memory usage after I leave CRT runs for an extended period of time (normally I would just leave my terminal app running the whole time I have my laptop run, which can be months at a time). It seems to reach this level in a day or so and stays around that.

CleanShot 2023-01-06 at 08 18 35@2x