Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove obsolete parameter SAOSAC_color_rays #70

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 17 additions & 36 deletions marx/libsrc/s-saosac.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,6 @@ static int File_Has_Time_Column;
static double Wgts_Scale_Factor = 1.0;
#endif

static int Use_Color_Rays = 0;

#if SCALE_SAOSAC_WEIGHTS
static int compute_weights_scale_factor (char *file, double *wp)
{
Expand Down Expand Up @@ -257,31 +255,24 @@ static int saosac_create_photons (Marx_Source_Type *st, Marx_Photon_Type *pt, /*
else
at->mirror_shell = 0;

if (Use_Color_Rays)
{
if (-1 == (*efun) (&st->spectrum, &at->energy))
return -1;
}
if (File_Has_Time_Column)
{
if (Start_Time == 0)
{
Start_Time = buf[8];
_marx_dither_set_ray_tstart (Start_Time);
}
this_time = buf[8] - Start_Time;
}
else
{
if (File_Has_Time_Column)
{
if (Start_Time == 0)
{
Start_Time = buf[8];
_marx_dither_set_ray_tstart (Start_Time);
}
this_time = buf[8] - Start_Time;
}
else
this_time += 1.0;

if (this_time < 0)
continue;

at->energy = buf[6];
at->arrival_time = this_time;
}
this_time += 1.0;

if (this_time < 0)
continue;

at->energy = buf[6];
at->arrival_time = this_time;


at++;
num_read++;
Expand Down Expand Up @@ -332,12 +323,6 @@ int marx_select_saosac_source (Marx_Source_Type *st, Param_File_Type *p, /*{{{*/
}
else Start_Time = 0;

#if 0
if (-1 == pf_get_boolean (p, "SAOSAC_Color_Rays", &Use_Color_Rays))
return -1;
#endif
Use_Color_Rays = 0; /* nolonger supported */

#if SCALE_SAOSAC_WEIGHTS
Wgts_Scale_Factor = 1.0;
if (-1 == pf_get_boolean (p, "SAOSAC_Scale_Wgts", &scale_wgts))
Expand All @@ -355,10 +340,6 @@ int marx_select_saosac_source (Marx_Source_Type *st, Param_File_Type *p, /*{{{*/

Saosac_Bin_Table = bt;

if (Use_Color_Rays)
{
return _marx_get_simple_specrum_parms (p, st, name);
}
st->spectrum.type = MARX_SAOSAC_SPECTRUM;

return 0;
Expand Down
1 change: 0 additions & 1 deletion marx/par/marx.par
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ UserSourceArgs,s,a,"pnts.dat",,,"user source parameter"
# This option allows SAOSAC FITS raytrace files to be used.
#
SAOSACFile,s,a,"saosac.fits",,,"marx input source/output ray filename"
SAOSAC_Color_Rays,b,a,no,,,"This option is no longer supported"
#
# SIMPUT Source parameters
#
Expand Down