I was write a raw file liking this:
unsigned long FileSize = 0;//height * width * slices;
const Uint16* FileData = new Uint16(FileSize);
metaInfo->findAndGetUint16Array(DCM_PixelData, FileData, &FileSize);
//_strFileName a raw file name like xxx.raw
std::fstream myFileStream(_strFileName.c_str(), std::ios::binary | std::ios::out);
if (myFileStream.is_open())
{
myFileStream.write((char*)FileData, FileSize * sizeof(Uint16));
}
myFileStream.close();
delete FileData;
Now I want to read the raw data and rendering it . How should i do ? any suggistions.