Lazarus

Programming => Graphics and Multimedia => Graphics => Topic started by: faber on August 18, 2010, 11:37:45 am

Title: Stretch picture from TImage
Post by: faber on August 18, 2010, 11:37:45 am
How to get stretched picture from TImage ?
I need TPicture (Image1.Picture.Bitmap), but when I take Picture.Bitmap I get orginal picture (loaded from file). I need a bitmap that TImage current shows (in my case stretched).
Title: Re: Stretch picture from TImage
Post by: felipemdc on August 18, 2010, 11:49:36 am
Just copy the bitmap to another one and then stretch it yourself.
Title: Re: Stretch picture from TImage
Post by: José Mejuto on September 02, 2010, 12:28:48 am
How to get stretched picture from TImage ?
I need TPicture (Image1.Picture.Bitmap), but when I take Picture.Bitmap I get orginal picture (loaded from file). I need a bitmap that TImage current shows (in my case stretched).

Hello,

You can download sources from http://sourceforge.net/projects/thetvdbartcut/ and inside there are some strenched copies from a base image.
Title: Re: Stretch picture from TImage
Post by: theo on September 02, 2010, 10:10:00 am
There is an example here:

http://www.lazarus.freepascal.org/index.php/topic,8282.msg39786.html#msg39786

This is a bit more than what you need, because it ist "zooming" an area of Image1 to Image2, but the principle is the same.
Title: Re: Stretch picture from TImage
Post by: faber on September 02, 2010, 12:29:28 pm
Thanks. Image1.Picture.Bitmap.Canvas.StretchDraw - this is what I was looking for.
TinyPortal © 2005-2018