Jump to content

Animated Trees


theShadow
 Share

Recommended Posts

just a quick thought. Does this system animate all the trees on the map at once, or only the trees the player can see?

The animation happens while transforming the vertices for display on the screen, so only the objects that are to be displayed are animated.

Link to comment
Share on other sites

It won't be hard to integrate, if that is what you mean. A minor outstanding "problem" is that it depends on GLSL, which is not activated by default, so the team would have to make a decision on what they want to do in that regard.

Link to comment
Share on other sites

I love BfME2 for its unit control (the battalions are awesome). Its econ leaves much to be desired, though. I also like the 3D rolling oceanic waves for the water and some aspects of the wall system.

No kidding, the efficiency radius on farms was too large, making it hard to get a good economy for things like walls. If there was one good thing about BfME2, it was the fact it sure looked good and the wall system was great in theory.

Anyone have any video of this? How do they deal with waves hitting the shore?

EA built a fancy graphics engine, powered by their partnership with nVidia. BfME2 Collector's Edition DVD might be able to shine more light on it, and since I have it, I will take a look.

Edited by Zeta1127
Link to comment
Share on other sites

Thanks :) Edit: Found a video. Posted here.

Looks totally doable, though it'd take a bit more hacking than the trees. Here's how I think it was done in that video:

  1. there is a much finer water mesh than in 0ad
  2. it is displaced with cos waves by the vertex shader (just like the trees)
  3. then there's also code in the fragment shader to draw a foam texture on areas where the angle of the water is large (the tops of the waves).

Unlike the trees, this will use more processing power, because there's a need for additional vertices.

I think all the effects in Lion.Kanzen's previous video should be possible with my other patches, with the exception of the cloud shadows. I think those can be done by passing in a cloud texture to the fragment shader and using the LOS texture transform to make it look like shadows on the ground. i.e. it should be as simple as a texture read and a multiplication.

Link to comment
Share on other sites

It won't be hard to integrate, if that is what you mean. A minor outstanding "problem" is that it depends on GLSL, which is not activated by default, so the team would have to make a decision on what they want to do in that regard.

We can turn it on by default on GPUs verified to work well with GLSL. It's actually very easy to do that, see hwdetect.js. We also have data like http://feedback.wildfiregames.com/report/opengl/ (much more privately collected and unanalyzed) which can help. Then it would be a matter of finding a good baseline of default effects for high(er)-end GPUs with GLSL support.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...