本文整理汇总了C++中Encoder::Encode方法的典型用法代码示例。如果您正苦于以下问题:C++ Encoder::Encode方法的具体用法?C++ Encoder::Encode怎么用?C++ Encoder::Encode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Encoder
的用法示例。
在下文中一共展示了Encoder::Encode方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Convert
BOOL CDBConverter::Convert(CString path)
{
CFile fp,fOut,fModel;
CStdioFile fLog;
int c, d, FileType;
int Domain, Class, Type, CTNumber;
char szFile[512];
int DXL_Offset = 0, DXL_size = 0, DXL_Processing_Type = 0;
DWORD FileOffset,FileSize;
strcpy(KoreaObjFolder, path);
sprintf(szFile, "%sKoreaObj.hdr", KoreaObjFolder);
fp.Open(szFile, CFile::modeRead);
LoadHDR(fp);
fp.Close();
LoadCT();
DWORD LODSize;
DWORD TagCount;
char *NodeTreeData;
BRoot *Root;
BNodeType *TagList,*TagRoot;
void *LODBuffer;
Converter *cvt;
CString s,k;
CString DirName;
BYTE *Buffer;
Encoder *ecd;
DrawDisable=true;
DBConvert=false;
ReBoot=false;
Abort=false;
FragIt=false;
AssembleIt=false;
TagRoot=TagList=(BNodeType*)malloc(MAX_TAGS*sizeof(BNodeType));
LODBuffer=malloc(LOD_BUFFER_SIZE);
ObjectInstance *TestObj=new ObjectInstance(1);
m_ConvProgress.SetRange(0, hdr.nLOD);
//...
// Open KO.lod
sprintf(szFile, "%sKoreaObj.lod", KoreaObjFolder);
fp.Open(szFile, CFile::modeRead);
void *FileBuffer=malloc(16384*1024);
Restart:
// Open the Saving File
if(DBConvert){
m_ExitKey.EnableWindow(false);
m_GotoKey.EnableWindow(false);
m_NextKey.EnableWindow(false);
m_PrevKey.EnableWindow(false);
sprintf(szFile, "%s"OBJECTS_DATABASE_NAME, KoreaObjFolder);
DirName.Format("%s\\Models", KoreaObjFolder);
DirName+='\\';
if(!FragIt){
fOut.Open(szFile, CFile::modeCreate|CFile::modeWrite|CFile::typeBinary);
} else {
CFileFind File;
int OnList=File.FindFile(DirName);
while(OnList){
OnList=File.FindNextFile();
if(File.IsDirectory())goto ok;
}
File.Close();
char Buffer[128];
strcpy(Buffer,DirName);
_mkdir(Buffer);
}
ok: _asm nop
sprintf(szFile, "%sDXL.Log", KoreaObjFolder);
fLog.Open(szFile, CFile::modeCreate|CFile::modeWrite|CFile::typeText);
}
FileOffset=0;
FileSize=0;
c=0;
while(c < hdr.nLOD)
{
m_ConvProgress.SetPos(c);
TagList=TagRoot;
//...
// Get Domain, Class and File Type, if LOD has a CT record
// if no CT record, then Domain = Class = FileType = 0
FileType = LODUsedByCT((int) c, (int*) &Domain, (int*) &Class, (int*)&Type, (int*)&CTNumber);
//.........这里部分代码省略.........