Skip to content
Snippets Groups Projects
Commit 1cf60c98 authored by Vinson Lee's avatar Vinson Lee
Browse files

progs/samples: Byte swap individual members of struct _rawImageRec.

parent bc0509bb
No related branches found
No related tags found
No related merge requests found
......@@ -93,7 +93,12 @@ static ImageRec *ImageOpen(char *fileName)
fread(image, 1, 12, image->file);
if (swapFlag) {
ConvertShort(&image->imagic, 6);
ConvertShort(&image->imagic, 1);
ConvertShort(&image->type, 1);
ConvertShort(&image->dim, 1);
ConvertShort(&image->xsize, 1);
ConvertShort(&image->ysize, 1);
ConvertShort(&image->zsize, 1);
}
image->tmp = (unsigned char *)malloc(image->xsize*256);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment