Closed RaphyRaph closed 9 years ago
In which tool? SwatchInstall or the command line ones?
SwatchInstall
ASE files come with no colorspace information, so we assume generic. You can patch Ase2Clr/RPCAdobeSwatchExchange.m:69 to use a different NSColor constructor (like it's done for the CMYK values, for example).
I tried to get in there and apply a sRGB color space it to the html2clr command and build it, but I failed because my coding skills are limited. Do you think you could share a version of html2clr that applies the sRGB color space?
You just have to patch ColorTools/Html2Clr/NSColor+Hexadecimal.m:58
Replace colorWithRed
by colorWithSRGBRed
and build.
Cool thx!! On Tue, Jan 27, 2015 at 3:36 AM Ramon Poca notifications@github.com wrote:
You just have to patch ColorTools/Html2Clr/NSColor+Hexadecimal.m:58 Replace colorWithRed by colorWithSRGBRed and build.
— Reply to this email directly or view it on GitHub https://github.com/ramonpoca/ColorTools/issues/4#issuecomment-71632948.
Doesn't seem to work. Just defaults to generic rgb.
That's your colorpicker working space, not the palette. If you change it you'll see the values of red, green and blue change to the selected colorspace. For example, set to sRGB, select r=40,g=40,b=40. Then change to Generic RGB and you'll see the values change to (30,30,30).
So sRGB(40,40,40) = GenericRGB(30,30,30). If your origin palette is in a sRGB colorspace and has #282828 (40,40,40), and you import it with the modified html2clr, it will show as (30,30,30) on the Generic RGB colorspace.
Got it. Then, how do I export a sRGB palette?
— Raphaël
On Wed, Jan 28, 2015 at 2:20 AM, Ramon Poca notifications@github.com wrote:
That's your colorpicker working space, not the palette. If you change it you'll see the values of red, green and blue change to the selected colorspace. For example, set to sRGB, select r=40,g=40,b=40. Then change to Generic RGB and you'll see the values change to (30,30,30). So sRGB(40,40,40) = GenericRGB(30,30,30).
If your origin palette is in a sRGB colorspace and has #282828 (40,40,40), and you import it with the modified html2clr, it will show as (30,30,30) on the Generic RGB colorspace.
Reply to this email directly or view it on GitHub: https://github.com/ramonpoca/ColorTools/issues/4#issuecomment-71811092
What are you trying to do?
I'm trying to export a set of hex values into a .clr file where the RGB values are set as sRGB by default. On Thu, Jan 29, 2015 at 12:12 AM Ramon Poca notifications@github.com wrote:
What are you trying to do?
— Reply to this email directly or view it on GitHub https://github.com/ramonpoca/ColorTools/issues/4#issuecomment-71985461.
If your origin hex values are COORDINATES IN THE sRGB COLORSPACE, and you import them as sRGB values (with the patched version of html2clr, creating the UIColor over the sRGB colorspace), then the colors in the .clr file will point the same perceptual color. Do you see a disparity between the hex coordinates and the loaded colors?
Would there be a way to set a color profile when converting color swatches? Right now it defaults to generic RGB but I'd like to set it to sRGB.