Exemple #1
0
 protected virtual IEnumerable <MarkupStyleDash> CalculateDashes(ILineTrajectory trajectory, LineBorders borders)
 {
     if (StyleHelper.CalculateSolidDash(borders, trajectory, 0f, Width, Color, out MarkupStyleDash dash))
     {
         yield return(dash);
     }
 }
Exemple #2
0
        protected override IEnumerable <MarkupStyleDash> Calculate(MarkupStopLine stopLine, ILineTrajectory trajectory)
        {
            var offset = ((stopLine.Start.Direction + stopLine.End.Direction) / -2).normalized * (Width / 2);

            return(StyleHelper.CalculateSolid(trajectory, CalculateDashes));

            IEnumerable <MarkupStyleDash> CalculateDashes(ILineTrajectory dashTrajectory)
            {
                yield return(StyleHelper.CalculateSolidDash(dashTrajectory, offset, offset, Width, Color));
            }
        }
Exemple #3
0
 protected virtual IEnumerable <MarkupStyleDash> CalculateDashes(ILineTrajectory trajectory)
 {
     yield return(StyleHelper.CalculateSolidDash(trajectory, 0f, Width, Color));
 }