0

I have a site that has a profile page and I would like to allow the users to upload an image for the profile picture. I forsee a problem if the user select an image that is larger than what I am allowing for the site. Is their a good refrence or example how to accomplish this?

The site is developed in Visual Studio 2008 with VB.NET 3.5.

4

2 に答える 2

1

次のサイトには、これを行う方法の良い例が含まれています - Hybrid ASP.NET File Upload and Resize Sample (VB.NET)

于 2010-04-15T11:56:16.580 に答える
1

画像の形状は正しいが大きすぎる場合は、Bermoが話している方法を使用できます。

ただし、画像の最も興味深い部分を選択したい場合は、Redditがサムネイルに使用する手法を使用できます。

詳細についてはこちらを参照してください。ソース コード (Python) はこちらです。基本的に、画像をセクションに分割し、entropy値を使用して最も興味深いセクションを見つけ出します。

于 2010-04-15T12:14:03.537 に答える