• 1
  • 2
  • 3(current)
  • 4
  • 5
  • 15
Release script.colorbox
#31
(2017-08-14, 17:44)realjohngalt Wrote:
(2017-08-14, 11:06)badaas Wrote:
(2017-08-13, 18:00)realjohngalt Wrote: I'm interested in using colorbox with multiiimage. Is there currently any support or options for this? While using SEVEN on a multiimage, it flashes through the colors faster than my multiimage is set.

Anyway, great work as always on the new functionality -- I look forward to trying it out Smile

Edit: btw, the latest capabilities are great. I'm using the following now, and the CColor looks great most of the time

Code:
<onfocus condition="System.HasAddon(script.colorbox)">AlarmClock(nms1,SetProperty(NINE_manual_set,"var=comp,set=hue|var=bump,set=16|var=hsv,set=0;-0.2;0.2|var=quality,set=8|var=blursize,set=1|var=bitsize,set=1|var=pixelsize,set=12|var=black,set=000000|var=white,set=ffffff",home),00:05,true)</onfocus>

Thanks!
Everything is done by multis, try using FIVE, not sure if SEVEN just processes art(fanart) colour not image and not images supplied..
Unfortunately with FIVE I get the same result. I can also confirm that SEVEN is using the multiimage art that's given to it in 7977. It flashes through the colors for all the multiimage art maybe every ~1/4 second, but I have the multiimage it's provided set to 6 seconds.

If I go to a multiimage that's only provided one image, there's no problem at all.

Edit: colorbox is disabled in these photos, but it gives you an idea. I'm using colorbox to color the focused gradient, with the poster (on supported titles) cycling every 6 seconds after loading: http://imgur.com/a/k5pwU

Here's the skin commit where I switched to multiimage for poster: https://gitlab.com/RealJohnGalt/skin.fus...2f4e95b0d0

And colorbox uses that Image_Poster var in 7977 (was 7975 when testing FIVE)

Ok, where is:

Code:
<control type="multiimage" id="7977">

and 7977 only returns color, it doesn't process any effects.
Reply
#32
(2017-08-14, 17:58)badaas Wrote: and 7977 only returns color, it doesn't process any effects.

Say I want to only get colours, will using 7977 instead of 7975 benefit performance in any way? And in what aspect do FIVE, SEVEN, NINE, etc. actually differ? It's not really clear to me why these exist and when I should use which. Previously I thought they were just some sort of preset.
Reply
#33
(2017-08-14, 18:25)Jeroen Wrote:
(2017-08-14, 17:58)badaas Wrote: and 7977 only returns color, it doesn't process any effects.

Say I want to only get colours, will using 7977 instead of 7975 benefit performance in any way? And in what aspect do FIVE, SEVEN, NINE, etc. actually differ? It's not really clear to me why these exist and when I should use which. Previously I thought they were just some sort of preset.

Yeah so 7977 (SEVEN) will only process color, so less overhead.

NINE is used to change variables or to use instead of RunScript(). You set window property 'NINE_manual_set' to what you want to do, ie. change blur size, pixel size etc. Or process an image with a unique prefix etc.
FIVE and EIGHT are the same, process image and colors.
Set property 'cfa_demon_set' to blur or posterize etc, it will process current 'ListItem.art(fanart)'. And return image and colors (see Default.py for property names). Will not process anything if 'cfa_demon_set' is empty or not set.

Then you also have RunScript() support.

I will try to find time to lay it all out soon Big Grin
Reply
#34
(2017-08-14, 12:41)jurialmunkey Wrote: @badaas

Yeah still happens when deleting colors.txt

It only happens when I use quite high values for HSV e.g. (0;0.7;0.9)
Though I see that it adds to the value which is not really what I had in mind anyway. I was more looking for something to fix the value at certain level -- e.g. so the saturation would always be at 0.7 and the value at 0.9 no matter what the colour returned was.

Ok, so now you have 'fix' and it uses HLS.
It will fix the L+S to whatever is in 'color_hls' for both comp color and image color.
If you want to invert comp color set color_hls 'H' to -1.0, then the other L+S fixed luminance/saturation values.

There is now a check to clamp > 1.0 (it will sub the diff and return that value, ie. 1.8 - 1.0 == 0.8).

PLEASE delete colors.txt again!

Sample startup, now with color_hls:
PHP Code:
<onfocus condition="System.HasAddon(script.colorbox)">AlarmClock(nms1,SetProperty(NINE_manual_set,"var=comp,set=fix|var=bump,set=16|var=hsv,set=0;-0.2;0.2|var=hls,set=0.0;0.7;0.7|var=quality,set=$INFO[Skin.String(colorbox_quality)]|var=blursize,set=$INFO[Skin.String(colorbox_blursize)]|var=bitsize,set=$INFO[Skin.String(colorbox_bitsize)]|
var=pixelsize,set=
$INFO[Skin.String(colorbox_pixelsize)]|
var=black,set=
$INFO[Skin.String(colorbox_black)]|var=white,set=$INFO[Skin.String(colorbox_white)]",home),00:05,true)</onfocus

@ https://github.com/BADMS/script.colorbox

edit: I may change to 'fix' & 'fixboth', where the latter fixes L+S for both colors, the former only comp color.. done on git
Reply
#35
(2017-08-14, 17:58)badaas Wrote:
(2017-08-14, 17:44)realjohngalt Wrote:
(2017-08-14, 11:06)badaas Wrote: Thanks!
Everything is done by multis, try using FIVE, not sure if SEVEN just processes art(fanart) colour not image and not images supplied..
Unfortunately with FIVE I get the same result. I can also confirm that SEVEN is using the multiimage art that's given to it in 7977. It flashes through the colors for all the multiimage art maybe every ~1/4 second, but I have the multiimage it's provided set to 6 seconds.

If I go to a multiimage that's only provided one image, there's no problem at all.

Edit: colorbox is disabled in these photos, but it gives you an idea. I'm using colorbox to color the focused gradient, with the poster (on supported titles) cycling every 6 seconds after loading: http://imgur.com/a/k5pwU

Here's the skin commit where I switched to multiimage for poster: https://gitlab.com/RealJohnGalt/skin.fus...2f4e95b0d0

And colorbox uses that Image_Poster var in 7977 (was 7975 when testing FIVE)

Ok, where is:

Code:
<control type="multiimage" id="7977">

and 7977 only returns color, it doesn't process any effects.
It's in MyVideoNav.xml, here https://gitlab.com/RealJohnGalt/skin.fus...av.xml#L11

And it's set to Image_Poster elsewhere like: <value condition="!Skin.HasSetting(FanartForColorbox)">$VAR[Image_Poster]</value>

Regarding the effects, it returns new colors faster than the multiimage cycles the images. Maybe every 1/4 or 1/3 of a second it returns a new color, so it's very fast.
Reply
#36
(2017-08-14, 18:50)badaas Wrote:
(2017-08-14, 18:25)Jeroen Wrote:
(2017-08-14, 17:58)badaas Wrote: and 7977 only returns color, it doesn't process any effects.

Say I want to only get colours, will using 7977 instead of 7975 benefit performance in any way? And in what aspect do FIVE, SEVEN, NINE, etc. actually differ? It's not really clear to me why these exist and when I should use which. Previously I thought they were just some sort of preset.

Yeah so 7977 (SEVEN) will only process color, so less overhead.

NINE is used to change variables or to use instead of RunScript(). You set window property 'NINE_manual_set' to what you want to do, ie. change blur size, pixel size etc. Or process an image with a unique prefix etc.
FIVE and EIGHT are the same, process image and colors.
Set property 'cfa_demon_set' to blur or posterize etc, it will process current 'ListItem.art(fanart)'. And return image and colors (see Default.py for property names). Will not process anything if 'cfa_demon_set' is empty or not set.

Then you also have RunScript() support.

I will try to find time to lay it all out soon Big Grin

Check. That already clears up a lot, thanks!
Reply
#37
@badaas, Thank you again for all your help! I feel like an idiot, but I just had to set the timeperimage for 7977 to match (6300 in this case due to 6000 timeperimage on poster and 300 fadetime). Commit for reference: https://gitlab.com/RealJohnGalt/skin.fus...e4c9e5423f

Now I'll play with the new HLS stuff Smile
Reply
#38
(2017-08-14, 22:00)realjohngalt Wrote: @badaas, Thank you again for all your help! I feel like an idiot, but I just had to set the timeperimage for 7977 to match (6300 in this case due to 6000 timeperimage on poster and 300 fadetime). Commit for reference: https://gitlab.com/RealJohnGalt/skin.fus...e4c9e5423f

Now I'll play with the new HLS stuff Smile

Good work ! Big Grin
Reply
#39
(2017-08-14, 21:44)Jeroen Wrote:
(2017-08-14, 18:50)badaas Wrote:
(2017-08-14, 18:25)Jeroen Wrote: Say I want to only get colours, will using 7977 instead of 7975 benefit performance in any way? And in what aspect do FIVE, SEVEN, NINE, etc. actually differ? It's not really clear to me why these exist and when I should use which. Previously I thought they were just some sort of preset.

Yeah so 7977 (SEVEN) will only process color, so less overhead.

NINE is used to change variables or to use instead of RunScript(). You set window property 'NINE_manual_set' to what you want to do, ie. change blur size, pixel size etc. Or process an image with a unique prefix etc.
FIVE and EIGHT are the same, process image and colors.
Set property 'cfa_demon_set' to blur or posterize etc, it will process current 'ListItem.art(fanart)'. And return image and colors (see Default.py for property names). Will not process anything if 'cfa_demon_set' is empty or not set.

Then you also have RunScript() support.

I will try to find time to lay it all out soon Big Grin

Check. That already clears up a lot, thanks!

You also have an unlimited number of multis you can set (atm these are a one shot setup, they can't be changed once daemon is running).

PHP Code:
RunScript(script.colorbox,daemon=True,multis=$NUMBER[7988]:MYMULTI_ONE.:blur|$NUMBER[7989]:MYMULTI_TOO.:pixelate

that is multi ID, the name of the window property 'MYMULTI_ONE' will give you 'MYMULTI_ONE.ImageFilter', 'MYMULTI_ONE.Image', 'MYMULTI_ONE.ImageColor', 'MYMULTI_ONE.ImageCColor', and effect to use. Each multi seprated by '|' and vars within that by ':'
Reply
#40
@badaas -- the "fixboth" setting is working fantastic, exactly what I wanted. One request: it seems like with "fix both" that both the main colour and the comp colour are set as the same hue -- is it possible to have the comp colour hue inverted (or even better, use the first value in the HLS tuple as an additive value like in HSV one)?
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#41
(2017-08-15, 08:54)jurialmunkey Wrote: @badaas -- the "fixboth" setting is working fantastic, exactly what I wanted. One request: it seems like with "fix both" that both the main colour and the comp colour are set as the same hue -- is it possible to have the comp colour hue inverted (or even better, use the first value in the HLS tuple as an additive value like in HSV one)?

Yeah I left I it so if you set 'H' to -1.0 it will subtract the hue, it will only do this for comp colour, image hue is left as is.

Code:
var=hls,set=-1.0;0.7;0.7
Reply
#42
@badaas - I did try that before. I figured out why I thought it wasn't working -- it seems that it is only switching the Green and Blue channel of RGB hex values (put them in my debug overlay to check) rather than finding the colour which is 180 degrees away.

e.g. I have one colour #0cb6f2 and its complimentary is returning as #0cf2b6 -- However, it should be #f2490c as that is its opposite on the colour wheel. The problem is if I have a colour which is say #11EEEE then I will get exactly the same colour for complimentary, but its complimentary should be #EE1111

EDIT: Nevermind. Just need to use -0.5 for the hue value instead of -1.0
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#43
(2017-08-15, 11:33)jurialmunkey Wrote: @badaas - I did try that before. I figured out why I thought it wasn't working -- it seems that it is only switching the Green and Blue channel of RGB hex values (put them in my debug overlay to check) rather than finding the colour which is 180 degrees away.

e.g. I have one colour #0cb6f2 and its complimentary is returning as #0cf2b6 -- However, it should be #f2490c as that is its opposite on the colour wheel. The problem is if I have a colour which is say #11EEEE then I will get exactly the same colour for complimentary, but its complimentary should be #EE1111

EDIT: Nevermind. Just need to use -0.5 for the hue value instead of -1.0

Ok, I'm guessing 0.5 is 180°, I'm no expert on hls hsv hsb rgb atm lol
If you have a link to the colour wheel I can have a look.

edit: found this for now www.ethangardner.com/articles/2009/03/15/a-math-based-approach-to-color-theory-using-hue-saturation-and-brightness-hsb
Reply
#44
@jurial can you try

Code:
var=hls,set=0.5-1.0;0.7;0.7
Reply
#45
Quote:Ok, I'm guessing 0.5 is 180°, I'm no expert on hls hsv hsb rgb atm lol
If you have a link to the colour wheel I can have a look.

edit: found this for now www.ethangardner.com/articles/2009/03/15/a-math-based-approach-to-color-theory-using-hue-saturation-and-brightness-hsb

This is basically how I am doing it once u get your overall color tuple convert hls check ur hue and if I remember add.5 which is the 180 for you complentary and bring saturation to at .75 as most time the colors will be 2 washed out with a lower saturation.

Also to get your normal traid color wheel you could plus and minus .33 on the hue. That way u will have overall color plus 2 complentary colors keeping in mind that saturation need to be up for them to look any kinda way.

Once done repack hls and convert back to rbg for Kodi 2 use.

And maybe u already said all this I just read the previous post.
Reply
  • 1
  • 2
  • 3(current)
  • 4
  • 5
  • 15

Logout Mark Read Team Forum Stats Members Help
script.colorbox1