c++ - How i can extract information from DICOM file ? -
i want write script extract header information of dicom file using c or c ++, don't want use external libraries dicomsdl... when open file bloc-notes see special characters , character string patient name .. if can me read file. yes, open file in binary though might contain sequences of characters. out deep it, consider writing following record of out file (i'm showing record c-struct): struct rec_tag { int id; char name[50]; }; now, suppose use structure create file, shown in following code: file1.c: /* compile as: gcc -ansi -pedantic -wall file.c -o file_test */ #include <stdio.h> #include <stdlib.h> #include <string.h> struct rec_tag { int id; char name[50]; }; int main(int argc, char** argv) { file* fp = null; struct rec_tag rec1; struct rec_tag rec2; rec1.id = 20; strcpy(rec1.name, "thurizas"); rec2.id = 345689; strcpy(rec2.name, &quo