Releases: facelessuser/coloraide
Releases · facelessuser/coloraide
1.8
1.8.0
- NEW: Modern sRGB, HSL, and HWB should allow mixed percentage and numbers. HSL and HWB percentages in the
hsl()
andhwb()
formats respectively will resolve to numbers in the range [0, 100]. These changes reflect the latest
changes in the CSS Level 4 Color spec. - NEW: HSL and HWB can serialize to a modern syntax that does not use percentages, but the default still uses
percentages. - NEW: Rework CSS parsing for better performance.
- FIX: Handle some parsing corner cases that are handled by browsers, but not by ColorAide. For example,
color(srgb 1-0.5.4)
should parse ascolor(srgb 1 -0.5 0.4)
. - FIX: Ensure that
COLOR_FORMAT
is respected.
1.7.1
1.7.1
- FIX: Ensure CAM16 spaces mirrors positive and negative percentages for
a
andb
components. - FIX: Since the CAM16 JMh model can not predict achromatic colors with negative lightness and, more importantly,
negative lightness is not useful, limit the lower end of lightness in CAM16 spaces to zero. - FIX: When a CAM16 JMh (or HCT) color's chroma, when not discounting illuminance, has chroma drop below the actual
ideal achromatic chroma threshold, just use the ideal chroma to ensure better conversion back to XYZ. - FIX: Jzazbz and JzCzhz model can never translate a color with a negative lightness, so just clamp negative
lightness while in Jzazbz and JzCzhz. - FIX: Fix a math error in CAM16.
- FIX: Fix CAM16 JMh M limit which was too low.
- FIX: IPT was set to "bound" when it should have an unbounded gamut.
- FIX: When both
comma
andnone
are enabled it could make undefined alpha values show up asnone
in legacy CSS
format. - FIX: Sane handling of inverse lightness in DIN99o.
1.7
1.7
- NEW: Add support for CAM16 Jab and JMh:
cam16
andcam16-jmh
respectively. - NEW: Add support for CAM16 UCS (Jab forms):
cam16-ucs
,cam16-scd
, andcam16-lcd
. - NEW: Add support for the HCT color space (
hct
) which combines the colorfulness and hue from CAM16 JMh and the
lightness from CIELab. - NEW: Gamut mapping classes derived from
fit_lch_chroma
can setDE_OPTIONS
to pass ∆E parameters. - NEW: While rare, some cylindrical color spaces have an algorithm such that achromatic colors convert best with a
very specific hue. Internally, this is now handled during conversions, but there can be reasons where knowing the hue
can be useful such as plotting. Cylindrical spaces now expose a method calledachromatic_hue()
which will
return this specific hue if needed. - FIX: Fix
rec2100-hlg
transform. - FIX: Some color transformation improvements.
- FIX: Relax some achromatic detection logic for sRGB cylindrical models. Improves achromatic hue detection results
when converting to and from various non-sRGB color spaces.
1.6
1.6
- NEW: Add
rec2100-hlg
color space. - BREAKING:
rec2100pq
should have been namedrec2100-pq
for consistency. It has been renamed torec2100-pq
and
serializes with the CSS ID of--rec2100-pq
. This is likely to have little impact on most users.
1.5
1.5
- NEW: Formally add support for Python 3.11.
- NEW: Add support for custom domains when interpolating.
- NEW:
set()
can now take a dictionary of channels and values and set multiple channels at once. - NEW:
get()
can now take a list of channels and will return a list of those channel values. - ENHANCE: Simplify some type annotation syntax.
- ENHANCE: Some minor performance enhancements.
- FIX: Fix OkLCh CSS parsing.
1.4
1.4
- NEW: A color space can now declare its dynamic range. By default, spaces are assumed to be SDR, but can declare
themselves as HDR, or something else. This allows ColorAide to make decisions based on a color's dynamic range. - NEW: Add channel aliases for IPT and IPT-like color spaces (IgPgTg and ICtCp):
intensity
,protan
, and
tritan
. - FIX: The ICtCp and oRGB space would return the Lab-ish equivalents for
a
andb
in reverse order if calling
Labish.labish_names
. This was not actually called anywhere in the code, but is now fixed for any future cases that
may require calling it. - FIX: Undefined channels should be ignored when clipping a color.
- FIX: Do not apply SDR shortcuts in gamut mapping when fitting in a non-SDR color gamut, such as HDR.
1.3
1.3
- ENHANCE: Color vision deficiency filters can now be instantiated with different default methods for severe and
anomalous cases. - FIX: Fix premultiplication handling when using
compose
.
1.2
1.2
- NEW: Add new monotone interpolation method.
- ENHANCE: Better extrapolation past end of spline.
- FIX: Small speed up in natural spline calculation.
- FIX: Fix import that should have been relative, not absolute.
1.1
1.1
- NEW: Slight refactor of interpolation plugin so that common code does not need to be duplicated, and the
interpolate
method no longer needs to accept aneasing
parameter as the plugin class exposes a newease
method
to automatically acquire the proper, specified easing function and apply it. - NEW: Functions built upon interpolation can now use a new
extrapolate
parameter to enable extrapolation if
interpolation inputs exceed 0 - 1.point
will be passed toInterpolator.interpolate
un-clamped ifextrapolate
is
enabled. If a particular interpolation plugin needs to do additional work to handle extrapolation, they can check
self.extrapolate
to know whether extrapolation is enabled. - NEW: Implement and provide the following easing functions as described in the CSS Easing Level 1 spec:
cubic_bezier
,ease
,ease_in
,ease_out
, andease_in_out
. Also provide a simplelinear
easing function. - New: Add
natural
andcatrom
cubic spline options for interpolation. Thecatrom
(Catmull-Rom) spline requires
the plugin to be registered in order to use it. - FIX: Due to floating point math, B-spline could sometimes return an interpolation of fully opaque colors with an
imperceptible amount of transparency. If alpha is very close (#!py3 1e-6
) to being opaque, just round it to opaque. - FIX: An easing function's output should not be clamped, only the input, and that only needs to occur on the
the outer range of an entire interpolation.
1.0
1.0
Note Stable Release!
Checkout migration guide if you were an early adopter.
- NEW: Bezier interpolation dropped for B-spline which provides much better interpolation.
- NEW: All new interpolation methods now support hue fix-ups:
shorter
,longer
,increasing
,decreasing
,
andspecified
. - NEW: Interpolation is now exposed as a plugin to allow for expansion.
- FIX: Fixed an issue related to premultiplication and undefined alpha channels.