L3DT documentation
Large 3D terrain generator

zfunc_Load

Description

Load a Zeolite extension function from a plugin.

Files

Declaration Zeolite.h
Implementation Zeolite.cpp

Function prototype

TYPE zfunc_Load(const char* lpFnName, const char* lpExportName, long rvalVarID, ZLIST hArgList);

Arguments

Name Type Comment
lpFnName const char* A handle to a C-style string containing the name of the function as is to appear in the Zeolite function list. Use the '.' (dot) character to delimit namespaces.
lpFnName const char* A handle to a C-style string containing the name of the function as it is defined in the plugin source code.
rvalVarID long The variable type ID of the return variable when the function is called. May be VarID_void if no var is returned.
hArgListPrototype ZLIST A handle to the prototype of the argument list for the function. If null, no arguments are expected.

Return value

A null handle if an error occurred, and a valid (non-null) handle to the function otherwise.

Comments

zeoexport

For zfunc_Load to succeed, the function in the plugin must be declared using the zeoexport keyword, which disables name mangling and enforces C-style name decoration. Below is an example of a 'correct' function definition:

zeoexport bool __stdcall MyFunctionName(ZVAR hRval, ZVAR hArgList) {
 
  // do your stuff here...
 
  return true;
}
 
zeolite/functions/zfunc_load.txt · Last modified: 2017/08/31 07:35 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki