gflSetIPTCValue - Delphi

Discussions on GFL SDK, the graphic library for reading and writing graphic files

Moderators: helmut, XnTriq, xnview

kurka666
Posts: 47
Joined: Thu Mar 10, 2005 11:41 am

gflSetIPTCValue - Delphi

Post by kurka666 »

I have just downloaded the GFL SDK for use with Delphi, but it seems the gflSetIPTCValue function (amongst others) are not available to Delpih. Is this correct, and if so, when will it be available.

I intended to use the GFL SDK mainly for updating IPTC-information
User avatar
xnview
Author of XnView
Posts: 45870
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: gflSetIPTCValue - Delphi

Post by xnview »

kurka666 wrote:I have just downloaded the GFL SDK for use with Delphi, but it seems the gflSetIPTCValue function (amongst others) are not available to Delpih. Is this correct, and if so, when will it be available.

I intended to use the GFL SDK mainly for updating IPTC-information
Yes, i have not updated the delphi wrapper. Don't when because i'm not expert with Delphi ;-)
Pierre.
Guest

Re: gflSetIPTCValue - Delphi

Post by Guest »

Yes, i have not updated the delphi wrapper. Don't when because i'm not expert with Delphi ;-)
oh - could there be anyone else here at the forum that can do this, or that have already done so?
User avatar
Eric__38
Posts: 8
Joined: Tue Mar 08, 2005 12:28 pm
Location: amiens

can this help U ?

Post by Eric__38 »

hi, i'm a Delphi programmer too.

try to update the libgfl.pas like this :

1/add in interface the lines (AFTER DECLARATION OF PGFL_IPTC_DATA) :

Code: Select all

function gflSetIPTCValue(iptc_data: PGFL_IPTC_DATA; id: GFL_UINT32; const filename: PChar): GFL_ERROR; stdcall;
function gflNewIPTC: PGFL_IPTC_DATA; stdcall; 
2/add in IMPLEMENTATION (AFTER COMMENT '// functions in LibGflxxx.dll') the lines :

Code: Select all

function gflSetIPTCValue; external GflDLL;
function gflNewIPTC: PGFL_IPTC_DATA; external GflDLL; 
sample of code :

Code: Select all

procedure TForm1.Button1Click(Sender: TObject);
var iptc_data: PGFL_IPTC_DATA;
begin
  iptc_data := gflNewIPTC;
  ///fill iptc_data
  gflSetIPTCValue(iptc_data, 0, 'c:\0.jpg');
  gflFreeIPTC(iptc_data);
end; 
NOT TESTED but compilation is ok.

bye, bye
Eric
kurka666
Posts: 47
Joined: Thu Mar 10, 2005 11:41 am

Re: can this help U ?

Post by kurka666 »

Thank you very much. I'll give that a try tomorrow!

Let me know if you have any Delphi-samples to share! :-)