Google map with custom picture (localmap for ex.) ?

General discussion and socializing.

Re: Google map with custom picture (localmap for ex.) ?

Postby DatOneGuy » Tue Jun 01, 2010 4:04 am

The issues with markers is really really annoying. I can seem to get it working but it won't show the markers properly, and if I add in the code to 'create' markers it completely breaks, so I've decided to post in the google maps API group and continue tomorrow trying to adapt code from Mike's site (econym) and attempt to see how havenmap.tk came up with that code and how it works.

Edit: Also this is all in javascript not in php, and I hate javascript but working around this isn't too terrible :X Luckily I have a little experience from back in highschool and my web design teacher not trusting PHP (You can still get the teacher's passwords just by viewing source = =;)
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . .Hi. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
User avatar
DatOneGuy
 
Posts: 5553
Joined: Sun Apr 18, 2010 7:50 am
Location: I'm in Miami, trick.

Re: Google map with custom picture (localmap for ex.) ?

Postby L0ckAndL0ad » Tue Jun 01, 2010 6:35 am

DatOneGuy wrote:The issues with markers is really really annoying. I can seem to get it working but it won't show the markers properly, and if I add in the code to 'create' markers it completely breaks, so I've decided to post in the google maps API group and continue tomorrow trying to adapt code from Mike's site (econym) and attempt to see how havenmap.tk came up with that code and how it works.

What type of coordinate system do you use? I thought, using just GImageCutter and pixel coordinate system (or whatever it is out there) might make dyn. markers managment even worse (if it's even possible to use both dyn. markers and simple pixel coordinate system at all).

I mean.. Every time we change image size - coordinates for every marker will change. So, the only simple solution i have - hardprint(or overprint, dunno how do you english people call it) markers into the map itself before changing image size. Working with photoshop (or similar) it's simple to hide/rename those overprinted markers in coming releases of the map(like I do it now, with known villages/named lakes, etc). This is acceptable solution for me, really.

DatOneGuy wrote:Edit: Also this is all in javascript not in php, and I hate javascript but working around this isn't too terrible :X Luckily I have a little experience from back in highschool and my web design teacher not trusting PHP (You can still get the teacher's passwords just by viewing source = =;)

I guess it doesn't really matter before you'll try store coordinate data in your own SQL-DB.
Deculture!
Image
Zero | Fairy | Frontier | Area 88
User avatar
L0ckAndL0ad
 
Posts: 95
Joined: Thu Apr 29, 2010 11:06 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby DatOneGuy » Tue Jun 01, 2010 6:41 am

L0ckAndL0ad wrote:
DatOneGuy wrote:The issues with markers is really really annoying. I can seem to get it working but it won't show the markers properly, and if I add in the code to 'create' markers it completely breaks, so I've decided to post in the google maps API group and continue tomorrow trying to adapt code from Mike's site (econym) and attempt to see how havenmap.tk came up with that code and how it works.

What type of coordinate system do you use? I thought, using just GImageCutter and pixel coordinate system (or whatever it is out there) might make dyn. markers managment even worse (if it's even possible to use both dyn. markers and simple pixel coordinate system at all).

I mean.. Every time we change image size - coordinates for every marker will change. So, the only simple solution i have - hardprint(or overprint, dunno how do you english people call it) markers into the map itself before changing image size. Working with photoshop (or similar) it's simple to hide/rename those overprinted markers in coming releases of the map(like I do it now, with known villages/named lakes, etc). This is acceptable solution for me, really.

DatOneGuy wrote:Edit: Also this is all in javascript not in php, and I hate javascript but working around this isn't too terrible :X Luckily I have a little experience from back in highschool and my web design teacher not trusting PHP (You can still get the teacher's passwords just by viewing source = =;)

I guess it doesn't really matter before you'll try store coordinate data in your own SQL-DB.

Was storing them in SQL with lat/lng. I'll have to look into how/if GMapImageCutter changes anything related to how all that works though.

The markers won't be as big of an issue if you have one huge static size and change the maps to that size beforehand. For example if you want the whole worldmap 9x9 to be 10,000x10,000 pixels, you would fill all empty space with black and that would be that, when updating you would simply change the images that are output.

For something more 'local' this is quite a problem though.
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . .Hi. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
User avatar
DatOneGuy
 
Posts: 5553
Joined: Sun Apr 18, 2010 7:50 am
Location: I'm in Miami, trick.

Re: Google map with custom picture (localmap for ex.) ?

Postby L0ckAndL0ad » Tue Jun 01, 2010 6:46 am

DatOneGuy wrote:he markers won't be as big of an issue if you have one huge static size and change the maps to that size beforehand. For example if you want the whole worldmap 9x9 to be 10,000x10,000 pixels, you would fill all empty space with black and that would be that, when updating you would simply change the images that are output.

For something more 'local' this is quite a problem though.

Yeah, looks like a good idea. But i guess i want those overprinted markers anyway %) They can be really cute sometimes :)
Deculture!
Image
Zero | Fairy | Frontier | Area 88
User avatar
L0ckAndL0ad
 
Posts: 95
Joined: Thu Apr 29, 2010 11:06 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby Teme » Tue Jun 01, 2010 9:24 am

L0ckAndL0ad wrote:
DatOneGuy wrote:he markers won't be as big of an issue if you have one huge static size and change the maps to that size beforehand. For example if you want the whole worldmap 9x9 to be 10,000x10,000 pixels, you would fill all empty space with black and that would be that, when updating you would simply change the images that are output.

For something more 'local' this is quite a problem though.

Yeah, looks like a good idea. But i guess i want those overprinted markers anyway %) They can be really cute sometimes :)


But is it not possible to update your map next way: First there is 1 local map (center), then you just update your map that way its says at center. Even if you only want to add one localmap next to (center) map, you can fill other sides with "black localmaps" :p

Good logic?
Plaah ~Image
User avatar
Teme
 
Posts: 97
Joined: Mon Apr 19, 2010 5:21 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby L0ckAndL0ad » Tue Jun 01, 2010 12:37 pm

Teme wrote:But is it not possible to update your map next way: First there is 1 local map (center), then you just update your map that way its says at center. Even if you only want to add one localmap next to (center) map, you can fill other sides with "black localmaps" :p

Good logic?

Dunno if i understood you right, but.. I guess so called "center" will shift anyway. If you're not talking about 10k x 10k px static blank map. If you are, then I don't get what you're talking about %)
Deculture!
Image
Zero | Fairy | Frontier | Area 88
User avatar
L0ckAndL0ad
 
Posts: 95
Joined: Thu Apr 29, 2010 11:06 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby Teme » Tue Jun 01, 2010 1:13 pm

L0ckAndL0ad wrote:
Teme wrote:But is it not possible to update your map next way: First there is 1 local map (center), then you just update your map that way its says at center. Even if you only want to add one localmap next to (center) map, you can fill other sides with "black localmaps" :p

Good logic?

Dunno if i understood you right, but.. I guess so called "center" will shift anyway. If you're not talking about 10k x 10k px static blank map. If you are, then I don't get what you're talking about %)


B = black picture
C = center (1st map)
L = localmap

BBL
BCB
BLB

That would make 3x3 localmap sized areas
Plaah ~Image
User avatar
Teme
 
Posts: 97
Joined: Mon Apr 19, 2010 5:21 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby L0ckAndL0ad » Tue Jun 01, 2010 1:53 pm

Ehm.. So?
Deculture!
Image
Zero | Fairy | Frontier | Area 88
User avatar
L0ckAndL0ad
 
Posts: 95
Joined: Thu Apr 29, 2010 11:06 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby Teme » Wed Jun 02, 2010 2:57 pm

lul forget it :D

Anything new on dynamic markers?
Plaah ~Image
User avatar
Teme
 
Posts: 97
Joined: Mon Apr 19, 2010 5:21 pm

Re: Google map with custom picture (localmap for ex.) ?

Postby Jsk1993 » Wed Jun 02, 2010 7:39 pm

If you want an alternative to markers, you can always just use different layers in photoshop.
Just have two layers in a huge photo/canvas in PS. The bottom layer will be the map and top will be markers/annotations.

To update the map, all you have to do is open up the PSD, copy/add the map to the bottom layer, Ctrl+Click the bottom layer to only select what you have so far of the map, then copy and paste into a new picture. Save it as PNG or whatever and upload it to the map.
Jsk1993
 
Posts: 3
Joined: Sun Mar 28, 2010 1:37 am

PreviousNext

Return to The Inn of Brodgar

Who is online

Users browsing this forum: Claude [Bot], Yandex [Bot] and 1 guest