Madhumitha
Madhumitha

Reputation: 3824

how to rotate google map for iphone app

I am doing map oriented iphone application.In that am showing an area on google map.That area is placed in horizantal view.I want to rotate it in vertical view.Any idea?Please help me.I attached the map image below.

enter image description here

Upvotes: 0

Views: 1168

Answers (1)

Ajeet Pratap Maurya
Ajeet Pratap Maurya

Reputation: 4254

To rotate the view, I would suggest to use the CGAffineTransform to rotate the view. As your map is shown in the mapView, you can rotate it.

float   angle = M_PI;  //rotate 180°, or 1 π radians
CGAffineTransform transform = CGAffineTransformMakeRotation(angle);
[[self viewWithTag:999] setTransform:transform]; //you can use the view or its tag

hope that helps

Upvotes: 1

Related Questions