File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -199,7 +199,7 @@ struct LineStyleInfo
199
199
}
200
200
201
201
// If it's all draw or all gap
202
- bool isSingleSegment () const
202
+ inline bool isSingleSegment () const
203
203
{
204
204
const bool allDraw = stipplePattern[0 ] == 1 .0f && stipplePatternSize == 1u ;
205
205
const bool allGap = !isVisible ();
@@ -325,6 +325,11 @@ struct LineStyleInfo
325
325
inline bool hasShape () const { return shapeNormalizedPlaceInPattern != InvalidNormalizedShapeOffset; }
326
326
327
327
inline bool isVisible () const { return stipplePatternSize != InvalidStipplePatternSize; }
328
+
329
+ inline bool skipPreprocess () const
330
+ {
331
+ return isSingleSegment () && !hasShape () && !isRoadStyleFlag;
332
+ }
328
333
};
329
334
330
335
class CPolylineBase
@@ -491,8 +496,8 @@ class CPolyline : public CPolylineBase
491
496
492
497
void preprocessPolylineWithStyle (const LineStyleInfo& lineStyle, const AddShapeFunc& addShape = {})
493
498
{
494
- // if (! lineStyle.isVisible ())
495
- // return;
499
+ if (lineStyle.skipPreprocess ())
500
+ return ;
496
501
// DISCONNECTION DETECTED, will break styling and offsetting the polyline, if you don't care about those then ignore discontinuity.
497
502
// _NBL_DEBUG_BREAK_IF(!checkSectionsContinuity());
498
503
PolylineConnectorBuilder connectorBuilder;
You can’t perform that action at this time.
0 commit comments