Terrain Textures

Improving the artwork in Warzone2100 - not for mod discussions
i-NoD
Code contributor
Code contributor
Posts: 318
Joined: 30 Nov 2008, 00:42
Location: In the middle of nowhere

Re: Terrain Textures

Post by i-NoD »

effigy wrote:I don't see anything wrong with sample 1, but in sample 2 you've captured a place where plateaus are ambiguous.
My point was: I don't see how cliffs are exact bound if they are not. In sample one 2.3 has a sand tile on cliff's top, but in master it completely gone, are they equal?
cybersphinx
Inactive
Inactive
Posts: 1695
Joined: 01 Sep 2006, 19:17

Re: Terrain Textures

Post by cybersphinx »

2.3 has both terrain type and texture (and rotation/flipping of the texture) per tile, while the new terrain uses only the terrain type to determine the texture to use iirc.
We want information... information... information.
User avatar
effigy
Regular
Regular
Posts: 1217
Joined: 22 Jan 2010, 03:21

Re: Terrain Textures

Post by effigy »

i-NoD wrote:
effigy wrote:I don't see anything wrong with sample 1, but in sample 2 you've captured a place where plateaus are ambiguous.
My point was: I don't see how cliffs are exact bound if they are not. In sample one 2.3 has a sand tile on cliff's top, but in master it completely gone, are they equal?
I see.. and that looks like 2 tiles wide in 2.3? That is an issue, imo. I've seen this in some maps with nice looking terrain. It's a problem for users of transports: you find out you can land by accident/experimenting.
This is why some features aren't implemented: http://forums.wz2100.net/viewtopic.php?f=30&t=7490&view=unread#p87241
zany
Trained
Trained
Posts: 303
Joined: 20 Sep 2011, 07:04

Re: Terrain Textures

Post by zany »

are the new textures going to be in the next beta?
User avatar
Emdek
Regular
Regular
Posts: 1329
Joined: 24 Jan 2010, 13:14
Location: Poland

Re: Terrain Textures

Post by Emdek »

zany, I really doubt. :-)
Nadszedł już czas, najwyższy czas, nienawiść zniszczyć w sobie.
The time has come, the high time, to destroy hatred in oneself.


Beware! Mad Qt Evangelist.
User avatar
Berg
Regular
Regular
Posts: 2204
Joined: 02 Sep 2007, 23:25
Location: Australia

Re: Terrain Textures

Post by Berg »

I just happen to make a new rubble texture hope you like it.
You do not have the required permissions to view the files attached to this post.
Cyp
Evitcani
Evitcani
Posts: 784
Joined: 17 Jan 2010, 23:35

Re: Terrain Textures

Post by Cyp »

Are you sure that's rubble and not stubble?
User avatar
aubergine
Professional
Professional
Posts: 3462
Joined: 10 Oct 2010, 00:58

Re: Terrain Textures

Post by aubergine »

Someone must really hate flinstones, there's several gunshot wounds to the head in that pic lol.
"Dedicated to discovering Warzone artefacts, and sharing them freely for the benefit of the community."
-- https://warzone.atlassian.net/wiki/display/GO
User avatar
Flail13
Code contributor
Code contributor
Posts: 263
Joined: 16 May 2008, 12:00

Re: Terrain Textures

Post by Flail13 »

I have another idea :oops:
this one is simpler

- split the map tiles by half in each direction (graphically only)
- make one 512x512 texture that is a more detailed transition between each of the current textures. the main problem is you need ~20 more textures per tileset
- over the halves of the tile, blend from texture[A] to transition[A,B] then to texture

which has the same effect as what I suggested before but at less cost. +20 loaded textures still too much?

for cliffs, the transition texture could be closer in appearance to the passable texture to make the cliff edges more sharp.
Jorzi
Regular
Regular
Posts: 2063
Joined: 11 Apr 2010, 00:14

Re: Terrain Textures

Post by Jorzi »

@Berg: The tiling is far too visible, needs more work. :wink:
ImageImage
-insert deep philosophical statement here-
Per
Warzone 2100 Team Member
Warzone 2100 Team Member
Posts: 3780
Joined: 03 Aug 2006, 19:39

Re: Terrain Textures

Post by Per »

For what it is worth, this is an older explanation of my plans for the terrain renderer. This work was begun in the 'newterrain' branch, starting with converting the old data into a more appropriate format for such rendering, but put on hold until javascript porting and 3.1 release work is completed. The mentioned modding improvements have been addressed in the branch, but very little documentation exists yet. I'd be happy to discuss the details of this plan, if someone wants to work on it.
The current map renderer has some painful issues with transitions that
blend badly or get wrong geometry. This is due to the way the blending
is done by shifting tiles instead of doing proper splatting. Now,
different solutions will have different limitations. I would like to
design a solution that does not need shaders (see more on shaders
below), and can work on worse graphics hardware. I would also like to
make code that is maintainable and clean. The first point of order in
that regard is to fix up the map format, so that conversions are done
once in an external tool. I am currently working on this. The idea is
to keep height and terrain type in 8 bit grayscale PNGs, and decal
info in an INI file. The heightmap is expanded to four points, of
which we use two (upper left pixel as upper left height, and lower
right pixel as center height) for now. The current terrain type is
split into a terrain type (8 bit value) and an optional decal entry.
The rotation and flipping is ignored for terrain, while rotation is
kept for decals.

Each terrain square is thought rendered as four triangles. We will be
needing hardware support for 4 texture units and multitexturing.
Terrain will be drawn in one pass. Two texture units will be loaded
with packed terrain textures, and one with a variety of packed
blending masks. (I am unsure if the choice of blending mask should be
left to the map editor and saved as PNG of its own, or whether this
should be generated automatically on load. We may want to use some
pseudo-random variety in blending masks here.) For each triangle we
calculate texture coordinates that blend a 'native' terrain with an
'opposing' terrain (the terrain 'native' to whichever tile the
triangle faces) using one of the blending masks. If the 'opposing'
terrain is identical to the 'native' terrain, we just use null
coordinates. For decals, I would like to pack the decals, as well, but
in as many pages as we need to support any number of decals. If we
have more decals than we have available texture units, we just add
more draw passes. I think we should offer the user a choice of 512x512
and 256x256 texture sizes for terrain, the lower size for people with
worse GPUs, and I think that will be more than large enough at the
zoom distances that people will play the game. This leaves us with a
hard-coded limitation of max 16 base terrain textures for each
tileset, 64 blending masks (since they are triangles), and any number
of decals. I think this will be quite enough. Adding variety to maps
should in any case be done by adding decals, while the number of base
terrain types should be kept low (for aesthetic consistency reasons).

The current master map rendering framework is quite difficult to mod.
I want to change this as well, to make it very easy to add new
tilesets and bundle them with maps, while reusing any existing
textures as desired. (I do not have my notes for this available, so I
will have to add those details to the plan later.) The textures will
be stored as individual files, as now, not as texture pages, to allow
easy re-mapping and re-paging.
User avatar
Emdek
Regular
Regular
Posts: 1329
Joined: 24 Jan 2010, 13:14
Location: Poland

Re: Terrain Textures

Post by Emdek »

I liked idea of bitmap use since I've seen it in that ticket (#652). :-)
Nadszedł już czas, najwyższy czas, nienawiść zniszczyć w sobie.
The time has come, the high time, to destroy hatred in oneself.


Beware! Mad Qt Evangelist.
User avatar
Flail13
Code contributor
Code contributor
Posts: 263
Joined: 16 May 2008, 12:00

Re: Terrain Textures

Post by Flail13 »

Per, it's good to know there are plans to get to it evetually. While the file format is being covered, is there a plan of *how* to improve the terrain?

If anyone is interested in the difference between 16 triangles and 4, this is something I tested in FlaME, compared with current.
You do not have the required permissions to view the files attached to this post.
User avatar
Emdek
Regular
Regular
Posts: 1329
Joined: 24 Jan 2010, 13:14
Location: Poland

Re: Terrain Textures

Post by Emdek »

Flail13, better, but still not perfect (I'm sure that special meshes in form of shipped features could be solution for "perfect" ones ;-)).
Nadszedł już czas, najwyższy czas, nienawiść zniszczyć w sobie.
The time has come, the high time, to destroy hatred in oneself.


Beware! Mad Qt Evangelist.
User avatar
Flail13
Code contributor
Code contributor
Posts: 263
Joined: 16 May 2008, 12:00

Re: Terrain Textures

Post by Flail13 »

Is there info somewhere on how that will work?