diff options
author | Thomas White <taw@physics.org> | 2022-05-03 15:28:46 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2022-06-02 12:15:38 +0200 |
commit | 992e25b007f8a418fd7860cc34a441932cdf023c (patch) | |
tree | b949c905232ece7bbce237eacde6b4834d4a08e4 /libcrystfel | |
parent | 7cae8ed0e420173b17aec11329411d4284de32cd (diff) |
indexamajig: Track metadata (e.g. for ASAP::O)
Diffstat (limited to 'libcrystfel')
-rw-r--r-- | libcrystfel/src/image.c | 4 | ||||
-rw-r--r-- | libcrystfel/src/image.h | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/libcrystfel/src/image.c b/libcrystfel/src/image.c index 1bad7d00..10c05525 100644 --- a/libcrystfel/src/image.c +++ b/libcrystfel/src/image.c @@ -1385,6 +1385,7 @@ struct image *image_read(const DataTemplate *dtempl, struct image *image_read_data_block(const DataTemplate *dtempl, void *data_block, size_t data_block_size, + char *meta_data, DataSourceType type, int serial, int no_image_data, @@ -1407,6 +1408,7 @@ struct image *image_read_data_block(const DataTemplate *dtempl, image->ev = NULL; image->data_block = data_block; image->data_block_size = data_block_size; + image->meta_data = meta_data; image->data_source_type = type; @@ -1431,6 +1433,7 @@ void image_free(struct image *image) free(image->filename); free(image->ev); free(image->data_block); + free(image->meta_data); if ( image->detgeom != NULL ) { np = image->detgeom->n_panels; @@ -1476,6 +1479,7 @@ struct image *image_new() image->ev = NULL; image->data_block = NULL; image->data_block_size = 0; + image->meta_data = NULL; image->data_source_type = DATA_SOURCE_TYPE_UNKNOWN; image->n_cached_headers = 0; diff --git a/libcrystfel/src/image.h b/libcrystfel/src/image.h index 3746e115..6c7e2a50 100644 --- a/libcrystfel/src/image.h +++ b/libcrystfel/src/image.h @@ -148,6 +148,7 @@ struct image * filenename/ev OR this should be filled in, but not both */ void *data_block; size_t data_block_size; + char *meta_data; /** A list of metadata read from the stream */ struct header_cache_entry *header_cache[HEADER_CACHE_SIZE]; @@ -225,6 +226,7 @@ extern struct image *image_create_for_simulation(const DataTemplate *dtempl); extern struct image *image_read_data_block(const DataTemplate *dtempl, void *data_block, size_t data_block_size, + char *meta_data, DataSourceType type, int serial, int no_image_data, |