var shape = {"title":"29 North Neighborhood in Charlottesville, VA","description":"","tags":"","points":[[38.057297, -78.488307], [38.056661, -78.489269], [38.056683, -78.489377], [38.056759, -78.49016], [38.056813, -78.490712], [38.05689, -78.491339], [38.056987, -78.492156], [38.057043, -78.492952], [38.057106, -78.49355], [38.057158, -78.493903], [38.057243, -78.494833], [38.05726, -78.495025], [38.057274, -78.495195], [38.057433, -78.495375], [38.061862, -78.491604], [38.062092, -78.491726], [38.062139, -78.491685], [38.062187, -78.49164], [38.062291, -78.491543], [38.063122, -78.490818], [38.063317, -78.49064], [38.064183, -78.489896], [38.065937, -78.488327], [38.067003, -78.487357], [38.067979, -78.486491], [38.06926, -78.485323], [38.069212, -78.485232], [38.069166, -78.48512], [38.067761, -78.48242], [38.066938, -78.481141], [38.066748, -78.481167], [38.06669, -78.481253], [38.065567, -78.481066], [38.065429, -78.481015], [38.065261, -78.481719], [38.06474, -78.48279], [38.064251, -78.483509], [38.063409, -78.484091], [38.061618, -78.484688], [38.060501, -78.485269], [38.060042, -78.485682], [38.059063, -78.486968], [38.058079, -78.488539], [38.058037, -78.488651], [38.05773, -78.488522], [38.057297, -78.488307]],"author":"admin"};
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(38.057297, -78.488307),5);
map.addControl(new GSmallMapControl());
var latlngs = [];
for (var i=0; i<shape.points.length; i++)
{
    latlngs[i] = new GLatLng(shape.points[i][0], shape.points[i][1]);
}
var poly = new GPolygon(latlngs, '#ff0000', 3, .8, '#ff0000', .4);
map.addOverlay(poly);
var bounds = poly.getBounds();
map.setZoom(map.getBoundsZoomLevel(bounds));
map.panTo(bounds.getCenter());