9 #include "Fdimpar.h" //(DIMPAR) fluka include
10 #include "Ftrackr.h" //(TRACKR) fluka common
12 # define bxdraw bxdraw_
14 # define bxdraw BXDRAW
17 void bxdraw(Int_t& icode, Int_t& mreg, Int_t& newreg,
18 Double_t& xsco, Double_t& ysco, Double_t& zsco)
20 TFluka* fluka = (TFluka*) gMC;
22 fluka->SetIcode(icode);
23 fluka->SetNewreg(newreg);
27 Int_t verbosityLevel = fluka->GetVerbosityLevel();
28 Bool_t debug = (verbosityLevel>=3)?kTRUE:kFALSE;
30 // Double step for boundary crossing
32 fluka->SetTrackIsNew(kFALSE); // has to be called BEFORE Stepping()
33 if (debug) printf("bxdraw (ex) \n");
34 fluka->SetTrackIsExiting();
37 (TVirtualMCApplication::Instance())->Stepping();
39 if (debug) printf("bxdraw (en) \n");
41 fluka->SetTrackIsEntering();
42 if (fluka->GetDummyBoundary() == 1) fluka->SetDummyBoundary(2);
43 fluka->SetMreg(newreg);
44 (TVirtualMCApplication::Instance())->Stepping();
47 } // end of extern "C"