如上所述,此时 android_npapi.h 提供了上述类型的多个错误:
struct ANPInterface {
uint32_t inSize; // size (in bytes) of this struct
};
enum ANPLogTypes {
kError_ANPLogType = 0, // error
kWarning_ANPLogType = 1, // warning
kDebug_ANPLogType = 2 // debug only (informational)
};
typedef int32_t ANPLogType;
struct ANPLogInterfaceV0 : ANPInterface {
/** dumps printf messages to the log file
e.g. interface->log(instance, kWarning_ANPLogType, "value is %d", value);
*/
void (*log)(ANPLogType, const char format[], ...);
};
struct ANPBitmapInterfaceV0 : ANPInterface {
/** Returns true if the specified bitmap format is supported, and if packing
is non-null, sets it to the packing info for that format.
*/
bool (*getPixelPacking)(ANPBitmapFormat, ANPPixelPacking* packing);
};
从“struct ANPLogInterfaceV0 : ANPInterface”开始,每个包含 ANPInterface 继承的结构定义都会出现上述错误。
有关上述头文件的更多信息:android_npapi.h