Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wing light: not showing emmiting face lit (S/T variant affected) #533

Closed
hbeni opened this issue Nov 25, 2023 · 13 comments · Fixed by #534
Closed

Wing light: not showing emmiting face lit (S/T variant affected) #533

hbeni opened this issue Nov 25, 2023 · 13 comments · Fixed by #534

Comments

@hbeni
Copy link
Collaborator

hbeni commented Nov 25, 2023

When at night and activating the rear domeligt, you can switch on exterior lights.

The (compositor) light nicely lights up the side of the plane and the apron, however the wing light mount is not bright.

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 25, 2023

The Extlight also shows when the cabin back light is activated, but is transparent/invisible.
I verified this by a "pick" animation.

@wlbragg @TheFGFSEagle Is there something wrong with the model?
I tried to make it shine using material/emission animation but failed.

The only occurance where I can make it show "something" is adding

<animation>
   <type>material</type>
   <object-name>ExtLight</object-name>
   <property-base>sim/model/livery/</property-base>
   <texture-prop>texture</texture-prop>
   <texture>Light_lit.png</texture>
   <emission>	
    <red>1</red>	
    <green>1</green>	
    <blue>1</blue>
  </emission>
 </animation>

After the select definition. But its dark grey instead of a nice white.

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 25, 2023

pushed branch Issue533_FixWingLights for investigation

@TheFGFSEagle
Copy link
Contributor

Post that texture please - the emission will get multiplied with the diffuse color (texture pixel), and if that is dark, the end result will be dark as well … ;)

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 26, 2023

It is not in the repo, so probably in fgdata.
I just copied the example from the wiki 🫣
And was happy that it at least was showing something.
i assume the texture to be completely white pixels.
And what also puzzles me; the interior domelight also has such an emmiter face, and that is shown…

@TheFGFSEagle
Copy link
Contributor

I just copied the example from the wiki 🫣

link ?

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 26, 2023

https://wiki.flightgear.org/Howto:Illuminate_faces

at „Changing texture if illuminated„

@TheFGFSEagle
Copy link
Contributor

Does that object even have a texture, originally ? In any case the texture referenced there is not in FGData - it is just an example, and the referenced texture is a modified version of the original one. But it doesn't really make sense, in fact - or do you know of an object that is for example red when switched off and goes green when switched on ? I don't !

Also, what is the object in question exactly - the light shine (glare, star like appearance around the light source) or the light source (bulb) ?

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 27, 2023

I don't know it there is a texture originally. I tried looking it up in Blender (the .blend file exterior model) but my blender is messed up (3.4 and the exported model will segfault my fgfs) and I'm not sure what I am doing there.

The object in question is a quadratic light under the wing, near to the cabin. It's a rectangular black spot below the wing when not "on", and i expect this to show white when the light is switched on.
The actual light is implemented using compsitor and already working fine. Its just that the light currently comes out from a black hole so to say, and that looks weird.

off:
grafik

on, roughly marked as expected:
grafik

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 27, 2023

Also I would prefer to have a xml solution for this if possible :)
(because there are changes recently and I fear that we loose track... can git handle .blend files well?
I think the current base one is C182SNEW.blend that wlbragg made a while ago)

Also, what I have seen is that there is a difference in the C182S.blend and C182SNEW.blend regarding the light definition.

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 27, 2023

(T variant has the same issue)

@hbeni hbeni changed the title Wing light: not showing source Wing light: not showing emmiting face lit (S/T variant affected) Nov 27, 2023
@wlbragg
Copy link
Collaborator

wlbragg commented Nov 28, 2023

@hbeni
Do you know why we have the C182SNEW.blend and what all is different in it compared to C182S.blend? I think the "NEW" one is the current working blend file. I know the lights are different, but do you know if there is anything else different? If it was me that made the "NEW" one then I did that to keep the original just in case. We can rename them so as to keep them straight. Chand NEW to just C182S.blend and change the original C182S to C182S-HIST.blend or get rid of it.

I know what is wrong with the ExtLight object. It is a simple uv-mapping fix, not an xml fix. Git handels the blend files ok other than you don't get any tracking info like you do text. But it does track that it has changed so you know to commit it like any file.

I will push a new PR with the fix for this.

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 28, 2023

I will push a new PR with the fix for this.

Thanks Wayne!
Merged your changes into my refactoring code here.

Do you know why we have the C182SNEW.blend and what all is different in it compared to C182S.blend?

Yes I know where this model comes from. (I think) You added it then Implementing the Rain enhancement recently;
commit 4ef3716

@hbeni
Copy link
Collaborator Author

hbeni commented Nov 28, 2023

Probably we should overwrite the original dev model with the NEW model, once this settles.
I'll open a ticket for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants