Board index FlightGear Development Aircraft

A320-family development

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

Re: A320-family development

Postby legoboyvdlp » Mon Oct 28, 2019 11:52 am

I'm using the model-interior effect to control a lightmap on /controls/lighting/panel-light:

Code: Select all
<PropertyList>
    <name>panel</name>
    <inherits-from>Effects/model-interior</inherits-from>
    <parameters>
        <lightmap-enabled type="int">1</lightmap-enabled>
        <lightmap-factor type="float" n="0"><use>/controls/lighting/panel-light</use></lightmap-factor>
        <lightmap-color type="vec3d" n="0">1.0 1.0 1.0</lightmap-color>
        <texture n="3">
            <image>Aircraft/A320-family/Models/Effects/panel-floodlight.png</image>
            <filter>linear-mipmap-linear</filter>
            <wrap-s>clamp</wrap-s>
            <wrap-t>clamp</wrap-t>
            <internal-format>normalized</internal-format>
        </texture>
      <irradiance-map-type type="int">2</irradiance-map-type>
      <irradiance-map-strength type="float">0.1</irradiance-map-strength>
      <texture n="4">
      <type>cubemap</type>
         <images>
            <positive-x>Models/Effects/res/white.png</positive-x>
            <negative-x>Models/Effects/res/white.png</negative-x>
            <positive-y>Models/Effects/res/white.png</positive-y>
            <negative-y>Models/Effects/res/white.png</negative-y>
            <positive-z>Models/Effects/res/white.png</positive-z>
            <negative-z>Models/Effects/res/white.png</negative-z>
         </images>
      </texture>
       <!--
       the cube center must be the same as the camera x,y,z in blend
      -->
      <opacity-cube-center type="vec3d" n="0"> 0.207344 0.0 0.797276</opacity-cube-center>
      <opacity-cube-scale type="vec3d" n="0"> 0.672 0.672 0.672</opacity-cube-scale>
      <opacity-cube-angle type="float">0.0</opacity-cube-angle>
    </parameters>
</PropertyList>


The opacity cube is - for now - disabled.

But, what is bizarre is that people say /controls/lighting/panel-light is.... 1

Image

Image

Everything is identical to the IDG-A32X, yet it works on one and not the other. And it works for me....?

I don't understand how its even possible that the lightmap does not work when the controlling property is set to 1 and the shaders are set properly...

Image
User avatar
legoboyvdlp
 
Posts: 7750
Joined: Sat Jul 26, 2014 1:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: A320-family development

Postby CaptB » Mon Oct 28, 2019 3:08 pm

legoboyvdlp wrote in Mon Oct 28, 2019 11:52 am:Everything is identical to the IDG-A32X, yet it works on one and not the other. And it works for me....?


Indeed it works on the last master from IDG. Which files to look at? panel-flood.eff?
CaptB
 
Posts: 600
Joined: Thu May 23, 2013 6:36 pm
Callsign: EKCH_AP
IRC name: CAPTB
Version: 2020.1.1
OS: Xubuntu 20.04

Re: A320-family development

Postby legoboyvdlp » Mon Oct 28, 2019 3:20 pm

Indeed it works on the last master from IDG. Which files to look at? panel-flood.eff?[/quote]

That's correct but I don't think the problem is in that file - they appear to be identical here :?:
User avatar
legoboyvdlp
 
Posts: 7750
Joined: Sat Jul 26, 2014 1:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: A320-family development

Postby Thorsten » Mon Oct 28, 2019 3:22 pm

On the systems where it does not work - what happens if the line

Code: Select all

        <lightmap-factor type="float" n="0"><use>/controls/lighting/panel-light</use></lightmap-factor>


is changed to

Code: Select all
        <lightmap-factor type="float" n="0">1.0</lightmap-factor>



(i.e. the map is commanded to be always on)?
Thorsten
 
Posts: 11720
Joined: Mon Nov 02, 2009 8:33 am

Re: A320-family development

Postby CaptB » Mon Oct 28, 2019 3:47 pm

Thorsten wrote in Mon Oct 28, 2019 3:22 pm:(i.e. the map is commanded to be always on)?


Yes, it's on.
CaptB
 
Posts: 600
Joined: Thu May 23, 2013 6:36 pm
Callsign: EKCH_AP
IRC name: CAPTB
Version: 2020.1.1
OS: Xubuntu 20.04

Re: A320-family development

Postby Thorsten » Mon Oct 28, 2019 4:09 pm

Does anything else set that control property? I've seen cases where a property is set twice to different values during a frame - so it can potentially appear with one value in the property browser and be passed to the effect with a different value - because they're not querying the value at the same time.

And that could be system-dependent because it's a timing question.
Thorsten
 
Posts: 11720
Joined: Mon Nov 02, 2009 8:33 am

Re: A320-family development

Postby legoboyvdlp » Mon Oct 28, 2019 4:47 pm

Not that I'm aware of :(
It's only set in one place and then referred to.
https://github.com/legoboyvdlp/A320-fam ... ight&type=
User avatar
legoboyvdlp
 
Posts: 7750
Joined: Sat Jul 26, 2014 1:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: A320-family development

Postby hayden2000 » Mon Oct 28, 2019 4:54 pm

legoboyvdlp wrote in Sun Oct 27, 2019 9:16 pm:And finally I would appreciate confirmation if people can confirm if they can hear non-engine sounds on both the CFM and IAE (e.g. pushbuttons, avionics, etc).

They are still not working for me.
User avatar
hayden2000
 
Posts: 26
Joined: Mon Oct 28, 2019 4:51 pm
Location: Cincinnati (CVG)/Portland (PWM)
Callsign: DAL1718
Version: nightly
OS: macOS 11.0

Re: A320-family development

Postby CaptB » Mon Oct 28, 2019 6:02 pm

Tried to do a read/write --trace on /controls/lighting/panel-light and I got nothing, however the values seem to change in the property browser?
CaptB
 
Posts: 600
Joined: Thu May 23, 2013 6:36 pm
Callsign: EKCH_AP
IRC name: CAPTB
Version: 2020.1.1
OS: Xubuntu 20.04

Re: A320-family development

Postby Thorsten » Mon Oct 28, 2019 6:12 pm

What if you assign it to a different property - say /test/light in the effect file? It would seem the problem isn't with the shader but with getting the property value into the shader, so let's elaborate on that theme.
Thorsten
 
Posts: 11720
Joined: Mon Nov 02, 2009 8:33 am

Re: A320-family development

Postby CaptB » Mon Oct 28, 2019 9:27 pm

Thorsten wrote in Mon Oct 28, 2019 6:12 pm:What if you assign it to a different property


No difference.
CaptB
 
Posts: 600
Joined: Thu May 23, 2013 6:36 pm
Callsign: EKCH_AP
IRC name: CAPTB
Version: 2020.1.1
OS: Xubuntu 20.04

Re: A320-family development

Postby legoboyvdlp » Mon Oct 28, 2019 10:13 pm

So to confirm whenever it's set to use a property it doesn't work no matter what value that property has? Or did I misunderstand that last post? Because that would be incredible and at that point I'd be convinced my PC was haunted...
User avatar
legoboyvdlp
 
Posts: 7750
Joined: Sat Jul 26, 2014 1:28 am
Location: Northern Ireland
Callsign: G-LEGO
Version: next
OS: Windows 10 HP

Re: A320-family development

Postby CaptB » Tue Oct 29, 2019 6:21 am

Yes. I have changed the property but there's no change and the problem persist. The value of the property does change along with twisting the knob.

Edit: I mapped the property directly to /controls/lighting/main-flood-knb and now it works. Not sure why it didn't work previously when I changed the property(does it it need an FG restart or reloading the model/materials is sufficient?) I suppose it doesn't like something the dc-ess and dc-1 OR logic, but it doesn't seem so since it's aliased correctly?
CaptB
 
Posts: 600
Joined: Thu May 23, 2013 6:36 pm
Callsign: EKCH_AP
IRC name: CAPTB
Version: 2020.1.1
OS: Xubuntu 20.04

Re: A320-family development

Postby Thorsten » Tue Oct 29, 2019 8:41 am

I mapped the property directly to /controls/lighting/main-flood-knb and now it works. Not sure why it didn't work previously when I changed the property(does it it need an FG restart or reloading the model/materials is sufficient?)


It needs an effect system restart, I'm fairly sure just reloading model isn't sufficient - not sure what exactly triggers the effect restart, but I usually do FG restart (and yes, with a complex craft like the Shuttle that tends to be painful...)
Thorsten
 
Posts: 11720
Joined: Mon Nov 02, 2009 8:33 am

Re: A320-family development

Postby Thorsten » Tue Oct 29, 2019 8:43 am

Well, at least you have all ingredients - you have it working mapped to one property, so now do all the things to that working state which are done to the other property and see which one breaks it.

Then we know more.
Thorsten
 
Posts: 11720
Joined: Mon Nov 02, 2009 8:33 am

PreviousNext

Return to Aircraft

Who is online

Users browsing this forum: No registered users and 2 guests