Ruben2776 / PicView

Fast, free and customizable image viewer for Windows 10 and 11.
https://picview.org
Other
939 stars 63 forks source link

startup speed is slow. #125

Open cmhdream opened 7 months ago

cmhdream commented 7 months ago

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like A clear and concise description of what you want to happen.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

cmhdream commented 7 months ago

After the system starts, the first time I see the picture, the startup speed is slow.

nopeless commented 7 months ago

@cmhdream can you upload the picture in question here

cmhdream commented 7 months ago

@cmhdream can you upload the picture in question here

I think this is because the program is not started first when booting. So when you click on the image to open it, the program will be loaded, so it will be slower.

nopeless commented 7 months ago

@cmhdream can you upload the picture in question here

I think this is because the program is not started first when booting. So when you click on the image to open it, the program will be loaded, so it will be slower.

I was just trying to see if there are some elements that could otherwise influence this behaviour. My best guess is that the .net runtime takes time to start + the jit compiler just needs time to convert il to machine code

in otherwords there're not many ways to fix this :/

Ruben2776 commented 5 months ago

In the 2.2 version, I've optimized the startup procedure to load the visual elements first and the rest later, to make it feel faster.

Additionally, I'm currently working on rewriting from WPF to the Avalonia platform (and also add macOS support). Avalonia supports Native AOT deployment, which have faster startup time and smaller memory footprints.

It will take a while to convert it, but when it's completed, you can expect a new version with smoother performance and start-up time.

cmhdream commented 5 months ago

PicView 2.2.1 There are indeed improvements, not the .net version. However, compared with honeyview, the speed of starting the first picture for the first time is still slower. But I'm still looking forward to your new version, and I'd like to thank you for noticing the questions I raised.

.net 8 version. It seems a little faster.