From 8e2f2f44f46c18f7bd621a2ef9a3d0aa813d76d9 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Mon, 20 Jan 2014 17:20:10 +0100 Subject: pattern_sim: Overhaul and add SASE spectrum simulation --- libcrystfel/src/image.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'libcrystfel/src/image.h') diff --git a/libcrystfel/src/image.h b/libcrystfel/src/image.h index a1ac75a3..0c189cad 100644 --- a/libcrystfel/src/image.h +++ b/libcrystfel/src/image.h @@ -44,6 +44,10 @@ #include "crystal.h" #include "index.h" +typedef enum { + SPECTRUM_TOPHAT, + SPECTRUM_SASE +} SpectrumType; /* Structure describing a feature in an image */ struct imagefeature { @@ -67,6 +71,13 @@ struct imagefeature { /* An opaque type representing a list of image features */ typedef struct _imagefeaturelist ImageFeatureList; +/* Structure describing a wavelength sample from a spectrum */ +struct sample +{ + double k; + double weight; +}; + /** * image: @@ -144,6 +155,10 @@ struct image { int id; /* ID number of the thread * handling this image */ + struct sample *spectrum; + int nsamples; /* Number of wavelengths */ + int spectrum_size; /* Size of "spectrum" */ + /* Per-shot radiation values */ double lambda; /* Wavelength in m */ double div; /* Divergence in radians */ -- cgit v1.2.3