zoot Posted July 15, 2012 Report Share Posted July 15, 2012 This grass effect. If it's too slow for terrain, what about applying it to a farm field decal and use the feature for nice-looking 3-D farms that conform to the terrain?Some of the slowness can probably be mitigated with the LOD feature that myconid just implemented. As for actors, maybe we can use some kind of UV map (e.g. RGB for color, A for blade length)? Then you could even color it brown, put it on a bear and call it fur Quote Link to comment Share on other sites More sharing options...
myconid Posted July 15, 2012 Author Report Share Posted July 15, 2012 Some of the slowness can probably be mitigated with the LOD feature that myconid just implemented. As for actors, maybe we can use some kind of UV map (e.g. RGB for color, A for blade length)? Then you could even color it brown, put it on a bear and call it fur The LOD is actually just for models atm, though it'll get adapted eventually. As for fur on bears... it's possible, but is it worth it? Quote Link to comment Share on other sites More sharing options...
zoot Posted July 15, 2012 Report Share Posted July 15, 2012 As for fur on bears... it's possible, but is it worth it?Probably not Quote Link to comment Share on other sites More sharing options...
zoot Posted July 15, 2012 Report Share Posted July 15, 2012 What if we wanted grass on a pitched roof? Can that be done with decals? Quote Link to comment Share on other sites More sharing options...
myconid Posted July 15, 2012 Author Report Share Posted July 15, 2012 (edited) What if we wanted grass on a pitched roof? Can that be done with decals?Best way would be to add it as a prop, meaning it's a model with a grass material attached to a specific point on the main roof.(when I'm talking about decals, I'm talking about terrain decals like the patch of dirt drawn under buildings) Edited July 15, 2012 by myconid Quote Link to comment Share on other sites More sharing options...
zoot Posted July 15, 2012 Report Share Posted July 15, 2012 Best way would be to add it as a prop, meaning it's a model with a grass material attached to a specific point on the main roof.Sounds good. You can probably reuse that solution for water also then? Quote Link to comment Share on other sites More sharing options...
myconid Posted July 15, 2012 Author Report Share Posted July 15, 2012 Sounds good. You can probably reuse that solution for water also then?Yes! Quote Link to comment Share on other sites More sharing options...
Mythos_Ruler Posted July 15, 2012 Report Share Posted July 15, 2012 At the very least, that would give me an excuse to implement fancy materials for decals. This would solve an issue we've had for years and years--how to make farms look nice while conforming to the terrain grid. The current farms are not ideal, since they're just a flat decal. Adding that "grass" effect, while conforming to terrain, would pretty much look awesome. Quote Link to comment Share on other sites More sharing options...
Gen.Kenobi Posted July 16, 2012 Report Share Posted July 16, 2012 Indeed! And we could add some farm variations, like wheat, barley, ... 1 Quote Link to comment Share on other sites More sharing options...
Mythos_Ruler Posted July 16, 2012 Report Share Posted July 16, 2012 I don't like all the swaying... wind isn't like that, it comes in bursts. The swaying in that game looks like everything is underwater, so we should stay away from that. Though, that brings up the possibility of swaying underwater kelp for 0 A.D. Quote Link to comment Share on other sites More sharing options...
Wijitmaker Posted July 16, 2012 Report Share Posted July 16, 2012 Wijit, I removed the bones from the Hero model and attached your textures. Here's what I get: http://imgur.com/a/ZsvjUCould you try it again with this? Quote Link to comment Share on other sites More sharing options...
fabio Posted July 16, 2012 Report Share Posted July 16, 2012 This is what I get. Also I still get the terrain texture flickering. Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 (edited) Could you try it again with this?Yup, that looks more correct! http://imgur.com/a/CkHWfIn regards to parallax: when you are creating heightmaps remember that the parallax effect actually goes inwards (i.e. the real surface of the polygon is at height=white). If your entire polygon is much lower than that, it gets pushed inwards and the effect doesn't know what to draw to fill in the gaps at the edges. That's why you got tiling gaps on the roof of the roman civil centre. The solution? Make the brick heightmap brighter, until the tops of the stones=white. Edited July 16, 2012 by myconid Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 (edited) This is what I get. Also I still get the terrain texture flickering.The flickering is sort of expected, as I haven't worked on the shadowmap at all... but there's no sign of any effects anywhere, which is odd (it should either work or fail miserably, not look unchanged). Just to be sure, are you on the "effectsdistance"branch and preferglsl/gentangents are set to true in the config?(thanks btw) Edited July 16, 2012 by myconid Quote Link to comment Share on other sites More sharing options...
zoot Posted July 16, 2012 Report Share Posted July 16, 2012 For what it's worth, I get no effects on the civic center either:(I'm on 'effectsdistance2' as suggested here.) Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 Whoops looks like I forgot to add the civic centre files to that branch, sorry! Mars_temple2 should work, though! Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 Back to doing groundwork for the postprocessing effects manager. Here's HDR + bloom + fog: http://imgur.com/a/p1jxmCode: https://github.com/myconid/0ad/tree/postprocMrEmjeR, if you want to get started on the tilt-shift shader, look at the "hdr" shader for how to access the render and depth buffers. Quote Link to comment Share on other sites More sharing options...
Wijitmaker Posted July 16, 2012 Report Share Posted July 16, 2012 Yup, that looks more correct! http://imgur.com/a/CkHWfIn regards to parallax: when you are creating heightmaps remember that the parallax effect actually goes inwards (i.e. the real surface of the polygon is at height=white). If your entire polygon is much lower than that, it gets pushed inwards and the effect doesn't know what to draw to fill in the gaps at the edges. That's why you got tiling gaps on the roof of the roman civil centre. The solution? Make the brick heightmap brighter, until the tops of the stones=white.Cool and thanks for the tip, I'll get that fixed up this afternoon.Back to doing groundwork for the postprocessing effects manager. Here's HDR + bloom + fog: http://imgur.com/a/p1jxmLooks great! Quote Link to comment Share on other sites More sharing options...
wraitii Posted July 16, 2012 Report Share Posted July 16, 2012 I still think your HDR looks oversaturated, Myconid. While I like the effect for a screenshot, it'd probably get tedious in-game. Of course, you've probably set that as a setting by now . Quote Link to comment Share on other sites More sharing options...
Mythos_Ruler Posted July 16, 2012 Report Share Posted July 16, 2012 Back to doing groundwork for the postprocessing effects manager. Here's HDR + bloom + fog: http://imgur.com/a/p1jxmThese shots don't look as nice as before. The colors look blown out. Perhaps too much overbrightness and too bright of a sun color is the problem (not the HDR). Quote Link to comment Share on other sites More sharing options...
zoot Posted July 16, 2012 Report Share Posted July 16, 2012 I think the whole approach to coloring has to be thought over. While it does look 'oversaturated' in bright areas (which there are many of currently), it just looks gorgeous in the dark areas: Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 Let's not get ahead of ourselves, people. Here my focus was on the postprocessing manager, not on the effects themselves. You'll get a chance to tinker with the effects settings yourselves eventually, so for now I'll just stick to coding. Quote Link to comment Share on other sites More sharing options...
zoot Posted July 16, 2012 Report Share Posted July 16, 2012 Back to doing groundwork for the postprocessing effects manager. Here's HDR + bloom + fog: http://imgur.com/a/p1jxmCode: https://github.com/m...d/tree/postprocI get this error:ERROR: Failed to compile shader 'shaders/glsl/model_common.fs':0:194(27): error: Cannot access field `x' of non-structure / non-vector.0:194(27): error: type mismatchERROR: Failed to compile shader 'shaders/glsl/model_common.fs':0:194(27): error: Cannot access field `x' of non-structure / non-vector.0:194(27): error: type mismatchAlso, there seems to be an issue with the fog being clipped at the edge of the map. This is from Atlas but it also shows in-game: Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 I get this error:ERROR: Failed to compile shader 'shaders/glsl/model_common.fs':0:194(27): error: Cannot access field `x' of non-structure / non-vector.0:194(27): error: type mismatchERROR: Failed to compile shader 'shaders/glsl/model_common.fs':0:194(27): error: Cannot access field `x' of non-structure / non-vector.0:194(27): error: type mismatchAlso, there seems to be an issue with the fog being clipped at the edge of the map. This is from Atlas but it also shows in-game:Please ignore the fog thing for now, it's not properly implemented yet so it gets drawn over the LOS. In the prototype I used multi-target rendering to draw the LOS to a different buffer and then recombine it with the output after the fog, though that feels like a massive kludge and I want to avoid it. Maybe there's something clever I can do with the renderbuffer's alpha channel, if you see what I mean...As for the other error, fixed. Man, ATI's GLSL compiler will let me get away with anything. Quote Link to comment Share on other sites More sharing options...
myconid Posted July 16, 2012 Author Report Share Posted July 16, 2012 Myconid's random experiment #2842: Animated water material that can be attached to models. http://imgur.com/QfhzHNo reflections or refractions. Not sure how efficient those would be to render. Maybe they can be faked with static simple/cube textures instead... Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.