From cb6389ae61e8f7e279ea16f8ab1a94969d6c0dc9 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Fri, 28 Apr 2017 17:15:13 +0200 Subject: Skeleton image file API --- libcrystfel/src/image.h | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) (limited to 'libcrystfel/src/image.h') diff --git a/libcrystfel/src/image.h b/libcrystfel/src/image.h index 2ed7140f..f310a09b 100644 --- a/libcrystfel/src/image.h +++ b/libcrystfel/src/image.h @@ -123,7 +123,7 @@ struct beam_params * struct detector *det; * struct beam_params *beam; * char *filename; - * const struct copy_hdf5_field *copyme; + * const struct imagefile_field_list *copyme; * * int id; * @@ -155,8 +155,8 @@ struct beam_params * returned by the low-level indexing system. n_crystals * is the number of crystals which were found in the image. * - * copyme represents a list of HDF5 fields to copy - * to the output stream. + * copyme represents a list of fields in the image + * file (e.g. HDF5 fields or CBF headers) to copy to the output stream. **/ struct image; @@ -174,7 +174,7 @@ struct image { struct beam_params *beam; /* The nominal beam parameters */ char *filename; struct event *event; - const struct copy_hdf5_field *copyme; + const struct imagefile_field_list *copyme; struct stuff_from_stream *stuff_from_stream; double avg_clen; /* Average camera length extracted @@ -242,10 +242,17 @@ extern int imagefile_read(struct imagefile *imfile, struct image *image, struct event *event); extern struct hdfile *imagefile_get_hdfile(struct imagefile *imfile); extern void imagefile_copy_fields(struct imagefile *imfile, - struct copy_hdf5_file *copyme, FILE *fh, - struct event *ev); + const struct imagefile_field_list *copyme, + FILE *fh, struct event *ev); extern void imagefile_close(struct imagefile *imfile); +/* Field lists */ +extern struct imagefile_field_list *new_imagefile_field_list(void); +extern void free_imagefile_field_list(struct imagefile_field_list *f); + +extern void add_imagefile_field(struct imagefile_field_list *copyme, + const char *name); + #ifdef __cplusplus } #endif -- cgit v1.2.3