Terrain Textures
-
MaNGusT
- Art contributor
- Posts: 1154
- Joined: 22 Sep 2006, 10:31
- Location: Russia
-
Emdek
- Regular

- Posts: 1329
- Joined: 24 Jan 2010, 13:14
- Location: Poland
Re: Terrain Textures
MaNGusT, now find someone to volunteer to write OpenGL 4 renderer (or at least someone to make rendering more abstract). 
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.
The time has come, the high time, to destroy hatred in oneself.
Beware! Mad Qt Evangelist.
-
Flail13
- Code contributor

- Posts: 263
- Joined: 16 May 2008, 12:00
Re: Terrain Textures
how difficult would it be to use per-tile alpha masks on the texture blending?
for example this: could be something like this:
for example this: could be something like this:
You do not have the required permissions to view the files attached to this post.
-
MaNGusT
- Art contributor
- Posts: 1154
- Joined: 22 Sep 2006, 10:31
- Location: Russia
Re: Terrain Textures
mask itself is not too difficult to make. dk about code.Flail13 wrote:how difficult would it be to use per-tile alpha masks on the texture blending?
But as far as I understand, you are talking about textures transition, currently it is too wide. I suggested a long time ago to decrease it, but as always no one listened me.
-
NoQ
- Special

- Posts: 6226
- Joined: 24 Dec 2009, 11:35
- Location: /var/zone
Re: Terrain Textures
Doesn't it bring us back to the old renderer? We would need to either automatically set up all these transitions, which is impossible for an arbitrary mess of colors, or rely on the map tile hints, which will be the same as 2.3 with better textures.per-tile alpha masks
Maps | Tower Defense | NullBot AI | More NullBot AI | Scavs | More Scavs | Tilesets | Walkthrough | JSCam
-
Flail13
- Code contributor

- Posts: 263
- Joined: 16 May 2008, 12:00
Re: Terrain Textures
NoQ, like you said, it's impossible to create all the possible transitions, which also rules out 2.3-like fixed tilesets for this.
Trying to think of an acutal method myself:
- leave the 512x512 texture files as they are.
- create different types of 128x128 alpha masks for different tiles and appearances eg: straight/corners & straight-narrow-transition/wide-jagged-transition
- specify them for each tile with an orientation in the map file
Upon starting a game:
- split the 512x512 textures into 128x128 tiles (no alternate orientations)
- scan the map for each combination of mask-orientation and terrain textures that is *actually used*
- pre-combine only those tile transitions in the graphics card (dont know how consuming this is)
- draw the pre-combined textures onto each tile
Trying to think of an acutal method myself:
- leave the 512x512 texture files as they are.
- create different types of 128x128 alpha masks for different tiles and appearances eg: straight/corners & straight-narrow-transition/wide-jagged-transition
- specify them for each tile with an orientation in the map file
Upon starting a game:
- split the 512x512 textures into 128x128 tiles (no alternate orientations)
- scan the map for each combination of mask-orientation and terrain textures that is *actually used*
- pre-combine only those tile transitions in the graphics card (dont know how consuming this is)
- draw the pre-combined textures onto each tile
-
Emdek
- Regular

- Posts: 1329
- Joined: 24 Jan 2010, 13:14
- Location: Poland
Re: Terrain Textures
I like possibility to use such things (would be best for blending for my terrain models idea for cliffs), but personally I like look of current transitions better, as it doesn't create sharp edges between colors (which looks unnatural).
BTW, we already have tiles that needs to be blended (craters, roads etc.), alpha channel use would make it look better.
BTW, we already have tiles that needs to be blended (craters, roads etc.), alpha channel use would make it look better.
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.
The time has come, the high time, to destroy hatred in oneself.
Beware! Mad Qt Evangelist.
-
Flail13
- Code contributor

- Posts: 263
- Joined: 16 May 2008, 12:00
Re: Terrain Textures
I understand my example doesn't look like anything in particular. It could be made to look like bushes or a straight edge for concrete, for example. I looked on Google Maps satellite and Arizona doesn't seem blurry.
-
Emdek
- Regular

- Posts: 1329
- Joined: 24 Jan 2010, 13:14
- Location: Poland
Re: Terrain Textures
Flail13, sure, but this is not simulation. 
And previous textures compared to current look weak (at least on some maps).
And previous textures compared to current look weak (at least on some maps).
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.
The time has come, the high time, to destroy hatred in oneself.
Beware! Mad Qt Evangelist.
-
NoQ
- Special

- Posts: 6226
- Joined: 24 Dec 2009, 11:35
- Location: /var/zone
Re: Terrain Textures
But the whole talk is about the fact that we do need sharp edges!Emdek wrote:I like possibility to use such things (would be best for blending for my terrain models idea for cliffs), but personally I like look of current transitions better, as it doesn't create sharp edges between colors (which looks unnatural).
Maybe not between different ground colors, but we need sharp edges at least for separating cliffs from ground, because it's often hard to say where you can go and where you can't go.
Maps | Tower Defense | NullBot AI | More NullBot AI | Scavs | More Scavs | Tilesets | Walkthrough | JSCam
-
Emdek
- Regular

- Posts: 1329
- Joined: 24 Jan 2010, 13:14
- Location: Poland
Re: Terrain Textures
NoQ, yes, for things like tiles or cliffs we need, and we have (ale least sharp enough for me).
For cliffs (including marking as not passable) check my topic in Ideas and Suggestions.
For cliffs (including marking as not passable) check my topic in Ideas and Suggestions.
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.
The time has come, the high time, to destroy hatred in oneself.
Beware! Mad Qt Evangelist.
-
Jorzi
- Regular

- Posts: 2063
- Joined: 11 Apr 2010, 00:14
Re: Terrain Textures
Per-tile alpha masks is not a bad idea imo. All that would be needed is a few straight and a few L-shaped masks. These could then be inverted or rotated as suitable. We would of course need a way to choose random gradients to prevent ugly tiling, as well as automated detection of a number of cases.


-insert deep philosophical statement here-
-
effigy
- Regular

- Posts: 1217
- Joined: 22 Jan 2010, 03:21
Re: Terrain Textures
+1NoQ wrote:But the whole talk is about the fact that we do need sharp edges!Emdek wrote:I like possibility to use such things (would be best for blending for my terrain models idea for cliffs), but personally I like look of current transitions better, as it doesn't create sharp edges between colors (which looks unnatural).
Maybe not between different ground colors, but we need sharp edges at least for separating cliffs from ground, because it's often hard to say where you can go and where you can't go.
Also, I miss the way 2.3 transitioned to water.
This is why some features aren't implemented: http://forums.wz2100.net/viewtopic.php?f=30&t=7490&view=unread#p87241
-
MaNGusT
- Art contributor
- Posts: 1154
- Joined: 22 Sep 2006, 10:31
- Location: Russia
Re: Terrain Textures
a possible solution for cliffs transition is to convert a map into mesh(in gpu?!) then allocate cliffs by angle and make hard edges via smooth groups
-
Emdek
- Regular

- Posts: 1329
- Joined: 24 Jan 2010, 13:14
- Location: Poland
Re: Terrain Textures
MaNGusT, yeah, seems like technical implementation of what I've posted elsewhere. 
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.
The time has come, the high time, to destroy hatred in oneself.
Beware! Mad Qt Evangelist.