| 1392 | } |
| 1393 | |
| 1394 | void TransitSchemeBuilder::GenerateTransfer(ref_ptr<dp::GraphicsContext> context, |
| 1395 | StopNodeParamsSubway const & stopParams, m2::PointD const & pivot, |
| 1396 | dp::Batcher & batcher) |
| 1397 | { |
| 1398 | m2::PointD const pt = MapShape::ConvertToLocal(stopParams.m_pivot, pivot, kShapeCoordScalar); |
| 1399 | |
| 1400 | size_t maxLinesCount = 0; |
| 1401 | m2::PointD dir; |
| 1402 | |
| 1403 | for (auto const & shapeInfo : stopParams.m_shapesInfo) |
| 1404 | { |
| 1405 | if (shapeInfo.second.m_linesCount > maxLinesCount) |
| 1406 | { |
| 1407 | dir = shapeInfo.second.m_direction; |
| 1408 | maxLinesCount = shapeInfo.second.m_linesCount; |
| 1409 | } |
| 1410 | } |
| 1411 | |
| 1412 | float constexpr kInnerScale = 1.0f; |
| 1413 | float constexpr kOuterScale = 1.5f; |
| 1414 | |
| 1415 | auto const outerColor = GetColorConstant(kTransitTransferOuterColor); |
| 1416 | auto const innerColor = GetColorConstant(kTransitTransferInnerColor); |
| 1417 | |
| 1418 | float const widthLinesCount = maxLinesCount > 3 ? 1.6f : 1.0f; |
| 1419 | float const innerScale = maxLinesCount == 1 ? 1.4f : kInnerScale; |
| 1420 | float const outerScale = maxLinesCount == 1 ? 1.9f : kOuterScale; |
| 1421 | |
| 1422 | GenerateMarker(context, pt, dir, widthLinesCount, maxLinesCount, outerScale, outerScale, kOuterMarkerDepth, |
| 1423 | outerColor, batcher); |
| 1424 | |
| 1425 | GenerateMarker(context, pt, dir, widthLinesCount, maxLinesCount, innerScale, innerScale, kInnerMarkerDepth, |
| 1426 | innerColor, batcher); |
| 1427 | } |
| 1428 | |
| 1429 | void TransitSchemeBuilder::GenerateTransfer(ref_ptr<dp::GraphicsContext> context, StopNodeParamsPT const & stopParams, |
| 1430 | m2::PointD const & pivot, dp::Batcher & batcher) |
nothing calls this directly
no test coverage detected