Jump to content

Map previews - how to generate?


Recommended Posts

Hi,

I am curious to know how these map previews are rendered / generated.  Is there a special camera setup or are these done completely manual by hand?  Atlas? For example could someone generate one of these from a random generated map somehow?  Thanks.

- I was thinking Atlas but you can't seem to set the # of players to 0 to capture the entire map w/o territory like the attached.

archipelago.png

  • Like 1
Link to comment
Share on other sites

Interesting, thanks.  I found an earlier thread of mine in regards to dumping video replays and I have an idea of how this could be done (possibly) programmatically by placing the camera (via command line argument), grabbing the frame, and exiting.  

I am realizing now after looking at https://wildfiregames.com/forum/uploads/monthly_2016_03/golden_island.jpg.c2d49d25456c383d3f990527ef838c5d.jpg that the territories are in fact there since you can see the civic centers.  It would be nice to see a Maps page on play0ad.com at some point since there are so many now.  If I get anywhere with the automation of it I will post back.

Link to comment
Share on other sites

It would be nice to have better camera controll in Atlas e.g. setting the camera for a full map view straight down.

That also could be done for a default map preview. That could also include generating a screenshot and exporting it in a format usable as mappreview.

Would definitely be nice to have.

(I wonder though if that axcess in space in the mappreviews is more a hack than sane ;p

Yes, the vidget size might change but then it'd be preferable to automatically resample/cut a given mappreview to fit that widget...)

Link to comment
Share on other sites

  • The main reason to have a tool to take those screenshots is not because it's easier to use, but because it could enforce a standard format.
  • 400 x 300 px² are used, but the image size must be 512x512 px²
  • The preview image should show the entire map (see Red Sea preview image) and use as much of the screenspace as possible (well picked inclination)
  • Some maps might look better with size normal, others better with size large. The used pixels of the resulting image should remain identical.
  • Like 2
Link to comment
Share on other sites

I made a little progress ... I was toying around with the Misc Hacks menu + w/ the Reset Camera option + was able to set the camera to center map, rotate 45, zoom out + WriteScreenshot() ... the one thing I can't figure out is how to set g_EnvironmentSettings.fogfactor to 0 (to remove from the screenshot on some maps) ... I think as a hack I would need to do this work + then set that back and then reset the camera again (for example if there was a button that said Generate Preview, etc).

I tried a straight 90 degree down on the camera but I don't think it picks up the height of the map that well.  It would great to figure out not just a standard preview image but also to generate a standard cinematic preview somehow :-\

screenshot0004.png

screenshot0006.png

Edited by jonbaer
  • Like 3
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...