next up previous
Next: new_description() Up: Brain Volume I/O Handling Previous: delete_description()

delete_lhs_description()  

Remove a specific header description entry matching key



Synopsis


int 
delete_lhs_description( header *hdr, char *lhs)


Description
Remove the description entry with the key string lhs.

Usage

This piece of code removes info about min and max values in the header (this data is very often incorrect (!!)) without reading in the entire data volume.

Note: The program does not work on compressed files.

  char buf[2048];
  header *hdr;
  FILE *f;
  int ofs;
  hdr = new_header();
  read_header("myvolume.vol", hdr);
  delete_lhs_description(hdr, "min");
  delete_lhs_description(hdr, "max");
  open_write("myvolume.vol", hdr, &f, &ofs, PRESERVE);
  close_file(hdr, f);
  free_header(hdr);

Revision


1.0  29/10-96   Ulrik Kjems


Program listing






Ulrik Kjems
6/3/1998