#ifndef DETECTORSTRUCT_H #define DETECTORSTRUCT_H #include "fieldslice.h" #include "nearfield.h" #include using namespace std; struct sourcePoint { bsPoint f; ptype A; }; struct microscopeStruct { int padding; int ss; //field slice at the detector fieldslice Ufd; fieldslice Ud; bool scalarSim; //detector image scalarslice* D; //sample scalarslice* Di; //incident field image ptype objective[2]; //image position and orientation in world space rts::rtsQuad pos; vector focalPoints; microscopeStruct(); nearfieldStruct nf; void init(); void destroy(); //functions for dealing with extended sources void SimulateExtendedSource(); void LoadExtendedSource(std::string filename); void SimulateScattering(); void SimulateImaging(); void Simulate(); void setNearfield(); void setRes(int x_res, int y_res, int pad, int supersampling); void setPos(bsPoint pMin, bsPoint pMax, bsVector normal); void applyBandpass(); void getFarField(); void integrateDetector(); void clearDetector(); //compute detector measurements scalarslice getAbsorbance(); scalarslice getTransmittance(); scalarslice getIntensity(); }; #endif