diff options
author | Thomas White <taw@physics.org> | 2010-02-04 19:04:20 +0100 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2010-02-04 19:04:20 +0100 |
commit | a162a01f988a86f38d10a1b507d524637670566e (patch) | |
tree | 401f12e5878d8ca150b51bca5835cae627eabc6e /src/pattern_sim.c | |
parent | c85a8a308ec7ab50545255530da6a31b841be3ed (diff) |
Improved framework for detector geometry
Diffstat (limited to 'src/pattern_sim.c')
-rw-r--r-- | src/pattern_sim.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/pattern_sim.c b/src/pattern_sim.c index 7a27ceb6..d3056643 100644 --- a/src/pattern_sim.c +++ b/src/pattern_sim.c @@ -220,6 +220,24 @@ int main(int argc, char *argv[]) image.lambda = ph_en_to_lambda(eV_to_J(2.0e3)); /* Wavelength */ image.molecule = load_molecule(); + /* Set up detector configuration */ + image.det.n_panels = 2; + image.det.panels = malloc(2*sizeof(struct panel)); + /* Upper panel */ + image.det.panels[0].min_x = 0; + image.det.panels[0].max_x = 1023; + image.det.panels[0].min_y = 512; + image.det.panels[0].max_y = 1023; + image.det.panels[0].cx = 491.9; + image.det.panels[0].cy = 440.7; + /* Lower panel */ + image.det.panels[1].min_x = 0; + image.det.panels[1].max_x = 1023; + image.det.panels[1].min_y = 0; + image.det.panels[1].max_y = 511; + image.det.panels[1].cx = 492.0; + image.det.panels[1].cy = 779.7; + /* Splurge a few useful numbers */ STATUS("Wavelength is %f nm\n", image.lambda/1.0e-9); |