Benjamin Otte [Sun, 23 Nov 2008 17:36:32 +0000 (18:36 +0100)]
fix Multiply component-alpha version
Benjamin Otte [Sun, 23 Nov 2008 17:34:50 +0000 (18:34 +0100)]
fix comment
Benjamin Otte [Sun, 23 Nov 2008 16:03:50 +0000 (17:03 +0100)]
fix component-alpha versions for seperable blend modes
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.
Benjamin Otte [Sun, 23 Nov 2008 14:42:53 +0000 (15:42 +0100)]
rework blend-mode documentation to match current code better
Benjamin Otte [Wed, 19 Nov 2008 20:07:13 +0000 (21:07 +0100)]
typo fix: Seperable => Separable
Benjamin Otte [Wed, 19 Nov 2008 20:06:06 +0000 (21:06 +0100)]
remove semicolon at end of macro
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
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.
Benjamin Otte [Thu, 13 Nov 2008 16:34:19 +0000 (17:34 +0100)]
add non-seperable versions for component alpha
Benjamin Otte [Thu, 13 Nov 2008 16:29:00 +0000 (17:29 +0100)]
add component-alpha versions of the seperable blend-modes
Benjamin Otte [Thu, 13 Nov 2008 15:12:22 +0000 (16:12 +0100)]
rewrite nonseperable blend modes the same way as seperable ones
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
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
Benjamin Otte [Wed, 12 Nov 2008 18:12:12 +0000 (19:12 +0100)]
remove invert operator
src INVERT dest == (white IN src) DIFFERENCE dest
Benjamin Otte [Thu, 23 Oct 2008 19:20:23 +0000 (21:20 +0200)]
add nonseperable blend modes from 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
Benjamin Otte [Thu, 9 Oct 2008 16:00:45 +0000 (18:00 +0200)]
use PDF algorithm for soft-light
Benjamin Otte [Tue, 7 Oct 2008 13:13:45 +0000 (15:13 +0200)]
Add INVERT and SUBTRACT blend modes used in Flash
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
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>
Michel Dänzer [Tue, 23 Jun 2009 18:02:26 +0000 (14:02 -0400)]
Fix the build on big endian machines.
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
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.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 11:34:17 +0000 (07:34 -0400)]
Remove unused typedefs.
Søren Sandmann Pedersen [Tue, 23 Jun 2009 00:43:08 +0000 (20:43 -0400)]
Delete unused _pixman_image_get_fetcher() function
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
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
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:35:11 +0000 (19:35 -0400)]
Delete FbInOverC macro
Søren Sandmann Pedersen [Mon, 22 Jun 2009 23:25:25 +0000 (19:25 -0400)]
Make pixman-mmx.c compile again.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 20:34:15 +0000 (16:34 -0400)]
Fix typo in CLIP macro.
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().
Søren Sandmann Pedersen [Mon, 22 Jun 2009 19:58:28 +0000 (15:58 -0400)]
Delete FbInU macro.
Replace uses of it with FbIntMult().
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.
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.
Søren Sandmann Pedersen [Mon, 22 Jun 2009 11:05:24 +0000 (07:05 -0400)]
Remove unused ACCESS macros in pixman-bits-image.c
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
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:33:31 +0000 (22:33 -0400)]
Some formatting changes
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:16:39 +0000 (22:16 -0400)]
Delete struct point
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:12:25 +0000 (22:12 -0400)]
Move region helpers into pixman-utils.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:11:07 +0000 (22:11 -0400)]
Move code around
Søren Sandmann Pedersen [Mon, 22 Jun 2009 02:05:49 +0000 (22:05 -0400)]
Move pixman_version() to pixman.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
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:42:14 +0000 (21:42 -0400)]
Eliminate pointless Red/Green/Blue macros
Søren Sandmann Pedersen [Thu, 4 Jun 2009 11:39:13 +0000 (07:39 -0400)]
Get rid of indexed argument to store functions
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:36:43 +0000 (21:36 -0400)]
Move macros around in pixman-private.h
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:32:23 +0000 (21:32 -0400)]
Move some macros into pixman-access.c
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:28:38 +0000 (21:28 -0400)]
Delete obsolete comment
Søren Sandmann Pedersen [Mon, 22 Jun 2009 01:28:24 +0000 (21:28 -0400)]
Move edge stepper macros into pixman-edge.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:45:29 +0000 (19:45 -0400)]
Delete FB_MASK and FB_ALLONES macros
Søren Sandmann Pedersen [Sun, 21 Jun 2009 23:38:57 +0000 (19:38 -0400)]
Implement fbStore_a2g2b2r2
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.
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
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.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:51:36 +0000 (18:51 -0400)]
Delete unused WRITE_ACCESS() macro
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:51:06 +0000 (18:51 -0400)]
Move pixman_image_fill_rectangles() to pixman.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 22:43:27 +0000 (18:43 -0400)]
Delete unused mod macro
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.
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()
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.
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()
Søren Sandmann Pedersen [Sun, 21 Jun 2009 19:09:02 +0000 (15:09 -0400)]
Move FbGen macro into pixman-combine.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.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 15:19:00 +0000 (11:19 -0400)]
Move edge utilities into pixman-trap.c
Søren Sandmann Pedersen [Sun, 21 Jun 2009 15:15:30 +0000 (11:15 -0400)]
Move compiler dependencies to a new pixman-compiler.h file
Søren Sandmann Pedersen [Sun, 21 Jun 2009 14:12:15 +0000 (10:12 -0400)]
Rename FastPathInfo to pixman_fast_path_t
Søren Sandmann Pedersen [Sun, 21 Jun 2009 14:09:22 +0000 (10:09 -0400)]
Eliminate MSBFirst, LSBFirst, IMAGE_BYTE_ORDER, and BITMAP_BIT_ORDER.
Just use WORDS_BIGENDIAN instead.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 13:50:24 +0000 (09:50 -0400)]
Rename combine.inc and combine.h.inc to pixman-combine.{c,h}.template.
Søren Sandmann Pedersen [Sun, 21 Jun 2009 13:44:22 +0000 (09:44 -0400)]
Only use force_align_arg_pointer on gcc/x86-32
Søren Sandmann Pedersen [Sun, 21 Jun 2009 00:28:36 +0000 (20:28 -0400)]
Rename pixman-pict.c to pixman.c
There are no traces of fbpict.c in it anymore.
M Joonas Pihlaja [Fri, 19 Jun 2009 14:29:11 +0000 (17:29 +0300)]
Remove redundant NULL checks from general_composite_rect().
The general_composite_rect() function has two invocations
of the return_if_fail() macro before any of its variable
declarations. Removing them allows for compilation to
succeed using a pre-C99 compiler.
Søren Sandmann Pedersen [Fri, 19 Jun 2009 17:19:02 +0000 (13:19 -0400)]
Get rid of pixman_region_internal_set_static_pointers()
Instead just define the function in pixman-region16.c
Søren Sandmann Pedersen [Thu, 4 Jun 2009 11:31:39 +0000 (07:31 -0400)]
Rename PixmanTimer to pixman_timer_t
Søren Sandmann Pedersen [Thu, 4 Jun 2009 11:29:14 +0000 (07:29 -0400)]
Rename GradientWalker to pixman_gradient_walker_t
Søren Sandmann Pedersen [Fri, 19 Jun 2009 17:14:11 +0000 (13:14 -0400)]
Delete unused IS_SOURCE_IMAGE() macro
Søren Sandmann Pedersen [Thu, 4 Jun 2009 11:17:36 +0000 (07:17 -0400)]
Remove commented-out fbAddTriangles
Søren Sandmann Pedersen [Fri, 19 Jun 2009 17:04:26 +0000 (13:04 -0400)]
Remove useless FbBits typedef
Søren Sandmann Pedersen [Thu, 4 Jun 2009 10:52:32 +0000 (06:52 -0400)]
Delete unused CombineFunc{32,64} types
Søren Sandmann Pedersen [Fri, 19 Jun 2009 16:57:56 +0000 (12:57 -0400)]
Rename bits_image.fetch_pixels_{32,64} to fetch_pixels_raw_{32,64}
Also add a couple of comments about what these functions do.
Søren Sandmann Pedersen [Fri, 19 Jun 2009 16:28:59 +0000 (12:28 -0400)]
Delete empty FASTCALL macro
Søren Sandmann Pedersen [Fri, 19 Jun 2009 16:15:19 +0000 (12:15 -0400)]
Delete FbComposeData type
Søren Sandmann Pedersen [Thu, 4 Jun 2009 10:02:32 +0000 (06:02 -0400)]
Remove unused pixmanFetchGradient() declaration
Søren Sandmann Pedersen [Thu, 4 Jun 2009 02:51:18 +0000 (22:51 -0400)]
Remove dstMask from pixman-fast-path.c
These were used to zero the x8 channel of PIXMAN_x8r8g8b8
destinations. However, we treat this channel as undefined, so there is
no need to zero it.
Søren Sandmann Pedersen [Thu, 4 Jun 2009 02:48:57 +0000 (22:48 -0400)]
Eliminate trivial READ and WRITE macros in pixman-fast-path.c
William Bonnet [Fri, 19 Jun 2009 11:27:28 +0000 (07:27 -0400)]
Fix build on Sun Studio.
Don't use return in a void function.
Jonathan Morton [Tue, 16 Jun 2009 16:08:29 +0000 (12:08 -0400)]
[NEON] Add ARGB8-over-RGB565 compositing blitter.
Jonathan Morton [Tue, 16 Jun 2009 16:08:29 +0000 (12:08 -0400)]
[NEON] Add transparent rect blitter.
Jonathan Morton [Tue, 16 Jun 2009 16:08:29 +0000 (12:08 -0400)]
[NEON] Replace Ian's glyph-blitter with a better one.
Each scanline of the destination is bulk-loaded into a cached buffer on
the stack (using the QuadWordCopy routine) before being processed. This
is the primary benefit on uncached framebuffers, since it is necessary
to minimise the number of accesses to such things and avoid
write-to-read turnarounds.
This also simplifies edge handling, since QuadWordCopy() can do a
precise writeback efficiently via the write-combiner, allowing the main
routine to "over-read" the scanline edge safely when required. This is
why the glyph's mask data is also copied into a temporary buffer of
known size.
Each group of 8 pixels is then processed using fewer instructions,
taking advantage of the lower precision requirements of the 6-bit
destination (so a simpler pixel multiply can be used) and using a more
efficient bit-repacking method.
(As an aside, this patch removes nearly twice as much code as it
introduces. Most of this is due to duplication of Ian's inner loop,
since he has to handle narrow cases separately. RVCT support is of
course preserved.)
We measured the doubling of performance by rendering 96-pixel height
glyph strings, which are fillrate limited rather than latency/overhead
limited. The performance is also improved, albeit by a smaller amount,
on the more usual smaller text, demonstrating that internal overhead is
not a problem.
Søren Sandmann Pedersen [Tue, 16 Jun 2009 15:59:20 +0000 (11:59 -0400)]
Post-release version bump
Søren Sandmann Pedersen [Tue, 16 Jun 2009 15:52:48 +0000 (11:52 -0400)]
Pre-release version bump
Jonathan Morton [Mon, 15 Jun 2009 13:09:32 +0000 (16:09 +0300)]
Add RVCT support for straight blitter.
Jonathan Morton [Mon, 15 Jun 2009 13:02:04 +0000 (16:02 +0300)]
Better CFLAGS handling for recent ARM platforms.
Jonathan Morton [Wed, 27 May 2009 12:31:59 +0000 (15:31 +0300)]
Misc warning fixes.
Søren Sandmann Pedersen [Sat, 13 Jun 2009 13:32:59 +0000 (09:32 -0400)]
Add API to set a function to be called when the image is destroyed.
Søren Sandmann Pedersen [Wed, 10 Jun 2009 12:52:31 +0000 (08:52 -0400)]
Work around X server bug.
X servers prior to
ebfd6688d1927288155221e7a78fbca9f9293952
relied on pixman not clipping to destination geometry whenever an
explicit clip region was set. Since only X servers set
source_clipping, we can just trigger off of that.
Søren Sandmann Pedersen [Wed, 3 Jun 2009 09:21:29 +0000 (05:21 -0400)]
Move region computation closer to the region walking.
Computing the composite is region is a bit expensive, so only compute
it if we are likely to actually walk it.
Søren Sandmann Pedersen [Wed, 3 Jun 2009 03:17:34 +0000 (23:17 -0400)]
Simplify clipping rule
The new rule is:
- Output is clipped to the destination clip region.
- If a source image has the clip_sources property set, then there
is an additional step, after repeating and transforming, but before
compositing, where pixels that are not in the source clip are
rejected. Rejected means no compositing takes place (not that the
pixel is treated as 0). By default source clipping is turned off;
when they are turned on, only client-set clips are honored.
The old rules were unclear and inconsistently implemented.
Søren Sandmann Pedersen [Wed, 3 Jun 2009 04:25:54 +0000 (00:25 -0400)]
Fix pixman_image_is_opaque()
- Don't claim that non-repeating bits images are opaque.
- Don't claim that conical gradients are opaque ever.
Søren Sandmann Pedersen [Wed, 3 Jun 2009 02:57:23 +0000 (22:57 -0400)]
Only call fast paths when the images cover the composite region
Søren Sandmann Pedersen [Wed, 3 Jun 2009 02:17:00 +0000 (22:17 -0400)]
Pass the region to walk_region_internal()