简体   繁体   English

G711Codec.h:44:1:构建错误:未知类型名称“类”; 您指的是 'Class' 吗?

[英]G711Codec.h:44:1: error build: unknown type name 'class'; did you mean 'Class'?

want to add some Camera SDK in my swift project.. but cant solve this error..想在我的 swift 项目中添加一些 Camera SDK.. 但无法解决此错误..

libAndHeaders/MediaPlayer/G711Codec.h:42:1: error build: unknown type name 'class'; libAndHeaders/MediaPlayer/G711Codec.h:42:1: 构建错误:未知类型名称“类”; did you mean 'Class'?您指的是 'Class' 吗?

maybe this is cpp header file or some other file.也许这是 cpp header 文件或其他文件。 when i include this in my Objectice-c header file then it gives me this err..当我将它包含在我的 Objectice-c header 文件中时,它给了我这个错误..

/*
    G711解码库
*/

#ifndef _G711_CODEC_H_
#define _G711_CODEC_H_



#define word16 short
#define word32 int

#define Word16 short
#define Word32 int

#define HI_VOICE_MAX_FRAME_SIZE       (480+1)    /* dont change it */

#define BIAS        (0x84)      /* Bias for linear code. */
#define CLIP         8159

#define SIGN_BIT    (0x80)      /* Sign bit for a A-law byte. */
#define QUANT_MASK  (0xf)       /* Quantization field mask. */
#define NSEGS       (8)     /* Number of A-law segments. */
#define SEG_SHIFT   (4)     /* Left shift for segment number. */
#define SEG_MASK    (0x70)      /* Segment field mask. */

static int seg_aend[8] = {0x1F, 0x3F, 0x7F, 0xFF,
    0x1FF, 0x3FF, 0x7FF, 0xFFF};
static int seg_uend[8] = {0x3F, 0x7F, 0xFF, 0x1FF,
    0x3FF, 0x7FF, 0xFFF, 0x1FFF};

/* HISI_VOICE codec type */

/* Real-time transport protocol(RTP) */
#define G711_A                        0x01  /* 64kbps G.711 A, see RFC3551.txt  4.5.14 PCMA */
#define G711_U                        0x02  /* 64kbps G.711 U, see RFC3551.txt  4.5.14 PCMU */
#define G711_ORG_A                    0x41  /* original version 64kbps G.711 A */
#define G711_ORG_U                    0x42  /* original version 64kbps G.711 U */

typedef int (*G711_Decoder)(int sample);

class G711Codec 
{

check this screenshot检查这个截图Xcode 截图

Yes, it´sa c++ header. You can mix obj-c and c++ if you need to (such source files need to have.mm extension, so that the compiler recognizes them), but probably you can choose another (obj-c) framework for what you need.是的,它是 c++ header。如果需要,您可以混合使用 obj-c 和 c++(此类源文件需要具有 .mm 扩展名,以便编译器识别它们),但您可能可以选择另一个 (obj-c)您需要的框架。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 未知类型名称“类”; 您指的是 'Class' 吗? - Unknown type name 'class'; did you mean 'Class'? 未知的类型名称'class';你的意思是'上课'吗? AurioTouch - Unknown type name 'class'; did you mean 'Class'? AurioTouch 未知类型名称“类”; 你是说班级? CCApplicationProtocol.h,CCApplication.h和预期的';'上的错误 在顶级声明器错误之后 - Unknown Type name 'class'; did you mean Class'? ERROR on CCApplicationProtocol.h, CCApplication.h and Expected ';' after top level declarator ERROR Xcode:C ++错误:未知类型名称“类”是否表示“类” - Xcode: C++ error: unknown type name 'class' did you mean 'Class' typedef类:未知类型名称“ MyType”; 您是说“ MyType_t”吗? - typedef class: Unknown type name 'MyType'; did you mean 'MyType_t'? 命名空间和模板 class 方法的向量声明(“向量”没有命名类型;您的意思是“错误”吗?) - namespace and template class vector declaration of methods('Vector' does not name a type; did you mean 'perror'?) 未知类型名称“类” - unknown type name 'class' 未知的类型名称类 - Unknown type name class 编译错误:'PCM' 没有命名类型; 您指的是“PC0”吗? - Compilation error: 'PCM' does not name a type; did you mean 'PC0'? 错误:未知类型名称“类” NDK CDT JNI - error: unknown type name 'class' NDK CDT JNI
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM