•   
  • 1
  • 2
  • 3
  • 4(current)
  • 5
  • 6
  • 12
  •   
Release script.colorbox
#46
Ok, I've added 'fixcomp'. This will return the image and comp color with fixed HLS (plus option to use 'H' to add to existing H, ie. H+0.56 or H+-0.56, it will auto max/min to 0/1, or just leave as 0.0 to do nothing).

The two colors in colors.txt will always be image + comp color, both unaffected by however you choose to process them later.

You will need to delete colors.txt again Big Grin

I will need to write all this down as I am a bit lost now!! Big Grin

Basically use 'fixcomp' or 'comp' for normal usage.
Reply
#47
@badaas I've been trying out the recent changes, and failing miserably to keep up with everything, but the results are so much better right from the start. Great job Smile
Reply
#48
(2017-08-15, 18:57)Jeroen Wrote: ...and failing miserably to keep up with everything...

Same here! hehe, thanks Big Grin
Reply
#49
Ok, I've tweaked it back a little. Reget, and delete colors.txt before restarting. Thanks.

Recap (for me!).

comp - normal
bump - bump each RGB in comp color by x amount
fixbump - as above with equation on H and fixed LS
fixcomp - both image/comp fixed LS
fix - comp is image color to LS and equation on H, image color stays same (untouched) [use this with -0.5;0.7;0.7 to get comp opposite to image color]
fixboth - image color fixed to LS, comp color is image color fixed to LS and equation on H
light - image color untouched, comp color is image color +H+L+S
hue - image color untouched, comp color is image color +H+S+V


..phew
Reply
#50
Hey @badaas any documentation beyond evaluating your demo skin?

I'd really like to incorporate some aspects of this script into my projects, Thanks.
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Twitter | Help?
Reply
#51
(2017-08-15, 20:39)Lunatixz Wrote: Hey @badaas any documentation beyond evaluating your demo skin?

I'd really like to incorporate some aspects of this script into my projects, Thanks.

Not atm, just what's here and in adonic.

I'll try document a little each day.


You can enable kodi system->logging->debug logging, then most errors will be posted to kodi.log (as well as standard python errors).

I'm trying to maintain a set of colorbox_* skin.strings for each setting (see top of Utils.py), these need to be init by skin before python can use (afaik may have changed), then any setting will be stored in that for future use.

FIVE_daemon_set, cfa_daemon_set, SEVEN_daemon_set & EIGHT_daemon_set window propertys need to be set to an effect to work (SEVEN can be any garbage as it only makes colors).
They HAVE to be exact effect name (and var name for settings), as they are used to map the functions via a dictionary, see here in default.py:
Code:
ColorBox_function_map = {
        'blur':         Utils.blur,
        'pixelate':     Utils.pixelate,
        'shiftblock':   Utils.shiftblock,
        'pixelnone':    Utils.pixelnone,
        'pixelwaves':   Utils.pixelwaves,
        'pixelrandom':  Utils.pixelrandom,
        'pixelfile':    Utils.pixelfile,
        'pixelfedges':  Utils.pixelfedges,
        'pixeledges':   Utils.pixeledges,
        'fakelight':    Utils.fakelight,
        'twotone':      Utils.twotone,
        'posterize':    Utils.posterize,
        'distort':      Utils.distort,
        'halftone':     Utils.halftone,
        'dither':       Utils.dither,
        'dataglitch':   Utils.dataglitch}
ColorBox_settings_map = {
        'pixelsize':    Utils.set_pixelsize,
        'bitsize':      Utils.set_bitsize,
        'blursize':     Utils.set_blursize,
        'black':        Utils.set_black,
        'white':        Utils.set_white,
        'hsv':          Utils.set_hsv,
        'hls':          Utils.set_hls,
        'comp':         Utils.set_comp,
        'bump':         Utils.set_bump,
        'quality':      Utils.set_quality}

I suggest if using daemon, to fire it up on Startup.xml, then delay the settings via AlarmClock. All the settings can be chained in one hit as per eg.
PHP Code:
<onfocus condition="System.HasAddon(script.colorbox)">AlarmClock(nms1,SetProperty(NINE_manual_set,"var=comp,set=fixcomp|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

Once running all daemon settings done via window property NINE.

You can also RunScript(), chaining all settings (as these will be lost in each namespace ofc.). ie.
PHP Code:
<onload>RunScript(script.colorbox,info=blur,id=$VAR[PICTURE_LOCATION],prefix=mypic1,blursize=1,quality=8)</onload

more to follow...
Reply
#52
To change via skin, use something like script.toolbox or own custom to do:

PHP Code:
        <control type="button" id="11122">
            <
description>widget</description>
            <include>
ButtonCommonValues</include>
            <
label>32009</label>
            <
label2>$INFO[Skin.String(colorbox_comp),[UPPERCASE],[/UPPERCASE]]</label2>
            <
onclick>SetProperty(RefreshItem,$LOCALIZE[32009],home)</onclick>
            <
onclick>SetProperty(Dialog.NumItems,8)</onclick>
            <
onclick>SetProperty(Dialog.1.Label,Complimentary)</onclick>
            <
onclick>SetProperty(Dialog.1.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=comp",home))</onclick>
            <
onclick>SetProperty(Dialog.2.Label,Bump RGB Comp)</onclick>
            <
onclick>SetProperty(Dialog.2.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=bump",home))</onclick>
            <
onclick>SetProperty(Dialog.3.Label,Hue HSV Main)</onclick>
            <
onclick>SetProperty(Dialog.3.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=hue",home))</onclick>
            <
onclick>SetProperty(Dialog.4.Label,Lighten HLS Main)</onclick>
            <
onclick>SetProperty(Dialog.4.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=light",home))</onclick>
            <
onclick>SetProperty(Dialog.5.Label,Fix Comp HLS)</onclick>
            <
onclick>SetProperty(Dialog.5.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=fix",home))</onclick>
            <
onclick>SetProperty(Dialog.6.Label,Fix Both HLS)</onclick>
            <
onclick>SetProperty(Dialog.6.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=fixboth",home))</onclick>
            <
onclick>SetProperty(Dialog.7.Label,Fix Main HLS)</onclick>
            <
onclick>SetProperty(Dialog.7.BuiltIn,SetProperty(NINE_manual_set,"var=comp,set=fixcomp",home))</onclick>
            <
onclick>RunScript(script.toolbox,info=selectdialog,header=Select Highlight Colorbox)</onclick>
            <
onunfocus>SetProperty(FIVE_daemon_fire,True,home)</onunfocus>
        </
control

You can 'SetProperty(FIVE_daemon_fire,True,home)' to force daemon to update.
Reply
#53
(2017-08-15, 23:49)badaas Wrote:
(2017-08-15, 20:39)Lunatixz Wrote: Hey @badaas any documentation beyond evaluating your demo skin?

I'd really like to incorporate some aspects of this script into my projects, Thanks.

Not atm, just what's here and in adonic.

I'll try document a little each day.

I suggest if using daemon, to fire it up on Startup.xml, then delay the settings via AlarmClock. All the settings can be chained in one hit as per eg.

Okay thanks, I'll have to review the code when i'm free... actually I'm hoping to use it with PseudoTV Live not a skin... Big Grin
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Twitter | Help?
Reply
#54
(2017-08-16, 00:23)Lunatixz Wrote:
(2017-08-15, 23:49)badaas Wrote:
(2017-08-15, 20:39)Lunatixz Wrote: Hey @badaas any documentation beyond evaluating your demo skin?

I'd really like to incorporate some aspects of this script into my projects, Thanks.

Not atm, just what's here and in adonic.

I'll try document a little each day.

I suggest if using daemon, to fire it up on Startup.xml, then delay the settings via AlarmClock. All the settings can be chained in one hit as per eg.

Okay thanks, I'll have to review the code when i'm free... actually i'm I'm hoping to use it with PseudoTV Live not a skin... Big Grin

Sweet, hopefully it will stand up! I'll try to support when I can Angel
Reply
#55
- added 'fixbump'
- 'fixcomp' only touches comp color now

Code:
comp - normal
bump - bump each RGB in comp color by x amount
fixbump - as above with equation on H and fixed LS
fixcomp - comp color fixed LS only
fix - comp is image color to LS and equation on H, image color stays same (untouched) [use this with -0.5;0.7;0.7 to get comp opposite to image color etc.]
fixboth - image color fixed to LS, comp color fixed to LS and equation on H
fixmain - image color +H, fixed L+S
light - image color untouched, comp color is image color +H+L+S
hue - image color untouched, comp color is image color +H+S+V

I've added a quick options to skin.adonic @ https://github.com/BADMS/skin.adonic

Hopefully out of all this you get what you want!!
If not let me know Big Grin
Reply
#56
Loving the latest changes. This script really takes skins to the next level Big Grin.

Edit: the multi support is really nice as well.
Reply
#57
(2017-08-16, 21:52)realjohngalt Wrote: Loving the latest changes. This script really takes skins to the next level Big Grin.

Edit: the multi support is really nice as well.

Thanks, if I can find time, the multis would be better for all ops. That way you wouldn't be tied FIVE EIGHT NINE etc.. but, time will tell Wink

If anyone is using Libreelec or any other *elec, can they test. Mine seems a little fussy (as linux is!).
Reply
#58
(2017-08-16, 23:07)badaas Wrote:
(2017-08-16, 21:52)realjohngalt Wrote: Loving the latest changes. This script really takes skins to the next level Big Grin.

Edit: the multi support is really nice as well.

Thanks, if I can find time, the multis would be better for all ops. That way you wouldn't be tied FIVE EIGHT NINE etc.. but, time will tell Wink

If anyone is using Libreelec or any other *elec, can they test. Mine seems a little fussy (as linux is!).
It's good with LE8.1 and master, I just had to reboot after switching to a skin with colorbox.
Reply
#59
badaas,

great job with this script! I really enjoy the implementation on Horizon
Reply
#60
@badaas -- it seems on the latest that with "fixboth" the hue value is affecting both the main and comp colour rather than just the comp. If I change the hue value, I get a different main colour which afaik shouldn't be happening.
Reply
  •   
  • 1
  • 2
  • 3
  • 4(current)
  • 5
  • 6
  • 12
  •   



Logout Mark Read Team Forum Stats Members Help
script.colorbox1
This forum uses Lukasz Tkacz MyBB addons.