IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Sep 17, 2009, 2:26:32 PM (17 years ago)
Author:
eugene
Message:

change radius for extended sources to use footprint; clean up some of the visualizations; plug some leaks

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/20090715/psphot/src/psphotPetrosianVisual.c

    r25275 r25433  
    1919
    2020static int kapa = -1;
     21static int kapa2 = -1;
    2122
    2223// if no valid data is supplied (NULL or n <- 0), leave limits as they were
     
    5354
    5455    // return true;
    55     if (!pmVisualIsVisual()) return true;
    56 
    57     if (kapa == -1) {
    58         kapa = KapaOpenNamedSocket ("kapa", "psphot:plots");
    59         if (kapa == -1) {
     56    // if (!pmVisualIsVisual()) return true;
     57
     58    if (kapa2 == -1) {
     59        kapa2 = KapaOpenNamedSocket ("kapa", "psphot:plots");
     60        if (kapa2 == -1) {
    6061            fprintf (stderr, "failure to open kapa; visual mode disabled\n");
    6162            pmVisualSetVisual(false);
     
    6465    }
    6566
    66     KapaClearPlots (kapa);
     67    KapaClearPlots (kapa2);
    6768    KapaInitGraph (&graphdata);
    68     KapaSetFont (kapa, "courier", 14);
     69    KapaSetFont (kapa2, "courier", 14);
    6970
    7071    pmVisualLimitsFromVectors (&graphdata, radius, flux);
    71     KapaSetLimits (kapa, &graphdata);
    72 
    73     KapaBox (kapa, &graphdata);
    74     KapaSendLabel (kapa, "radius", KAPA_LABEL_XM);
    75     KapaSendLabel (kapa, "flux", KAPA_LABEL_YM);
    76 
    77     graphdata.color = KapaColorByName ("black");
    78     graphdata.style = 2;
    79     graphdata.ptype = 0;
    80     graphdata.size = 1.0;
    81     KapaPrepPlot (kapa, radius->n, &graphdata);
    82     KapaPlotVector (kapa, radius->n, radius->data.F32, "x");
    83     KapaPlotVector (kapa, radius->n, flux->data.F32, "y");
     72    KapaSetLimits (kapa2, &graphdata);
     73
     74    KapaBox (kapa2, &graphdata);
     75    KapaSendLabel (kapa2, "radius", KAPA_LABEL_XM);
     76    KapaSendLabel (kapa2, "flux", KAPA_LABEL_YM);
     77
     78    graphdata.color = KapaColorByName ("black");
     79    graphdata.style = 2;
     80    graphdata.ptype = 0;
     81    graphdata.size = 1.0;
     82    KapaPrepPlot (kapa2, radius->n, &graphdata);
     83    KapaPlotVector (kapa2, radius->n, radius->data.F32, "x");
     84    KapaPlotVector (kapa2, radius->n, flux->data.F32, "y");
    8485
    8586    // pause and wait for user input:
Note: See TracChangeset for help on using the changeset viewer.