Hex Map Larger and a Different File Format?

I ran into a new issue yesterday. This may be a known problem, but it's one I've never encountered before (possibly because I never added a hex grid to a map).

I created a map and exported it. Then yesterday I added a hex grid to the same map. Adding the hex grid (and changing the order of sheets a little) was the ONLY change I made to the map. I then exported it, using the EXACT same settings as before. It came out about one-third physically larger than the original in each dimension (by which I mean it went from a little under 7000 pixels wide to over 9000 pixels wide) and it also exported as a BMP rather than a PNG - meaning it was almost four times as large in terms of memory usage! I triple-checked, and I told it to export as a PNG.

Does anyone have an explanation for this? I've never encountered this issue before - the maps always came out the exact number of pixels I entered into the export options, in the exact file format I entered. Is this a known quirk with hex grid maps? Is there something I need to do to compensate for it?

ETA: I exported the non-hex version of the map several months ago. Could this maybe be a change caused by the latest update?
«1

Comments

  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Is the file named YourFilename.PNG.BMP ?
    Did you export with anti-aliasing on?

    If both those are true, what happened is that imagemagick failed to do the final conversion of the file. CC3+ always exports the file as a .bmp, and lets ImageMagick do the final conversion. Likewise, if antialiasing is on, the file is exported larger than the values specified (exact size dependant on antialiasing settings), and the image is then reduced to the correct size as part of the antialiasing process.
    However, if ImageMagick fails for some reason (usually memory issues), this proces doesn't take place, and you'll be left with the raw export from CC3+ in BMP format.
  • Yeah, it looks like you identified the exact problem. Thanks!

    When you say "memory issues" - would it likely be with my computer, or the program itself?
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    It is a case of ImageMagick running out of memory when processing the bitmap. Like CC3+ itself, the version of imagemagick that ships with it is also 32-bit, so it is limited to 2GB (or 4 if it is LAA, not sure).

    This SHOULD be fixed with the latest CC3+ update, since it does pass some parameters to imagemagick to have it limit memory usage to avoid this exact situation, which seems to work for me at least.

    I do recommend you restart your computer before trying again, just to clean up memory and make sure as much as possible is available.
  • Just FYI, I tried exporting the non-hex version of the map, which I successfully exported back in May. (Before I did this, I reinstalled the latest update and restarted my computer.) The map came out borked exactly the same as the hexed version: too large and still a BMP. So either something has gone wrong with my computer since May, or one of the updates since then created a problem rather than fixing one!
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    edited January 2018
    What happens if you export the map at a significantly lower resolution? Same problem, or does it work then?

    And you are running CC3+ V.3.80 right?
  • I'll try it and see.

    Yes, it is CC3+ V.3.80.
  • Let me ask this: did CC3+ always default to 96 dpi, or was this increased in one of the recent updates? I never paid attention to it before. Maybe that's the problem.
  • You can set your output. Once you 'Save As' a graphic type such as jpg, png, or bmp; look to the lower left of the Save As popup and open Options.
  • Right, but I'm trying to figure out what might have changed since May that is causing my maps to come out borked. Do you happen to remember if it always defaulted to 96 dpi?
  • I reduced the image dpi from 96 to 48 and got pretty much the same result as before. This is the error message being displayed at the end of the export box: "-limit memory 256 mb -limit map 512 mb -monitor -units PixelsPerInch (my file name) resize 7251x5436 -filter Bartlett -density 48 (my file name)"

    I would uninstall the last update, to see if that's the problem, except it doesn't show up on my "Programs and Files" list. To get rid of it, I would have to uninstall everything and reinstall (I still have updates 10 and 12). The prospect of doing that has got me pretty grouchy. This was a map that exported just fine a few months ago.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    edited January 2018
    Posted By: Blackadder23I reduced the image dpi from 96 to 48 and got pretty much the same result as before.
    Sorry, I should have been more clear when I said lowering the resolution, as that can mean two different things, but I wanted you to try lowering the actual pixel size of the image, for example halving both height and width, thus exporting a smaller image, just to see if the behavior changes.

    Posted By: Blackadder23-limit memory 256 mb -limit map 512 mb -monitor -units PixelsPerInch (my file name) resize 7251x5436 -filter Bartlett -density 48 (my file name)
    Doesn't anything appear after this message? This is the command line being sendt to imagemagick, and after this line, it would typically report the progress on various tasks, like loading and resizing the image. Normally, the export should continue working on the process for some time after diplaying this line.
    Posted By: Blackadder23I would uninstall the last update, to see if that's the problem
    Updates can't be uninstalled. They have replaced vital files in your CC3+ directory, so uninstalling an update would remove these files and cause CC3+ to stop working because it would be missing it's files. Uninstalling something under Windows doesn't mean to put things back that was there before, just to remove what was put in.
  • Nothing appears after the lines I quoted. The exporting process just freezes, leaving me with a bit map file as I described before. I tried waiting quite a while, but it stayed frozen. Needless to say, this never happened before (I watched the exporting process more than once in the past, and I never even saw the message I'm quoting).

    I will try a smaller export.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Posted By: Blackadder23and I never even saw the message I'm quoting
    The message is new with 3.80, it is just an informative message to see what is going on.
    Nothing appears after the lines I quoted. The exporting process just freezes
    Sounds like it may have problems starting imagemagick or something. If you look at my attached screenshot, you see how it is supposed to look during the export. Right now, I am wondering if either ImageMagick is still working in the background, just not displaying progress, or if it really hung. You said you tried waiting for quite a while, how long is that? Depending on a lot of factors, the final part of the process (after it shows the command line) can easily take up to 20 minutes on some systems (or more for a low hdd or very large export). I am wondering if it is perhaps working in the background, because normally when this process fails, it just exists immediately, the export window doesn't stay on screen. Exporting using a smaller resolution should partially answer that.
  • I'm getting a similar error, anti-alias is off. I tried a map I worked on yesterday with no problem. Same error.

    It looks like even though I have turned off Defender, its still messing with things, and thats the problem. I have better anti-virus software.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Posted By: JimPI'm getting a similar error, anti-alias is off.
    With simialr error, do you mean you experience the same as BlackAdder23, i.e. that exports don't complete properly, and you end up with a .bmp file (instead of a .png)?
  • it doesn't complete. Then I get a popup from Defender that tells me my computer is protected. I dislike stupid software.

    It does leave a filename.png.bmp. 1200 pixels wide.

    I can convert it to png using Irfanview. Its only done this today.
  • Odd. It suddenly started working.

    I did do a reboot, and it didn't work, then it started working correctly.

    I probably need a way to delete or make helpless Defender.
  • I found a means to do so.

    Use at your own risk. These tenforums are run by people who are far more expert at Windows than I am.

    https://www.tenforums.com/tutorials/3569-turn-off-windows-defender-real-time-protection-windows-10-a.html
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Out of curiosity, have any of you enabled the new 'Protected Folders' feature in Windows defender? This allows access based on a predefined program whitelist, so I am just wonder if there may be blocking access from the ImageMagick executable:
  • No, as I turned Defender off months ago. So I have no idea why it thinks it needs to do anything. New definitions were downloaded today, which is likely the problem.

    My trust of MS has dropped almost to zero.
  • Okay, I tried exporting it at half size, and initially it appeared to freeze on that same message exactly as before. However! I left it alone for a while and it apparently it finished when I wasn't looking. The result was a proper PNG of the designated size.

    Now I'm going to try to export a full size version again, and leave it overnight (if necessary) to see if it ever completes.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Interesting. That indicates that it seems to be working fine, just that you don't see the status messages from ImageMagick for some reason. We'll still need to see the result of your full export before coming to any conclusion, but if that goes through, it seems to be just a display issue.
  • Blackadder23Blackadder23 Traveler
    edited January 2018
    Maybe it's because I'm running Windows 7? I actually see a black box with white writing, rather than what you posted above.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Yea, mine is also normally black, that screenshot was for my work computer, where I have reversed the colors on the command prompt because it makes it easier to read on a projector in the classroom. The colors in that window follow the default command prompt colors in windows, so you can make it what you want.
  • I'm wondering if the change is caused by the recent security update for the Spectre and Meltdown vulnerabilities. Older machines are reported to have a bigger slowdown for certain types of operations.
  • It took 45 minutes just for the last, "converting" step... but the map did eventually export at full size. It appears identical to the copy I exported in May.

    Now to try the hexed version (although I see no reason to believe it will be any different).
  • The hexed version exported as well, taking about the same amount of time. So the takeaway is to be prepared to wait some time for the final step of the exporting sequence. The time it took to export the non-hex version was almost double what it used to be. Hopefully there is some compensating advantage to the new setup.

    Anyway, thanks for your help.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    The export times are longer than they used to be, true, but it also allowed CC3+ to export larger images than before. It is possible to improve the speed by replacing the version of imagemagick shipped with CC3+ with a 64-bit version instead, and then change the command line to remove the memory limits. You can also change the command line to change the filter used by by ImageMagick for the resizing (for antialiasing purposes), this will allow you to sacrifice quality for speed. All that is a little technical though, and requires manual editing of CC3+'s config file, so give me a word if you want to attempt that, and I'll post some instructions.
  • I appreciate the offer, but I definitely don't want to sacrifice quality. I just need to remember to start the export and leave it for a couple of hours. :)
  • That sounds like something I'd like to do, could you post the instructions for it here?
    Posted By: MonsenThe export times are longer than they used to be, true, but it also allowed CC3+ to export larger images than before. It is possible to improve the speed by replacing the version of imagemagick shipped with CC3+ with a 64-bit version instead, and then change the command line to remove the memory limits. You can also change the command line to change the filter used by by ImageMagick for the resizing (for antialiasing purposes), this will allow you to sacrifice quality for speed. All that is a little technical though, and requires manual editing of CC3+'s config file, so give me a word if you want to attempt that, and I'll post some instructions.
Sign In or Register to comment.