Rounded corners around artwork?
#1
I'm setting up a screen with "Now Playing", where the artwork is displayed. I'm currently stock on making the artwork match my background, which has rounded corners. Is it possible to specify which corner of the artwork you want to bend?

Thanks in advance Smile
HTPC Streacom FC8 Evo, BIOSTAR Hi-Fi 3D Motherboard, Intel Core i5 4670T 2.3 GHz, 4GB Kingston HyperX, 500GB 7200 HDD, Streacom IRRC Remote
TV Sony Bravia 32" Full HD
Reply
#2
Rounded corners are achieved by applying a diffuse filter to your image.

eg

PHP Code:
<texture diffuse="YOUR_DIFFUSE_FILTER">$INFO[MusicPlayer.Cover]</texture

http://wiki.xbmc.org/index.php?title=Texture_Attributes
Reply
#3
Thank you! You're the man! Big Grin
HTPC Streacom FC8 Evo, BIOSTAR Hi-Fi 3D Motherboard, Intel Core i5 4670T 2.3 GHz, 4GB Kingston HyperX, 500GB 7200 HDD, Streacom IRRC Remote
TV Sony Bravia 32" Full HD
Reply
#4
My apologies for bumping an old thread. This one comes up as top result on google search for "Kodi rounded corners".

I was able to create a diffuse filter - PNG file that has a white rectangle with rounded corners and the edges are Alpha channel. 

However, I have no idea where to save this file so I can reference it with "diffuse". I tried the complete URL to my local server to serve this file as diffuse filter but that didn't work.

Can you please elaborate on where to save this diffuse filter  and how to reference it ? I'm running LibreElec 8.2 (Kodi 17.6) on an Odroid C2.
Reply
#5
This isn't something you can do like that - you need to do it in the skin you are using.

https://kodi.wiki/view/Skinning_Manual
Reply
#6
Thank you for your prompt response @Hitcher.

My bad, I should have elaborated on what I am doing, i.e. I'm working on creating a python add-on along with a Custom XML to create a GUI.

I was able to do the rounded corners by saving the PNG I created under <pathTo.kodi/.kodi/addons/skin.confluence/media/diffusefilter.png

and then in the XML I'm referencing it like this:

<control type="image">
<top>0</top>
<left>2</left>
<width>186</width>
<height>190</height>
<info>ListItem.Icon</info>
<texture diffuse="diffuseRoundedCorners.png"></texture>
</control>

This worked and now I have rounded corners, but I want them to look a lot more polished. Like they do in this mod:

https://forum.kodi.tv/showthread.php?tid...pid2758347

Any advice on how to get this glossy look ?

Thanks in advance.
Reply
#7
Use another image control with a transparent texture and place it after the original control so it gives the effect you want.
Reply
#8
Thanks. I'll spend some time on this and update in a day or two.
Reply

Logout Mark Read Team Forum Stats Members Help
Rounded corners around artwork?0