From kde-kimageshop Wed Sep 15 13:59:53 2004 From: Boudewijn Rempt Date: Wed, 15 Sep 2004 13:59:53 +0000 To: kde-kimageshop Subject: Re: always an alpha channel Message-Id: <200409151559.57737.boud () valdyas ! org> X-MARC-Message: https://marc.info/?l=kde-kimageshop&m=109525684403161 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============0457081929==" --===============0457081929== Content-Type: multipart/signed; boundary="nextPart6448366.DOmzBW4itC"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit --nextPart6448366.DOmzBW4itC Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Wednesday 15 September 2004 15:30, Casper Boemann wrote: > > Case 1 problems might be overcome, if we think of a "normal layer" as a > "color layer" and an "alpha layer" always combined. The "normal layer" > would then have the responsibillity of combining the two. But what happens > when we use paintdevices that are not layers - wouldn't we still want alp= ha > for those? Of course. Otherwise you won't be able to do antialiased brushes. Before=20 painting a brush stroke, the brush mask is first converted to a paint devic= e. > > My suggestion would be more in the like of a RGB colorstrategy, a RGBA > colorstrategy, a RAGABA colorstrategy and so fourth with CMYK, CMYKA etc. > To avoid code duplication we could have an AlphaColorstrategyTrait and let > RGBA inherit from both RGBColorStrategy and AlphaColorstrateyTrait. The > trait could be reused for CMYK with alpha. Yes, that could be the way to go, I think. But the current API is confusing with its myriad ways of discovering whether there's an alpha channel, and n= o=20 way to add one that's missing... On the other hand, once onvererting between RGB and RGBA would become=20 possible, having an in-band alpha would slow things down. The advantage of= =20 using a separate alpha 'layer' that's always associated with a paint device= =20 is that it becomes really easy to add or remove an alpha channel. Oh, well -- I'll add some templates first, fix the selections workflow &=20 paste/past into and move, and look into the weird scaling artefacts for=20 images that are partly obscured by the UI. And there are composition=20 artefacts that show up in the selection code. =2D-=20 Boudewijn Rempt | "Geef mij maar zuurtjes." http://www.valdyas.org/fading/index.cgi --nextPart6448366.DOmzBW4itC Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQBBSErddaCcgCmN5d8RAg/3AJ9nxm7daNod9+gLEHD6WAqf41urrQCfbrcD HpDTR21NPolB8S5buSg4Fkk= =qnRm -----END PGP SIGNATURE----- --nextPart6448366.DOmzBW4itC-- --===============0457081929== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kimageshop mailing list kimageshop@kde.org https://mail.kde.org/mailman/listinfo/kimageshop --===============0457081929==--