Music Visualization OSD, add info like bitrate depth?
#1
How can i customize info in Music Visualization OSD?
Is possible?

The OSD show me:
- file type with logo (mp3, flac etc...)
- sample frequency (44Khz, 96Khz etc..)
- file kbps
- music classification (pop, classical etc..)

so is possible to add file smaple bit depth (16bit, 24bit etc..)?
and the file channel info (2.0 or 5.1)?

Thanks
Reply
#2
if you know how to mod a skin, you can add these:

Quote:MusicPlayer.Channels Number of channels of current song
MusicPlayer.BitsPerSample Number of bits per sample of current song
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#3
Thanks for the info. I had to do a little more research since I'm pretty new to modifying skins, but I was able to figure it out. I made a few of modifications to the confluence skin, including the bit rate, year, as well as changing the duration to the right of the progress bar to time remaining, and moving the duration above that. I also changed the width of the portion that contains the title, codec, and bitrate so that if the song title is very long it wont overlap with the duration. Here's a screenshot, as well as the contents of the modified MusicVisualization.xml located in /usr/share/xbmc/addons/skin.confluence/720p (in linux, for windows it would probably be in C:\program files\xbmc\...).

Image

Code:
<window id="2006">
    <defaultcontrol>-</defaultcontrol>
    <allowoverlay>no</allowoverlay>
    <controls>
        <control type="visualisation" id="2">
            <!-- FIX ME Music Visualization needs to have an id of 2 in this window to be able to lock or change preset -->
            <description>visualisation</description>
            <posx>0</posx>
            <posy>0</posy>
            <width>1280</width>
            <height>720</height>
        </control>
        <!-- media infos -->
        <control type="group">
            <animation effect="fade" time="200">VisibleChange</animation>
            <visible>[Player.ShowInfo | Window.IsActive(MusicOSD)] + ![Window.IsVisible(AddonSettings) | Window.IsVisible(SelectDialog) | Window.IsVisible(VisualisationPresetList)]</visible>
            <control type="image">
                <posx>0</posx>
                <posy>-150</posy>
                <width>1280</width>
                <height>256</height>
                <texture flipy="true">HomeNowPlayingBack.png</texture>
            </control>
            <control type="label">
                <description>Partymode Header label</description>
                <posx>30</posx>
                <posy>5</posy>
                <width>800</width>
                <height>25</height>
                <align>left</align>
                <aligny>center</aligny>
                <font>font13</font>
                <textcolor>white</textcolor>
                <shadowcolor>black</shadowcolor>
                <label>$LOCALIZE[589]</label>
                <visible>MusicPartyMode.Enabled</visible>
            </control>
            <control type="label">
                <description>Normal Header label</description>
                <posx>30</posx>
                <posy>5</posy>
                <width>800</width>
                <height>25</height>
                <align>left</align>
                <aligny>center</aligny>
                <font>font13</font>
                <textcolor>white</textcolor>
                <shadowcolor>black</shadowcolor>
                <label>$INFO[musicplayer.Playlistposition,$LOCALIZE[554]: ]$INFO[musicplayer.Playlistlength, / ]</label>
                <visible>!MusicPartyMode.Enabled</visible>
            </control>
            <control type="label">
                <description>Clock label</description>
                <posx>1250</posx>
                <posy>5</posy>
                <width>800</width>
                <height>25</height>
                <align>right</align>
                <aligny>center</aligny>
                <font>font13</font>
                <textcolor>white</textcolor>
                <shadowcolor>black</shadowcolor>
                <label>$INFO[System.Time]</label>
                <animation effect="slide" start="0,0" end="-70,0" time="0" condition="Window.IsVisible(MusicOSD)">conditional</animation>
            </control>
            <control type="image">
                <posx>0</posx>
                <posy>230r</posy>
                <width>1280</width>
                <height>230</height>
                <texture>HomeNowPlayingBack.png</texture>
            </control>
            <control type="image">
                <description>cover image</description>
                <posx>20</posx>
                <posy>250r</posy>
                <width>300</width>
                <height>230</height>
                <info>MusicPlayer.Cover</info>
                <aspectratio aligny="bottom">keep</aspectratio>
                <bordertexture border="8">ThumbShadow.png</bordertexture>
                <bordersize>8</bordersize>
            </control>
            <control type="group">
                <posx>330</posx>
                <posy>175r</posy>
                <control type="label" id="1">
                    <description>Heading label</description>
                    <posx>0</posx>
                    <posy>0</posy>
                    <width>910</width>
                    <height>25</height>
                    <align>left</align>
                    <font>font13</font>
                    <label>$LOCALIZE[31040]</label>
                    <textcolor>white</textcolor>
                    <shadowcolor>black</shadowcolor>
                    <animation effect="slide" start="0,0" end="0,25" time="0" condition="IsEmpty(MusicPlayer.Artist) + IsEmpty(MusicPlayer.Album)">conditional</animation>
                </control>
                <control type="label" id="1">
                    <description>Artist label</description>
                    <posx>20</posx>
                    <posy>30</posy>
                    <width>910</width>
                    <height>25</height>
                    <align>left</align>
                    <font>font12</font>
                    <label>$INFO[MusicPlayer.Artist] - $INFO[MusicPlayer.Album] ($INFO[MusicPlayer.Year])</label>
                    <textcolor>grey2</textcolor>
                    <shadowcolor>black</shadowcolor>
                </control>
                <control type="grouplist">
                    <posx>20</posx>
                    <posy>60</posy>
                    <width>850</width>
                    <height>35</height>
                    <itemgap>5</itemgap>
                    <orientation>horizontal</orientation>
                    <control type="label">
                        <width min="10" max="650">auto</width>
                        <height>30</height>
                        <font>font30</font>
                        <align>left</align>
                        <aligny>center</aligny>
                        <label>$INFO[MusicPlayer.Title]</label>
                        <textcolor>orange</textcolor>
                        <scroll>true</scroll>
                    </control>
                    <control type="image">
                        <description>Audio Codec Image</description>
                        <width>80</width>
                        <height>35</height>
                        <aspectratio align="right">keep</aspectratio>
                        <texture>$INFO[MusicPlayer.Codec,flagging/audio/,.png]</texture>
                    </control>
                    <control type="label" id="1">
                        <description>Bit Rate</description>
                        <width min="10" max="80">auto</width>
                        <height>30</height>
                        <align>left</align>
                        <aligny>center</aligny>
                        <font>font28</font>
                        <label>$INFO[MusicPlayer.BitRate]k</label>
                        <textcolor>white</textcolor>
                        <shadowcolor>black</shadowcolor>
                    </control>
                </control>
                <control type="label">
                    <posx>0</posx>
                    <posy>120</posy>
                    <width>910</width>
                    <height>25</height>
                    <label>$LOCALIZE[209]: $INFO[MusicPlayer.offset(1).Artist,, - ]$INFO[MusicPlayer.offset(1).Title]</label>
                    <align>center</align>
                    <aligny>center</aligny>
                    <font>font12</font>
                    <textcolor>grey</textcolor>
                    <scroll>true</scroll>
                    <visible>MusicPlayer.HasNext + !Window.IsVisible(MusicOSD)</visible>
                    <animation effect="fade" time="200">VisibleChange</animation>
                </control>
            </control>
            <control type="group">
                <posx>330</posx>
                <posy>85r</posy>
                <control type="label">
                    <posx>0</posx>
                    <posy>0</posy>
                    <width>100</width>
                    <height>40</height>
                    <font>font13</font>
                    <align>left</align>
                    <aligny>center</aligny>
                    <label>$INFO[Player.Time(hh:mm:ss)]</label>
                </control>
                <control type="progress">
                    <description>Progressbar</description>
                    <posx>100</posx>
                    <posy>15</posy>
                    <width>720</width>
                    <height>16</height>
                    <info>Player.Progress</info>
                </control>
                <control type="label">
                    <posx>920</posx>
                    <posy>0</posy>
                    <width>100</width>
                    <height>40</height>
                    <font>font13</font>
                    <align>right</align>
                    <aligny>center</aligny>
                    <label>$INFO[Player.TimeRemaining(hh:mm:ss)]</label>
                </control>
                <control type="label">
                    <posx>920</posx>
                    <posy>-30</posy>
                    <width>100</width>
                    <height>40</height>
                    <font>font13</font>
                    <align>right</align>
                    <aligny>center</aligny>
                    <label>$INFO[Player.Duration(hh:mm:ss)]</label>
                </control>
            </control>
        </control>
        <!-- codec & viz infos -->
        <control type="group" id="0">
            <posx>0</posx>
            <posy>50</posy>
            <visible>Player.ShowCodec + ![Window.IsVisible(script-XBMC_Lyrics-main.xml) | Window.IsVisible(VisualisationSettings) | Window.IsVisible(VisualisationPresetList)]</visible>
            <animation effect="fade" time="200">VisibleChange</animation>
            <control type="image">
                <description>media info background image</description>
                <posx>0</posx>
                <posy>0</posy>
                <width>1280</width>
                <height>105</height>
                <colordiffuse>AAFFFFFF</colordiffuse>
                <texture>black-back.png</texture>
            </control>
            <control type="label">
                <description>row 1 label</description>
                <posx>50</posx>
                <posy>10</posy>
                <label>-</label>
                <align>left</align>
                <label>$INFO[musicplayer.Codec,$LOCALIZE[21446]: ,]$INFO[musicplayer.Bitrate, · $LOCALIZE[623]: ,kbps]$INFO[musicplayer.bitspersample, · $LOCALIZE[612]: ,bit]$INFO[musicplayer.Samplerate, · $LOCALIZE[613]: ,kHz]$INFO[musicplayer.Channels, · $LOCALIZE[21444]: ]</label>
                <font>font12</font>
            </control>
            <control type="label">
                <description>row 2 label</description>
                <posx>50</posx>
                <posy>40</posy>
                <label>-</label>
                <align>left</align>
                <label>$INFO[Visualisation.Name] [i][color=orange]($LOCALIZE[20166])[/color][/i] · fps: $INFO[System.FPS]</label>
                <font>font12</font>
                <visible>Visualisation.Locked</visible>
            </control>
            <control type="label">
                <description>Unlocked row 2 label</description>
                <posx>50</posx>
                <posy>40</posy>
                <label>-</label>
                <align>left</align>
                <label>$INFO[Visualisation.Name] · fps: $INFO[System.FPS]</label>
                <font>font12</font>
                <visible>!Visualisation.Locked</visible>
            </control>
            <control type="label">
                <description>row 3 label</description>
                <posx>50</posx>
                <posy>70</posy>
                <label>-</label>
                <align>left</align>
                <label>$LOCALIZE[13388]: $INFO[Visualisation.Preset]</label>
                <font>font12</font>
            </control>
        </control>
    </controls>
</window>
Reply
#4
I made something like this

Image
Reply

Logout Mark Read Team Forum Stats Members Help
Music Visualization OSD, add info like bitrate depth?0