参考下面
CString MulToWideString(char *szIn)
{
int unicodeLen = MultiByteToWideChar(CP_UTF8, 0, szIn, -1, NULL, 0)
WCHAR *pUnicode = new WCHAR[unicodeLen + 1]
memset(pUnicode,0,(unicodeLen+1)*sizeof(wchar_t))
MultiByteToWideChar(CP_UTF8,0,szIn,-1, pUnicode,unicodeLen)
CString str(pUnicode)
delete []pUnicode
return str
}
CString MulToWideString(const char *szIn)
{
int unicodeLen = MultiByteToWideChar(CP_UTF8, 0, szIn, -1, NULL, 0)
WCHAR *pUnicode = new WCHAR[unicodeLen + 1]
memset(pUnicode,0,(unicodeLen+1)*sizeof(wchar_t))
MultiByteToWideChar(CP_UTF8,0,szIn,-1, pUnicode,unicodeLen)
CString str(pUnicode)
delete []pUnicode
return str
}
UINT WideStringToMul(CString &strIn,char *pOut,int nCharLen)
{
if(pOut == NULL)
{
return 0
}
int nLen = WideCharToMultiByte(CP_ACP, 0, (LPCWSTR)strIn.GetBuffer(0),-1, NULL, 0, NULL, NULL)
nLen =min(nLen,nCharLen)
WideCharToMultiByte(CP_ACP, 0, (LPCWSTR)strIn.GetBuffer(0), -1, pOut,nLen, NULL, NULL)
if(nLen <nCharLen)
{
pOut[nLen] = 0x00
}
return nLen
}
Pr输出的XML导入DaVinci Resolve时,点击OK后,指定与Pr时间线上同名的源素材位置进行连接,Pr时间线上的素材与链接源素材的时间码、长春竖度、文件名等源数据一至方宽纤能连接成功扒巧大。欢迎分享,转载请注明来源:内存溢出
评论列表(0条)