Trax3 3.1.0
trax track library
Loading...
Searching...
No Matches
trax::SectionPainter Class Referenceabstract

Paints a track by taking a cross section as a profile. More...

#include <C:/Trend/Development/Trax3/Code/trax/TrackPainter.h>

Inheritance diagram for trax::SectionPainter:

Public Member Functions

dclspc SectionPainter (int mode, common::Interval< Length > segmentLimits={epsilon__length, plausible_maximum_length}, Length e=epsilon__length)
Public Member Functions inherited from trax::TrackPainter
TrackPainter & operator= (const TrackPainter &)=default
TrackPainter & operator= (TrackPainter &&)=default
TrackPainter & operator() (const SectionTrack &track)
int GetMode () const noexcept
int GetCountSegments () const noexcept
dclspc TrackPainter (int mode, common::Interval< Length > segmentLimits={epsilon__length, plausible_maximum_length}, Length e=epsilon__length)
dclspc TrackPainter (const TrackPainter &)=default
dclspc TrackPainter (TrackPainter &&)=default
dclspc Length Paint (const TrackBuilder &track, const Section &section, Length offset=0_m)
 Paints the track.

Protected Member Functions

void dclspc StartPaint (const spat::Frame< Length, One > &rFrame, Length offset, const Section &section) override
 Gets called once on rendering startup before all PaintSegment() calls.
void dclspc PaintSegment (const spat::Frame< Length, One > &rFrame, Length segmentLength, const Section &section) override
 This gets called once per segment to paint a segment of the track.
virtual void AddVertex (const spat::Frame< Length, One > &rFrame, const Section::SectionPoint &pt, const spat::Position2D< One > &textcoord)=0
virtual void AddTriangle (unsigned int i0, unsigned int i1, unsigned int i2)=0
Protected Member Functions inherited from trax::TrackPainter
virtual void EndPaint (const spat::Frame< Length, One > &)
 Gets called once on rendering end after all PaintSegment() calls.

Additional Inherited Members

Public Types inherited from trax::TrackPainter
enum  Mode {
  mode_none = 0x00 , mode_leftHandedFaces = 0x01 , mode_constantSegmentLength = 0x02 , mode_SegmentLength = 0x04 ,
  mode_checkedSegmentLength = 0x04 , mode_totallycheckedSegmentLength = 0x08 , mode_ignoreCuvesTorsion = 0x10 , mode_localFrame = 0x20 ,
  mode_startFrame = 0x40 , mode_default = mode_none
}

Detailed Description

Paints a track by taking a cross section as a profile.

Member Function Documentation

◆ PaintSegment()

void dclspc trax::SectionPainter::PaintSegment ( const spat::Frame< Length, One > & rFrame,
Length segmentLength,
const Section &  )
overrideprotectedvirtual

This gets called once per segment to paint a segment of the track.

Parameters
rFramePosition and orientation at the end of the segment to paint.
segmentLengthLength of the segment. This value migh vary from call to call.

Implements trax::TrackPainter.

◆ StartPaint()

void dclspc trax::SectionPainter::StartPaint ( const spat::Frame< Length, One > & ,
Length ,
const Section &  )
overrideprotectedvirtual

Gets called once on rendering startup before all PaintSegment() calls.

Reimplemented from trax::TrackPainter.


The documentation for this class was generated from the following file: