Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7814255
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T05:08:36+00:00 2026-06-02T05:08:36+00:00

This is one function in the C++ header file I want to call from

  • 0

This is one function in the C++ header file I want to call from Delphi:

 * @param hConnection Handle to the connection to FM.
 * @param pOperation See description of ABS_OPERATION.
 * @param dwTemplateCount Count of templates in the pTemplateArray.
 * @param pTemplateArray Pointer to the array of pointers to templates.
 * @param pResult Pointer to memory location, where result of the comparing 
 */
ABS_STATUS BSAPI ABSVerify(
    IN ABS_CONNECTION hConnection,
    IN ABS_OPERATION* pOperation,
    IN ABS_DWORD dwTemplateCount,
    IN ABS_BIR** pTemplateArray,
    OUT ABS_LONG* pResult,
    IN ABS_DWORD dwFlags
);

— Def

/** 
 * The header of the BIR. This type is equivalent to BioAPI's structure 
 * BioAPI_BIR_HEADER. 
 */
typedef struct abs_bir_header {
  ABS_DWORD Length;     ///< Length of Header + Opaque Data
  ABS_BYTE HeaderVersion;   ///< HeaderVersion = 1
  ABS_BYTE Type;    ///< Type = 4 (BioAPI_BIR_DATA_TYPE_PROCESSED)
  ABS_WORD FormatOwner;     ///< FormatOwner = 0x12 (STMicroelectronics)
  ABS_WORD FormatID;    ///< FormatID = 0
  ABS_CHAR Quality;     ///< Quality = -2 (BioAPI_QUALITY is not supported)
  ABS_BYTE Purpose;     ///< Purpose (BioAPI_PURPOSE_xxxx, ABS_PURPOSE_xxxx).
  ABS_DWORD FactorsMask;    ///< FactorsMask = 0x08 (BioAPI_FACTOR_FINGERPRINT)
} ABS_BIR_HEADER;

/** 
 * A container for biometric data. 
 */
typedef struct abs_bir {
  ABS_BIR_HEADER Header;    ///< BIR header
  ABS_BYTE Data[ABS_VARLEN];    ///< The data composing the fingerprint template.
} ABS_BIR;

  struct abs_operation;
typedef struct abs_operation ABS_OPERATION;  /* forward declaration */

/** 
 * A type of the callback function that an application can supply to 
 * the BSAPI to enable itself to display GUI state information to user. 
 * 
 * @param pOperation Pointer to ABS_OPERATION structure used when calling the interactive operation.
 * @param dwMsgID ID of message. See description of ABS_MSG_xxxx constants.
 * @param pMsgData Pointer to data with additional information related with 
 * the message. 
 */
typedef void (BSAPI  *ABS_CALLBACK) ( const ABS_OPERATION*, ABS_DWORD, void*);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T05:08:39+00:00Added an answer on June 2, 2026 at 5:08 am

    It’s probably something like this:

    function ABSVerify(
        hConnection: Integer;
        Operation: PABS_OPERATION;
        dwTemplateCount: DWORD;
        pTemplateArray: PPABS_BIR;
        var pResult: Integer;
        dwFlags: DWORD
    ): Integer; stdcall; external 'bsapi.dll';
    

    The things that are a little hazy are ABS_OPERATION. Because that is an IN parameter and yet it is passed as a pointer to ABS_OPERATION, I imagine it is a struct. You will need to declare a matching Delphi record and a pointer type for it. Maybe like this:

    type
      ABS_OPERATION = record
        field1: Integer;
        field2: Integer;
        //etc.
      end;
      PABS_OPERATION = ^ABS_OPERATION;
    

    The other parameter that requires care is pTemplateArray:

    pTemplateArray Pointer to the array of pointers to templates.

    This is an array of pointers. Arrays in C are passed as pointers to the first element. So that explains the type, ABS_BIR**, pointer to first element, which is itself a pointer to an ABS_BIR.

    type
      ABS_BIR = ... //whatever it is
      PABS_BIR = ^ABS_BIR;
      PPABS_BIR = ^PABS_BIR;
    

    You might call the function something like this:

    var
      TemplateArray: array of PABS_BIR;
    ...
      SetLength(TemplateArray, dwTemplateCount);
      // populate TemplateArray
      returnval := ABSVerify(..., dwTemplateCount, @TemplateArray[0], ...);
    

    I see now that you have added the struct definitions in an edit. I’ll leave my made up structs here because you ought to be able to convert these structs yourself.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have one header file which uses a virtual function. This is declared and
I have this function that switches the HTML contents from one element on a
This function is global and is defined in the header file ( temporarily I
I have a ComboBox with a label function like this one: private function fieldLabelFunction(item:Object):String
I am writing this code that one function calls itself recursively. But I am
This one is quite obviously a function pointer : typedef int (* foobar) (int
Given a class with a member template function like this one: template <typename t>
So I am baffled by this one. I have a function that is responsible
I have been tearing my hair with this one for a while. index.php: $(document).ready(function(){
I can't find any solution to get this jquery events to work. $(window).one('click',function(){ console.log('hide

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.