在Windows窗体应用程序中预览图像列表. [英] Preview a list of images in windows form application.

查看:66
本文介绍了在Windows窗体应用程序中预览图像列表.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,我目前正在使用Visual Studio 2008从事一个大学项目; C#,Windows窗体应用程序.

在一个任务中,我想以程序的形式预览图像列表.

以前,我使用imageList和listView(Largeimagelist)来显示目录中的所有图像.

但是,由于我拥有大量图像(数千张),因此预览需要很长时间才能将所有图像加载到listView中.

因此,我的问题是,有没有一种有效且快速的方法可以在Windows窗体应用程序的窗体上预览大量图像?

Hi all, I''m currently working on a college project using Visual studio 2008; C#,windows form application.

In a task, i would like to preview a list of images on the form of my program.

Previously, the i used imageList and listView(Largeimagelist) to show all the images within a directory.

However, due to the large number of the images i have (a few thousands of them), the preview takes very long to load all the images in the listView.

So, my question is, is there any efficient and faster way i can preview a large number of images on the form of my windows form application program?

推荐答案

成千上万无论您做什么,图像加载都将花费很长时间.

如果要生成缩略图,则需要进行大量处理.

如果要显示图像(并且它们的大小不限),则有很多磁盘访问权限.

开箱即用的唯一操作是在添加到列表之前,确保您正在使用AddRange或最少使用BeginUpdate/EndUpdate.

希望这会有所帮助.

干杯.
Thousands of images will take a long time to load no matter what you do.

If you are generating thumbnails, there''s a lot of processing going on.

If you''re showing the images (and there is any size to them at all) there is lots of disk access.

The only thing to do out-of-the-box is to make sure you''re using AddRange or minimally using BeginUpdate/EndUpdate before adding to the list.

Hope this helps.

Cheers.


这篇关于在Windows窗体应用程序中预览图像列表.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆