Function Pointer TypesA function pointer is a pointer which points to a function. In WGAL, function pointers of various types are used for passing callbacks, which are invoked by the library. For instance, draw and update callback functions are automatically called every frame. Note that the signature of a referenced function must exactly match that of the type of referencing function pointer. The following table shows function pointer types used in WGAL and their signatures. | WGAL type definition | return type | parameters | remarks | | WGALUpdateProc | WGALVoid | WGALUInt32 frames | frames indicates the number of frames passed after last update | | WGALDrawProc | WGALVoid | none | | | WGALCommandProc | WGALBool | none | TRUE should be returned if the command has been processed; otherwise FALSE should be returned |
|