Top | ![]() |
![]() |
![]() |
![]() |
void | imagefile_close () |
void | imagefile_copy_fields () |
struct hdfile * | imagefile_get_hdfile () |
enum imagefile_type | imagefile_get_type () |
struct imagefile * | imagefile_open () |
int | imagefile_read () |
int | imagefile_read_simple () |
signed int | is_cbf_file () |
struct imagefile_field_list * | new_imagefile_field_list () |
void | add_imagefile_field () |
void | free_imagefile_field_list () |
void | image_add_feature () |
struct imagefeature * | image_feature_closest () |
Reflection * | image_reflection_closest () |
int | image_feature_count () |
void | image_feature_list_free () |
ImageFeatureList * | image_feature_list_new () |
struct imagefeature * | image_get_feature () |
void | image_add_crystal () |
void | image_remove_feature () |
void | free_all_crystals () |
int | remove_flagged_crystals () |
struct | image |
struct | beam_params |
struct | imagefeature |
typedef | ImageFeatureList |
enum | SpectrumType |
struct | sample |
struct | imagefile |
struct | imagefile_field_list |
The image structure represents an image, usually one frame from a large series of diffraction patterns, which might be from the same or different crystals.
void imagefile_copy_fields (struct imagefile *f
,const struct imagefile_field_list *copyme
,FILE *fh
,struct event *ev
);
int imagefile_read (struct imagefile *f
,struct image *image
,struct event *event
);
void add_imagefile_field (struct imagefile_field_list *copyme
,const char *name
);
void image_add_feature (ImageFeatureList *flist
,double x
,double y
,struct panel *p
,struct image *parent
,double intensity
,const char *name
);
struct imagefeature * image_feature_closest (ImageFeatureList *flist
,double fs
,double ss
,struct panel *p
,double *d
,int *idx
);
Reflection * image_reflection_closest (RefList *rlist
,double fs
,double ss
,struct panel *p
,struct detector *det
,double *d
);
struct image { float **dp; /* Data in panel */ int **bad; /* Bad pixels by panel */ float **sat; /* Per-pixel saturation values */ Crystal **crystals; int n_crystals; IndexingMethod indexed_by; struct detector *det; struct beam_params *beam; /* The nominal beam parameters */ char *filename; struct event *event; const struct imagefile_field_list *copyme; struct stuff_from_stream *stuff_from_stream; double avg_clen; /* Average camera length extracted * from stuff_from_stream */ int id; /* ID number of the thread * handling this image */ int serial; /* Monotonically ascending serial * number for 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 */ double bw; /* FWHM bandwidth as a fraction */ /* Detected peaks */ long long num_peaks; long long num_saturated_peaks; ImageFeatureList *features; };
The field data
contains the raw image data, if it
is currently available. The data might be available throughout the
processing of an experimental pattern, but it might not be available when
simulating, scaling or merging patterns.
crystals
is an array of Crystal
directly
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 fields in the image
file (e.g. HDF5 fields or CBF headers) to copy to the output stream.
The image data, by panel |
||
The bad pixel mask, array by panel |
||
The per-pixel saturation mask, array by panel |
||
Crystal ** |
Array of crystals in the image |
|
The number of crystals in the image |
||
IndexingMethod |
Indexing method which indexed this pattern |
|
struct detector * |
Detector structure |
|
struct beam_params * |
Beam parameters structure |
|
Filename for the image file |
||
struct event * |
Event ID for the image |
|
const struct imagefile_field_list * |
Fields to copy from the image file to the stream |
|
struct stuff_from_stream * |
Items read back from the stream |
|
Mean of camera length values for all panels |
||
ID number of the thread handling this image |
||
Serial number for this image |
||
struct sample * |
Spectrum information |
|
Number of spectrum samples |
||
SIze of spectrum array |
||
Wavelength |
||
Divergence |
||
Bandwidth |
||
The number of peaks |
||
The number of saturated peaks |
||
ImageFeatureList * |
The peaks found in the image |
struct beam_params { double photon_energy; char *photon_energy_from; double photon_energy_scale; };
struct imagefeature { struct image *parent; double fs; double ss; struct panel *p; double intensity; /* Reciprocal space coordinates (m^-1 of course) of this feature */ double rx; double ry; double rz; const char *name; };
Represents a peak in an image.
Note carefully that the fs
and ss
coordinates are the distances, measured
in pixels, from the corner of the panel. They are NOT pixel indices.
If the peak is in the middle of the first pixel, its coordinates would be
0.5,0.5.
A SpectrumType
represents a type of X-ray energy spectrum to use for
generating simulated data.