VideoOSD
#1
I have this code in VideoOSD :

Code:
<control type="slider" id="87" description="Seek Slider">
    <posx>100</posx>
    <posy>40</posy>
    <width>1070</width>
    <height>24</height>
    <onup>-</onup>
    <ondown>-</ondown>
    <action>seek</action>
    <texturesliderbar border="14,0,14,0">OSD/OSDProgressBack.png</texturesliderbar>
    <textureslidernib border="8">OSD/SeekNibNF.png</textureslidernib>
    <textureslidernibfocus border="8">OSD/SeekNibFO.png</textureslidernibfocus>
    </control>

but I'm unable to make a NIB (24x24px) keep aspect ratio. It always gets stretched. What am I missing?
My skins:

Amber
Quartz

Reply
#2
Tried border="12" ?
Reply
#3
Hitcher Wrote:Tried border="12" ?

Just tried it. It still makes bar out of nib.
My skins:

Amber
Quartz

Reply
#4
Its a bug basically you can't because the size of the nib is calculated by the size of the slider background so what you need to do is fart around wih OSD/OSDProgressBack.png and inscrease its dimensions (width mostly) like I had too with confluence Sad
Reply
#5
I'm happy to change things around if there's a better idea - remember that most controls scale to their defined rect size, so atm we basically assume that all textures should scale by the same amount that the background does.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#6
Jezz_X Wrote:Its a bug basically you can't because the size of the nib is calculated by the size of the slider background so what you need to do is fart around wih OSD/OSDProgressBack.png and inscrease its dimensions (width mostly) like I had too with confluence Sad

Thanks, I wondered how you did it. I'll take a peek.
My skins:

Amber
Quartz

Reply
#7
jmarshall Wrote:I'm happy to change things around if there's a better idea - remember that most controls scale to their defined rect size, so atm we basically assume that all textures should scale by the same amount that the background does.

I'm little confused. NIB seams to work just fine in scrollbars, which led me to think that NIB is an image that has aspectratio=keep hardwired.
My skins:

Amber
Quartz

Reply
#8
I agree that the Slider Nib should not be scaled with the background when it comes to the OSDs. They are after all indicating a specific, single point in the progress of whatever's playing.
Reply
#9
@ pecinko

You could try padding it with empty space on the right of the image and then set the border to cover the part you don't want scaled.
Reply
#10
Which bit is scaled? Is it scaled with height and width or with both? As I say, am happy to change it to not scale at all, or only scale in one dimension and keep aspect otherwise etc.

Just let me know a recipe that'll work for you all and I'll apply it Smile

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#11
I'd go for height scaling so the maths works like this

image are background = 16 pixels high, nib = 32 pixels high

in skin background gets sized to 8 pixels high then nib gets sized to 16 pixels high and keeps its aspect and is aligned with the slider in the center of the nib not the start of it
Reply
#12
https://github.com/jmarshallnz/xbmc/tree...spect_keep

That should do what you want I think?
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#13
jmarshall Wrote:That should do what you want I think?

I cannot build, but if it behaves as in Jezz_X's explanation - that's the way.
My skins:

Amber
Quartz

Reply

Logout Mark Read Team Forum Stats Members Help
VideoOSD0