~chris-rogers/maus/emr_mc_digitization

« back to all changes in this revision

Viewing changes to src/py_cpp/optics/PyOpticsModel.cc

  • Committer: Chris Rogers
  • Date: 2014-04-16 11:48:45 UTC
  • mfrom: (707 merge)
  • mto: This revision was merged to the branch mainline in revision 711.
  • Revision ID: chris.rogers@stfc.ac.uk-20140416114845-h3u3q7pdcxkxvovs
Update to trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
90
90
        cm_out = new CovarianceMatrix(optics_model->Transport
91
91
                                                           (*cm_in, end_plane));
92
92
    }
93
 
    catch(std::exception& exc) {
 
93
    catch (std::exception& exc) {
94
94
        PyErr_SetString(PyExc_RuntimeError, (&exc)->what());
95
95
        return NULL;
96
96
    }
143
143
        psv_out = new PhaseSpaceVector(optics_model->Transport
144
144
                                                          (*psv_in, end_plane));
145
145
    }
146
 
    catch(std::exception& exc) {
 
146
    catch (std::exception& exc) {
147
147
        PyErr_SetString(PyExc_RuntimeError, (&exc)->what());
148
148
        return NULL;
149
149
    }
183
183
    try {
184
184
        Json::Value* cards = Globals::GetConfigurationCards();
185
185
        // just gets deltas (dx, dy, ...) and polynomial order
186
 
        optics->model = new MAUS::PolynomialOpticsModel(*cards);
 
186
        optics->model = new MAUS::PolynomialOpticsModel(cards);
187
187
        // uses MAUS::Globals::MAUSGeant4Manager for geometry, etc
188
188
        optics->model->Build();
189
189
        is_built = true;  // done by constructor
190
 
    } catch(std::exception& exc) {
 
190
    } catch (std::exception& exc) {
191
191
        PyErr_SetString(PyExc_RuntimeError, (&exc)->what());
192
192
        return -1;
193
193
    }