Updated Mapping System

Updated Mapping System

Requests for features in the spring code.

Moderator: Moderators

User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Updated Mapping System

Post by Forboding Angel »

Spring's SMF map system is pretty old at this point, and fairly inefficient. SSMF updates and smoth and jk's work have more or less extended the life of smf maps (Either that or raised the bar of entry high enough so that few people really try anymore).

Perhaps it's a good time to start thinking of a newer mapping system?

The big problem is that stuff like this isn't grown over the course of a day or a couple of months and requires a terrifying amount of work, but isn't putting it off at this point simply delaying the inevitable?

SM3 showed a lot of promise, but had a lot of ... eh, design flaws? But the idea seemed quite solid.

This doesn't really belong in feature requests, as it's not really a request, more of a talking point, but whatever.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: Updated Mapping System

Post by SinbadEV »

I think the "simplest" solution would be:

Texture/Tiles as images (alpha for transparency or blending)

Lua script to place/set everything including Textures/Tile locations, Heights, Trees, Geos, Metal, Grass, Features, Details, Starting Locations etc.with support for using [some raw bitmap format] for getting values.
User avatar
Jools
XTA Developer
Posts: 2816
Joined: 23 Feb 2009, 16:29

Re: Updated Mapping System

Post by Jools »

What's wrong with SMF? Other than the age? Old whisky is usually not much worse than new one so simply the age cannot be the argument...
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

no real support for rigid geomitry patches, no ability to simply apply my own tiles over an area, the splat maps, normal maps and specular maps have issues when they are not power of two.

Inbefore use a unit or feature.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: Updated Mapping System

Post by SinbadEV »

If we are playing wish-list you could have force passed as a ray traced vector and allow the map's Lua script handle deformation.
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10454
Joined: 24 Jan 2006, 21:12

Re: Updated Mapping System

Post by PicassoCT »

I have to admit, the real interesting thing to me there, is the lowest possible entrance barrier.

So what tools does a newcomer have?
What programs can be used online, without a big introduction?

And no - texteditors dont count as low entry curve. Normal people open textfiles, look at stuff and then discouraged close them again, because they fear they will break something.

I actually have no good approach on this..
Maybe that in 3d terraineditor, with a postprocessing in some paint.

or a

Google Sketchup importer and auto-texturer, that adds a heightmaptexture

or a

way to glue it together from pre-built pieces.

The trouble by now is, that i look at this from a way more diffrent perspective than a beginner. My view is compromised. I admit that. Hell even the original mapconverter asked for user to snort a comandline up there nose. (batchediting is opening a texteditor)

On the other hand, nobody is willing to re-write a map-format from scratch + the tools.
So approach should be incremental improvement of the ways newcomers get to make ssfm maps.
1. One mapeditor goes along with the engine. No ifs, no buts, its a seperate executable for windows and works.
Also no linking to some third party software no matter how good it is. Or because your uncle runs that company. I would stop searching the moment someone links me to some comercial frontpage for what-do-i-know, that never even mentions spring.

2. It is reachable via the lobby- and so are tutorials. One click to get there.

3. The editor has a inbuilt irc-chat, that pumps questions directly into moddev or some other channel and answers back.

4.It comes with a preset of material textures for smf too chose from. And is able to preview the results of these applied.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

SinbadEV wrote: Lua script handle deformation.
you could at least know we can handle deformation.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: Updated Mapping System

Post by SinbadEV »

smoth wrote:
SinbadEV wrote: Lua script handle deformation.
you could at least know we can handle deformation.
I was thinking about mesh based terrain being affected by the same deformation mechanism as the current terrain.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

no
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: Updated Mapping System

Post by enetheru »

Forboding Angel wrote:Spring's SMF map system is pretty old at this point, and fairly inefficient.
What are the inefficiencies? I'm not saying your wrong, but I would like to see some data on this.
Forboding Angel wrote:Perhaps it's a good time to start thinking of a newer mapping system?
New for the sake of new isn't really a useful direction. What are the problems you want to solve? what are the features you want to see?
SinbadEV wrote:Texture/Tiles as images (alpha for transparency or blending)
what in your opinion is the tangible benefits of a tile based map method in terms of performance, code complexity, supported tools, artistic expression?
SinbadEV wrote:Lua script to place/set everything including Textures/Tile locations, Heights, Trees, Geos, Metal, Grass, Features, Details, Starting Locations etc.with support for using [some raw bitmap format] for getting values.
This one is doable in short order
Jools wrote:What's wrong with SMF? Other than the age? Old whisky is usually not much worse than new one so simply the age cannot be the argument...
Custom file format which is half redundant because of lua. requires poorly supported custom tools. Hard for new users to come to grips with its idiosyncrasies.

Or if you are talking about the engine side of things, age, flexibility.
PicassoCT wrote:And no - texteditors dont count as low entry curve. Normal people open textfiles, look at stuff and then discouraged close them again, because they fear they will break something.
I completely disagree with this, but I also agree that a GUI tool is easier to use. the problem is code development and maintenance.

I know people here have a irrational hatred of blender but this is what an enterprising person could do with it, basically a complete re-work of the interface for a specific use case.
http://www.blendernation.com/2014/08/30 ... available/

IMHO:
Does the pathfinding part of the engine use the ROAM mesh?

What I would like to see now:
* Full support for SMF features in lua. Remove the dependency on the custom file format, kill off smf and smt file formats.

Wishlist
* Normal map defining gravity
* Separate ROAM terrain for water
* Shaders for terrain, map objects and water defined in map scripts
* Custom mesh terrain
* Custom mesh water
* Voxel based mesh terrain
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7052
Joined: 16 Nov 2004, 13:08

Re: Updated Mapping System

Post by zwzsg »

Wishtlist:
- A lua hook to swap the minimap picture with my own picture (that doesn't involve reimplementing the entire minimap mechanic).
- A lua hook to disable the unsynced view of the terrain deformation. Or to force updating it despite fog of war.

The rest I can do with the existing Lua.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Updated Mapping System

Post by gajop »

I'd like the ability to modify textures while still achieving the quality and relatively small (dynamic size depending on distance/GPU thing?) size default textures have.
Also smoth might've mentioned it (don't know the lingo), but would be nice to have some texture solution for high sloped terrain.
Lastly, would like to have some shader control input to how textures get rendered (actually not sure if this is doable at all when using the existing texture compression mechanism), but if possible, it could make way for a whole new series of maps.
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: Updated Mapping System

Post by enetheru »

gajop wrote:I'd like the ability to modify textures while still achieving the quality and relatively small (dynamic size depending on distance/GPU thing?) size default textures have.
Also smoth might've mentioned it (don't know the lingo), but would be nice to have some texture solution for high sloped terrain.
Lastly, would like to have some shader control input to how textures get rendered (actually not sure if this is doable at all when using the existing texture compression mechanism), but if possible, it could make way for a whole new series of maps.
so the diffuse textures are stored as 32x32 pixel tiles in the smt file using DXT1 compression, with 4 mip levels, 16x16 8x8 4x4.
On load of the map it pulls all the tiles and generates per patch the lowest MIP level, which is 128x128 pixels.

then as the LOD works it constructs the textures from the various MIP levels based on the distance from the camera or some such. with the largest size being 1024x1024.

every time the LOD changes for a ROAM patch it generates the texture for the patch, optionally does either EXT or DXT compression on it before sending it to GPU or some such( i'm not sure about the last part).

The reason the tiles are 32x32 pixels is legacy. the fact that it has to construct a new texture image every time LOD changes(not sure if it uses cached textures for this) would be a slowdown.

It looks from the code that the solution was half baked, and was intended to support different size tiles, but it never made it to completion.

I don't see a reason why the diffuse texture cant be sourced from 1024x1024 DXT images with 4 mips removing the construction phase of the pipeline(speedup). and using any method you want.

I had read and read and read the code to get an understanding because it was the goal of my little project. but I have yet to finish the mapconv stuff to build SMT's that source 1024x1024 images instead of 32x32.

High slope textures would require a deviation from the standard model, but I don't see why with some shader magic it couldn't be solved with some box or cylinder mapped textures like would be used in typical cg art.

each patch references a separate texture (generated from the tile mips) I don't think it technically difficult to replace the code with something else. I think allowing the map scripts to define the shaders would be more robust. still its all cosmetic in nature.

You would have your legacy texture pulling from SMT, and then you would override that with the LUA and whatever shaders you had.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: Updated Mapping System

Post by SinbadEV »

enetheru wrote:
SinbadEV wrote:Texture/Tiles as images (alpha for transparency or blending)
what in your opinion is the tangible benefits of a tile based map method in terms of performance, code complexity, supported tools, artistic expression?
SinbadEV wrote:Lua script to place/set everything including Textures/Tile locations, Heights, Trees, Geos, Metal, Grass, Features, Details, Starting Locations etc.with support for using [some raw bitmap format] for getting values.
This one is doable in short order
The first exists to support the second... wouldn't be useful to be able to place textures using a script unless the textures were images.

But mostly I was imagining a "traditional" RTS like Starcraft or Warcraft where the textures were tiles but then thinking it would be nice if you could have arbitrarily shaped "map chunks" that faded to alpha at the edges so they would blend with the layer below or simply be transparent so that we could have the "holes in the map" effect from Starcraft space platforms.

I was also thinking about the good old TA map editor where you could just place tiles and make a map using a collection of assets.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

gajop wrote:Also smoth might've mentioned it (don't know the lingo), but would be nice to have some texture solution for high sloped terrain.
I'd rather use 3d modeled tiles that I could plonk down as part of a map. That way they can be shared with the community as doing good ones would be quite an effort.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: Updated Mapping System

Post by SinbadEV »

smoth wrote:
gajop wrote:Also smoth might've mentioned it (don't know the lingo), but would be nice to have some texture solution for high sloped terrain.
I'd rather use 3d modeled tiles that I could plonk down as part of a map. That way they can be shared with the community as doing good ones would be quite an effort.
Like "put a 3D thing here" in the map format that isn't a feature or a unit... kinda a bit like how grass is told where to be drawn but isn't actually a "thing" it's just "something the map draws".

I like it.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

not so much that just some games use this sort of tile stitching to make their worlds.
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: Updated Mapping System

Post by enetheru »

smoth wrote:I'd rather use 3d modeled tiles that I could plonk down as part of a map. That way they can be shared with the community as doing good ones would be quite an effort.
This can be done already, but poorly.
there are a couple of areas I would want to fix to make this properly
* shading match with the terrain
* LOD limitations for surrounding mesh objects, and draw distance.

With some transparency on the map itself, you can make overhanging cliffs and pseudo caves with this method.

I really need to know how the pathfinding works, if it uses the ROAM mesh then things are difficult.
Decoupling it to use a navigation mesh would allow separation of the terrain mesh from the pathfinding, then 'real' mesh terrain objects would be possible.
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Updated Mapping System

Post by smoth »

Inbefore use a unit or feature.
User avatar
enetheru
Posts: 627
Joined: 11 Jun 2010, 07:32

Re: Updated Mapping System

Post by enetheru »

Another feature request which might be of interest to AI devs is for a gaia AI for various fauna and flora.
smoth wrote:
Inbefore use a unit or feature.
yeah its ugly, Ideally there would be a new category of meshes being terrain mesh.

I've never really understood why there are different systems for units vs features vs buildings etc etc.
Post Reply

Return to “Feature Requests”