Changeset 8376 for trunk/MagicSoft


Ignore:
Timestamp:
03/14/07 19:12:17 (18 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Cosy
Files:
34 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Cosy/Changelog

    r8184 r8376  
    11                                                                  -*-*- END -*-*-
     2
     3 2007/03/14 Thomas Bretz
     4
     5   * bend.cc, cosy.cc, starg.cc, testse.cc, base/MStarList.cc,
     6     base/MThread.cc, base/log.h, base/msgqueue.cc, candrv/nodedrv.cc,
     7     candrv/sdolist.cc, catalog/SlaPlanets.cc, catalog/Slalib.cc,
     8     catalog/StarCatalog.cc, gui/MGAccuracy.cc, gui/MGCoordinate.cc,
     9     gui/MGCoordinates.cc, gui/MGCosy.cc, gui/MGNumStars.cc,
     10     gui/MGSkyPosition.cc, main/MBending.cc, main/MStargHistograms.cc:
     11     - replaced obsolete .h by C++ headers
     12     - added namespace std
     13
     14   * base/MStarList.h:
     15     - fixed warnings about overwriting of Delete
     16
     17   * base/MStopwatch.h, gui/MGCoordinate.h, gui/MGCoordinates.h:
     18     - fixed warning about overwriting of Print()
     19
     20   * base/MTimeout.cc, candrv/nodedrv.cc, devdrv/macs.cc:
     21     - fixed default argument is declaration
     22
     23   * catalog/StarCatalog.cc, gui/MGAccuracy.cc:
     24     - fixed a type problem (int instead of double)
     25
     26   * gui/MGCoordinate.cc, gui/MGCosy.cc:
     27     - fixed a warning about double declaration
     28
     29
    230
    331 2006/11/01 Thomas Bretz
  • trunk/MagicSoft/Cosy/base/MStarList.cc

    r1810 r8376  
    11#include "MStarList.h"
    22
    3 #include <iostream.h>
     3#include <iostream>
     4
     5using namespace std;
    46
    57void MStarList::RemoveTwins(Double_t radius)
  • trunk/MagicSoft/Cosy/base/MStarList.h

    r1810 r8376  
    3131    }
    3232
    33     void Delete(Int_t i)    { delete fStars.RemoveAt(i); }
    34     void Delete(MStar *obj) { delete fStars.Remove(obj); }
     33    void Delete(Option_t *o="") { }
     34    void Delete(Int_t i)        { delete fStars.RemoveAt(i); }
     35    void Delete(MStar *obj)     { delete fStars.Remove(obj); }
    3536
    3637    Int_t GetMax() const { return fStars.GetLast()+1; }
  • trunk/MagicSoft/Cosy/base/MStopwatch.h

    r732 r8376  
    88public:
    99    void Print(Float_t i);
     10    void Print(Option_t *o="") const { }
    1011};
    1112
  • trunk/MagicSoft/Cosy/base/MThread.cc

    r2407 r8376  
    11#include <MThread.h>
    22
    3 #include <iostream.h>
     3#include <iostream>
    44
    55#include <pthread.h>
     
    88#undef DEBUG
    99//#define DEBUG
     10
     11using namespace std;
    1012
    1113// ----------------------------------------------------------------------
  • trunk/MagicSoft/Cosy/base/MTimeout.cc

    r2518 r8376  
    33#include <TSystem.h>
    44
    5 MTimeout::MTimeout(unsigned long ms=500) : fTimeout((ULong_t)gSystem->Now()+ms)
     5MTimeout::MTimeout(unsigned long ms) : fTimeout((ULong_t)gSystem->Now()+ms)
    66{
    77    // Use SetTime to change the timing
     
    1414}
    1515
    16 void MTimeout::Start(unsigned long ms=500)
     16void MTimeout::Start(unsigned long ms)
    1717{
    1818    fTimeout = (ULong_t)gSystem->Now()+ms;
  • trunk/MagicSoft/Cosy/base/coord.h

    r4076 r8376  
    33
    44#include <math.h>          // floor
    5 #include <fstream.h>
     5#include <iostream>
    66
    77#include "MAGIC.h"
     
    3737class XY
    3838{
    39     friend ifstream& operator>>(ifstream &in, XY &xy);
    40     friend ofstream& operator<<(ofstream &in, XY &xy);
     39    friend istream& operator>>(istream &in, XY &xy);
     40    friend ostream& operator<<(ostream &in, XY &xy);
    4141
    4242protected:
     
    7373};
    7474
    75 inline ifstream& operator>>(ifstream &in,  XY &xy) { in  >> xy.fX; in  >> xy.fY; return in; }
    76 inline ofstream& operator<<(ofstream &out, const XY &xy) { out << xy.X() << " " << xy.Y(); return out; }
     75inline std::istream& operator>>(std::istream &in,  XY &xy) { in  >> xy.fX; in  >> xy.fY; return in; }
     76inline std::ostream& operator<<(std::ostream &out, const XY &xy) { out << xy.X() << " " << xy.Y(); return out; }
    7777
    7878class AltAz : public XY
  • trunk/MagicSoft/Cosy/base/log.h

    r2384 r8376  
    22#define COSY_Log
    33
    4 #include <ostream.h>
     4#include <ostream>
    55
    66#ifndef MARS_MLog
  • trunk/MagicSoft/Cosy/base/msgqueue.cc

    r4076 r8376  
    11#include "msgqueue.h"
    22
    3 #include <iostream.h>
     3#include <iostream>
    44
    55#include <unistd.h>        // usleep
     
    77
    88#undef DEBUG
     9
     10using namespace std;
    911
    1012// --------------------------------------------------------------------------
  • trunk/MagicSoft/Cosy/bend.cc

    r1953 r8376  
    1 #include <iomanip.h>
    2 #include <iostream.h>
     1#include <iomanip>
     2#include <fstream>
    33
    44#include <MBending.h>
     5
     6using namespace std;
    57
    68/* ---------------------------------------------------------------------- */
  • trunk/MagicSoft/Cosy/candrv/nodedrv.cc

    r7313 r8376  
    4545#include "nodedrv.h"
    4646
    47 #include <iomanip.h>
    48 #include <iostream.h>
     47#include <iomanip>
     48#include <iostream>
    4949
    5050//#include <TTimer.h>
     
    5555
    5656ClassImp(NodeDrv);
     57
     58using namespace std;
    5759
    5860// --------------------------------------------------------------------------
     
    217219// In this case false is returned, otherwise true
    218220//
    219 bool NodeDrv::SendPDO1(BYTE_t m0=0, BYTE_t m1=0, BYTE_t m2=0, BYTE_t m3=0,
    220                        BYTE_t m4=0, BYTE_t m5=0, BYTE_t m6=0, BYTE_t m7=0)
     221bool NodeDrv::SendPDO1(BYTE_t m0, BYTE_t m1, BYTE_t m2, BYTE_t m3,
     222                       BYTE_t m4, BYTE_t m5, BYTE_t m6, BYTE_t m7)
    221223{
    222224    if (!fIsZombie)
     
    233235// In this case false is returned, otherwise true
    234236//
    235 bool NodeDrv::SendPDO2(BYTE_t m0=0, BYTE_t m1=0, BYTE_t m2=0, BYTE_t m3=0,
    236                        BYTE_t m4=0, BYTE_t m5=0, BYTE_t m6=0, BYTE_t m7=0)
     237bool NodeDrv::SendPDO2(BYTE_t m0, BYTE_t m1, BYTE_t m2, BYTE_t m3,
     238                       BYTE_t m4, BYTE_t m5, BYTE_t m6, BYTE_t m7)
    237239{
    238240    if (!fIsZombie)
     
    543545};
    544546
    545 void NodeDrv::StartGuarding(Bool_t real=kTRUE)
     547void NodeDrv::StartGuarding(Bool_t real)
    546548{
    547549    if (fGuard)
  • trunk/MagicSoft/Cosy/candrv/sdolist.cc

    r4076 r8376  
    11#include "sdolist.h"
    22
    3 #include <iostream.h>
     3#include <iostream>
    44
    55ClassImp(PendingSDO);
    66ClassImp(PendingSDOList);
     7
     8using namespace std;
    79
    810PendingSDOList::PendingSDOList()
  • trunk/MagicSoft/Cosy/catalog/SlaPlanets.cc

    r3897 r8376  
    11#include "SlaPlanets.h"
    22
    3 #include <iostream.h>
     3#include <iostream>
    44
    55#include "slalib.h"
    66
    77ClassImp(SlaPlanets);
     8
     9using namespace std;
    810
    911SlaPlanets::SlaPlanets(MObservatory::LocationName_t key) : Slalib(key), fDt(slaDt(2000.0)/60./60./24.)
  • trunk/MagicSoft/Cosy/catalog/Slalib.cc

    r4104 r8376  
    22
    33#include <time.h>
    4 #include <iostream.h>  // cout
     4#include <iostream>  // cout
    55
    66#include "coord.h"
     
    99
    1010ClassImp(Slalib);
     11
     12using namespace std;
    1113
    1214Slalib::Slalib(MObservatory::LocationName_t key) : MObservatory(key)
  • trunk/MagicSoft/Cosy/catalog/StarCatalog.cc

    r7787 r8376  
    11#include "StarCatalog.h"
    22
    3 #include <iomanip.h>   // cout
    4 #include <iostream.h>  // cout
     3#include <iomanip>   // cout
     4#include <iostream>  // cout
    55
    66#include <TSystem.h>
     
    1515
    1616ClassImp(StarCatalog);
     17
     18using namespace std;
    1719
    1820StarCatalog::StarCatalog(MObservatory::LocationName_t key) : SlaStars(key), fW(768), fH(576), fAstro(0), /*fSao(NULL), fSrt(NULL), fEntries(0),*/ fSinAngle(0), fCosAngle(1), fBox(768)
     
    136138    {
    137139        const int mag = (10 - (star->GetMag()>1 ? (int)star->GetMag() : 1))/2;
    138         Double_t color = 0xf0; //0x0f;       
     140        Int_t color = 0xf0; //0x0f;
    139141        // DrawStars flips the picture in X defaultwise now
    140142        DrawCircle(color, img, 768-(int)star->GetX(), (int)star->GetY(), mag);
     
    155157{
    156158    // For an apropriate unit conversion to pixels [pix/rad]
    157     const Double_t scale = TMath::RadToDeg()*sqrt(768*768 + 576*576)/(fAstro->GetRadiusFOV()*2);
     159    const Double_t scale = TMath::RadToDeg()*TMath::Sqrt(768*768 + 576*576)/(fAstro->GetRadiusFOV()*2);
    158160
    159161    // Offsets to shift [-n/2;n/2] to [0;n] and to
  • trunk/MagicSoft/Cosy/cosy.cc

    r7788 r8376  
    1111
    1212#include "MStarguider.h"
     13
     14using namespace std;
    1315
    1416#define EXPERT
  • trunk/MagicSoft/Cosy/devdrv/macs.cc

    r4104 r8376  
    550550}
    551551
    552 void Macs::SendMsg(BYTE_t d0=0, BYTE_t d1=0, BYTE_t d2=0,
    553                    BYTE_t d3=0, BYTE_t d4=0, BYTE_t d5=0)
     552void Macs::SendMsg(BYTE_t d0, BYTE_t d1, BYTE_t d2,
     553                   BYTE_t d3, BYTE_t d4, BYTE_t d5)
    554554{
    555555    GetNetwork()->SendCanFrame(fMacId, 0, 0, d0, d1, d2, d3, d4, d5);
  • trunk/MagicSoft/Cosy/gui/MGAccuracy.cc

    r7790 r8376  
    11#include "MGAccuracy.h"
    22
    3 #include <iostream.h>  // cout
     3#include <iostream>  // cout
    44
    55#include <TArc.h>
     
    1616
    1717ClassImp(MGAccuracy);
     18
     19using namespace std;
    1820
    1921void MGAccuracy::DrawText(const char *c1, const char *c2, const char *c3, const char*txt)
     
    163165    dist *= 3600.; // [sec]
    164166
    165     int rs = (int)floor(fmod(dist, 60.));
     167    int rs = TMath::FloorNint(fmod(dist, (float)60.));
    166168
    167169    dist /= 60.;   // [min]
  • trunk/MagicSoft/Cosy/gui/MGCoordinate.cc

    r7794 r8376  
    88
    99#include <stdlib.h>    // atoi
    10 #include <iostream.h>  // cout
     10#include <iostream>  // cout
    1111
    1212#include <TSystem.h>
     
    1818
    1919ClassImp(MGCoordinate);
     20
     21using namespace std;
    2022
    2123enum {
     
    2527};
    2628
    27 MGCoordinate::MGCoordinate(const TGWindow* p, const Int_t type=kETypeDeg,
     29MGCoordinate::MGCoordinate(const TGWindow* p, const Int_t type,
    2830                           const Int_t flag, const char *txt,
    2931                           const Int_t deg, const UInt_t min, const UInt_t sec)
     
    9193    TGLabel *label;
    9294
    93     const char *deg = type==kETypeDeg ? "\xb0" : "h";
    94     const char *min = type==kETypeDeg ? "'"    : "m";
    95     const char *sec = type==kETypeDeg ? "\""   : "s";
     95    const char *sdeg = type==kETypeDeg ? "\xb0" : "h";
     96    const char *smin = type==kETypeDeg ? "'"    : "m";
     97    const char *ssec = type==kETypeDeg ? "\""   : "s";
    9698
    9799    if (flag==1)
    98100    {
    99         label = new TGLabel(this, deg);
     101        label = new TGLabel(this, sdeg);
    100102        label->SetTextJustify(kTextLeft);
    101103        label->Move(37, 29-offset);
     
    103105        fList->Add(label);
    104106
    105         label = new TGLabel(this, min);
     107        label = new TGLabel(this, smin);
    106108        label->SetTextJustify(kTextLeft);
    107109        label->Move(71, 29-offset);
     
    109111        fList->Add(label);
    110112
    111         label = new TGLabel(this, sec);
     113        label = new TGLabel(this, ssec);
    112114        label->SetTextJustify(kTextLeft);
    113115        label->Move(107, 29-offset);
     
    116118    }
    117119
    118     label = new TGLabel(this, deg);
     120    label = new TGLabel(this, sdeg);
    119121    label->SetTextJustify(kTextLeft);
    120122    label->Move(39, ypos);
     
    122124    fList->Add(label);
    123125
    124     label = new TGLabel(this, min);
     126    label = new TGLabel(this, smin);
    125127    label->SetTextJustify(kTextLeft);
    126128    label->Move(73, ypos);
     
    128130    fList->Add(label);
    129131 
    130     label = new TGLabel(this, sec);
     132    label = new TGLabel(this, ssec);
    131133    label->SetTextJustify(kTextLeft);
    132134    label->Move(107, ypos);
     
    149151}
    150152
    151 void MGCoordinate::Print()
     153void MGCoordinate::Print(Option_t *o) const
    152154{
    153155    if (fLabel)
  • trunk/MagicSoft/Cosy/gui/MGCoordinate.h

    r7790 r8376  
    5858    Bool_t ProcessMessage(Long_t msg, Long_t mp1, Long_t mp2);
    5959
    60     void Print();
     60    void Print(Option_t *o="") const;
    6161
    6262    ClassDef(MGCoordinate, 0)
  • trunk/MagicSoft/Cosy/gui/MGCoordinates.cc

    r7790 r8376  
    77#include "MGCoordinates.h"
    88
    9 #include <iostream.h>  // cout
     9#include <iostream>  // cout
    1010
    1111#include "MGCoordinate.h"
     
    1313
    1414ClassImp(MGCoordinates);
     15
     16using namespace std;
    1517
    1618MGCoordinates::MGCoordinates(const TGWindow* p,
     
    5456}
    5557
    56 void MGCoordinates::Print()
     58void MGCoordinates::Print(Option_t *o) const
    5759{
    5860    fX->Print();
  • trunk/MagicSoft/Cosy/gui/MGCoordinates.h

    r7790 r8376  
    3737    void SetCoordinates(const XY &xy);
    3838
    39     void Print();
     39    void Print(Option_t *o="") const;
    4040
    4141    ClassDef(MGCoordinates, 0)
  • trunk/MagicSoft/Cosy/gui/MGCosy.cc

    r7794 r8376  
    11#include "MGCosy.h"
    22
    3 #include <iomanip.h>
    4 #include <iostream.h>
     3#include <iomanip>
     4#include <fstream>
    55
    66#include "msgqueue.h"
     
    4242
    4343ClassImp(MGCosy);
     44
     45using namespace std;
    4446
    4547#define IDM_EXIT   1
     
    827829    cout << "MGCosy: Setting Size" << endl;
    828830#endif
    829     const Int_t w = 1010;
    830     const Int_t h =  700;
    831     SetWMSizeHints(w, h, w, h, 1, 1);  // set the smallest and biggest size of the Main frame
     831    const Int_t ww = 1010;
     832    const Int_t hh =  700;
     833    SetWMSizeHints(ww, hh, ww, hh, 1, 1);  // set the smallest and biggest size of the Main frame
    832834
    833835    SetWindowName("Cosy Main Window");
     
    838840#endif
    839841    MapSubwindows();
    840     Resize(w, h); //GetDefaultSize());
     842    Resize(ww, hh); //GetDefaultSize());
    841843    MapWindow();
    842844}
  • trunk/MagicSoft/Cosy/gui/MGNumStars.cc

    r7794 r8376  
    11#include "MGNumStars.h"
    22
    3 #include <iostream.h>  // cout
     3#include <iostream>  // cout
    44
    55#include <TLine.h>
     
    1313
    1414ClassImp(MGNumStars);
     15
     16using namespace std;
    1517
    1618void MGNumStars::DrawText(const char*txt)
  • trunk/MagicSoft/Cosy/gui/MGSkyPosition.cc

    r2751 r8376  
    77#include "MGSkyPosition.h"
    88
    9 #include <iostream.h>  // cout
     9#include <iostream>  // cout
    1010
    1111#include <TArc.h>
     
    2121
    2222ClassImp(MGSkyPosition);
     23
     24using namespace std;
    2325
    2426void MGSkyPosition::InitArc(TArc *arc, Int_t fillstyle, Int_t fillcolor, Int_t linecolor)
  • trunk/MagicSoft/Cosy/main/MBending.cc

    r4255 r8376  
    5959#include "MBending.h"
    6060
    61 #include <fstream.h>
    62 #include <iomanip.h>
     61#include <fstream>
     62#include <iomanip>
    6363#include <TVector3.h>
    6464
     
    6868
    6969ClassImp(MBending);
     70
     71using namespace std;
    7072
    7173#undef DEBUG
  • trunk/MagicSoft/Cosy/main/MCaos.cc

    r7790 r8376  
    11#include "MCaos.h"
    22
    3 #include <iostream>
     3#include <fstream>
    44#include <iomanip>
    55
     
    2121#include "coord.h"
    2222
    23 void MCaos::ReadResources(const char *name="leds.txt")
     23using namespace std;
     24
     25void MCaos::ReadResources(const char *name)
    2426{
    2527    ifstream fin(name);
     
    242244    c->Update();
    243245
    244     const Int_t n1 = (Int_t)(sqrt(fPositions.GetEntriesFast())+1.0);
    245     const Int_t n2 = (Int_t)(sqrt(fPositions.GetEntriesFast())+0.5);
     246    const Int_t n1 = (Int_t)(TMath::Sqrt(fPositions.GetEntriesFast())+1.0);
     247    const Int_t n2 = (Int_t)(TMath::Sqrt(fPositions.GetEntriesFast())+0.5);
    246248
    247249    TCanvas *c1 = new TCanvas("cpos", "Led Positions", 800, 600);
     
    330332}
    331333
    332 Ring MCaos::Run(byte *img, bool printl, bool printr, const ZdAz &pos, const MTime &t, Double_t box, Double_t cut)
     334Ring MCaos::Run(byte *img, bool printl, bool printr, const ZdAz &pos, const MTime &t, Int_t box, Double_t cut)
    333335{
    334336    Leds &leds = *fLeds;
     
    355357        // Try to find Led in this area
    356358        const Led &l0 = fPositions(i);
    357         f.Execute(leds, l0.GetX(), l0.GetY());
     359        f.Execute(leds, TMath::FloorNint(l0.GetX()), TMath::FloorNint(l0.GetY()));
    358360
    359361        // Loop over newly found Leds
  • trunk/MagicSoft/Cosy/main/MCaos.h

    r4865 r8376  
    8989
    9090    Ring Run(byte *img, bool printl, bool printr, const ZdAz &pos,
    91              const MTime &t, Double_t box, Double_t cut);
     91             const MTime &t, Int_t box, Double_t cut);
    9292};
    9393
  • trunk/MagicSoft/Cosy/main/MCosy.cc

    r7790 r8376  
    11#include "MCosy.h"
    22
    3 #include <iomanip.h>
    4 #include <fstream.h>
    5 #include <iostream.h>
     3#include <iomanip>
     4#include <fstream>
    65
    76#include <TROOT.h>
     
    3029
    3130ClassImp(MCosy);
     31
     32using namespace std;
    3233
    3334typedef struct tm tm_t;
     
    493494    {
    494495#ifdef EXPERT
    495         fMac1->SetDeceleration(0.5*fMac1->GetVelRes());
    496         fMac2->SetDeceleration(0.5*fMac2->GetVelRes());
     496        fMac1->SetDeceleration(TMath::Nint(0.5*fMac1->GetVelRes()));
     497        fMac2->SetDeceleration(TMath::Nint(0.5*fMac2->GetVelRes()));
    497498#else
    498         fMac1->SetDeceleration(0.3*fMac1->GetVelRes());
    499         fMac2->SetDeceleration(0.3*fMac2->GetVelRes());
     499        fMac1->SetDeceleration(TMath::Nint(0.3*fMac1->GetVelRes()));
     500        fMac2->SetDeceleration(TMath::Nint(0.3*fMac2->GetVelRes()));
    500501#endif
    501502        fMac1->SetRpmMode(FALSE);
  • trunk/MagicSoft/Cosy/main/MPointing.cc

    r7230 r8376  
    66
    77ClassImp(MPointing);
     8
     9using namespace std;
    810
    911//#define EXPERT
     
    3032    if (ratio<1)
    3133    {
    32         fCosy->fMac1->SetVelocity(vel);
    33         fCosy->fMac2->SetVelocity(vel*ratio);
     34        fCosy->fMac1->SetVelocity(TMath::Nint(vel));
     35        fCosy->fMac2->SetVelocity(TMath::Nint(vel*ratio));
    3436    }
    3537    else
    3638    {
    37         fCosy->fMac1->SetVelocity(vel/ratio);
    38         fCosy->fMac2->SetVelocity(vel);
     39        fCosy->fMac1->SetVelocity(TMath::Nint(vel/ratio));
     40        fCosy->fMac2->SetVelocity(TMath::Nint(vel));
    3941    }
    4042}
     
    5658    fCosy->SetStatus(MDriveCom::kMoving);
    5759
    58     if (axe1) fCosy->fMac2->StartRelPos(rd.Zd());
    59     if (axe2) fCosy->fMac1->StartRelPos(rd.Az());
     60    if (axe1) fCosy->fMac2->StartRelPos(TMath::Nint(rd.Zd()));
     61    if (axe2) fCosy->fMac1->StartRelPos(TMath::Nint(rd.Az()));
    6062#ifdef EXPERT
    6163    cout << "Waiting for positioning..." << flush;
     
    7375{
    7476    const int vr = mac->GetVelRes();
    75     mac->SetAcceleration(acc*vr);
    76     mac->SetDeceleration(dec*vr);
     77    mac->SetAcceleration(TMath::Nint(acc*vr));
     78    mac->SetDeceleration(TMath::Nint(dec*vr));
    7779    return !mac->IsZombieNode();
    7880}
  • trunk/MagicSoft/Cosy/main/MStargHistograms.cc

    r7767 r8376  
    2222
    2323#include "coord.h"
     24
     25using namespace std;
    2426
    2527void MStargHistograms::OpenFile()
  • trunk/MagicSoft/Cosy/main/MStarguider.cc

    r7795 r8376  
    44#include "MStarguider.h"
    55
    6 #include <fstream.h>    // ifstream
    7 #include <iostream.h>   // cout
    8 #include <iomanip.h>   // cout
     6#include <fstream>    // ifstream
     7#include <iostream>   // cout
     8#include <iomanip>    // cout
    99
    1010#include <TH2F.h>
     
    5757
    5858ClassImp(MStarguider);
     59
     60using namespace std;
    5961
    6062enum {
     
    14571459           
    14581460            const Int_t idx = x.GetSize();
    1459            
     1461
    14601462            x.Set(idx+1);
    14611463            y.Set(idx+1);
    14621464            mag.Set(idx+1);
    1463            
     1465
    14641466            x.AddAt(dpos.X(), idx);
    14651467            y.AddAt(dpos.Y(), idx);
     
    15071509    fPZdAz->SetCoordinates(cpos);
    15081510
    1509 
    15101511    // Check StargTPoint data set request
    15111512    if (!fStargTPoint->IsDown())
     
    15751576}
    15761577
    1577 XY MStarguider::FindRoqueLamp(FilterLed &f, FilterLed &f2, Ring &CameraCenter, MTime &t, Double_t cut, Double_t box, XY SearchCenter)
     1578XY MStarguider::FindRoqueLamp(FilterLed &f, FilterLed &f2, Ring &CameraCenter, MTime &t, Double_t cut, Int_t box, XY SearchCenter)
    15781579{
    15791580    // Set search Paremeters (FIXME: Get them from user input!)
     
    16111612}
    16121613
    1613 ZdAz MStarguider::FindStar(FilterLed &f, FilterLed &f2, Ring &center, MTime &t, Double_t cut, Double_t box, Double_t scalefactor = 1.0)
     1614ZdAz MStarguider::FindStar(FilterLed &f, FilterLed &f2, Ring &center, MTime &t, Double_t cut, Int_t box, Double_t scalefactor = 1.0)
    16141615{
    16151616    // Set search Paremeters (FIXME: Get them from user input!)
     
    18501851    {
    18511852        // SCALE FACTOR ASSUMED TO BE 70
    1852         FindStar(f, f2, center, t, 3.5, 70);
     1853        FindStar(f, f2, center, t, 3/*3.5*/, 70);
    18531854        SendAmcTrigger("TPoint");
    18541855    }
     
    19201921
    19211922        Double_t imageclean = 1.5;
    1922         Double_t boxradius = 60;
     1923        Int_t    boxradius = 60;
    19231924        //Double_t scalefactor = 1;
    19241925        XY searchcenter(768/2-1,576/2+25);
     
    19471948
    19481949        Double_t imageclean = 5;
    1949         Double_t boxradius = 60;
     1950        Int_t    boxradius = 60;
    19501951        //Double_t scalefactor = 1;
    19511952        //      XY searchcenter(sgcenter.GetX(),sgcenter.GetY());
     
    20162017                     sgcenter.GetY()-293.6+28.5);
    20172018
    2018         fSao->CalcStars(stars, 530, 292, off.X(), off.Y());
     2019        fSao->CalcStars(stars, 530, 292, TMath::FloorNint(off.X()), TMath::FloorNint(off.Y()));
    20192020        fSao->DrawStars(stars, cimg);
    20202021
  • trunk/MagicSoft/Cosy/starg.cc

    r4865 r8376  
    1 #include <iostream.h>
     1#include <iostream>
    22
    33#include <TROOT.h>
     
    55
    66#include "MStarguider.h"
     7
     8using namespace std;
    79
    810/* ---------------------------------------------------------------------- */
  • trunk/MagicSoft/Cosy/testse.cc

    r1953 r8376  
    1 #include <iostream.h>
     1#include <iostream>
    22
    33#include "network.h"
    44#include "shaftencoder.h"
     5
     6using namespace std;
    57
    68TROOT root("Cosy", "Magic Control System");
Note: See TracChangeset for help on using the changeset viewer.