Creating Water Surfaces - Any tips on how to achieve it

Blitz3D Forums/Blitz3D Programming/Creating Water Surfaces - Any tips on how to achieve it

Matty(Posted 2004) [#1]
Does anyone have any tips on how to create a water surface? I am not interested in the rippling
effect but more in the reflective/transparent appearance. What are some techniques that
could be used to achieve this.


_PJ_(Posted 2004) [#2]
EntityAlpha Entity,xxx# for the transparent effect. For reflection, I guess you'll need to use environment-mapping, but I haven't had much luck/experience with this yet...


Neo Genesis10(Posted 2004) [#3]
Cubemapping is your best bet. Take a look at the SetCubeFace commands and the optional texture flag. Essentially what you want to do to create a reflection is to render the world as seen from the surface to the cubemap texture. Blitz takes care of the rest when you call RenderWorld. Note than in order to render to a texture buffer you need to use RenderWorld and then CopyRect to the buffer.


Ross C(Posted 2004) [#4]
Check out Robs Demo1 in his sig:

http://www.redflame.net/files/cubed.zip


darklordz(Posted 2004) [#5]
Yep rob's demo is the best water surface thingy ive seen so far, except for the outcast water....


_PJ_(Posted 2004) [#6]
Awesome! Really impressive stuff that.


Andy(Posted 2004) [#7]
You can also use a mirror!

http://www.blitzbasic.com/b3ddocs/command.php?name=CreateMirror&ref=3d_a-z

Andy


_PJ_(Posted 2004) [#8]
Problem with mirrors is they're a bit too Planar, and can be 'over-reflective'. Okay if you have a large or multiple water sources and a defined water level - otherwise, they're not too great.


Andy(Posted 2004) [#9]
>Problem with mirrors is they're a bit too Planar, and can
>be 'over-reflective'. Okay if you have a large or multiple
>water sources and a defined water level - otherwise,
>they're not too great.

And yet it is a perfectly reasonable answer to the question asked. I am sure that MATTY will try it out and choose whatever approach suits his game!

Andy


Ash(Posted 2004) [#10]
Don't mirrors increase polygon count, too? I thought they doubled polygon count for every mirror placed...


Ross C(Posted 2004) [#11]
Yeah, it does. But cubemapped water requires you to take a render of the enviroment, which is probably as slow as a mirror. :)

Cubemapped water does look the better tho :) But if, as you say, you don't need to rippling, then a mirror could be the way to go.