Ell [Tue, 30 Jul 2019 17:37:18 +0000 (20:37 +0300)]
meson: fix AVX2 detection on x86
s/rax/eax/
Øyvind Kolås [Tue, 30 Jul 2019 08:03:04 +0000 (10:03 +0200)]
build: remove autogen.sh, remnants of autotools
Øyvind Kolås [Mon, 29 Jul 2019 22:24:17 +0000 (00:24 +0200)]
babl: initialize buffer pointers
This silences a false warning from gcc, where it doesn't recognize the type
of control flow occuring with the pre/post switches in the reference
conversion.
Øyvind Kolås [Mon, 29 Jul 2019 20:31:51 +0000 (22:31 +0200)]
build: remove autotools
Alexandre Prokoudine [Fri, 26 Jul 2019 13:47:02 +0000 (13:47 +0000)]
NEWS: formatting :)
Øyvind Kolås [Thu, 25 Jul 2019 13:30:47 +0000 (15:30 +0200)]
docs: fix html tag typo
Øyvind Kolås [Wed, 24 Jul 2019 16:36:26 +0000 (18:36 +0200)]
post-release version bump
Øyvind Kolås [Wed, 24 Jul 2019 16:35:58 +0000 (18:35 +0200)]
release 0.1.68
Øyvind Kolås [Thu, 25 Jul 2019 12:54:49 +0000 (14:54 +0200)]
NEWS: update
Øyvind Kolås [Thu, 25 Jul 2019 12:58:17 +0000 (14:58 +0200)]
INSTALL.in: document meson build instead of autotools build
Øyvind Kolås [Thu, 25 Jul 2019 10:29:39 +0000 (12:29 +0200)]
docs: remove duplicate files
Ell [Wed, 24 Jul 2019 20:52:08 +0000 (23:52 +0300)]
extensions: distribute avx2-int8-tables.h
Ell [Wed, 24 Jul 2019 20:24:29 +0000 (23:24 +0300)]
extensions: add AVX2 linear-float -> gamma-u8 conversions
Add AVX2 conversions from Y float, YA float, RGB float, and RGBA
float, to Y' u8, Y'A u8, R'G'B' u8, and R'G'B'A u8, respectively.
The conversions use a lookup table, similarly to the two-table
conversions, indexed using AVX2's 256-bit gather instruction, which
allow us to process 8 floats at once. Over here, this conversion
is ~5x faster than the SSE conversions.
Note, however, that unlike two-table, we don't use a second
"feedback" table to correct the result, leading to an off-by-one
conversion error with a probability of ~0.1%, using a 2^16-element
table. This error rate is low enough for babl to use the
conversion, but might still be a bit too high regardless; it can be
further reduced with a bigger table.
Ell [Wed, 24 Jul 2019 20:21:01 +0000 (23:21 +0300)]
configure.ac, meson, cpu-accel: add AVX2 detection
Detect AVX2 support during configuration and runtime, in
preperation for next commit.
Øyvind Kolås [Wed, 24 Jul 2019 16:44:47 +0000 (18:44 +0200)]
docs: remove wrong refernces to old versions
Øyvind Kolås [Wed, 24 Jul 2019 16:00:56 +0000 (18:00 +0200)]
docs: add a couple of entries to glossary
Øyvind Kolås [Wed, 24 Jul 2019 15:44:06 +0000 (17:44 +0200)]
meson: fix mistake in add_dist_script
Øyvind Kolås [Wed, 24 Jul 2019 14:23:23 +0000 (16:23 +0200)]
AUTHORS: update
Øyvind Kolås [Wed, 24 Jul 2019 14:09:48 +0000 (16:09 +0200)]
update NEWS
Øyvind Kolås [Wed, 24 Jul 2019 14:09:01 +0000 (16:09 +0200)]
HCY: convert luminance relative to RGB chromaticities
Øyvind Kolås [Wed, 24 Jul 2019 14:07:11 +0000 (16:07 +0200)]
docs: add OldNews page
Øyvind Kolås [Wed, 24 Jul 2019 13:28:59 +0000 (15:28 +0200)]
extensions/HSL: add model doc string
Øyvind Kolås [Wed, 24 Jul 2019 13:28:38 +0000 (15:28 +0200)]
extensions/HSV: update model docs
Félix Piédallu [Wed, 24 Jul 2019 11:35:26 +0000 (13:35 +0200)]
force generate git-version.h before copying
Øyvind Kolås [Wed, 24 Jul 2019 11:49:08 +0000 (13:49 +0200)]
build (docs): add Glossary.html to BUILT_EXTRA_DIST
Øyvind Kolås [Wed, 24 Jul 2019 11:39:01 +0000 (13:39 +0200)]
meson: require meson version 0.49.0
Øyvind Kolås [Wed, 24 Jul 2019 09:47:33 +0000 (11:47 +0200)]
extensions/HSV: add documentation for model
Félix Piédallu [Wed, 24 Jul 2019 10:58:54 +0000 (12:58 +0200)]
Fix git-version.h handling
Ell [Wed, 24 Jul 2019 04:58:00 +0000 (07:58 +0300)]
configure.ac: clean up SSE config
Øyvind Kolås [Tue, 23 Jul 2019 09:13:20 +0000 (11:13 +0200)]
docs: start adding a glossary
Øyvind Kolås [Mon, 22 Jul 2019 22:59:48 +0000 (00:59 +0200)]
docs: refer to Y in generated reference as Luminance
Øyvind Kolås [Mon, 22 Jul 2019 20:37:58 +0000 (22:37 +0200)]
babl-space: do not use universal rgb sse converter for non-sse path
Øyvind Kolås [Mon, 22 Jul 2019 15:25:26 +0000 (17:25 +0200)]
docs: s/git.gnome.org/gitlab.gnome.org/
Øyvind Kolås [Mon, 22 Jul 2019 15:20:37 +0000 (17:20 +0200)]
extensions/CIE: add some documentation overrides
Øyvind Kolås [Mon, 22 Jul 2019 15:10:08 +0000 (17:10 +0200)]
docs: improve generated reference
When registering types, models, formats and components one can now
specify override "doc" strings that end up in this reference.
Øyvind Kolås [Mon, 22 Jul 2019 14:11:07 +0000 (16:11 +0200)]
docs: update meson.build
Øyvind Kolås [Mon, 22 Jul 2019 14:10:02 +0000 (16:10 +0200)]
docs: dist Reference.html
Øyvind Kolås [Mon, 22 Jul 2019 13:59:23 +0000 (15:59 +0200)]
docs: rename vocabulary page to reference
Øyvind Kolås [Mon, 22 Jul 2019 13:49:51 +0000 (15:49 +0200)]
base: s/premultiplied/associated_alpha/
Øyvind Kolås [Mon, 22 Jul 2019 13:44:58 +0000 (15:44 +0200)]
extensions/sse2-float: s/premul/assoc/ in function names
Øyvind Kolås [Mon, 22 Jul 2019 13:44:46 +0000 (15:44 +0200)]
extensions/gimp-8bit: s/premul/assoc/ in function names
Øyvind Kolås [Mon, 22 Jul 2019 13:44:30 +0000 (15:44 +0200)]
extensions/cairo: s/premul/assoc/ in function names
Øyvind Kolås [Mon, 22 Jul 2019 13:29:33 +0000 (15:29 +0200)]
babl: replace premultiplied with associated in BablModelFlags
The terminology that babl has settled for - for the different types
of alpha is associated- and separate- alpha.
Øyvind Kolås [Mon, 22 Jul 2019 12:39:52 +0000 (14:39 +0200)]
docs: improve the generated reference
Øyvind Kolås [Mon, 22 Jul 2019 02:41:50 +0000 (04:41 +0200)]
meson: adapt to changes in docs build
Øyvind Kolås [Mon, 22 Jul 2019 02:06:26 +0000 (04:06 +0200)]
docs: add separate pages for CMYK, ColorManagement and alpha
Øyvind Kolås [Mon, 22 Jul 2019 01:40:42 +0000 (03:40 +0200)]
docs: remove reference to non-existing file build-docs.sh
Øyvind Kolås [Mon, 22 Jul 2019 01:22:11 +0000 (03:22 +0200)]
babl-space: add universal convertors between linear and nonlinear
Register conversions for all space pairs between "R'G'B'A float" and
"RGBA float" and vice versa, both SSE2 and non SIMD versions.
Øyvind Kolås [Mon, 22 Jul 2019 01:08:09 +0000 (03:08 +0200)]
babl-space: indentation improvements
Øyvind Kolås [Sat, 20 Jul 2019 15:15:29 +0000 (17:15 +0200)]
babl-fish: use abstraction for checking if space is cmyk
Øyvind Kolås [Sat, 20 Jul 2019 15:15:03 +0000 (17:15 +0200)]
babl-fish-path: cache a local sRGB space instance
Øyvind Kolås [Sat, 20 Jul 2019 13:34:15 +0000 (15:34 +0200)]
babl-space: 0 initialize temporary stack allocated BablSpace instances
After the CMYK support was added, we ended up sometimes having the is_cmyk
flag set on RGB matrix profiles, leading to forced reference conversions.
Øyvind Kolås [Thu, 4 Jul 2019 11:11:05 +0000 (13:11 +0200)]
extensions/CIE.c: improve handling of near zero values
Negative values were treated as near zero, causing more clipping than
neccesary to occur.
Øyvind Kolås [Thu, 4 Jul 2019 10:32:07 +0000 (12:32 +0200)]
babl: make model_is_symmetric test adapt tolerance for high values
When the values used are in the billions, the tolerance that originally
was mostly intended for values in the range 0.0-1.0 and its neighborhood
break apart - use 1% of component values as symmetry threshold for such
values.
Elle Stone [Sat, 29 Jun 2019 16:45:34 +0000 (12:45 -0400)]
Add Yu'v' (CIE 1976 UCS) to babl CIE color spaces
Yu'v' is a linear transform of xyY that is more perceptually
uniform, and well-suited for eg creating chromaticity diagrams
that aren't misleading when comparing various RGB color spaces.
This color space has been recommended by many people as a better
choice than xyY. ACES documentation already uses this color space.
Thomas Manni [Mon, 24 Jun 2019 10:12:38 +0000 (12:12 +0200)]
babl: performance improvement in model-gray
Use multiplication by the inverse instead of division in
premultiplied to non-premultiplied alpha conversion functions.
Øyvind Kolås [Wed, 19 Jun 2019 21:41:51 +0000 (23:41 +0200)]
meson: fix typoed filename
Øyvind Kolås [Wed, 19 Jun 2019 13:28:47 +0000 (15:28 +0200)]
AUTHORS: add some missing entries
Øyvind Kolås [Wed, 19 Jun 2019 12:27:11 +0000 (14:27 +0200)]
docs: add tools dir to dir-overview
Øyvind Kolås [Wed, 19 Jun 2019 12:06:52 +0000 (14:06 +0200)]
tests: rename from transparent_symmetry to alpha_symmetric_transform
Øyvind Kolås [Wed, 19 Jun 2019 12:04:26 +0000 (14:04 +0200)]
docs: add section about symmetric alpha transforms
Øyvind Kolås [Wed, 19 Jun 2019 11:20:43 +0000 (13:20 +0200)]
docs: update
Øyvind Kolås [Wed, 19 Jun 2019 09:35:30 +0000 (11:35 +0200)]
babl/base: use symmetric alpha transformations for CMYK
Øyvind Kolås [Thu, 13 Jun 2019 15:12:36 +0000 (17:12 +0200)]
meson: add transparent_symmetry test
Øyvind Kolås [Thu, 13 Jun 2019 15:08:57 +0000 (17:08 +0200)]
extensions: fix up some lingering references to babl_alpha_avoid_zero
Øyvind Kolås [Thu, 13 Jun 2019 15:00:23 +0000 (17:00 +0200)]
babl: symmetric conversions between associated and separate alpha.
Provide symmetric, color data preserving conversions between associated and
separate alpha for alpha values near and equal to 0.0 at single precision
floating point. Thus these symmetric conversions also augment associated alpha
to always maintain color information.
This is achieved by clamping the alpha used when computing the color
components when multiplying/dividing components between separate and
associated alpha to BABL_ALPHA_FLOOR and -BABL_ALPHA_FLOOR for values
near 0.0, the alpha value is copied unmodified between pixels; the main
improvement of this commit.
In the implementation BABL_ALPHA_FLOOR is 1/65536 = 0.
00001526.. small
enough that it vanishing in rounding for 16bit integer alpha but large
enough to retain color data.
The following table illustrates what corresponding values are between the
two alpha encodings supported. We here usea BABL_ALPHA_FLOOR of 0.01 instead
of 0.
00001526 to make it easier to see what happens.
```
"RGBA float" "RaGaBaA float"
separate alpha associated alpha
non-premultiplied pre-multiplied alpha
R G B A Ra Ga Ba A
10.000 1.000 0.100 0.000 0.100 0.010 0.001 0.000
10.000 1.000 0.100 0.005 0.100 0.010 0.001 0.005
__10.000___1.000__0.100__0.010_____0.100__0.010__0.001__0.010__
10.000 1.000 0.100 0.020 0.200 0.020 0.002 0.020
10.000 1.000 0.100 0.200 2.000 0.200 0.020 0.200
10.000 1.000 0.100 0.400 4.000 0.400 0.040 0.400
1000.000 100.000 10.000 0.000 10.000 1.000 0.100 0.000
1000.000 100.000 10.000 0.005 10.000 1.000 0.100 0.005
1000.000_100.000_10.000__0.010____10.000__1.000__0.100__0.010___
500.000 50.000 5.000 0.020 10.000 1.000 0.100 0.020
50.000 5.000 0.500 0.200 10.000 1.000 0.100 0.200
25.000 2.500 0.250 0.400 10.000 1.000 0.100 0.400
```
GEGL lets each operation compute with it's preferred encoding - for some
operations like blurs this is associated alpha, for others like color
adjustments it is separate alpha, perhaps even in CIE Lab based encodings
rather than RGB. An earlier iteration of this approach was already in use in
babl making un-erase mode and similar features in GIMP-2.10 work correctly
after blurring, the previous implementation did not preserve the
alpha value.
Just the core of the implementation follows:
```
#define BABL_ALPHA_FLOOR_F (1.0f/65536.0f)
static inline float
babl_epsilon_for_zero_float (float value)
{
if (value <= BABL_ALPHA_FLOOR_F)
{
/* for performance one could directly retun BABL_ALPHA_FLOOR_F here
and dropping handling negative values consistently. */
if (value >= 0.0f)
return BABL_ALPHA_FLOOR_F;
else if (value >= -BABL_ALPHA_FLOOR_F)
return -BABL_ALPHA_FLOOR_F;
}
return value; /* most common case, return input value */
}
static inline void
separate_to_associated_rgba (const float *separate_rgba,
float *associated_rgba)
{
float alpha = babl_epsilon_for_zero_float (separate_rgba[3]);
associated_rgba[0] = separate_rgba[0] * alpha;
associated_rgba[1] = separate_rgba[1] * alpha;
associated_rgba[2] = separate_rgba[2] * alpha;
associated_rgba[3] = separate_rgba[3]; /* direct copy */
}
static inline void
associated_to_separate_rgba (const float *associated_rgba,
float *separate_rgba)
{
float alpha = babl_epsilon_for_zero_float (associated_rgba[3]);
float reciprocal_alpha = 1.0f / alpha; /* the conditional normally in
this conversion to avoid
division by zero is handled by
epsilon_for_zero */
separate_rgba[0] = associated_rgba[0] * reciprocal_alpha;
separate_rgba[1] = associated_rgba[1] * reciprocal_alpha;
separate_rgba[2] = associated_rgba[2] * reciprocal_alpha;
separate_rgba[3] = associated_rgba[3]; /* direct copy */
}
```
Øyvind Kolås [Wed, 12 Jun 2019 17:45:50 +0000 (19:45 +0200)]
post release version bump
Øyvind Kolås [Wed, 12 Jun 2019 17:44:28 +0000 (19:44 +0200)]
release 0.1.66
Øyvind Kolås [Wed, 12 Jun 2019 13:31:47 +0000 (15:31 +0200)]
remove unused/unexported API to access internal matrices
Øyvind Kolås [Thu, 30 May 2019 15:50:10 +0000 (17:50 +0200)]
babl: always intialize encoding pointer during format construction
This fixes issue #35, we initialize with NULL which will cause
babl_format_get_encoding to itself call babl_get_name rather.
Øyvind Kolås [Tue, 28 May 2019 23:58:30 +0000 (01:58 +0200)]
babl: implement babl_space_get_rgb_luminance
This provides the factors often found as defines hard-coded for sRGB
with values that are adapted to the primaries of the RGB family of
pixel encodings for a given babl space.
Øyvind Kolås [Tue, 28 May 2019 21:32:34 +0000 (23:32 +0200)]
remove unused file conversions-type.c
Really resolving merge request !12 this time.
Jan Vesely [Sun, 26 May 2019 16:26:44 +0000 (12:26 -0400)]
Revert "meson: fix build for arch:i686 , cc:gcc-7"
This reverts commit
80347ef5b8706ddc0a2854dd5ff545b2d66ede4a.
Adding -march=native is a bad idea as it breaks invalidates individual
extension switches (sse, ...)
Issue #29 was fixed in
e75a27b5346f4c8480180479b7524b1b20ed8321.
Øyvind Kolås [Sat, 25 May 2019 17:06:06 +0000 (19:06 +0200)]
autotools,meson: post release version bump
Øyvind Kolås [Sat, 25 May 2019 17:01:55 +0000 (19:01 +0200)]
release 0.1.64
Øyvind Kolås [Sat, 25 May 2019 16:35:57 +0000 (18:35 +0200)]
meson: fix build for arch:i686 , cc:gcc-7
Fixing issue #29 and merge reuqest !6.
Jan Vesely [Sun, 5 May 2019 02:14:26 +0000 (22:14 -0400)]
gitlab-ci: Consolidate pacman setup and cache downloaded pacman packages
Signed-off-by: Jan Vesely <jano.vesely@gmail.com>
Jan Vesely [Sun, 5 May 2019 02:10:19 +0000 (22:10 -0400)]
gitlab-ci: Consolidate configuraiton into hierarchy of extensible configs
Signed-off-by: Jan Vesely <jano.vesely@gmail.com>
John Marshall [Fri, 3 May 2019 08:56:35 +0000 (09:56 +0100)]
meson build: add missing sse2 compiler flags to babl library build
John Marshall [Mon, 1 Apr 2019 22:08:48 +0000 (23:08 +0100)]
meson build: improve lcms dependency handling
John Marshall [Fri, 29 Mar 2019 09:13:25 +0000 (09:13 +0000)]
meson build: add new tests
John Marshall [Fri, 29 Mar 2019 09:12:24 +0000 (09:12 +0000)]
meson build: use index_html target name for README file generation
John Marshall [Fri, 29 Mar 2019 09:08:07 +0000 (09:08 +0000)]
meson build: implement new copy option with configure_file
John Marshall [Mon, 11 Jun 2018 09:12:24 +0000 (10:12 +0100)]
meson build: only build docs if we can run required objects in build environment
John Marshall [Mon, 11 Jun 2018 09:00:49 +0000 (10:00 +0100)]
meson build: add descriptions for configuration options
John Marshall [Mon, 11 Jun 2018 08:51:27 +0000 (09:51 +0100)]
meson build: clean up library dependency check
John Marshall [Mon, 11 Jun 2018 08:40:45 +0000 (09:40 +0100)]
meson build: improve function checking
John Marshall [Mon, 11 Jun 2018 08:27:33 +0000 (09:27 +0100)]
meson build: try to add -Ofast to CFLAGS
John Marshall [Tue, 16 Apr 2019 08:58:42 +0000 (09:58 +0100)]
git: build cleanup - add missing build objects to .gitignore
John Marshall [Tue, 29 May 2018 14:37:08 +0000 (15:37 +0100)]
tests: remove duplicate extract test
John Marshall [Mon, 1 Apr 2019 10:52:09 +0000 (11:52 +0100)]
build: remove unecessary _la_SOURCE entry from extension makefile
Nuno Ferreira [Sun, 7 Apr 2019 19:38:30 +0000 (20:38 +0100)]
removing conversions-type.c is best done in a different commit
Nuno Ferreira [Sat, 30 Mar 2019 11:15:29 +0000 (11:15 +0000)]
remove 'conversions-type.c' file since it is empty
Nuno Ferreira [Tue, 26 Mar 2019 07:59:15 +0000 (07:59 +0000)]
code style review
fixed style of function headers in the tools folder
hygonsoc [Thu, 2 May 2019 18:36:36 +0000 (02:36 +0800)]
add Hygon Dhyana support in arch_get_vendor
Signed-off-by: hygonsoc <hygonsoc@gmail.com>
Øyvind Kolås [Thu, 9 May 2019 14:26:37 +0000 (16:26 +0200)]
babl: add Y~aA formats - for completeness
In order for higher level code to be abstracted across all available
permutations we need this. This fixes gegl issue no 151
John Marshall [Sat, 13 Apr 2019 13:21:52 +0000 (14:21 +0100)]
build: add meson build files to EXTRA_DIST to include in autotools make dist
Nuno Ferreira [Tue, 26 Feb 2019 19:47:16 +0000 (19:47 +0000)]
code style review
fixed style of function headers in the babl/extensions folder
Øyvind Kolås [Wed, 6 Mar 2019 11:09:47 +0000 (12:09 +0100)]
babl: use inlined lookup functions inside type implementations
This avoids function call stack overhead for some calls that are
in many of our hot-paths.
Jan Vesely [Wed, 20 Feb 2019 21:39:35 +0000 (16:39 -0500)]
gitlab-ci: Replace base/archlinux with archlinux/base
Signed-off-by: Jan Vesely <jano.vesely@gmail.com>