如上所述,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
答案 0 :(得分:1)
您是否正在尝试编译包含C或C ++的代码?该标头使用结构继承,这意味着它需要编译为C ++。