Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Water : Reflection, and schrolling Texture ???

Author
Message
Dee
22
Years of Service
User Offline
Joined: 11th Feb 2003
Location: France
Posted: 4th Mar 2003 10:21
Hi,

I am creating a game on a isle... And I create water now. It's very HARD.

I do not know how to do a reflection in real time : I want my matrix reflect in the water...

And I do not know how is the function to shroll texture in a Matrix like : SCHROLL OBJECT TEXTURE.

Dee

P.S : I am sorry but my English is very bad (I am french)
---3Dee by me---
Rob K
Retired Moderator
22
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 4th Mar 2003 18:12
Hmm... you might have to do an object matrix, ie. use an OBJECT instead of a matrix for your landscape. Unfortunately DBP's system is currently a little disjointed (you cannot use the same effects on a matrix as you can on an object) so this is the only solution.

Current Project: Retro Compo. Entry.
Scorpyo
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: italy
Posted: 5th Mar 2003 21:49
mmm.. I would build a mirrored (downwards) copy of the first one and positioning right under it.
And if it shows up too much through the water i would ghost it..
Just a suggestion..cheers..
QuothTheRaven
22
Years of Service
User Offline
Joined: 2nd Oct 2002
Location: United States
Posted: 5th Mar 2003 21:52
maybe you're having trouble because it's SCROLL, not SCHROLL. I'm positive there's a scroll matrix command, dont know about texture tho...

Darken the skies, we are god
Snakey
22
Years of Service
User Offline
Joined: 4th Feb 2003
Location:
Posted: 5th Mar 2003 22:49
I recently made a water effect using two plains. At two different heights, the lower layer ghosted and top ghosted, 1. The top layer has the sky texture on it and lower the water texture.

Then made a reflection of everything above water (within reason) and ghosted, 1.

Then set top layer to scroll its texture real slow.

And to top it off made the lower layer and the reflections rise an fall in time with the flow of the water.

Took ten minutes and looks just swell!

Cheers!

Shadow Robert
22
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 5th Mar 2003 22:55
a slow but realistic way of creating a reflection is create a camera which moves in 8 points around the island and then export its backbuffer as a texture ... then using 8 plains setup just below the matrix which is ghosted you texture them with the camera's images from the backbuffer of it.

if you ghost that as well and turn on the ambient light, and put in a light to affect the matrix water - it does give a very nice effect

i can spend all day thinking up a million ways to achieve this ... my personal favourite would be to use a Pixel & Vertex Shader combo, cept not everyone can use them

failing that just use a sphere map on the water, gives a nice reflective look whilst not actually reflecting anything - nice, cheap and quick

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?
Bighead
22
Years of Service
User Offline
Joined: 1st Sep 2002
Location:
Posted: 6th Mar 2003 07:54
Snakey, do you have an example code of that?
n3t3r453r
22
Years of Service
User Offline
Joined: 8th Nov 2002
Location: Russia
Posted: 6th Mar 2003 16:18
Hey, my english is veeery bad too!

I advice you to make your own functions that construct\controls object like std. matrix. You need to work a lot with memblocks. This functions are very difficult-to-understant however the result will surprise you, I promise.

Currently we're making such function, unfortunately for commerce project, so I can't show you the sources

Good luck! (I'll need it, LOL )
Bighead
22
Years of Service
User Offline
Joined: 1st Sep 2002
Location:
Posted: 7th Mar 2003 12:49
It's ok, I included it in the "Wish list" for DBP tutorials ...

Login to post a reply

Server time is: 2025-05-19 03:40:32
Your offset time is: 2025-05-19 03:40:32