C++代码翻译
请帮忙将下列C++代码翻译成delphi的,谢谢
void ReadFile( char* fileName, int* shapeIdArray)
{
int width;
int height;
char* attibutes;
unsigned short* elevations;
FILE* file;
file = fopen (ffileName, "rb");
_ASSERTE (file);
width = 256;
height = 256;
elevations = (unsigned short*) malloc (width * height * sizeof (unsigned short));
attibutes = (char*) malloc (width * width * sizeof (char));
fread (elevations, sizeof (unsigned short), width * height, file);
memset (attibutes, 1, width * height * sizeof (char));
if (shapeIdArray) {
for (int i = 0; i < width * height; i ++) {
attibutes[i] = char(shapeIdArray[0]);
}
}
}
...全文
相关推荐
cpp-Rust代码和资源的精选列表中文翻译
Rust 代码和资源的精选列表中文翻译
C++头文件代码翻译为C#的工具
系统各种设备,经常需要引用C++编译的DLL文件,这些类库无法直接通过IDE添加引用,只能DllImport静态导入.很多时候,需要自己翻译头文件,获取DLL中的函数信息.
C++ 面试题翻译电话号码实例代码
C++ 面试题翻译电话号码实例代码 例如: 输入:OneTwoThree 输出:123 输入:OneTwoDoubleTwo 输出:1222 输入:1Two2 输出:ERROR 输入:DoubleDoubleTwo 输出:ERROR 有空格,非法字符,两个Double相连,Double位于最后一个单词 都错误。 #include <iostream> #include <string> using namespace std; void process(string str) { //各字符串的下标即为其对应的阿拉伯数字 char *ch[]={"zero","on
Delphi_IOCP源码,从小猪的C++代码翻译过来的
Delphi,IOCP源码,从小猪的C++代码翻译过来的,本人也刚学网络方面,译得不好别骂哈。
安卓版的C++英汉翻译词典程序代码.zip
安卓版的C++英汉翻译词典程序代码.zip


Windows SDK/API
