Join The Works program to have access to the most current content, and to be able to ask questions and get answers from Revelation staff and the Revelation community

At 24 APR 2002 04:07:32PM Eduardo Murphy wrote:

I'm looking for advise concerning:

1) calling an external routine from an RBasic OI program;

2) how to get a routine that takes a GIF image as input and converts it to JPEG format, and can be called from the RBasic program where the GIF image is the content of a variable.

Eduardo Murphy


At 24 APR 2002 10:51PM [url=http://www.sprezzatura.com]The Sprezzatura Group[/url] wrote:

Eduardo,

1) calling an external routine from an RBasic OI program;

I assume from this you mean calling an exported function from a DLL? There's a chapter on this in the online help, but basically you perform the following steps:

1) Prototype the functions you wish to call from the DLL. This involves creating a record in SYSPROCS that contains the functions you wish to call along with the type of arguments it expects.

2) Run the DECLARE_FCNS() program that takes the prototype record you defined in stage 1 above and creates pointers to the the functions as object code records in SYSOBJ, thus allowing you to call them from Basic+ as you would any other program.

There's also a more in-depth look at this topic in the on-line Knowledge Base that can be found here.

2) how to get a routine that takes a GIF image as input and converts it to JPEG format, and can be called from the RBasic program where the GIF image is the content of a variable.

OpenInsight uses the functions contained in the ImageMan DLL (ImgMan32.dll) for manipulating image files, and using the techniques described above you can use these functions too. There are basic functions in there to open, read and write image files, as well as to display them.

However, two points to bear in mind:

1) You need to know what arguments to pass to the functions, so you'd need a copy of the ImageMan help file that describes them.

2) GIF files are NOT supported in OI32 for licensing reasons so the necessary GIF import (.DIL) and export (.DEL) libraries are not supplied. However, reading GIF files IS supported in OI16 so you could write a 16-bit executable in C/VB/Delphi etc to use the 16bit version of ImageMan (IMGMAN11.DLL) to read them in and then write them out as a JPeg. However, the Image *Export* libraries are NOT supplied with OI16 so you'd need to get your hands on them before you could go down this route too! :-S If you wish to discuss this further please drop us a line.

Regards

The Sprezzatura Group

World leaders in all things RevSoft

www.sprezzatura.com_zz.jpg

View this thread on the Works forum...

  • third_party_content/community/commentary/forums_works/fbfdaaba13b93c4188256ba5006e8d96.txt
  • Last modified: 2023/12/30 11:57
  • by 127.0.0.1