Hi,
Replace :
MyCapture.Bitmap.SaveToFile(ChangeFileExt(ParamStr(0), '.jpg'));
by :
MyCapture.SaveToFile(ChangeFileExt(ParamStr(0), '.jpg'));
This work because Bgrabitmap set automatically the image writer based on the
extension.
Patrick
29 avril 2021 17:49 "Bo Berglund via lazarus" a
écri
On 2021/04/29 17:49, Bo Berglund via lazarus wrote:
I have an application which can capture a regon of the desktop into an image.
It uses TBgraBitmap since it has a method for grabbing data from the screen.
So I can assign this to the clipboard and also save to a file:
var
MyCapture : TBgraB
I have an application which can capture a regon of the desktop into an image.
It uses TBgraBitmap since it has a method for grabbing data from the screen.
So I can assign this to the clipboard and also save to a file:
var
MyCapture : TBgraBitmap;
Clip: TRect;
...
begin
...
Clip := Bound