I have a generic "toggle switch" instrument which is configured by a user property enum for the toggle type eg "AP", "FD", "ALT HOLD" etc.
Is it possible to update the preview image dynamically based on what "toggle type" the user has selected? eg if they select AP then I want AP to show on the preview image on the panel.
Dynamic instrument preview?
-
- Posts: 17
- Joined: Wed Dec 28, 2022 11:17 am
Re: Dynamic instrument preview?
maybe the instruments info.xml file could have a "previewproperty" element that tells AM to overlay the current value of given property on the preview image that's displayed on the panel?
so if I have a property called "Toggle type" then i can tell AM to display it's current value on the preview.
so if I have a property called "Toggle type" then i can tell AM to display it's current value on the preview.
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<pluginstrument>
<aircraft>Widget - Generic</aircraft>
<type>Toggle</type>
<uuid>d4aae7e4-8988-4354-9e11-ba9a0e087374</uuid>
...
<previewproperty>Toggle type</previewproperty>
...
</pluginstrument>
Re: Dynamic instrument preview?
The answer is no. We only currently have the ability to show a single preview image. I’ve often thought it would be nice for AM to provide a user property to allow the selection of alternative preview images. I have several instruments that would benefit from this.
Air Manager panels at https://www.experimentalsimavionics.com
Youtube Channel https://www.youtube.com/channel/UC8ZqXX ... kfZMq5BKig
Air Manager API Tutorial Video Series https://youtube.com/playlist?list=PLNr0 ... baT4gJKg5D
Youtube Channel https://www.youtube.com/channel/UC8ZqXX ... kfZMq5BKig
Air Manager API Tutorial Video Series https://youtube.com/playlist?list=PLNr0 ... baT4gJKg5D