Board index FlightGear Development

Sailing, anyone?

FlightGear is opensource, so you can be the developer. In the need for help on anything? We are here to help you.
Forum rules
Core development is discussed on the official FlightGear-Devel development mailing list.

Bugs can be reported in the bug tracker.

Re: Sailing, anyone?

Postby Kailingkazak » Fri Jan 14, 2011 6:36 pm

I tested them both briefly. The Liberty Class seemed to work quite well, although it seemed quite slow in it's reactions. The PT-Boat just went backwards and was unstoppable, until it crashed in 28R at KSFO. If you need help on sailing/boats, I can also help you.
Kailingkazak
Kailingkazak
 
Posts: 297
Joined: Tue Oct 16, 2007 9:48 am
Location: Switzerland
Version: 2
OS: Mac OS 10.6.6

Re: Sailing, anyone?

Postby DFaber » Sun Jan 20, 2013 1:41 pm

Here are some news from the "Water" Front. I have abandonned the concept of YaSim Ships. Instead I control an AI Aircraft directly via Nasal, which gives some advantages (like submerging submarines).
However the complete Ship dynamics need to be written. I've done a basic demonstrator for this:

Image

This is an early alpha, meant as a Proof of Concept. Get it here:

http://www.flightgear.sol2500.net/index ... lator.html

Any help appreciated.

Greetings
Detlef Faber
FlightGear Development:
http://flightgear-de.net

German FlightGear Forum
http://forum.flightgear-de.net
DFaber
 
Posts: 684
Joined: Fri Dec 01, 2006 7:51 pm
Location: Aachen, Germany
Version: GIT
OS: Linux

Re: Sailing, anyone?

Postby Michat » Mon Jan 21, 2013 12:43 am

Lake of Constance hangar has advanced AI sea planes and adventures. DO-X and DO-J-II Dorniers and MP-LODI-TABOR at http://www.marc-kraus.de/fg/ Contact Marc he is always doing great things for fun.

Also maybe you want to check http://dangerdeep.sourceforge.net/gallery/ free as in freedom software. I know that FG has terrain limitation, but maybe it can help you.


Your project is excellent. Hope to have in FG more actions like this https://en.wikipedia.org/wiki/Submarine ... ft_carrier

Any news from sailing boats?
User avatar
Michat
 
Posts: 925
Joined: Mon Jan 25, 2010 6:24 pm
Location: Spain
Version: 191b
OS: GNewSense

Re: Sailing, anyone?

Postby DFaber » Mon Jan 21, 2013 7:40 am

Hi Michat,

Michat wrote in Mon Jan 21, 2013 12:43 am: Hope to have in FG more actions like this https://en.wikipedia.org/wiki/Submarine ... ft_carrier


Submarines are planned, MP Carrier/towing capabilities too. Submarine carriers might be possible but it's uncertain wether the Aircraft can be transported below the waterline. If not they need to be "stored" somewhere else while diving.

Michat wrote in Mon Jan 21, 2013 12:43 am:Any news from sailing boats?


I'm afraid not. First I like to make the basic ship movement. Next will be reactions to waves and wind. This might take a while because my programming skills are limited :-(

Greetings
Detlef Faber
FlightGear Development:
http://flightgear-de.net

German FlightGear Forum
http://forum.flightgear-de.net
DFaber
 
Posts: 684
Joined: Fri Dec 01, 2006 7:51 pm
Location: Aachen, Germany
Version: GIT
OS: Linux

Re: Sailing, anyone?

Postby AndersG » Mon Jan 21, 2013 5:38 pm

That's a nice motor torpedo boat (or is it a S-Boot?) model. :)

You could also use JSBSim. Floating is not hard, hydrodynamics need work to achieve accuracy (but you have to do that work regardless of implementation platform - at least short of CFD), wind should be doable (it is made for simulating aircraft, after all) but waves are harder. I have some ideas for waves but nothing implemented.

See MTB_20m in my hangar for one example that includes marine propellers driven by the main and auxiliary engines. The link to my hangar is in my signature.

Cheers,
Anders
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2414
Joined: Wed Nov 29, 2006 9:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: Sailing, anyone?

Postby DFaber » Tue Jan 22, 2013 7:36 am

Hi Anders,

AndersG wrote in Mon Jan 21, 2013 5:38 pm:That's a nice motor torpedo boat (or is it a S-Boot?) model. :)


no, it's an american Elco 80ft PT-Boat (I should have put a flag on it :-) ). An S-Boot (or E-Boat) would have been longer. The Boat started as AI Object, but I got carried away and detailed it a bit more.

AndersG wrote in Mon Jan 21, 2013 5:38 pm:You could also use JSBSim. Floating is not hard, hydrodynamics need work to achieve accuracy (but you have to do that work regardless of implementation platform - at least short of CFD), wind should be doable (it is made for simulating aircraft, after all) but waves are harder. I have some ideas for waves but nothing implemented.


The Wave motion was one point for me to abandon the YaSim Ship approach. I am experimenting with a Nasal loop to control waves (basically just a counter and a sine function). The interesting part is which properties I can use to control the waves. I found some under /environment but they never change.
At least the water shader knows something about the waves, but I have not found out how to get that info.

AndersG wrote in Mon Jan 21, 2013 5:38 pm:See MTB_20m in my hangar for one example that includes marine propellers driven by the main and auxiliary engines. The link to my hangar is in my signature.


I'll definitly have a look. Thanks!

Greetings
Detlef Faber
FlightGear Development:
http://flightgear-de.net

German FlightGear Forum
http://forum.flightgear-de.net
DFaber
 
Posts: 684
Joined: Fri Dec 01, 2006 7:51 pm
Location: Aachen, Germany
Version: GIT
OS: Linux

Re: Sailing, anyone?

Postby i4dnf » Tue Jan 22, 2013 8:44 am

The water shader uses /environment/sea/surface/wind-from-*-fps to determine the wind direction and speed and to rotate and scale the waves textures/trains accordingly. It then generates a couple of wave-trains on slightly different directions to create a more natural interference pattern, these are then overlayed on the small detail normalmap.
There are a couple of extra configurable parameters, but they do not change at runtime currently.
The exact math involved in the wave train generation can be found in Shaders/water-sine.frag (the evaluateWave*() functions and the sumWaves() function).
i4dnf
Retired
 
Posts: 745
Joined: Wed Sep 09, 2009 7:17 am
Location: LRBS
Callsign: YR-I4D
Version: GIT
OS: Gentoo Linux ~amd64

Re: Sailing, anyone?

Postby Thorsten » Tue Jan 22, 2013 8:51 am

I found some under /environment but they never change.
At least the water shader knows something about the waves, but I have not found out how to get that info.


/environment/sea/surface has the wind components as they are passed to the water shader. /environment/wave has config settings like the wave amplitude which are driven by wind change. The property rule filters doing that are in Environment/interpolator.xml.

All these change for me if the wind changes - the property rules mostly reference /environment/config/boundary/entry[0]/wind-speed-kt.

More or less the whole set is used by the water shader to generate the visible waves.

Edit: Emilian was faster... I do see changes of the content of /environment/wave though, and the property rules for the changes are there - are they passed but not actually used?
Thorsten
 
Posts: 9997
Joined: Mon Nov 02, 2009 8:33 am

Re: Sailing, anyone?

Postby i4dnf » Tue Jan 22, 2013 10:01 am

They are passed to the shader, so if they are changed by property rules they have an effect on wave appearance. I must have remembered incorrectly then.
i4dnf
Retired
 
Posts: 745
Joined: Wed Sep 09, 2009 7:17 am
Location: LRBS
Callsign: YR-I4D
Version: GIT
OS: Gentoo Linux ~amd64

Re: Sailing, anyone?

Postby Bomber » Tue Jan 22, 2013 11:25 am

Have you considered raising and lowering the z cordinate of the undercariage fractionally to give a rocking motion ?
"If anyone ever tells you anything about an aeroplane which is so bloody complicated you can't understand it, take it from me - it's all balls" - R J Mitchel
Bomber
 
Posts: 1934
Joined: Fri Dec 14, 2007 7:06 pm
OS: Windows XP and 10

Re: Sailing, anyone?

Postby DFaber » Tue Jan 22, 2013 6:04 pm

Many thanks Emilian and Thorsten, your answers are very helpful. I hope to find some time this week to try it out.

Greetings
Detlef Faber
FlightGear Development:
http://flightgear-de.net

German FlightGear Forum
http://forum.flightgear-de.net
DFaber
 
Posts: 684
Joined: Fri Dec 01, 2006 7:51 pm
Location: Aachen, Germany
Version: GIT
OS: Linux

Re: Sailing, anyone?

Postby Michat » Thu Jan 31, 2013 3:05 am

I found this video about math and simulation, aircraft and sailing boats. https://www.youtube.com/watch?v=LSxqpaCCPvY
User avatar
Michat
 
Posts: 925
Joined: Mon Jan 25, 2010 6:24 pm
Location: Spain
Version: 191b
OS: GNewSense

Re: Sailing, anyone?

Postby Cpt Goosnen » Mon May 13, 2013 6:16 am

Hy evryone

this is FG Noob^^ first i try to thank u all, cause of ur nice ideas and development!!
i have some requests, i was playing around with the pt-boat and have now a nice and steerable OliverPerry :mrgreen:
Rudder i get managed also max speed, and the Roll Factor was also good (nearly like the mp-carriers) but its gone, it just stays flat on the water now.... but thats not the main problem.

1. It hangs on Bridges
ship.nas line 120 called from line 44>>

means the way it requests the Ground parameters cant detect Bridges i guess.
cause i set the "if speed" to 10 knots, so it makes 10 knots on land but still hangs at bridges (which are far high enough)

2. cause im totall noob (thats also the point why i wanna start with something easy like ships^^) i dont know how too manage some things like acceleration factor, or just set engine to running. (set running for sound, i have done a soundpath but it just runs when i set the running parameter ingame (developer menue-browse internals) to "true" so it would work but just a simple flat Engine sound, without any change by acceleration)

and for the wave discussion- i found the SanAntonio threat here in the forum, and downloaded it. The developer wrote it would have wavemovement, and there is also something like that in the .xml but it dont works at my pc.... guess he should know how to let the boat roll and pitch in the waves

so that should it be for the first :)
i am happy for any reposts and sorry for my bad english....

greetings "excited following wave discussion" Goos


ps: @DFaber i have also seen there is a yasim file but that wont work, i run it with nullFDM
Last edited by Cpt Goosnen on Mon May 13, 2013 6:40 am, edited 1 time in total.
User avatar
Cpt Goosnen
 
Posts: 154
Joined: Mon May 13, 2013 5:08 am
Location: direct north of EDDF's rnwy18
Callsign: Arse
Version: 3.0
OS: atari

Re: Sailing, anyone?

Postby DFaber » Mon May 13, 2013 6:38 am

Hi Goos,

thanks for your interest! I have to admit that I have not done much on the Ships recently. Sad to hear that they don't work anymore. I'll take a look oncef I get back to my FG PC.
The Ships are very alpha right now, some parameters in the SDM file are simply not yet used, but if there is interest I'm happy to improve.

1. It hangs on Bridges
ship.nas line 120 called from line 44>>


yes, the FlightGear Scenery was not created with shipping in mind, so roads just pass over water without a "gap" between. In the future I intend to make a few more checks to the terrain to discern between beach, rock and bridges.

i dont know how too manage some things like acceleration factor, or just set engine to running. (set running for sound, i have done a soundpath but it just runs when i set the running parameter ingame (developer menue-browse internals) to "true" so it would work but just a simple flat Engine sound, without any change by acceleration)


Another long term goal is the "Nasal engine". You may know I'm using the AI System for the Ships and therefor I don't have an engine and need to create one. However this is useful for quite a few other use cases (e.G Jeep, Helicopters). This is work in Progress and will sometime provide the necessary properties for sounds.

i have also seen there is a yasim file but that wont work, i run it with nullFDM


I've abandoned the Yasim approach because submarines aren't possible with it.

Greetings
Detlef Faber
FlightGear Development:
http://flightgear-de.net

German FlightGear Forum
http://forum.flightgear-de.net
DFaber
 
Posts: 684
Joined: Fri Dec 01, 2006 7:51 pm
Location: Aachen, Germany
Version: GIT
OS: Linux

Re: Sailing, anyone?

Postby Cpt Goosnen » Mon May 13, 2013 6:50 am

thx alot, well it works very fine, just this thing with bridges, but the spray and steering is great succes to the FG projekt :mrgreen: and the mp-carrier is even able to pass bridges, that thing i guess can maybe solve AndersG

ok, when u or anybody else can give me a link for the null developement parameters i will take alook (searched alot but havent found any null dev description). if i can help u with that or even make a little beginn, that u have just do the finetuning ;)

btw: i will ask evry developers bevore i upload anything, and i also found some Boat.wav 's
http://www.grsites.com/archive/sounds/c ... ?offset=24 if u on the search
actually quite still naive
User avatar
Cpt Goosnen
 
Posts: 154
Joined: Mon May 13, 2013 5:08 am
Location: direct north of EDDF's rnwy18
Callsign: Arse
Version: 3.0
OS: atari

PreviousNext

Return to Development

Who is online

Users browsing this forum: No registered users and 2 guests