Steve Jackson Games - Site Navigation
Home General Info Follow Us Search Illuminator Store Forums What's New Other Games Ogre GURPS Munchkin Our Games: Home

Go Back   Steve Jackson Games Forums > Board and Card Games > Ogre and G.E.V.

Reply
 
Thread Tools Display Modes
Old 10-10-2013, 01:41 AM   #1
HeatDeath
 
Join Date: May 2012
Default Announcement: New Map Bashing Tool - ScreenshotGrid

In the course of my long running personal projects to create Ogre maps of Salt Lake City and Montreal, I developed a need to be able to lay a grid over a map. I messed around with a few graphics programs, but found them either fiddly and awkward to use or massive overkill. And getting the map images out of Google Earth to even start with was a pain in the rear. So I wrote something that worked the way I wanted it to.

ScreenshotGrid allows you to take any graphic that will fit on your screen, lay almost any kind of grid over it, and save the result. The resulting file can be a very useful reference to use to start creating your map in a program like Ogre Map Editor, which I found very helpful.

To start, get the map you want to use positioned on your screen, displaying the region you want at the resolution you want, in any application you want. I use this primarily with a web browser displaying a map, but it will work with any program - that's part of the beauty of it.

Then run ScreenshotGrid, and maximize it.

Click the "Capture Screenshot" menu item. ScreenshotGrid will minimize itself to get itself out of the way, take a screenshot, and then remaximize itself. A picture of the window or windows that were underneath ScreenshotGrid will now be displayed in the ScreenshotGrid window, with a hex grid overlaid upon them.

Now the fun part begins. Use the menu options to change the type of the grid (rectangular, horizontal or vertical grain hexes, etc), color of the gridlines, etc. Use the plus/minus keys to make the grid squares or hexes the right scale. Use the arrow keys to align the grid horizontally and vertically (for example to ensure that major roads go through the middle of hexes instead of along hexsides, or to ensure that streams or small rivers run along hexsides instead of through the middles of hexes).

Once you have the grid sized, colored, and aligned the way you wat, use the Save Image As.. menu option to save the underlying image with the superimposed grid as a PNG file you can use as a reference for map bashing.

I've attached a screenshot showing a typical session.

I'm open to suggestions of how to distribute this. I don't have a webpage of my own at the moment, but for now I'll email the zipped executable to anyone who requests it here or in PM. and if anyone wants to volunteer to host it, that'd be awesome.

I made this as a tool to make my life easier, and I'm hoping it simplifies other people's lives too.

P.S. It's written in Visual Studio Express 2008, using the .Net 3.5 framework, which should work in any version of Windows released since Bush's first term. If anybody is interested in how I wrote any of it, just ask! The screenshot code and self-minimizing code are neat little tricks, and the Hexagon grid code may be fairly educational.

[Yes, I know the hex grids look a little wonky at certain zoom levels. That has to do with rounding errors creeping in as you convert Sines and Cosines to integer pixel coordinates. But you can always find a zoom level that renders cleanly within 2-3 pixels of the current hex size. If I can figure out the mathematical properties that the clean rendering zoom levels have in common, I may make the plus and minus keys zoom directly to those instead of stepping up and down one pixel at a time, but for now I'm just happy the whole thing actually works.]
Attached Images
File Type: jpg Parallels Picture.jpg (108.0 KB, 249 views)

Last edited by HeatDeath; 10-10-2013 at 01:53 AM.
HeatDeath is offline   Reply With Quote
Old 10-10-2013, 08:57 AM   #2
adm
 
adm's Avatar
 
Join Date: Aug 2004
Location: MO, U.S.A.
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

This looks quite interesting, I would love a copy.

admerritt@gmail<dot>com
__________________
Xenophilia is Dr. Who. Plus Lecherous is Jack Harkness.- Anaraxes

Last edited by adm; 10-10-2013 at 10:09 AM. Reason: Add Email.
adm is online now   Reply With Quote
Old 10-10-2013, 09:26 AM   #3
GranitePenguin
Ogre Line Editor
 
GranitePenguin's Avatar
 
Join Date: Sep 2006
Location: Plainfield, IL
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

very cool, I can almost see the Ogre crushing things :-)
__________________
GranitePenguin
Ogre Line Editor
GranitePenguin is offline   Reply With Quote
Old 10-10-2013, 09:38 AM   #4
jfleisher
 
jfleisher's Avatar
 
Join Date: Aug 2004
Location: Central Ohio
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

I'd love a copy as well. You should consider www.dropbox.com for hosting it, easy and free.

My email is jfleisher (at) columbus (dot) rr (dot) com
__________________
"Think of it as Evolution in Action"... Larry Niven & Jerry Pournelle, Oath of Fealty

My Ogre Miniatures Blog: http://ogreminiatures.blogspot.com
jfleisher is offline   Reply With Quote
Old 10-10-2013, 11:42 AM   #5
shantke
 
Join Date: May 2008
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

I would take as copy as well. It looks awesome!!! shawnhantke@rushmore.com
shantke is offline   Reply With Quote
Old 10-10-2013, 10:05 PM   #6
HeatDeath
 
Join Date: May 2012
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

Ok, if you gave me your email here you should have a zipped copy of the executable in your Inbox. No installation necessary, just unzip it to wherever and run it.

I virus scanned it but you should probably do that yourselves as well.

Adm, Gmail has just informed me that they auto-block zipped executables for security purposes. Let me know another email address if you can. In the meantime I'll try to get Dropbox set up.

Thanks for the interest, everybody!
HeatDeath is offline   Reply With Quote
Old 10-10-2013, 10:18 PM   #7
HeatDeath
 
Join Date: May 2012
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

Ok gang, Screenshot Grid should be accessible on this link:

https://www.dropbox.com/sh/gwiaixxbnuvr9px/5aC5UxZ_Fh
HeatDeath is offline   Reply With Quote
Old 10-11-2013, 02:47 AM   #8
sqw
 
Join Date: Feb 2008
Location: UK
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

How brilliant - I am downloading it now :)
__________________
New rules are made for PLAYTESTING :) Get off the internet and go play
sqw is offline   Reply With Quote
Old 10-11-2013, 03:05 AM   #9
sqw
 
Join Date: Feb 2008
Location: UK
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

Some instant thoughts:

1) Would be great if you could load an image from file.

2) For your hex line up problem, two suggestions:
a) Pre-calculate the sin/cos values and hold them in an array for speed
b) You only need to calculate the top part of each hex, then the bottom lines are made by the next hex down. That should fix your line up problems.
c) Instead of (a), you could just calculate the points for a large hex, then scale them or create a PNG image of a hex and overlay it many times.

3) The lines are a little jaggy - could they be anti-aliased to clean them up? Or is the jagginess a function of the calculations?

Nice tool though, and very fast.
__________________
New rules are made for PLAYTESTING :) Get off the internet and go play
sqw is offline   Reply With Quote
Old 10-11-2013, 09:11 AM   #10
brandonm
Cybernetic Overlord, Protector of the Fairness, Ebliberator of Stealage & Grand Purveyor of Laser Cats
 
brandonm's Avatar
 
Join Date: May 2012
Location: Austin TX
Default Re: Announcement: New Map Bashing Tool - ScreenshotGrid

Quote:
To start, get the map you want to use positioned on your screen, displaying the region you want at the resolution you want, in any application you want. I use this primarily with a web browser displaying a map, but it will work with any program - that's part of the beauty of it.

Then run ScreenshotGrid, and maximize it.
I've tried this on Windows 7 and 8; maximizing ScreenshotGrid is resulting in it being added to the final image. So you get whatever is running underneath as well as the program overlaid on that, also showing the underlying material and doubling of the grid in that space.

To work around this I changed the size of ScreenshotGrid to be just the toolbar showing and positioned it in front of the browser toolbar, then when you hit capture it still shows up but not in the part of the browser showing the map.

Also, I am not seeing any underlying image when using the tool maximized. I see the grid but it is on a white background. Once I've done a capture I then double click the title bar to maximize the window and see how things turned out. I suspect it must be working differently in XP, which is what it looks like it is running in from the first post screenshot.

Quote:
Would be great if you could load an image from file.
Not sure why you would need to load a file; it looks to me that anything under the ScreenshotGrid program on your first monitor's desktop will be captured and overlaid with a grid. So you could open an image file in any program and then bring up ScreenshotGrid to get the capture.

Overall, a neat tool for anyone wanting to make custom hex maps!
__________________
Brandon McClelland
Digital Wizard
sjgames.com

Last edited by brandonm; 10-11-2013 at 09:17 AM.
brandonm is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Fnords are Off
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 12:53 PM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2024, vBulletin Solutions, Inc.