Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, Akow, degenerate_762), 1,430 guests, and 9 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19055 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 5 of 9 1 2 3 4 5 6 7 8 9
Re: Fluid Dynamics for lower editions [Re: EvilSOB] #277222
07/08/09 12:12
07/08/09 12:12
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
VeT Offline

Serious User
VeT  Offline

Serious User

Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
Good luck smile


1st prize: Lite-C and Newton 2.17 by Vasilenko Vitaliy

Newton2 videos: http://tinyurl.com/NewtonVideos
LiteC+Newton2 discussion: http://tinyurl.com/NewtonWrapperDiscussion
Latest LiteC+Newton2 version(v23, from 29.10.2009): http://depositfiles.com/files/ae1l0tpro
Re: Fluid Dynamics for lower editions [Re: VeT] #277320
07/08/09 20:02
07/08/09 20:02
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
Gack! Brain melting...
I think I'll have to sleep on this one.
I just know Im going to have nightmares about three-dimensional arrays drifting through time.
With any luck I'll wake up with an answer.

If I keep going round in circles like this, Im going to disappear up my own algorithm.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: Fluid Dynamics for lower editions [Re: EvilSOB] #277323
07/08/09 20:12
07/08/09 20:12
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
VeT Offline

Serious User
VeT  Offline

Serious User

Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
//I just know Im going to have nightmares about three-dimensional arrays drifting through time.
With any luck I'll wake up with an answer.

Maybe you'd share, whats the problem ? smile


1st prize: Lite-C and Newton 2.17 by Vasilenko Vitaliy

Newton2 videos: http://tinyurl.com/NewtonVideos
LiteC+Newton2 discussion: http://tinyurl.com/NewtonWrapperDiscussion
Latest LiteC+Newton2 version(v23, from 29.10.2009): http://depositfiles.com/files/ae1l0tpro
Re: Fluid Dynamics for lower editions [Re: VeT] #277325
07/08/09 20:26
07/08/09 20:26
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
Just trying to get the DAMNED thing to be frame-rate independant.
I cant seem to find a balanced way to put in time_step or time_frame.
Either it goes too slow, and if you increase the speed the waves increase in size expotentially,
Or the waves propagation is nearly non-existant, and fade to nothing before hitting the walls.

The core algorithm is just so finely tuned, and the documentation its based on is rather vague
in regards to timing, hell, it doesnt really mention timing at all.

PS: The core loop of the "fluid_action" code Im working with is still the same as my last code-post.

Last edited by EvilSOB; 07/08/09 20:28. Reason: update.

"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: Fluid Dynamics for lower editions [Re: EvilSOB] #277337
07/08/09 21:14
07/08/09 21:14
Joined: Dec 2008
Posts: 528
Wagga, Australia
the_mehmaster Offline OP
User
the_mehmaster  Offline OP
User

Joined: Dec 2008
Posts: 528
Wagga, Australia
Hmm.. I'm trying to get it working with newton ATM so don't have much time for this. Newton will be released tomorrow sometime.

What have you got so far? all i can see is the 'wait' instruction, which is the only FPS independent instruction.

About the documentation:
Yeah, the documentation has nothing about timing..But it's the best i could find.

Re: Fluid Dynamics for lower editions [Re: the_mehmaster] #277408
07/09/09 08:13
07/09/09 08:13
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
I still think you should use sin curves.
In physics class, to show/define waves, you use sin curves, even (or especially) for water-waves.
it would be something like:

var startTime; //set this at the total_ticks value when the wave is started
VECTOR* startpos; //set this to the position of the
var waveSpeed = 1; //(speed of propagation? is that what you call it?)
var myDistance; //distance from this vertex to startpos (with vec_dist)
while((total_ticks-startTime)*waveSpeed < myDistance)wait(1); //wait until the wave has reached this vertex.
startTime = total_ticks; //now start time is the time at which it starts to move
my_vertex_height = max_height*sin(2*Pi*(total_ticks-startTime)/waveSpeed);

max_height would need to decrease, of course.

Also, this is (obviously, it's only for one vertex) just pseudo-code, but something like this could work for making it fps independent, because the wave would spread at an even rate.
There must be a reason why physicist use sin functions for waves.

[edit] tested the fluidsimdemo1. It's much better, and the pullling with your mouse to get the effect idea was a very good one!
When clicking on one of the vertecies on the edge it doesn't come back down though, and, as Vet said, it's still not FPS independent, making it "jitter" much too fast on faster computers.

Last edited by Germanunkol; 07/09/09 08:16.

~"I never let school interfere with my education"~
-Mark Twain
Re: Fluid Dynamics for lower editions [Re: Germanunkol] #277411
07/09/09 08:22
07/09/09 08:22
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
VeT Offline

Serious User
VeT  Offline

Serious User

Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
Really, using sin() function is good idea smile


1st prize: Lite-C and Newton 2.17 by Vasilenko Vitaliy

Newton2 videos: http://tinyurl.com/NewtonVideos
LiteC+Newton2 discussion: http://tinyurl.com/NewtonWrapperDiscussion
Latest LiteC+Newton2 version(v23, from 29.10.2009): http://depositfiles.com/files/ae1l0tpro
Re: Fluid Dynamics for lower editions [Re: VeT] #277417
07/09/09 08:40
07/09/09 08:40
Joined: Dec 2008
Posts: 528
Wagga, Australia
the_mehmaster Offline OP
User
the_mehmaster  Offline OP
User

Joined: Dec 2008
Posts: 528
Wagga, Australia
Quote:
It's much better, and the pullling with your mouse to get the effect idea was a very good one!

That was me smile

Re: Fluid Dynamics for lower editions [Re: the_mehmaster] #277418
07/09/09 08:44
07/09/09 08:44
Joined: Dec 2008
Posts: 528
Wagga, Australia
the_mehmaster Offline OP
User
the_mehmaster  Offline OP
User

Joined: Dec 2008
Posts: 528
Wagga, Australia
With the newton demo in development,

Do you think i should add particle effects for splashes when vertice height gets above a certain value? Or should this be in a separate demo?

Re: Fluid Dynamics for lower editions [Re: the_mehmaster] #277421
07/09/09 08:48
07/09/09 08:48
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
VeT Offline

Serious User
VeT  Offline

Serious User

Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
I think you may add particles, why not? smile
Maybe, also, it would be nice if they would be optional.


1st prize: Lite-C and Newton 2.17 by Vasilenko Vitaliy

Newton2 videos: http://tinyurl.com/NewtonVideos
LiteC+Newton2 discussion: http://tinyurl.com/NewtonWrapperDiscussion
Latest LiteC+Newton2 version(v23, from 29.10.2009): http://depositfiles.com/files/ae1l0tpro
Page 5 of 9 1 2 3 4 5 6 7 8 9

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1