and some implementation for one point (it is easy to reproduce it to
large datasets of points - not tested):
$x = 51.28127305768449; $y = 1.3599228858947754; $zoom = 17;
$tile = GoogleMapUtility::toTileXY($x,$y,$zoom);
//$rect = GoogleMapUtility::getTileRect($tile->x,$tile->y,$zoom);
$point = GoogleMapUtility::toZoomedPixelCoords($x,$y,$zoom);
$xp = $point->x - (GoogleMapUtility::TILE_SIZE * $tile->x);
$yp = $point->y - (GoogleMapUtility::TILE_SIZE * $tile->y);
ob_start();
$im = imagecreate(GoogleMapUtility::TILE_SIZE, GoogleMapUtility::TILE_SIZE);
$blank = imagecolorallocate( $im, 0, 0, 0 );
imagefilledrectangle( $im, 0, 0, GoogleMapUtility::TILE_SIZE,
GoogleMapUtility::TILE_SIZE, $blank );
$red = imagecolorallocate($im, 255, 0, 0);
imagefilledellipse($im,$xp-5,$yp-5,10,10,$red);
imagecolortransparent($im, $blank);
imagepng($im);
imagedestroy($im);
header('Content-type: image/png');
$imagedata = ob_get_flush();
file_put_contents("file.png", $imagedata);
> thanks neil,
> My problem is how can i create these png images , as i have just lat
> long in large numbers. and i don't know how can i create theses png
> files using those lat longs.
> thanks
> >
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---