반응형
	int imageWidth = 3000;
	int imageHiehgt = 3000;
	int fileSize = imageWidth * imageHiehgt * sizeof(USHORT);

	USHORT* pixelData = new USHORT[imageWidth * imageHiehgt];
	memset(pixelData, 0, fileSize);

	CString strFilePath;
	strFilePath.Format("Test.raw");

	FILE* pFile;
	fopen_s(&pFile, strFilePath, "wb");
	fwrite(pixelData, 1, fileSize, pFile);
	fclose(pFile);
반응형

+ Recent posts