aboutsummaryrefslogtreecommitdiff
path: root/src/detector.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2009-11-13 12:10:12 +0100
committerThomas White <taw@physics.org>2009-11-13 12:10:12 +0100
commitef6a971cf432321ceb057b8c355c8e6814d5aff6 (patch)
tree1d8d7373a1b7c1591cf28fcf61230122e19c1ca4 /src/detector.c
parent857cc8c991a5ee4e717d01822da271ae34f5adaa (diff)
Work in progress on photon correctness
Diffstat (limited to 'src/detector.c')
-rw-r--r--src/detector.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/detector.c b/src/detector.c
index ebcbb814..9e4e5649 100644
--- a/src/detector.c
+++ b/src/detector.c
@@ -29,11 +29,13 @@ void record_image(struct image *image)
uint16_t counts;
double val;
double intensity;
+ double phac;
val = image->sfacs[x + image->width*y];
+ phac = image->phactors[x + image->width*y];
intensity = pow(val, 2.0);
- counts = intensity*16;
+ counts = intensity * phac;
image->data[x + image->width*y] = counts;