| [658] | 1 | // This may look like C code, but it is really -*- C++ -*-
 | 
|---|
 | 2 | //  Adaptateurs et Drawers divers pour Outils PEIDA++
 | 
|---|
 | 3 | //                             R. Ansari  06-08/98
 | 
|---|
 | 4 | // LAL (Orsay) / IN2P3-CNRS  DAPNIA/SPP (Saclay) / CEA
 | 
|---|
 | 5 | 
 | 
|---|
 | 6 | #ifndef PIPODRW_H_SEEN
 | 
|---|
 | 7 | #define PIPODRW_H_SEEN
 | 
|---|
 | 8 | 
 | 
|---|
 | 9 | #include "pidrawer.h"
 | 
|---|
 | 10 | #include "parradapter.h"
 | 
|---|
 | 11 | #include "cvector.h"
 | 
|---|
 | 12 | #include "matrix.h"
 | 
|---|
 | 13 | #include "histos2.h"
 | 
|---|
 | 14 | 
 | 
|---|
 | 15 | 
 | 
|---|
 | 16 | class GeneralFunction;
 | 
|---|
 | 17 | class PIGFFDrawer : public PIDrawer {
 | 
|---|
 | 18 | public:
 | 
|---|
 | 19 |                      PIGFFDrawer(GeneralFunction*);
 | 
|---|
 | 20 |   virtual           ~PIGFFDrawer();
 | 
|---|
 | 21 |   
 | 
|---|
 | 22 |   virtual void       Draw(PIGraphicUC* g, double xmin, double ymin, double xmax, double ymax);
 | 
|---|
 | 23 |   virtual void       SetParms(double const*);
 | 
|---|
 | 24 | protected:
 | 
|---|
 | 25 |   GeneralFunction*    mFunc;
 | 
|---|
 | 26 |   int                 mNParms;
 | 
|---|
 | 27 |   double*             mParms;
 | 
|---|
 | 28 | };
 | 
|---|
 | 29 | 
 | 
|---|
 | 30 | 
 | 
|---|
 | 31 | // Adaptateur de vecteurs Peida++ a P1DArrayAdapter
 | 
|---|
 | 32 | class POVectorAdapter : public P1DArrayAdapter {
 | 
|---|
 | 33 | public :
 | 
|---|
 | 34 |                   POVectorAdapter(Vector* v, bool ad=false);
 | 
|---|
 | 35 |   virtual         ~POVectorAdapter();
 | 
|---|
 | 36 |   virtual double  Value(int i);
 | 
|---|
 | 37 | 
 | 
|---|
 | 38 | protected:
 | 
|---|
 | 39 |   bool aDel;
 | 
|---|
 | 40 |   Vector* mVec;
 | 
|---|
 | 41 | };
 | 
|---|
 | 42 | 
 | 
|---|
 | 43 | // Adaptateur d'Histo-2D Peida++ a P2DArrayAdapter
 | 
|---|
 | 44 | class POH2DAdapter :  public P2DArrayAdapter {
 | 
|---|
 | 45 | public :
 | 
|---|
 | 46 |                   POH2DAdapter(Histo2D* h2d, bool ad=false);
 | 
|---|
 | 47 |   virtual         ~POH2DAdapter();
 | 
|---|
 | 48 | 
 | 
|---|
 | 49 |   virtual double  Value(int ix, int iy);   
 | 
|---|
 | 50 | 
 | 
|---|
 | 51 | protected:
 | 
|---|
 | 52 |   bool aDel;
 | 
|---|
 | 53 |   Histo2D* mH2d;
 | 
|---|
 | 54 | };
 | 
|---|
 | 55 | 
 | 
|---|
 | 56 | // Adaptateur de matrice Peida++ a P2DArrayAdapter
 | 
|---|
 | 57 | // Attention MatrixAdapter(X=Colonne, Y= Row) = Matrix(row, col)  
 | 
|---|
 | 58 | class POMatrixAdapter :  public P2DArrayAdapter {
 | 
|---|
 | 59 | public :
 | 
|---|
 | 60 |                   POMatrixAdapter(Matrix* mtx, bool ad=false);
 | 
|---|
 | 61 |   virtual         ~POMatrixAdapter();
 | 
|---|
 | 62 | 
 | 
|---|
 | 63 |   virtual double  Value(int ix, int iy);   
 | 
|---|
 | 64 | 
 | 
|---|
 | 65 | protected:
 | 
|---|
 | 66 |   bool aDel;
 | 
|---|
 | 67 |   Matrix* mMtx;
 | 
|---|
 | 68 | };
 | 
|---|
 | 69 | 
 | 
|---|
 | 70 | 
 | 
|---|
 | 71 | #endif
 | 
|---|