Spacecraft Control Framework 1.0
Spacecraft Control Library
|
#include <sc_pinhole_camera.h>
Public Member Functions | |
PinholeCamera (void) | |
Constructor. | |
void | Initialize (double f, double wX, double wY, double gain) |
Initialize the camera physical parameters. More... | |
void | InitializeNoise (double sigmaXY, double sigmaI, double sigmaFS, int fSAtEnd) |
Initialize the camera noise model. More... | |
ml_matrix | Update (ml_matrix u, ml_matrix intensity, ml_matrix bUToCamera) |
Update the camera measurement from unit vectors. More... | |
ml_matrix | GetPixelOutput (void) |
Get the pixel intensity output, (1,m). More... | |
ml_matrix | GetStars (void) |
Get the star matrix output, (1,m). More... | |
ml_matrix | UpdateFromPosition (ml_matrix rT, ml_matrix r, ml_matrix intensity, ml_matrix q_eci_to_body, ml_matrix q_body_to_camera) |
Update the camera measurement from unit vectors. More... | |
Pinhole camera model. Explicitly models star camera measurements with position and intensity noise parameters
as well as false stars.
void PinholeCamera::Initialize | ( | double | f, |
double | wX, | ||
double | wY, | ||
double | gain | ||
) |
Initialize the camera physical parameters.
The units of f, wX, and wY should be consistent, i.e. mm or pixels.
f | Scaled focal length |
wX | Width of sensing element in X |
wY | Width of sensing element in Y |
gain | Camera gain |
void PinholeCamera::InitializeNoise | ( | double | sigmaXY, |
double | sigmaI, | ||
double | sigmaFS, | ||
int | fSAtEnd | ||
) |
Initialize the camera noise model.
sigmaXY | Position noise 1 sigma |
sigmaI | Intensity noise 1 sigma |
sigmaFS | False star noise 1 sigmas |
fSAtEnd | Flag, 1 if false stars are at the end of the measurements |
ml_matrix PinholeCamera::Update | ( | ml_matrix | u, |
ml_matrix | intensity, | ||
ml_matrix | bUToCamera | ||
) |
Update the camera measurement from unit vectors.
Keeps only those vectors within the imaging chip limits. Applies the camera gain to get the measured intensity. Noise is not yet modeled. See also u_to_pix.
u | Star unit vectors (3,n) |
intensity | Star intensity (1,n) |
bUToCamera | Rotation to imager frame (3,3) |
References u_to_pix().
Referenced by UpdateFromPosition().
ml_matrix PinholeCamera::GetPixelOutput | ( | void | ) |
Get the pixel intensity output, (1,m).
ml_matrix PinholeCamera::GetStars | ( | void | ) |
Get the star matrix output, (1,m).
This is the index of the stars seen from the unit vectors passed to Update().
ml_matrix PinholeCamera::UpdateFromPosition | ( | ml_matrix | rT, |
ml_matrix | r, | ||
ml_matrix | intensity, | ||
ml_matrix | q_eci_to_body, | ||
ml_matrix | q_body_to_camera | ||
) |
Update the camera measurement from unit vectors.
Keeps only those vectors within the imaging chip limits. Applies the camera gain to get the measured intensity. Noise is not yet modeled. See also u_to_pix.
r | Position of camera in ECI |
rT | Position of target in ECI |
intensity | Target illumination |
q_eci_to_body | Quaternion from eci to body |
q_body_to_camera | Quaternion from body to camera |
References Update().