MCPcopy Create free account
hub / github.com/comaps/comaps / SetAngle

Method SetAngle

libs/drape_frontend/user_event_stream.cpp:500–516  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

498}
499
500bool UserEventStream::SetAngle(double azimuth, bool isAnim, TAnimationCreator const & parallelAnimCreator)
501{
502 ScreenBase screen;
503 GetTargetScreen(screen);
504 m2::PointD pt = m_visibleViewport.Center();
505 m2::PointD gPt = screen.PtoG(screen.P3dtoP(pt));
506
507 if (screen.isPerspective())
508 {
509 return SetFollowAndRotate(gPt, pt, azimuth, kDoNotChangeZoom, kDoNotAutoZoom, isAnim, false /* isAutoScale */,
510 nullptr /* onFinishAction */, parallelAnimCreator);
511 }
512
513 screen.SetAngle(azimuth);
514 screen.MatchGandP3d(gPt, pt);
515 return SetScreen(screen, isAnim, parallelAnimCreator);
516}
517
518bool UserEventStream::SetRect(m2::RectD rect, int zoom, bool applyRotation, bool isAnim, bool useVisibleViewport,
519 TAnimationCreator const & parallelAnimCreator)

Callers 2

GetPrettyFollowAnimationFunction · 0.45
SetFollowAndRotateMethod · 0.45

Calls 5

isPerspectiveMethod · 0.80
MatchGandP3dMethod · 0.80
CenterMethod · 0.45
PtoGMethod · 0.45
P3dtoPMethod · 0.45

Tested by

no test coverage detected