Project
Loading...
Searching...
No Matches
Spline2D.h
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
16
17#ifndef ALICEO2_GPUCOMMON_TPCFASTTRANSFORMATION_SPLINE2D_H
18#define ALICEO2_GPUCOMMON_TPCFASTTRANSFORMATION_SPLINE2D_H
19
20#include "Spline1D.h"
21#include "Spline2DSpec.h"
22#include "FlatObject.h"
23#include "GPUCommonDef.h"
24
25#if !defined(__CLING__) && !defined(G__ROOT) && !defined(GPUCA_GPUCODE) && !defined(GPUCA_NO_VC)
26#include <Vc/Vc>
27#include <Vc/SimdArray>
28#endif
29
30class TFile;
31
32namespace o2::gpu
33{
58
72template <typename DataT, int32_t YdimT, class FlatBase>
74 : public Spline2DSpec<DataT, YdimT, SplineUtil::getSpec(YdimT), FlatBase>
75{
76 protected:
78 using ParentSpec = Spline2DSpec<DataT, YdimT, SplineUtil::getSpec(YdimT), FlatBase>;
79
80 public:
81#if !defined(GPUCA_GPUCODE)
82 using ParentSpec::ParentSpec; // inherit constructors
83
85 {
86 static_cast<Container*>(this)->cloneFromObject(v, nullptr);
87 return *this;
88 }
89#else
90 Spline2DBase() = delete;
91 Spline2DBase(const Spline2DBase&) = delete;
92#endif
93
94#if !defined(GPUCA_GPUCODE) && !defined(GPUCA_STANDALONE)
95 static Spline2DBase* readFromFile(TFile& inpf, const char* name)
96 {
98 }
99#endif
100};
101
103template <typename DataT, int32_t YdimT = 0, class FlatBase = FlatObject>
105
107template <typename DataT, int32_t YdimT>
108class Spline2D<DataT, YdimT, FlatObject> : public Spline2DBase<DataT, YdimT, FlatObject>
109{
110 public:
111 using Spline2DBase<DataT, YdimT, FlatObject>::Spline2DBase;
112#if !defined(GPUCA_GPUCODE) && !defined(GPUCA_STANDALONE)
113 static Spline2D* readFromFile(TFile& inpf, const char* name)
114 {
116 }
117#endif
119};
120
122template <typename DataT, int32_t YdimT>
123class Spline2D<DataT, YdimT, NoFlatObject> : public Spline2DBase<DataT, YdimT, NoFlatObject>
124{
125 public:
126 using Spline2DBase<DataT, YdimT, NoFlatObject>::Spline2DBase;
127};
128
129} // namespace o2::gpu
130
131#endif
Definition of FlatObject class.
Definition of Spline1D class.
Definition of Spline2DSpec class.
Spline2DBase & operator=(const Spline2DBase &v)
Definition Spline2D.h:84
static Spline2DBase * readFromFile(TFile &inpf, const char *name)
Definition Spline2D.h:95
static Spline2DContainerBase * readFromFile(TFile &inpf, const char *name)
read a class object from the file
static Spline2D * readFromFile(TFile &inpf, const char *name)
Definition Spline2D.h:113
Forward declaration — specializations below select ClassDefNV based on FlatBase.
Definition Spline2D.h:104
static constexpr int32_t getSpec(int32_t nXdim, int32_t nYdim)
Definition SplineUtil.h:31
const GLdouble * v
Definition glcorearb.h:832
GLuint const GLchar * name
Definition glcorearb.h:781