title: Take screenshot of the Displayed OpenStreetMap
body: <p>I made an independent app to show the current user location using OpenStreetMaps. This is my Main Activity:</p>
  
  <p>I used osmdroid 5.6.2</p>
  
  <p>package com.example.re.osm;</p>
  
  <pre><code>public class MainActivity extends Activity {
  
      private LocationManager locationManager;
      private Location onlyOneLocation;
      private final int REQUEST_FINE_LOCATION = 1234;
      public GeoPoint startPoint;
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          Context ctx = getApplicationContext();
  
          if (ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED)
              ActivityCompat.requestPermissions(this, new String[] {Manifest.permission.ACCESS_FINE_LOCATION}, REQUEST_FINE_LOCATION);
  
  
          Configuration.getInstance().load(ctx, PreferenceManager.getDefaultSharedPreferences(ctx));
          setContentView(R.layout.activity_main);
  
          final MapView map = (MapView) findViewById(R.id.map);
          map.setTileSource(TileSourceFactory.MAPNIK);
          map.setBuiltInZoomControls(true);
          map.setMultiTouchControls(true);
  
          final IMapController mapController = map.getController();
          mapController.setZoom(18);
  
          CurrentLocation.requestSingleUpdate(this,
                  new CurrentLocation.LocationCallback() {
  
                      @Override public void onNewLocationAvailable(GPSCoordinates location) {
                          Log.d("Location", "my location is " + location.latitude + " : " + location.longitude);
                          startPoint = new GeoPoint(location.latitude, location.longitude);
  
                          // My Location Overlay
                          Marker marker=new Marker(map);
                          marker.setPosition(startPoint);
                          marker.setTitle("Your Location");
                          marker.showInfoWindow();
                          map.getOverlays().add(marker);
                          map.invalidate();
                          //This geopoint is currently static and shows a single location everytime the app is executed
                          mapController.setCenter(startPoint);
                      }
                  });
  
  
  
      }
  }
  </code></pre>
  
  <p>I need to take the screenshot of the map and display it. Any idea of how should I do it?</p>
  
  <p>Thanks</p>