public ProjectionRect getMapArea ( ProjectionRect rect ) { if ( rect == null ) rect = new ProjectionRect ( ) ; double width = pwidth / pix_per_world ; double height = pheight / pix_per_world ; // center point double wx0 = ( pwidth / 2 - pix_x0 ) / pix_per_world ; double wy0 = ( pix_y0 - pheight / 2 ) / pix_per_world ; rect . setRect ( wx0 - width / 2 , wy0 - height / 2 , // minx, miny width , height ) ; // width, height return rect ; }
Get current MapArea .