profile/ivi/pixman.git
15 years agoConstify the mask argument to scanline fetchers.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 01:28:28 +0000 (21:28 -0400)]
Constify the mask argument to scanline fetchers.

15 years agoAdd a mask and mask_bits argument to the raw scanline fetchers.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 01:22:06 +0000 (21:22 -0400)]
Add a mask and mask_bits argument to the raw scanline fetchers.

15 years agoRename fetchProc32 to fetch_scanline_t and fetch_pixels_32_t to fetch_pixels_t
Søren Sandmann Pedersen [Wed, 24 Jun 2009 01:10:52 +0000 (21:10 -0400)]
Rename fetchProc32 to fetch_scanline_t and fetch_pixels_32_t to fetch_pixels_t

15 years agoGet rid of the 64 bit fetcher types.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 00:58:39 +0000 (20:58 -0400)]
Get rid of the 64 bit fetcher types.

It's simpler to just declare everything as 32 bit fetchers and do the
conversion in the few functions that actually need to know the size of
the pixel type.

15 years agoConsolidate the three scanline store types into one.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 00:38:58 +0000 (20:38 -0400)]
Consolidate the three scanline store types into one.

The 64 bit storers do their own type conversion.

15 years agoGet rid of remaining scanFetchProc casts
Søren Sandmann Pedersen [Tue, 23 Jun 2009 23:03:11 +0000 (19:03 -0400)]
Get rid of remaining scanFetchProc casts

15 years agoGet rid of scanFetchProc casts in pixman-radial-gradient.c
Søren Sandmann Pedersen [Tue, 23 Jun 2009 23:02:10 +0000 (19:02 -0400)]
Get rid of scanFetchProc casts in pixman-radial-gradient.c

15 years agoGet rid of scanFetchProc casts in pixman-conical-gradient.c
Søren Sandmann Pedersen [Tue, 23 Jun 2009 23:00:52 +0000 (19:00 -0400)]
Get rid of scanFetchProc casts in pixman-conical-gradient.c

15 years agoGet rid of casts to scanFetchProc in pixman-bits-image.c
Søren Sandmann Pedersen [Tue, 23 Jun 2009 22:58:39 +0000 (18:58 -0400)]
Get rid of casts to scanFetchProc in pixman-bits-image.c

Instead just declare the functions with the required type and do any
type conversions in the function itself.

15 years agoFix bug where 64 bit pixel were fetched as 32 bit ones.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 22:44:01 +0000 (18:44 -0400)]
Fix bug where 64 bit pixel were fetched as 32 bit ones.

15 years agoDelete FbIntMult and FbIntDiv macros, and move FbIntAdd to pixman-combine.h
Søren Sandmann Pedersen [Tue, 23 Jun 2009 22:41:35 +0000 (18:41 -0400)]
Delete FbIntMult and FbIntDiv macros, and move FbIntAdd to pixman-combine.h

15 years agoAdd a table to oob-test so that it can test more than one setup.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 16:10:48 +0000 (12:10 -0400)]
Add a table to oob-test so that it can test more than one setup.

15 years agoFix offset bug in pixman_run_fast_path().
Søren Sandmann Pedersen [Wed, 24 Jun 2009 15:28:03 +0000 (11:28 -0400)]
Fix offset bug in pixman_run_fast_path().

Fast paths should only run when the source images complete cover the
composite region, because otherwise they would be required to sample
the border, and fast paths generally don't know how to do that.

The check for this did not work right because it didn't take the
offset generated by the composite coordinates into account. This
commits fixes that by adding (x, y) coordinates to image cover
indicating the new position of the source in destination coordinates.

Based on this we now compare against the region extents which are
already in destination coordinates.

15 years agoFix typo in oob-test.c
Søren Sandmann Pedersen [Wed, 24 Jun 2009 15:23:04 +0000 (11:23 -0400)]
Fix typo in oob-test.c

15 years agoAdd test case for out-of-bounds memory access.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 14:37:07 +0000 (10:37 -0400)]
Add test case for out-of-bounds memory access.

15 years agoFix comment in pixman-utils to have the right sense.
Søren Sandmann Pedersen [Wed, 24 Jun 2009 13:04:54 +0000 (09:04 -0400)]
Fix comment in pixman-utils to have the right sense.

15 years agoSubtract x_off/y_off before conversion to integer.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 20:55:53 +0000 (16:55 -0400)]
Subtract x_off/y_off before conversion to integer.

They are fixed-point values, not integers.

Bug 22437, reported by Michel Dänzer.

15 years agoAdd convolution-test.c program
Søren Sandmann Pedersen [Tue, 23 Jun 2009 20:37:35 +0000 (16:37 -0400)]
Add convolution-test.c program

15 years agoDelete leftover use of PIXMAN_OP_FLASH_SUBTRACT
Søren Sandmann Pedersen [Tue, 23 Jun 2009 20:23:26 +0000 (16:23 -0400)]
Delete leftover use of PIXMAN_OP_FLASH_SUBTRACT

15 years agoRemove support for component alpha with HSL blend modes.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 18:55:36 +0000 (14:55 -0400)]
Remove support for component alpha with HSL blend modes.

It isn't clear that component alpha makes sense with HSL blend modes.

15 years agoRemove FLASH_SUBTRACT blend mode.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 18:39:49 +0000 (14:39 -0400)]
Remove FLASH_SUBTRACT blend mode.

We may resurrect it later, but leave it out for now, as the closest
thing we have to a spec:

http://www.kaourantin.net/2005/09/some-word-on-blend-modes-in-flash.html

claims that alpha values should be subtracted, whereas real-world flash
files indicate that they shouldn't.

15 years agoFix BlendColorBurn
Carlos Garcia Campos [Tue, 23 Jun 2009 15:12:39 +0000 (17:12 +0200)]
Fix BlendColorBurn

It should return 0 when sa == 0

15 years agoAdd screen-test.c test program
Søren Sandmann Pedersen [Sun, 21 Jun 2009 00:19:57 +0000 (20:19 -0400)]
Add screen-test.c test program

15 years agoMake the composite test window bigger by default.
Søren Sandmann Pedersen [Wed, 17 Jun 2009 15:46:01 +0000 (11:46 -0400)]
Make the composite test window bigger by default.

Also rearrange the squares to better match typical aspect ratios.

15 years agoUse floating point in SetLum
Carlos Garcia Campos [Thu, 18 Jun 2009 13:24:33 +0000 (15:24 +0200)]
Use floating point in SetLum

15 years agoDo not use combineMask in component-alpha functions
Carlos Garcia Campos [Wed, 17 Jun 2009 15:40:52 +0000 (17:40 +0200)]
Do not use combineMask in component-alpha functions

15 years agoFix typo
Carlos Garcia Campos [Wed, 17 Jun 2009 14:59:45 +0000 (16:59 +0200)]
Fix typo

15 years ago[TEST] Update composite-test to test more operators
Carlos Garcia Campos [Wed, 17 Jun 2009 08:46:44 +0000 (10:46 +0200)]
[TEST] Update composite-test to test more operators

15 years agoFix ColorDodge and ColorBurn to conform to the spec
Søren Sandmann Pedersen [Sat, 29 Nov 2008 20:12:45 +0000 (15:12 -0500)]
Fix ColorDodge and ColorBurn to conform to the spec

15 years agoRemove optimizations that I'm not convinced are correct
Søren Sandmann Pedersen [Sat, 29 Nov 2008 20:11:07 +0000 (15:11 -0500)]
Remove optimizations that I'm not convinced are correct

15 years agoFix some more problems in MultiplyC
Søren Sandmann Pedersen [Sat, 29 Nov 2008 20:02:04 +0000 (15:02 -0500)]
Fix some more problems in MultiplyC

15 years agoFix various problems in FbCombineMultiplyC
Søren Sandmann Pedersen [Sat, 29 Nov 2008 19:53:57 +0000 (14:53 -0500)]
Fix various problems in FbCombineMultiplyC

Don't read the destination unless we have to.  fbByteMulAddC()
produces its result in its first argument, not its last.

15 years agoAdd some comments about the linearity of the non-separable blend modes
Søren Sandmann Pedersen [Wed, 26 Nov 2008 18:52:00 +0000 (13:52 -0500)]
Add some comments about the linearity of the non-separable blend modes

15 years agofix component-alpha versions to set source to 0 when mask is 0
Benjamin Otte [Tue, 25 Nov 2008 21:53:37 +0000 (22:53 +0100)]
fix component-alpha versions to set source to 0 when mask is 0

15 years agoremove debugging leftovers
Benjamin Otte [Tue, 25 Nov 2008 21:50:54 +0000 (22:50 +0100)]
remove debugging leftovers

15 years agocorrect subtract implementation
Benjamin Otte [Tue, 25 Nov 2008 21:50:17 +0000 (22:50 +0100)]
correct subtract implementation

15 years agofix Multiply component-alpha version
Benjamin Otte [Sun, 23 Nov 2008 17:36:32 +0000 (18:36 +0100)]
fix Multiply component-alpha version

15 years agofix comment
Benjamin Otte [Sun, 23 Nov 2008 17:34:50 +0000 (18:34 +0100)]
fix comment

15 years agofix component-alpha versions for seperable blend modes
Benjamin Otte [Sun, 23 Nov 2008 16:03:50 +0000 (17:03 +0100)]
fix component-alpha versions for seperable blend modes

15 years agorename operator SUBTRACT to FLASH_SUBTRACT
Benjamin Otte [Sun, 23 Nov 2008 15:23:22 +0000 (16:23 +0100)]
rename operator SUBTRACT to FLASH_SUBTRACT

Also document it and move it out of the PDF blend modes to make clear
that it is not in any way related to PDF.

15 years agorework blend-mode documentation to match current code better
Benjamin Otte [Sun, 23 Nov 2008 14:42:53 +0000 (15:42 +0100)]
rework blend-mode documentation to match current code better

15 years agotypo fix: Seperable => Separable
Benjamin Otte [Wed, 19 Nov 2008 20:07:13 +0000 (21:07 +0100)]
typo fix: Seperable => Separable

15 years agoremove semicolon at end of macro
Benjamin Otte [Wed, 19 Nov 2008 20:06:06 +0000 (21:06 +0100)]
remove semicolon at end of macro

15 years agoremove a leftover debugging statement
Benjamin Otte [Wed, 19 Nov 2008 20:05:16 +0000 (21:05 +0100)]
remove a leftover debugging statement

That was an assertion check by infinite loop

15 years agoinvent a Subtract operator for component alpha
Benjamin Otte [Thu, 13 Nov 2008 16:40:10 +0000 (17:40 +0100)]
invent a Subtract operator for component alpha

This seems to make sense, and as I can't test it against Adobe's Flash
player as that one can't do component alpha, this one looks best.

15 years agoadd non-seperable versions for component alpha
Benjamin Otte [Thu, 13 Nov 2008 16:34:19 +0000 (17:34 +0100)]
add non-seperable versions for component alpha

15 years agoadd component-alpha versions of the seperable blend-modes
Benjamin Otte [Thu, 13 Nov 2008 16:29:00 +0000 (17:29 +0100)]
add component-alpha versions of the seperable blend-modes

15 years agorewrite nonseperable blend modes the same way as seperable ones
Benjamin Otte [Thu, 13 Nov 2008 15:12:22 +0000 (16:12 +0100)]
rewrite nonseperable blend modes the same way as seperable ones

15 years agoclean up seperable blend modes
Benjamin Otte [Thu, 13 Nov 2008 14:13:17 +0000 (15:13 +0100)]
clean up seperable blend modes

The code is now shorter and faster than before

15 years agoprefix HSL operators with HSL
Benjamin Otte [Wed, 12 Nov 2008 18:26:13 +0000 (19:26 +0100)]
prefix HSL operators with HSL

This is necessary to distinguish SATURATE from PDF's HSL SATURATION

15 years agoremove invert operator
Benjamin Otte [Wed, 12 Nov 2008 18:12:12 +0000 (19:12 +0100)]
remove invert operator

src INVERT dest == (white IN src) DIFFERENCE dest

15 years agoadd nonseperable blend modes from PDF spec
Benjamin Otte [Thu, 23 Oct 2008 19:20:23 +0000 (21:20 +0200)]
add nonseperable blend modes from PDF spec

15 years agofix ColorDodge and ColorBurn to conform to the PDF spec
Benjamin Otte [Thu, 9 Oct 2008 19:46:50 +0000 (21:46 +0200)]
fix ColorDodge and ColorBurn to conform to the PDF spec

15 years agouse PDF algorithm for soft-light
Benjamin Otte [Thu, 9 Oct 2008 16:00:45 +0000 (18:00 +0200)]
use PDF algorithm for soft-light

15 years agoAdd INVERT and SUBTRACT blend modes used in Flash
Benjamin Otte [Tue, 7 Oct 2008 13:13:45 +0000 (15:13 +0200)]
Add INVERT and SUBTRACT blend modes used in Flash

15 years agouse a pixman_op_t here
Benjamin Otte [Wed, 29 Aug 2007 21:15:33 +0000 (23:15 +0200)]
use a pixman_op_t here

This improves the readability in gdb when debugging this structure

15 years agoAdd support for extended blend mode. First pass.
Benjamin Otte [Thu, 25 Sep 2008 10:53:06 +0000 (12:53 +0200)]
Add support for extended blend mode. First pass.

This adds support only for FbCombineU function.
This work is based on equations provided in SVG 1.2 specification draft.

http://www.w3.org/TR/SVG12/

Based on a previous patch by Emmanuel Pacaud <emmanuel.pacaud@free.fr>

15 years agoFix the build on big endian machines.
Michel Dänzer [Tue, 23 Jun 2009 18:02:26 +0000 (14:02 -0400)]
Fix the build on big endian machines.

15 years agoRename PIXMAN_FORMAT_16BPC macro to PIXMAN_FORMAT_IS_WIDE
Søren Sandmann Pedersen [Tue, 23 Jun 2009 17:44:48 +0000 (13:44 -0400)]
Rename PIXMAN_FORMAT_16BPC macro to PIXMAN_FORMAT_IS_WIDE

15 years agoWrite alpha map fetching with FbByteMul() instead of div_255()
Søren Sandmann Pedersen [Tue, 23 Jun 2009 17:41:27 +0000 (13:41 -0400)]
Write alpha map fetching with FbByteMul() instead of div_255()

Delete the div_255/div_65535 macros.

15 years agoRemove unused typedefs.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 11:34:17 +0000 (07:34 -0400)]
Remove unused typedefs.

15 years agoDelete unused _pixman_image_get_fetcher() function
Søren Sandmann Pedersen [Tue, 23 Jun 2009 00:43:08 +0000 (20:43 -0400)]
Delete unused _pixman_image_get_fetcher() function

15 years agoMove accessor macros to their own header.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:51:13 +0000 (19:51 -0400)]
Move accessor macros to their own header.

Also rearrange some things in pixman-private.h

15 years agoMove FbGet8() macro into pixman-bits-image.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:38:58 +0000 (19:38 -0400)]
Move FbGet8() macro into pixman-bits-image.c

It is only used for bilinear filtering now. Also some formatting
changes in pixman-private.h

15 years agoDelete FbInOverC macro
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:35:11 +0000 (19:35 -0400)]
Delete FbInOverC macro

15 years agoMake pixman-mmx.c compile again.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:25:25 +0000 (19:25 -0400)]
Make pixman-mmx.c compile again.

15 years agoFix typo in CLIP macro.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 20:34:15 +0000 (16:34 -0400)]
Fix typo in CLIP macro.

15 years agoTurn the FbAdd() macro into an FbIntAdd() which doesn't take a channel.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 20:05:27 +0000 (16:05 -0400)]
Turn the FbAdd() macro into an FbIntAdd() which doesn't take a channel.

The only use of the channel argument could be written better with FbByteAdd().

15 years agoDelete FbInU macro.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 19:58:28 +0000 (15:58 -0400)]
Delete FbInU macro.

Replace uses of it with FbIntMult().

15 years agoUse fbOver() instead of fbOver24.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 19:21:40 +0000 (15:21 -0400)]
Use fbOver() instead of fbOver24.

fbOver() is faster anyway, and this lets us get rid of fbOverU.

Also use FbByteMul() in fbIn instead of four times FbInU.

Finally, delete FbOverC and FbInC since they weren't used.

15 years agoEliminate Fetch/Store24 macros.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 12:09:11 +0000 (08:09 -0400)]
Eliminate Fetch/Store24 macros.

Replace them with inline functions in pixman-bits-image.c.

15 years agoRemove unused ACCESS macros in pixman-bits-image.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 11:05:24 +0000 (07:05 -0400)]
Remove unused ACCESS macros in pixman-bits-image.c

15 years agoVarious minor changes
Søren Sandmann Pedersen [Mon, 22 Jun 2009 10:51:04 +0000 (06:51 -0400)]
Various minor changes

- Add underscores to the pixman_image_get_solid(),
  pixman_image_is_solid(), and pixman_is_opaque() names.

- A number of formatting fixes

- Move debug code to the end of pixman-private.h

- Collect all prototypes for image methods in one place

15 years agoSome formatting changes
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:33:31 +0000 (22:33 -0400)]
Some formatting changes

15 years agoDelete struct point
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:16:39 +0000 (22:16 -0400)]
Delete struct point

15 years agoMove region helpers into pixman-utils.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:12:25 +0000 (22:12 -0400)]
Move region helpers into pixman-utils.c

15 years agoMove code around
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:11:07 +0000 (22:11 -0400)]
Move code around

15 years agoMove pixman_version() to pixman.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:05:49 +0000 (22:05 -0400)]
Move pixman_version() to pixman.c

15 years agoMove pixman_compute_composite_region() into pixman-utils.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:01:58 +0000 (22:01 -0400)]
Move pixman_compute_composite_region() into pixman-utils.c

15 years agoEliminate pointless Red/Green/Blue macros
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:42:14 +0000 (21:42 -0400)]
Eliminate pointless Red/Green/Blue macros

15 years agoGet rid of indexed argument to store functions
Søren Sandmann Pedersen [Thu, 4 Jun 2009 11:39:13 +0000 (07:39 -0400)]
Get rid of indexed argument to store functions

15 years agoMove macros around in pixman-private.h
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:36:43 +0000 (21:36 -0400)]
Move macros around in pixman-private.h

15 years agoMove some macros into pixman-access.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:32:23 +0000 (21:32 -0400)]
Move some macros into pixman-access.c

15 years agoDelete obsolete comment
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:28:38 +0000 (21:28 -0400)]
Delete obsolete comment

15 years agoMove edge stepper macros into pixman-edge.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:28:24 +0000 (21:28 -0400)]
Move edge stepper macros into pixman-edge.c

15 years agoDelete FB_MASK and FB_ALLONES macros
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:45:29 +0000 (19:45 -0400)]
Delete FB_MASK and FB_ALLONES macros

15 years agoImplement fbStore_a2g2b2r2
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:38:57 +0000 (19:38 -0400)]
Implement fbStore_a2g2b2r2

15 years agoReplace switch functions in pixman-access.c with a table of accessors.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:35:20 +0000 (19:35 -0400)]
Replace switch functions in pixman-access.c with a table of accessors.

Also delete unused orig_data pointer.

15 years agoRename pixman_image_can_get_solid() to pixman_image_is_solid
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:06:25 +0000 (19:06 -0400)]
Rename pixman_image_can_get_solid() to pixman_image_is_solid

15 years agoTurn fbComposeGetSolid() macro into a pixman_image_get_solid() function.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:58:53 +0000 (18:58 -0400)]
Turn fbComposeGetSolid() macro into a pixman_image_get_solid() function.

15 years agoDelete unused WRITE_ACCESS() macro
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:51:36 +0000 (18:51 -0400)]
Delete unused WRITE_ACCESS() macro

15 years agoMove pixman_image_fill_rectangles() to pixman.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:51:06 +0000 (18:51 -0400)]
Move pixman_image_fill_rectangles() to pixman.c

15 years agoDelete unused mod macro
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:43:27 +0000 (18:43 -0400)]
Delete unused mod macro

15 years agoEliminate bit fiddling macros from pixman-private.h.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:40:25 +0000 (18:40 -0400)]
Eliminate bit fiddling macros from pixman-private.h.

There was one remaining use of FbMaskBits in the a1 trap rasterizer;
just move that macro there.

15 years agoImplement fbComposeGetSolid() as a call to pixman_image_get_scanline()
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:29:39 +0000 (18:29 -0400)]
Implement fbComposeGetSolid() as a call to pixman_image_get_scanline()

15 years agoEliminate FbStipMask macro.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 20:45:17 +0000 (16:45 -0400)]
Eliminate FbStipMask macro.

It was only used for storing into a1 images, and that code could be
written more clearly by computing the bit index directly.

15 years agoImplement pixman_format_supported_destination() in terms of pixman_format_supported_s...
Søren Sandmann Pedersen [Sun, 21 Jun 2009 20:07:50 +0000 (16:07 -0400)]
Implement pixman_format_supported_destination() in terms of pixman_format_supported_source()

15 years agoMove FbGen macro into pixman-combine.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 19:09:02 +0000 (15:09 -0400)]
Move FbGen macro into pixman-combine.c

15 years agoUse DIV instead of _div In pixman-trap.c.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 17:18:46 +0000 (13:18 -0400)]
Use DIV instead of _div In pixman-trap.c.

15 years agoMove edge utilities into pixman-trap.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 15:19:00 +0000 (11:19 -0400)]
Move edge utilities into pixman-trap.c