Skip to content
EyeOdin edited this page Mar 24, 2026 · 32 revisions

Introduction

Pigment.O Picker is a color picker and color managment tool. The engine is color agnostic which allows compatibility between various color spaces regadless of the color space and bit depth of the active document guiding it. This level of color abstraction allows for independant scalability.

Pigment.O Sampler can create Masks by sampling colors from the active document and takes into consideration the selection and transparency context.

Pigment.O has also a valid API for other plugins to use.



Interface Installed

After installation the dockers will present them selves:

  • Picker with Panel Square in HSV.
  • Sampler with Channels in SRGB.

Picture

Picture



Picker Interface

Picture

  • Header : Color display ( Pixel, Vector, Menu )
  • Harmony : Harmony swatches ( Analagous, Tetradic, Triadic, Complementary, Monochromatic )
  • Panel : Graphical interface ( Display, Selector, Mixer )
  • Channel : Color space sliders ( GRAY, SRGB, LRGB, CMYK, RYB, YUV, HSV, HSL, HCY, ARD, XYZ, XYY, LAB, LCH )
  • Mixer : Linear interpolation between colors ( Kelvin, Pole, Linear )
  • Pin : Pin colors ( 11 slots )
  • History : History of selected colors
  • Mode : Update cycle mode
    • ON : Read=True and Write=True ( Default )
    • WRITE : Read=False and Write=True ( for when Picker is too heavy )
    • READ : Read=True and Write=False ( for Krita troubleshooting with the docker Log Viewer )
    • OFF : Read=False and Write=False ( for when something goes wrong )
  • Options : Various operations with icons
    • Fill Pixel : Fill active layer pixels with active color
    • Sample Screen : Pick a color from anywhere in the screen
  • Label : Display edit information
  • Code : Display numbers
    • #Hex : Active color hex code ( input and output )
      • hex6 - #RRGGBB
      • hex3 - #RGB
      • color_value - SRG( 255, 0, 0 )
      • color_name - "red", "green", "blue"
    • ΣSUM : Active code CMYK Sum ( output only )
  • Settings : Opens the settings dialog

Picker Settings

Picture



Sampler Interface

Picture

  • Panel : Graphical interface
  • Selection : Mode selection ( Channel, Range )
  • Color Space : Color space ( GRAY, SRGB, LRGB, CMYK, RYB, YUV, HSV, HSL, HCY, ARD, XYZ, XYY, LAB, LCH )
  • Split Method : Color split method
    • Channel : Split colors by color space
    • Range : Split colors by color range
    • LUT : Modifiy colors by using a LUT
  • Mask Generate : Generate maps for the active document
  • Mask Insert : Insert local selection mask into active layer
  • Settings : Opens the settings dialog

Sampler Settings

Picture



API - Aplication Programming Interface

Pigment.O Picker and Sampler allows other plugins/scripts to make requests for color math transformations or apply colors into Krita using their color management process and process other operations.

Import Pigment.O

import krita
pyid_picker = "pykrita_pigment_o_picker_docker"
pyid_sampler = "pykrita_pigment_o_sampler_docker"
docker_list = Krita.instance().dockers()
for docker in docker_list:
    try:
        if docker.objectName() == pyid_picker:
            pigment_o_picker = docker
            break
    except:
        pass
for docker in docker_list:
    try:
        if docker.objectName() == pyid_sampler:
            pigment_o_sampler = docker
            break
    except:
        pass

Picker API Commands

kac         = pigment_o_picker.API_Request_FG( self )
kbc         = pigment_o_picker.API_Request_BG( self )
wheel       = pigment_o_picker.API_Request_Wheel_Space( self )

name        = pigment_o_picker.API_Color_Name( self, hex6 )
convert     = pigment_o_picker.API_Color_Convert( self, mode, var_1, var_2, var_3, var_4, color_index )
interpolate = pigment_o_picker.API_Color_Interpolate( self, mode, color_a, color_b, var_mix )

color_index = pigment_o_picker.API_Input_Preview( self, mode, var_1, var_2, var_3, var_4 )
color_index = pigment_o_picker.API_Input_Apply( self, mode, var_1, var_2, var_3, var_4 )
report      = pigment_o_picker.API_Image_Analyse( self, qimage )

Picker Input Annotation

hex6        : string     : "#RRGGBB" hexadeximal color code with 6 character in length
mode        : string     : "GRAY", "SRGB", "LRGB", "CMYK", "RYB", "YUV", "HSV", "HSL", "HCY", "ARD", "XYZ", "XYY", "LAB", "LCH" color spaces
var         : float      : float with range of 0 - 1
color_index : dictionary : Pigment.O color object ( can be requested )
qimage      : QImage     : PyQt QImage object

Sampler API Commands

pigment_o_sampler.API_Display_Image( self, qpixmap )
pigment_o_sampler.API_Input_Color_Index( self, color_index )
pigment_o_sampler.API_LUT_to_Image( self, list_url )

Sampler Input Annotation

qpixmap     : QPixmap    : PyQt QPixmap object
color_index : dictionary : Pigment.O color object ( can be requested )
list_url    : list       : List with a sequence of url in string format

Clone this wiki locally