Project
Loading...
Searching...
No Matches
GPUDisplayROOT.cxx
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
14
15#ifndef GPUCA_NO_ROOT
16#include "Rtypes.h" // Include ROOT header first, to use ROOT and disable replacements
17#endif
18
19#include "GPUDisplay.h"
20using namespace o2::gpu;
21
22#ifndef GPUCA_NO_ROOT
23#include "Rtypes.h" // Include ROOT header first, to use ROOT and disable replacements
24#include "TROOT.h"
25#include "TSystem.h"
26#include "TMethodCall.h"
27
28int32_t GPUDisplay::buildTrackFilter()
29{
30 if (!mCfgH.trackFilter) {
31 return 0;
32 }
33 if (mUpdateTrackFilter) {
34 std::string name = "displayTrackFilter/";
35 name += mConfig.filterMacros[mCfgH.trackFilter - 1];
36 gROOT->Reset();
37 if (gROOT->LoadMacro(name.c_str())) {
38 GPUError("Error loading trackFilter macro %s", name.c_str());
39 return 1;
40 }
41 }
42 TMethodCall call;
43 call.InitWithPrototype("gpuDisplayTrackFilter", "std::vector<bool>*, const o2::gpu::GPUTrackingInOutPointers*, const o2::gpu::GPUConstantMem*");
44 const void* args[3];
45 std::vector<bool>* arg0 = &mTrackFilter;
46 args[0] = &arg0;
47 args[1] = &mIOPtrs;
48 const GPUConstantMem* arg2 = mChain ? mChain->GetProcessors() : nullptr;
49 args[2] = &arg2;
50
51 call.Execute(nullptr, args, sizeof(args) / sizeof(args[0]), nullptr);
52 return 0;
53}
54
55#else
56
57int32_t GPUDisplay::buildTrackFilter()
58{
59}
60
61#endif
const GPUConstantMem * GetProcessors()
Definition GPUChain.h:64
GLuint const GLchar * name
Definition glcorearb.h:781