[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

david

9/27/2004 12:53:00 AM

Hi,

I am somewhat new to the .net framework, and I need to create thumbnails for
an asp.net app that are 140x100 regardless of the source file's aspect ratio.

To deal with the difference in aspect ratios, the thumbnails should use the
largest center rectangle they can.

Any ideas?

Thanks, david
6 Answers

Justin Rogers

9/27/2004 1:03:00 AM

0

Specifically what you want:
http://weblogs.asp.net/jus.../archive/2004/08/15/2...

More general if you want to search for other GDI+ stuff:
http://weblogs.asp.net/jus.../category...


--
Justin Rogers
DigiTec Web Consultants, LLC.
Blog: http://weblogs.asp.net/jus...

"david" <david@discussions.microsoft.com> wrote in message
news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> Hi,
>
> I am somewhat new to the .net framework, and I need to create thumbnails for
> an asp.net app that are 140x100 regardless of the source file''s aspect ratio.
>
> To deal with the difference in aspect ratios, the thumbnails should use the
> largest center rectangle they can.
>
> Any ideas?
>
> Thanks, david


david

9/27/2004 1:29:00 AM

0

Thanks for the link.

As I am still new to the .net thing, how would I actually implement the
math given in the above link?

What other code is need to read in an image (JPEG), and write out a
center-cropped-fixed-aspect-ratio thumbnail?


Thanks Again :-)

David


"Justin Rogers" wrote:

> Specifically what you want:
> http://weblogs.asp.net/jus.../archive/2004/08/15/2...
>
> More general if you want to search for other GDI+ stuff:
> http://weblogs.asp.net/jus.../category...
>
>
> --
> Justin Rogers
> DigiTec Web Consultants, LLC.
> Blog: http://weblogs.asp.net/jus...
>
> "david" <david@discussions.microsoft.com> wrote in message
> news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> > Hi,
> >
> > I am somewhat new to the .net framework, and I need to create thumbnails for
> > an asp.net app that are 140x100 regardless of the source file''s aspect ratio.
> >
> > To deal with the difference in aspect ratios, the thumbnails should use the
> > largest center rectangle they can.
> >
> > Any ideas?
> >
> > Thanks, david
>
>
>

Bob Powell

9/27/2004 6:53:00 AM

0

The article on finding the best-fit for an image while retaining the aspect
ratio in the GDI+ FAQ should be adaptable to your needs.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/gdipl...

The GDI+ FAQ RSS feed: http://www.bobpowell.net/f...
Windows Forms Tips and Tricks RSS: http://www.bobpowell.net/tips...
Bob''s Blog: http://bobpowelldotnet.blogspot.co...






"david" <david@discussions.microsoft.com> wrote in message
news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> Hi,
>
> I am somewhat new to the .net framework, and I need to create thumbnails
for
> an asp.net app that are 140x100 regardless of the source file''s aspect
ratio.
>
> To deal with the difference in aspect ratios, the thumbnails should use
the
> largest center rectangle they can.
>
> Any ideas?
>
> Thanks, david


david

9/27/2004 6:55:00 PM

0

Thanks for the link.

Is this the link you are refering to?
http://www.bobpowell.net/b...



"Bob Powell [MVP]" wrote:

> The article on finding the best-fit for an image while retaining the aspect
> ratio in the GDI+ FAQ should be adaptable to your needs.
>
> --
> Bob Powell [MVP]
> Visual C#, System.Drawing
>
> Answer those GDI+ questions with the GDI+ FAQ
> http://www.bobpowell.net/gdipl...
>
> The GDI+ FAQ RSS feed: http://www.bobpowell.net/f...
> Windows Forms Tips and Tricks RSS: http://www.bobpowell.net/tips...
> Bob''s Blog: http://bobpowelldotnet.blogspot.co...
>
>
>
>
>
>
> "david" <david@discussions.microsoft.com> wrote in message
> news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> > Hi,
> >
> > I am somewhat new to the .net framework, and I need to create thumbnails
> for
> > an asp.net app that are 140x100 regardless of the source file''s aspect
> ratio.
> >
> > To deal with the difference in aspect ratios, the thumbnails should use
> the
> > largest center rectangle they can.
> >
> > Any ideas?
> >
> > Thanks, david
>
>
>

david

9/27/2004 9:39:00 PM

0

I must say that I am still not sure how all the different GDI objects work
together to get the final result.

Is this written up somewhere?

Thanks,
David

"Bob Powell [MVP]" wrote:

> The article on finding the best-fit for an image while retaining the aspect
> ratio in the GDI+ FAQ should be adaptable to your needs.
>
> --
> Bob Powell [MVP]
> Visual C#, System.Drawing
>
> Answer those GDI+ questions with the GDI+ FAQ
> http://www.bobpowell.net/gdipl...
>
> The GDI+ FAQ RSS feed: http://www.bobpowell.net/f...
> Windows Forms Tips and Tricks RSS: http://www.bobpowell.net/tips...
> Bob''s Blog: http://bobpowelldotnet.blogspot.co...
>
>
>
>
>
>
> "david" <david@discussions.microsoft.com> wrote in message
> news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> > Hi,
> >
> > I am somewhat new to the .net framework, and I need to create thumbnails
> for
> > an asp.net app that are 140x100 regardless of the source file''s aspect
> ratio.
> >
> > To deal with the difference in aspect ratios, the thumbnails should use
> the
> > largest center rectangle they can.
> >
> > Any ideas?
> >
> > Thanks, david
>
>
>

Bob Powell

9/28/2004 8:24:00 AM

0

Thats the one.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/gdipl...

The GDI+ FAQ RSS feed: http://www.bobpowell.net/f...
Windows Forms Tips and Tricks RSS: http://www.bobpowell.net/tips...
Bob''s Blog: http://bobpowelldotnet.blogspot.co...






"david" <david@discussions.microsoft.com> wrote in message
news:7CB057ED-BB22-4531-AA44-3569FD0BBBCD@microsoft.com...
> Thanks for the link.
>
> Is this the link you are refering to?
> http://www.bobpowell.net/b...
>
>
>
> "Bob Powell [MVP]" wrote:
>
> > The article on finding the best-fit for an image while retaining the
aspect
> > ratio in the GDI+ FAQ should be adaptable to your needs.
> >
> > --
> > Bob Powell [MVP]
> > Visual C#, System.Drawing
> >
> > Answer those GDI+ questions with the GDI+ FAQ
> > http://www.bobpowell.net/gdipl...
> >
> > The GDI+ FAQ RSS feed: http://www.bobpowell.net/f...
> > Windows Forms Tips and Tricks RSS:
http://www.bobpowell.net/tips...
> > Bob''s Blog: http://bobpowelldotnet.blogspot.co...
> >
> >
> >
> >
> >
> >
> > "david" <david@discussions.microsoft.com> wrote in message
> > news:FC97AB9F-2DFC-4B66-AB65-ABFE14C3EB2A@microsoft.com...
> > > Hi,
> > >
> > > I am somewhat new to the .net framework, and I need to create
thumbnails
> > for
> > > an asp.net app that are 140x100 regardless of the source file''s aspect
> > ratio.
> > >
> > > To deal with the difference in aspect ratios, the thumbnails should
use
> > the
> > > largest center rectangle they can.
> > >
> > > Any ideas?
> > >
> > > Thanks, david
> >
> >
> >