]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVE/Reve/LineGL.cxx
Dummy methods DefineParticle required by the interface added.
[u/mrichter/AliRoot.git] / EVE / Reve / LineGL.cxx
CommitLineData
6f04ebee 1// $Header$
2
3#include "LineGL.h"
4#include <Reve/Line.h>
5
19208112 6#include <TGLRnrCtx.h>
32e219c2 7#include <Reve/GLUtilNS.h>
19208112 8#include <TGLIncludes.h>
6f04ebee 9
10using namespace Reve;
11
12//______________________________________________________________________
13// LineGL
14//
15
16ClassImp(LineGL)
17
18LineGL::LineGL() : TPointSet3DGL(), fM(0)
19{
19208112 20 // fDLCache = false; // Disable display list.
6f04ebee 21}
22
23LineGL::~LineGL()
24{}
25
26/**************************************************************************/
27
19208112 28Bool_t LineGL::SetModel(TObject* obj, const Option_t* /*opt*/)
6f04ebee 29{
30 // TPointSet3DGL::SetModel(obj);
31 if(SetModelCheckClass(obj, Line::Class())) {
32 fM = dynamic_cast<Line*>(obj);
33 return kTRUE;
34 }
35 return kFALSE;
36}
37
38/**************************************************************************/
39
19208112 40void LineGL::DirectDraw(TGLRnrCtx & rnrCtx) const
6f04ebee 41{
19208112 42 // Direct GL rendering for Line.
43
44 // printf("LineGL::DirectDraw Style %d, LOD %d\n", rnrCtx.Style(), rnrCtx.LOD());
45
46 if (rnrCtx.DrawPass() == TGLRnrCtx::kPassOutlineLine)
47 return;
6f04ebee 48
49 Line& q = *fM;
50 if (q.Size() <= 0) return;
51
6f04ebee 52 if (q.fRnrLine)
32e219c2 53 GLUtilNS::RenderLine(q, q.GetP(), q.Size());
6f04ebee 54
55 if (q.fRnrPoints)
32e219c2 56 GLUtilNS::RenderPolyMarkers(q, q.GetP(), q.Size());
6f04ebee 57}