Board index FlightGear Development Aircraft

Multiplayer model: only fallback shown  Topic is solved

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Multiplayer model: only fallback shown  

Postby benih » Wed Oct 21, 2020 12:31 pm

Hello,
i tried to get the c182s model ready for multiplayer display.

For getting myself started, i read trough the MP Livery and MP Properties wiki entries, and have started flightgear 2020.3 with the "--prop:/sim/multiplay/debug-level=1" launcher setting, so the craft is copied from MP perspective. I also selected the plane from the launcher aircraft dialog.

My expectation was that this would be enough to at least show the correct model, however it looks like that just the fallback model is displayed.
If i comment the line "fallback-model-index" in the -set file, the blue/yellow glider is shown.

I suspected this may be because i use the run_fgfs.sh from the repository/build tree, but i also tried linking the c182s folder in the build-dir install dir "install/flightgear/fgdata/Aircraft/c182s" and as that didn't work, in my default installation dir "/usr/share/games/flightgear/Aircraft", to no avail.


What am i doing wrong, can you please advise?
Thank you very much!

[edit]c172p shows correct with the method above, so its something about the model or my setup here.
Launcher shows this line:
Code: Select all
Options passed on the command line:
--fg-root=/home/beni/workspace/fgfs/fgbuild/install/flightgear/bin/../fgdata
--launcher

Optionen, die im Launcher gesetzt wurden:
--enable-real-weather-fetch
--prop:/nasal/local_weather/enabled=true
--prop:/sim/gui/dialogs/metar/mode/global-weather=false
--prop:/sim/gui/dialogs/metar/mode/local-weather=true
--prop:/sim/gui/dialogs/metar/mode/manual-weather=true
--prop:/local-weather/tmp/tile-management=METAR
--prop:/local-weather/tmp/tile-type=live
--prop:/sim/rendering/multi-sample-buffers=1
--prop:/sim/rendering/multi-samples=4
--disable-rembrandt
--prop:/sim/rendering/shaders/skydome=true
--prop:/sim/rendering/texture-cache/cache-enabled=false
--enable-terrasync
--prop:/sim/multiplay/txhost=mpserver01.flightgear.org
--prop:/sim/multiplay/txport=5000
--callsign=D-EBHX
--aircraft-dir=/home/beni/Dokumente/FGFS/Aircraft/c182s
--aircraft=c182s
--airport=EDDF
--parking-id=V100
--fg-scenery=/usr/share/games/flightgear/terraGIT
--fg-scenery=/usr/share/games/flightgear/EDDF_Update
--fg-scenery=/usr/share/games/flightgear/osm-worldbuild
--fg-aircraft=/home/beni/Dokumente/FGFS/Aircraft
--addon=/usr/share/games/flightgear/add-ons/RedGriffinATC/

Optionen, die als weitere Argumente gesetzt wurden:
--prop:/sim/failure-manager/quiet=1
--generic=socket,out,10,localhost,16661,udp,fgcom-mumble
--prop:/sim/multiplay/debug-level=1


[...fgbuild...]bin/../fgdata/Aircraft/c182s symlinks to my c182s git repo clone at /home/beni/workspace/fgfs/c182s/
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby Johan G » Thu Oct 22, 2020 1:18 am

Usually when a user start FlightGear with an aircraft selected, FlightGear read in the Aircraft-set.xml (in this case c182s-set.xml) and for the model to show looks at /sim/model/path, which is either an AC3D file or, more common, an XML file (in this case Aircraft/c182s/Models/c182s.xml)
Code: Select all
<PropertyList>
 <sim>
  <model>
   <path>Aircraft/c182s/Models/c182s.xml</path>
  </model>
 </sim>
</PropertyList>

From that file, that handle all animations of and interactions with the models, FlightGear will look for the path to the AC3D model (in this case Models/c182s.ac)
Code: Select all
<PropertyList>
 <path>c182s.ac</path>
</PropertyList>


benih wrote in Wed Oct 21, 2020 12:31 pm:I suspected this may be because i use the run_fgfs.sh from the repository/build tree, but i also tried linking the c182s folder in the build-dir install dir "install/flightgear/fgdata/Aircraft/c182s" and as that didn't work, in my default installation dir "/usr/share/games/flightgear/Aircraft", to no avail.

I think you might be onto something here, as I after a quick glance do not see any obvious errors with the files mentioned above.
Low-level flying — It's all fun and games till someone looses an engine. (Paraphrased from a YouTube video)
Improving the Dassault Mirage F1 (Wiki, Forum, GitLab. Work in slow progress)
Johan G
Moderator
 
Posts: 6021
Joined: Fri Aug 06, 2010 5:33 pm
Location: Sweden
Callsign: SE-JG
IRC name: Johan_G
Version: 2020.3.2
OS: Windows 10, 64 bit

Re: Multiplayer model: only fallback shown

Postby benih » Thu Oct 22, 2020 7:57 am

Hm, this may be related to the problem in the EDDF-Triangle thread: viewtopic.php?f=10&t=13009&view=unread#p375294 !
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby benih » Thu Oct 22, 2020 10:39 am

OK i found a little bit more.

When starting offline, then connecting, the (locally replayed) model loads ok (ignore the gear for now).
So maybe this is some model loading race condition?
=> https://github.com/HHS81/c182s/issues/1 ... -714397187

When switching views (cockpit->outside), suddenly it reverts to the fallback model.
When it reverts, the OK-model is visible from the inside:
https://github.com/HHS81/c182s/issues/1 ... -714401007
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby jomo » Thu Oct 22, 2020 6:47 pm

Thank You All very much for thinking that much about my ATC-problem viewing any model in my range - viewing different models just in seconds! And sorry that I do not understand all problems of a model- nor FGFS-designer

To the basics: I am on Ubuntu 20.04.1 LTS and FGFS 2020.1.1, usually working parallel on 2 PC's same time (ATCjo1 + ATCjo2) for many many functions during an ATC-session! (That is NOT a slef-flying - but just watching many others at same time!)

1) To my knowledge I do need to have all models I want to view/show in my local libraries. Only in case I would use the FGFS-launcher i could pickup models out of different libraries - that means that is only good for the program-start! To my knowledge I cannot view my friends (different) model if it is NOT in my local libraries! (I tried that several times -- am I wrong? Pls consider that even the new LAUNCHER asks which library it should or may search for the model you want! )

2) And pls do not forget that there are many many model-libries usable for FlightGear - that means there maybe many 747-8i etc in different Libraries! I cannot see how to handle that during an ATC-job were many many "customers" are coming in with same models out of different repositories. That is why I stated I will only download models that are in the FGSF-library! Thus it may very well be that a 747-8i (out of a private library) will look different in my movies --> because that one will look like the one in the FGFS-library! I guess that should not be a big problem -- except if the name of the strange set-file was different - then the film just shows a blue-yellow

2) There are a lot of thoughts about file-searching - but I guess there are misunderstandings: My understanding is, that computers can search only from one beginning: e.g. if you search for a 747-8i set-file in a top-folder 747-8r that will not work - because the PC does not know that it should start looking in 8r !! I believe the structure then must be: In Folder 747-8 must be the 2 set-files for 8i and 8f.
--> And again: I am looking for different models to display within seconds!! And usually I have more than just 1 model active!!!! (1 OpenRadar + 1 ORCAM + MANY customers!!)

Sorry that this is that complex. But always consider that as ATC I do not define a "model" in my startup program - but just use the view function in my model to see the other model!!! That is a different deal! Try if it works if you try to view your friend's model (e.g. during a multiplayer session). And especially try that if your friend is using a different model out of a NON-FGFS library!

For Sure: Let's continue to have fun -even if there are not millions of models out of different libraries that may not be shown as exact as they would like to show!
jomo / ATCjomo + EDDFjo + EDDFjo1 + EDDFjo2
ATC at EDDF Fr,Sa,Su,We from 20:00 to 24:00 CET/MEZ., see http://www.emmerich-j.de
User avatar
jomo
 
Posts: 987
Joined: Thu Feb 12, 2009 6:46 pm
Location: Mainz, Germany
Callsign: jomo jomoATC
OS: UBUNTU 18.4

Re: Multiplayer model: only fallback shown

Postby benih » Thu Oct 22, 2020 9:32 pm

For Sure: Let's continue to have fun

Oh yeah!

But hacking in the models internals is fun too (for some of us :) )
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby benih » Mon Oct 26, 2020 5:21 pm

Has been resolved:
My issue was mainly the default detail settings. They always forced the fallback model to show.
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby Johan G » Mon Oct 26, 2020 9:16 pm

benih wrote in Mon Oct 26, 2020 5:21 pm:My issue was mainly the default detail settings.

How did that happen? Did you have detailed LOD at just a few meters (in essence barely enough for your own cockpit)?
Low-level flying — It's all fun and games till someone looses an engine. (Paraphrased from a YouTube video)
Improving the Dassault Mirage F1 (Wiki, Forum, GitLab. Work in slow progress)
Johan G
Moderator
 
Posts: 6021
Joined: Fri Aug 06, 2010 5:33 pm
Location: Sweden
Callsign: SE-JG
IRC name: Johan_G
Version: 2020.3.2
OS: Windows 10, 64 bit

Re: Multiplayer model: only fallback shown

Postby benih » Tue Oct 27, 2020 11:21 am

It happens with default settings.

Here it does not work (detailed model above 400px size):
https://pasteboard.co/JxzFVbN.png

Here it does, i just changed the slider to show the detailed model with very small pixel number:
https://pasteboard.co/JxzGj8PN.png
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX

Re: Multiplayer model: only fallback shown

Postby Richard » Tue Oct 27, 2020 6:18 pm

benih wrote in Tue Oct 27, 2020 11:21 am:It happens with default settings.

Here it does not work (detailed model above 400px size):


That is working as expected; what is not obvious is that although it says 400 pixels in size that is a nominal size based on an larger aircraft average bounding box (medium transport sized) - and the C182 is much smaller than the bounding box.

So when you set 400pixels probably the model will have to be a lot larger than that; this is why I tend to use 21 pixels as my high detail range; because it works well for smaller and larger aircraft.

We did consider actually measuring the bounding box of the two models - but it is a little complicated to do this in a generic way because of the flexibility of our models - and we thought it would be a lot of programming effort to come up with something reliable when in fact the user can just tune it until they get a value that works for them.

I did consider not labelling the sliders to avoid the expectation that "pixels in size" would refer to the size in pixels on the screen.
Richard
 
Posts: 783
Joined: Sun Nov 02, 2014 10:17 pm
Version: Git
OS: Win10

Re: Multiplayer model: only fallback shown

Postby benih » Tue Oct 27, 2020 8:13 pm

Good to know, however shouldn’t that not also clash with the default c172?

It would be great if that value could in some way be deduced from the actual model in question.

I guess most „average“ users do not realize that they are just seeing the fallback model.
Maybe defaults should be 40px, so users may tune down when they hit performance issues? That would scale better into the future with ever better hardware.
User avatar
benih
 
Posts: 254
Joined: Tue Aug 15, 2017 9:34 am
Callsign: D-EBHX


Return to Aircraft

Who is online

Users browsing this forum: Google [Bot], Majestic-12 [Bot] and 4 guests