]>
Commit | Line | Data |
---|---|---|
793ff80c | 1 | Int_t AliTRDcreateDigits() |
2 | { | |
3 | // | |
4 | // Creates the digits from the hits of the slow simulator | |
5 | // | |
6 | ||
7 | Int_t rc = 0; | |
8 | ||
793ff80c | 9 | if (!gAlice) { |
10 | cout << "<AliTRDcreateDigits> No AliRun object found" << endl; | |
11 | rc = 1; | |
12 | return rc; | |
13 | } | |
14 | gAlice->GetEvent(0); | |
15 | ||
16 | // Create the TRD digitzer | |
17 | AliTRDdigitizer *Digitizer = new AliTRDdigitizer("digitizer","Digitizer class"); | |
18 | ||
793ff80c | 19 | // Set the parameter |
20 | Digitizer->SetDiffusion(); | |
21 | Digitizer->SetVerbose(1); | |
22 | ||
23 | // Create the digits | |
e2c86a4a | 24 | if (!(Digitizer->MakeDigits())) { |
6244debe | 25 | rc = 2; |
793ff80c | 26 | return rc; |
27 | } | |
28 | ||
e2c86a4a | 29 | // Write the digits into the input file |
30 | if (!(Digitizer->WriteDigits())) { | |
6244debe | 31 | rc = 3; |
e2c86a4a | 32 | return rc; |
33 | } | |
34 | ||
35 | // Save the digitizer class in the AliROOT file | |
36 | if (!(Digitizer->Write())) { | |
6244debe | 37 | rc = 4; |
e2c86a4a | 38 | return rc; |
39 | } | |
40 | ||
793ff80c | 41 | return rc; |
42 | ||
43 | } |