Symbols in Area

I am playing with Symbols in Area along to model different tree densities in different size polygons. I'd like to be able to establish a density so that regardless of the polygon size, the density is consistent.

If all areas are the same size, it is easy-peasy just change the number to get the effect you want. But different size polygons require different amounts to fill the polygon.

One work around is to use a set number, say 5000 symbols and reapply it until it looks like I want.

I tried a little more controlled experiment.

Test 1 shows rectangles in which the density increases from top to bottom and from left to right the rectangles are different sizes. As you can see, each rectangle gets a different number of trees drawn in it and the density in a particular row looks fairly consistent. Interestingly enough, the number of trees is never equal to the number I specify and is different in each rectangle. For this test, it was 40, 400, 1000, 2000, and 4000 trees from top to bottom. In general, I think it looks okay.

Test 2 shows polygons with the same parameters. The numbers are different than the first test, which is to be expected since the area is different, but still not putting in the numbers I put in.

Test 3 shows where I set the number of trees to 40 and applied it to each rectangle. Note all are different (which with randomness should be expected.

Test 4 shows a different map, much larger than the three tests, and more complex polygons. Each fill was the same and I specified 1000 trees. The other settings were the same as for the previous tests. Note the number of drawn trees is much, much less than 1000, the trees are larger than the other tests.

The last shot shows my settings.

I would have thought that the scale might be different because it is a different, larger map. But why are so few trees drawn? Some of the large polgyons overlap with each other instead of being one huge polygon.
«13

Comments

  • Finally, a fill done on another map, larger than tests 1 - 3, but much smaller than test 4. The settings were similar to the other tests, except this time, particular for the polygon to the right, I just repeatedly applied the Symbols in Area to the area to fill up the polygon.

    Any thoughts on why test 4 is so different?

    I wonder if it possible to specify a density per some area (in^2 or cm^2) rather than specifying the number of symbols?

    Thanks
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    edited February 2020
    The way that fill with symbols works is to define a grid over the item to be filled and to try to place a symbol at every defined point on that grid. The size of the grid is determined from the item's rectangular bounding box (extents). At every potential point within the grid, the command tests if that point is within the item and only places the symbol if the item occupies that location. If you have a large item and a finely-spaced grid, it would be possible to place far more symbols than CC3+ can handle if it weren't for that "Max Symbols To Place" item, which limits the total number of symbols that a single command will place.

    The "Random" placement type follows exactly the same logic, except that the candidate point is positioned randomly within the grid area instead of exactly on the grid point. After the candidate position is chosen, the position is tested for validity and discarded if not valid. What that means is that you may have specified "1000" max symbols and a "random" layout pattern, but you may get far less than that number of symbols if your polygon has a complex shape with multiple holes. This behavior is pure programmer laziness, allowing the same loop to operate for all cases and not requiring a special loop for random placement.

    It's not possible to directly specify a density of symbols. The grid distance should get you that sort of thing, though. You can get something similar to that idea by using a pattern where the random HV distance is similar to grid HV distance. This type of layout will ensure that the overall density is roughly that of your grid, but the randomness will hide the actual grid value.

    If your heart is truly set on having random placement and you want a minimum distance between symbols (that is, something like "no closer than 5 meters", consider using the Minimum Distance feature of fill with symbols. During the symbol placement phase of the operation, the command makes a check to ensure that no already-placed symbols are closer than the specified distance before it drops a symbol (if there isn't a good place, it will discard the candidate symbol). It only checks against already-placed symbols rather than all symbols on the map, unfortunately.
  • edited February 2020
    Thanks. I found that fill with symbols only seems to work with a specific set and I was not able to get it to use the Symbols from CA149 Castles.

    On the large map, setting HV/DV to be the same as the random distances had a small effect, but not enough for what I wanted to do. Changing the scaling factor to 5, setting minimum distance to 0 and smoothing from 0.5 to 0.05 increased the number of trees drawn, as seen below.

    That being said, I guess for my smaller maps which take up a space of <=10 sq km, the way I did it will be good enough and I can just fiddle with it. Certainly it is better than placing every tree individually or perhaps making a group of them and copy/pasting them individually.

    For larger maps, passed on scales of 1:50000 to 1:250000 maps individual trees are not particularly needed and I can indicated density with color or transparency.
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    It's odd that the command wouldn't work with a symbol catalog. Clicking the Browse button on the SYMFILL dialog and picking the desired catalog (*.fsc file) should load the catalog into the preview list. You should also be able to select multiple items to treat with a single command. That way, you could do a light sprinkling over all of the light forests in an area, then go back over polygons with heavier forests and do the SYMFILL again to add density.
  • Well, I'm probably doing something wrong.

    Here's the steps.

    1. Select Draw|Fill with Symbols.
    2. Select Browse. within the Profantasy Directory it goes to Profantasy/CC3Plus/System/Fillers and a list of FSCs is displayed.
    3. Navigate to Profantasy/CC3Plus/Symbols/Castles/CA149 Vegetation.fsc and push open.
    4. Program returns to Fill with Symbols and the FSC is displayed at top, but nothing has changed in the display of symbols.
    5. Select Load. Program returns to Profantasy/CC3Plus/System/Fillers and displays a list of symbols ending in FIL. There is another directory named annual and more are shown, but not from CA149.
    6. Navigate to Profantasy/CC3Plus/Symbols/Castles and note only directories are displayed. selecting other directories also shows nothing.

    The symbols that are displayed in Symbols in Area all appear to be *.PNG while the symbols loaded with Fill with Symbols all end in *.FIL.

    I took screen shots, but I think the steps are clear.
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    That does indeed look like the correct steps. The list of symbols on the SYMFILL dialog should change to those in the symbol catalog during step 4. If it's not changing, there's something not quite right with the symbol catalog. I don't have that catalog to check what's going wrong, though.
  • LoopysueLoopysue ProFantasy 🖼️ 40 images Cartographer
    Oh it's probably my fault again. That's one of my annuals - Beaumaris Castle. Thought the trees looked kind of familiar. Has anyone let Ralf know yet?
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    It's hard to say what might be happening. The underlying code should be the same, but it's probably just different enough that it's causing problems in this case. I'm glad that users are taking time to report the issues, because that gets things fixed.
  • Sue,

    It's not just that catalog. The only symbols that appear to show, at least in my experience, are those in the System folder. If you look in the browse input box, you see the address is preceded by an "@" sign.

    I have also noticed that not all symbols in a catalog show up when you search for a *.png. For example, the symbols in Profantasy/CC3Plus/Symbols/Modern/Overland/Overland.FSC are not displayed during a search. They look like this:
  • @jslayton: My day job for the last 20 years was to assist in the development of US Army battle Simulations and then test the bejesus out of them. I still have PTRs out that have not been fixed that people would call me up and ask about. I also playtested a lot of computer games, starting with Harpoon, in which the initial instructions were see if you can get this to run. If so, tell us how. Then see if you can break it. Then tell us how. It was loads of fun.

    Now I am retired and work on my own boardgames.
  • LoopysueLoopysue ProFantasy 🖼️ 40 images Cartographer
    Those symbols that don't show up are probably vector symbols. Vector symbols are saved in the catalogue as part of the catalogue file, and never occur as png files.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Looking at this thread, it looks like people (and the CC3+ command names) seem to confuse each other.


    - The SYMFILL command which Joe talks about is the command for Symbols in Area, NOT Fill with symbol (That's the FOREST command).
    - *.FIL files aren't symbols, they're just saved settings for the Fill with Symbols command. The Load button in the Fill with Symbols dialog is not how you select a symbol catalog, that is done via the browse button at the top. These .fil files only exists for a few predefined settings, and does not cover every symbol catalog out there. You can make your own .fil files if you need to, just hit save in the dialog after setting things up as you want them.
    - For Fill with symbols, browsing to a new catalog isn't supposed to change the list under symbol name. Those are not the symbols in the catalog, they are the symbols that have been picked for use with the command. Click the ... button to pick a symbol from the catalog you selected with browse for any given spot in the list.
    - Sue's right regarding the "missing" symbols, they are indeed vector symbols.
    - Sue, there's nothing wrong with your catalog (as far as I can tell)
  • Thanks for clearing that up. I was right when I said I was doing something wrong. :)
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    edited February 2020
    I should try to use the menus more, but it's probably not going to happen soon. It looks like I definitely misread your step 1 on the list. Sorry about the confusion.
  • Bad interface. Don’t give the user a choice you don’t want him to make.
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    It's probably less that the GUI is bad and more that I tend to use the command-line operations. I often forget that there are similar-sounding things on the menu that aren't similar-sounding at all from the command-line. Certainly, I used the wrong term in my original response (I used "fill with symbols" rather than "symbols in area" - the two commands share implementation details internally and the top-level implementation detail is named "FillWithSymbols", which didn't help my feeble old brain).

    The FOREST command is for filling things with a hierarchy of symbols that is designed to minimize the number of symbols, while SYMFILL is a generalization of the ESC command to two dimensions and fills things with symbols from a symbol catalog without regards to hierarchy (but allowing random selection, variable alignment, scaling, and so on). FOREST is the original filler command, while SYMFILL is a relatively recent addition. I normally don't encounter FOREST directly (it's usually part of a drawing tool done by someone else), while I'm much more likely to see the SYMFILL GUI.

    Each of the commands has a very distinct niche and they can get significantly different results.
  • Here lately I have had my program hang when doing symbols in area. Am I needing to reinstall or is it because of my symbols? After church I can show an example of the settings.
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    Symbols in Area can take a long time to process if you're depositing many symbols. A quick check to see if it's hanging is to reduce the Max Symbols to Place value to something like 100 or smaller. If it completes within a few minutes, then it's just taking a long time for the normal operation. The most likely cause of slow insertion is symbols composed of many entities. If it's hanging, then things get a bit more complex.
  • Thanks for the suggestion. It turns out that that is the issue. Carrying on with this. Is there a tutorial or article that discusses how to place a symbol in area around a symbols fill to give that appears of moving from heavily contested to thinly congested? Like with woods or brush.
  • jslaytonjslayton Moderator, ProFantasy Mapmaker
    edited February 2020
    One way to get that effect would be to do something like contours and fill each contour individually followed by SYMSORT. The CONTOURSM command is a quick way to generate contours within a shape if you just want density proportional to distance from edge.
    Drawing the contours by hand would get you more organic shapes.
  • I have been looking at the PDF for 156A and a bit confused on the Fill an Area compared to the Fill along. In the example which is fill along for the sea cliffs it has the final step being saving as an .esc. When I looked at the orchard drawing tool the macro for it also shows a .esc file being referenced. However, I only see the fill area dialog allowing .fillsym in the save option and not .esc. Am I missing something here.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    edited February 2020
    .esc files are created using the Symbols Along dialog (ESC). This is a separate command from Symbols in Area.
  • Interesting. This is a snip of the orchard drawing tool from the CA156A bonus download. It is a symbols in area but has an esc executable in the macro command.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    I think that particular tool is broken. the CC3_Orchard.esc file doesn't exist, but CC3_Orchard.symfill does. I am guessing Ralf just was a bit to quick when he made this macro.
  • So, if I use symfill in the macro it should work? I hope.
  • MonsenMonsen Administrator 🖼️ 81 images Cartographer
    Yes, but it shouldn't use the ESCLOAD and ESCM commands either, those are linked to symbols along.
  • I’ll have to look at one of the other examples from the 156A expansion and see what was used.
  • RalfRalf Administrator, ProFantasy 🖼️ 18 images Mapmaker
    Yes, the macro for this tool should be the following:

    ESCLOAD @System/Fillers/CC3_Orchard.symfill
    SELSAVE
    SELBYP
    SYMFILLM
    SELREST

    You might also want to load the fill setting CC3_Orchard.symfill (Draw > Symbols in Area) and check that it has the correct symbol selected ("Decid Tree fruit n").
Sign In or Register to comment.