Follow-up Comment #14, patch #7667 (project freeciv): > this is quite performance critical code The code path you're talking about is the rendering of the selected tile in the editor dialog (3 calls). I don't think it's critical enough to deserve the additional complexity.
>> log_error("%s ", mapview_layer_name(t->layer_order[i])); > Accidentally included debugging code? Hum... yes > Some compilers needs tileset_layer_in_category() to return false after the switch. Out of curiosity: which ones? MSVC? Older GCC? > Documentation Done, quoted below. Hopefully it will be more useful than just explaining the option... ; The map is rendered in "layers", just like any decent image editor ; supports. The setting below allows to change the layer drawing order. The ; first layer in the list will be drawn below the others; the second on top ; of it, and so on. No layer can be omitted from the list, nor can new ones ; be added. ;layer_order = ; "Background", ; Background color (if enabled, the player color where there ; ; are units or cities). You probably want to leave this ; ; first. ; "Terrain1", ; The three terrain layers. See sections [layerN] below. ; "Terrain2", ; "Terrain3", ; "Water", ; All extras with "River" style. ; "Roads", ; All extras with style "RoadAllSeparate", ; ; "RoadParityCombined" or "RoadAllCombined". ; "Special1", ; 1st layer for extras with style "3Layers", "Single2" or ; ; "Single1". ; "Grid1", ; Grid layer for isometric tilesets. ; "City1", ; City and walls. ; "Special2", ; 2nd layer for extras with "3Layers" and "Single2" styles. ; "Fog", ; Fog of war (on tiles one knows but doesn't see). ; "Unit", ; Units except the selected one(s). ; "Special3", ; 3rd layer for extras with "3Layers" style, and base flags. ; "City2", ; City size when the city bar is disabled. ; "Grid2", ; Second grid layer (overhead tilesets only). ; "Overlays", ; Tile output sprites. ; "TileLabel", ; Tile labels ("Scorched spot"). ; "CityBar", ; The city bar with name, production, food, ... ; "FocusUnit", ; The focused unit(s). ; "Goto", ; Goto turn count and intermediate points, *not* goto lines. ; "WorkerTask", ; The unit task indicators ("G", "S", ...). ; "Editor" ; Editor stuff (selected tile and start points). Btw some tilesets have DOS end of lines (alio, hexemplio, toonhex). (file #28626) _______________________________________________________ Additional Item Attachment: File name: client-configure-layer-order-3.patch.bz2 Size:5 KB _______________________________________________________ Reply to this item at: <http://gna.org/patch/?7667> _______________________________________________ Message posté via/par Gna! http://gna.org/ _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev