I'm sorry, I'm still not understanding.
You want me to make a new, random flag for the video info screen based on the filename of what's in the video player? And then what?
And then how am I figuring out what I need to override the 'default' audio flag based on the filename, that's different for what works in the menu screens?
And I've posted all the audio relevant code from the variables.xml file. I've had to create it all myself as there are no other audio flag overrides in this skin. There are those for source flags and various other variables don't know about but nothing else for audio. I built the posted code based on the source code that already exists. But there's something not correct in it to get it to work.
Source code flag override in variable.xml
Code:
<variable name="SourceFlagVar">
<value condition="[SubString(ListItem.filename,PDTV) | SubString(ListItem.filename,sdtv) | SubString(ListItem.filename,sd tv)]">sdtv</value>
<value condition="[SubString(ListItem.Filename,hdtv) | SubString(ListItem.Filename,hd tv)]">hdtv</value>
<value condition="[SubString(ListItem.Filename,hddvd) | SubString(ListItem.Filename,hd-dvd)]">hddvd</value>
<value condition="[SubString(ListItem.Filename,bluray) | SubString(ListItem.Filename,blu-ray) | SubString(ListItem.Filename,bdrip) | SubString(ListItem.Filename,brrip)] + [SubString(ListItem.Filename,.3D.) | SubString(ListItem.Filename,3DBD)]">bluray3d</value>
<value condition="[SubString(ListItem.Filename,bluray) | SubString(ListItem.Filename,blu-ray) | SubString(ListItem.Filename,bdrip) | SubString(ListItem.Filename,brrip)]">bluray</value>
<value condition="SubString(ListItem.Filename,dvb)">dvb</value>
<value condition="SubString(ListItem.Filename,web-dl)">web-dl</value>
<value condition="SubString(ListItem.Filename,dvd) | StringCompare(ListItem.FileExtension,iso) | StringCompare(ListItem.FileExtension,ifo)">dvd</value>
<value>$INFO[ListItem.VideoCodec]</value>
</variable>
<variable name="VideoSourceFlagVar">
<value condition="[SubString(Player.Filenameandpath,PDTV) | SubString(Player.Filenameandpath,sdtv)]">sdtv</value>
<value condition="SubString(Player.Filenameandpath,hdtv)">hdtv</value>
<value condition="[SubString(Player.Filenameandpath,hddvd) | SubString(Player.Filenameandpath,hd-dvd)]">hddvd</value>
<value condition="[SubString(Player.Filenameandpath,bluray) | SubString(Player.Filenameandpath,blu-ray) | SubString(Player.Filenameandpath,bdrip) | SubString(Player.Filenameandpath,brrip)] + [SubString(Player.Filenameandpath,.3D.) | SubString(Player.Filenameandpath,3DBD)]">bluray3d</value>
<value condition="[SubString(Player.Filenameandpath,bluray) | SubString(Player.Filenameandpath,blu-ray) | SubString(Player.Filenameandpath,bdrip) | SubString(Player.Filenameandpath,brrip)]">bluray</value>
<value condition="SubString(Player.Filenameandpath,dvb)">dvb</value>
<value condition="SubString(Player.Filenameandpath,web-dl)">web-dl</value>
<value condition="SubString(Player.Filenameandpath,dvd) | SubString(Player.Filenameandpath,.iso,Right) | SubString(Player.Filenameandpath,.ifo,Right)">dvd</value>
<value>$INFO[VideoPlayer.VideoCodec]</value>
</variable>
Audio code flag override created in variables.xml
Code:
<variable name="AudioFlagVar">
<value condition="SubString(ListItem.Filenameandpath,atmos)">atmoslogo2</value>
<value>$INFO[ListItem.AudioCodec]$INFO[ListItem.AudioChannels]</value>
</variable>
<variable name="AudioFlagVar">
<value condition="SubString(Player.Filename,atmos)">atmoslogo2.png</value>
<value>$INFO[VideoPlayer.AudioCodec]$INFO[VideoPlayer.AudioChannels]</value>
</variable>
The first half of the audio code overrides the scraped/stream audio codec information (Dolby TrueHD 7.1) and instead displays a custom Atmos logo.
The second line of code seems to be correct based on the working Source code above yet does not work as the first audio code does. This is where I'm stuck.
If you know the answer please sort it out. But it seems you are wanting to lead me with a dangling carrott to "learn" this myself. I've tried, and tried, and tried. But nothing I've found in the online manual or from discecting the code explains what string or substring or whatever I need to properly get the videoplayer on screen info audio source flag to be overridder.
The only source flag I can find, and remove if I wish, for the OSD is in the DialgueFullScreenInfo.xml file and is as follws.
Code:
<control type="image">
<left>1745</left>
<texture fallback="flags/audio/defaultsound.png">$VAR[ColorFlagsAudio]audio/$INFO[VideoPlayer.AudioCodec]$INFO[VideoPlayer.AudioChannels,,.png]</texture>
<include>OSDFlagVars</include>
</control>
That just confuses me even more.