Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TGraphDelaunay2D.h
Go to the documentation of this file.
1// @(#)root/hist:$Id: TGraphDelaunay2D.h,v 1.00
2// Author: Olivier Couet, Luke Jones (Royal Holloway, University of London)
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT_TGraphDelaunay2D
13#define ROOT_TGraphDelaunay2D
14
15
16//////////////////////////////////////////////////////////////////////////
17// //
18// TGraphDelaunay2D //
19// //
20// This class uses the Delaunay triangles technique to interpolate and //
21// render the data set. //
22// //
23//////////////////////////////////////////////////////////////////////////
24
25#include "TNamed.h"
26
27#include "Math/Delaunay2D.h"
28
29class TGraph2D;
30class TView;
31
32class TGraphDelaunay2D : public TNamed {
33
34public:
35
36
37private:
40
41protected:
42
43 TGraph2D *fGraph2D; ///<! 2D graph containing the user data
44 ROOT::Math::Delaunay2D fDelaunay; ///<! Delaunay interpolator class
45
46public:
47
49
50 TGraphDelaunay2D(TGraph2D *g = nullptr);
51
54
55 TGraph2D *GetGraph2D() const {return fGraph2D;}
58 Double_t GetXNmin() const {return fDelaunay.XMin();}
59 Double_t GetXNmax() const {return fDelaunay.XMax();}
60 Double_t GetYNmin() const {return fDelaunay.YMin();}
61 Double_t GetYNmax() const {return fDelaunay.YMax();}
62
64
65 Triangles::const_iterator begin() const { return fDelaunay.begin(); }
66 Triangles::const_iterator end() const { return fDelaunay.end(); }
67
68 ClassDefOverride(TGraphDelaunay2D,1) // Delaunay triangulation
69
70private:
71
72
73};
74
75#endif
#define g(i)
Definition RSha256.hxx:105
#define ClassDefOverride(name, id)
Definition Rtypes.h:341
Class to generate a Delaunay triangulation of a 2D set of points.
Definition Delaunay2D.h:115
Triangles::const_iterator end() const
Definition Delaunay2D.h:164
Triangles::const_iterator begin() const
Definition Delaunay2D.h:163
double Interpolate(double x, double y)
Return the Interpolated z value corresponding to the given (x,y) point.
void SetZOuterValue(double z=0.)
set z value to be returned for points outside the region
Definition Delaunay2D.h:157
double YMin() const
Definition Delaunay2D.h:153
double XMax() const
Definition Delaunay2D.h:152
double ZOuterValue() const
return the user defined Z-outer value
Definition Delaunay2D.h:160
void FindAllTriangles()
Find all triangles.
double YMax() const
Definition Delaunay2D.h:154
double XMin() const
Definition Delaunay2D.h:151
std::vector< Triangle > Triangles
Definition Delaunay2D.h:129
int NumberOfTriangles() const
return the number of triangles
Definition Delaunay2D.h:149
Graphics object made of three arrays X, Y and Z with the same number of points each.
Definition TGraph2D.h:41
TGraphDelaunay2D generates a Delaunay triangulation of a TGraph2D.
Triangles::const_iterator begin() const
TGraphDelaunay2D & operator=(const TGraphDelaunay2D &)=delete
Double_t GetXNmax() const
TGraph2D * GetGraph2D() const
Triangles::const_iterator end() const
Double_t ComputeZ(Double_t x, Double_t y)
TGraphDelaunay2D(const TGraphDelaunay2D &)=delete
TGraph2D * fGraph2D
! 2D graph containing the user data
Double_t GetXNmin() const
Int_t GetNdt() const
Double_t GetMarginBinsContent() const
ROOT::Math::Delaunay2D fDelaunay
! Delaunay interpolator class
void SetMarginBinsContent(Double_t z=0.)
Double_t GetYNmax() const
Double_t GetYNmin() const
ROOT::Math::Delaunay2D::Triangles Triangles
The TNamed class is the base class for all named ROOT classes.
Definition TNamed.h:29
See TView3D.
Definition TView.h:25
Double_t y[n]
Definition legend1.C:17
Double_t x[n]
Definition legend1.C:17