summaryrefslogtreecommitdiff
path: root/source
AgeCommit message (Collapse)Author
2016-06-07Fix subarea image calculationsRobin Watts
Calculations that involved non power of 2 bpps were going wrong.
2016-06-06Bug 696810: Avoid integer overflows.Robin Watts
When blanking pixmaps (or converting pixmap colors), watch out for integer overflows.
2016-06-06Update MuJS.Tor Andersson
2016-06-06Add FZ_ENABLE_JS configuration define.Tor Andersson
2016-06-06Minimize the number of CMaps built in to the ones listed in the spec.Tor Andersson
Omitting the unlisted UTF-8 and UTF-32 CMaps saves ~1M. Omitting the unlisted other CMaps saves ~200k. Define CJK_CMAPS=0 to skip all CMaps. Define EXTRA_CMAPS=1 to include the various other CMaps. Define UTF8_CMAPS=1 and UTF32_CMAPS to include the UTF-8 and UTF-32 CMaps.
2016-06-06Fix broken ARM implementation of scale_row_to_temp3.Robin Watts
I had changed some code to *3 when creating the routine from the 4 bpp variant, but this particular multiplication should still have been *4, as it was looking up in an int table.
2016-06-06Fix problem with FZ_PLOTTER_G only builds.Robin Watts
In C we can't have a label as the only thing in a block.
2016-06-06Change ARM assembler to be compatible with Xcode/clangJoseph Heenan
clang only accepts the unified format - so use the unified syntax everywhere, and add .syntax unified to tell the gnu assembler we're using the unified syntax.
2016-05-31Bug 696813: Fix Lab colorspaces.Robin Watts
Lab colorspaces had been broken due to incorrect clipping of color values introduced in an effort to fix Bug 696796.
2016-05-31Update test device with passthrough option.Robin Watts
Update the test device so it can be used 'wrapping' another device. In particular, it can be used to wrap the display list device so that we can evaluate 'color or not' while building the display list rather than having to rerun the display list afterwards. Also, give improved control over whether we test every pixel of images/shadings.
2016-05-30Fix some "defined but not used" when FZ_PLOTTERS_RGB is 0.Robin Watts
2016-05-30Avoid fz_font pulling harfbuzz in.Robin Watts
We store an hb_font in every font, and currently have fz_drop_font know to call harfbuzz to destroy it. This causes harfbuzz to be included even in builds that never use it. We improve this situation by storing both an hb_font, and a function pointer to destroy it within fz_font. This costs us an extra pointer per fz_font, but solves the problem.
2016-05-30Respect FZ_ENABLE_SVG=0 in HTML/EPUB.Tor Andersson
Don't try to load SVG images if SVG support is disabled.
2016-05-30Respect FZ_ENABLE_PDF=0 to allow dropping all PDF specific code in tools.Tor Andersson
2016-05-30Add TOFU_BASE14 option.Robin Watts
2016-05-30Ensure that we can use FZ_PLOTTERS_N instead of FZ_PLOTTERS_RGB.Robin Watts
2016-05-30Add config.h include file.Robin Watts
Introduce FZ_PLOTTER defines to set which defines we required. Add FZ_ENABLE define to set which document handlers are built by default.
2016-05-29Accelerate common n=3 color case.Robin Watts
2016-05-29Tweak plotter code slightly for speed.Robin Watts
Use do {} while(--w) rather than while(w--) {} as this safes a test each time around the loop.
2016-05-29Improve speed of fz_paint_solid_color and friends.Robin Watts
2016-05-29Split draw-paint.c plotters out into separate functions.Robin Watts
Again, mainly so profiling works nicely.
2016-05-27Improve speed of fz_paint_affine_N_near and friends.Robin Watts
For the common cases, avoid the loop.
2016-05-27Rejig draw-affine.c for improved profiling.Robin Watts
Profilers can't identify which of the switch arms we are in for the inlined function calls, so rejig the code so that each of these is a separate function. In theory this code should be faster too, as the function 'lookup' is only done one rather than once per line, but I don't expect this to make a huge difference.
2016-05-27Add facility to track usage of functions.Robin Watts
Use this for plotters so we can see which ones are being used in any given build. Build with -DTRACK_USAGE to enable.
2016-05-27Mudraw: Move halftoning into render threads.Robin Watts
2016-05-27Fix ARM code for bitmap scalingRobin Watts
2016-05-26Bug 696803: Fix pam output.Robin Watts
PAM output was broken in the absence of alpha. Fixed now.
2016-05-26Optimisations in draw-affine for 0 alpha pixels.Robin Watts
2016-05-26Cope better when asked to plot alpha only pixmaps.Robin Watts
Converting a pixmap to an alpha only pixmap means "just keep the alpha". If there IS no alpha, then a solid alpha is assumed.
2016-05-26Avoid unnecessary alphas when decompressing images from streams.Robin Watts
2016-05-26Ensure fz_invert_pixmap can cope with no alpha.Robin Watts
2016-05-26Update bitmap scaler to cope with lack of alpha.Robin Watts
If we have alpha on the input, we preserve it. If we have no alpha on the input, we have to create it in the output if the edges aren't pixel aligned.
2016-05-24Skip alphas for "loaded" JPXs (where possible).Robin Watts
2016-05-24Fix fz_decode_tile in the absence of alpha.Robin Watts
When no alpha present, we were omitting to decode the last component.
2016-05-24Fix plotters; alpha being dropped.Robin Watts
In the absence of the source image having an alpha plane, we were dropping the constant alpha during linear interpolated plotting.
2016-05-24Fix optimisation in fz_paint_affine_N_nearRobin Watts
Only do int to int copying if we have an int to copy from. Also, when copying int to int, copy int32_t to int32_t to make us more future proof.
2016-05-24Skip alphas for "loaded" JPEGs.Robin Watts
2016-05-24Fix 696796: clamp color values in PDF to valid range.Tor Andersson
2016-05-24Fix issues uncovered by coverity.Tor Andersson
2016-05-24Sprinkle some consts and restricts in plotters.Robin Watts
Try and help C avoid pointer aliasing issues. Some of this may not help at all. None of it should hurt though.
2016-05-24Silence "Variable might be used uninitialised" warning.Robin Watts
2016-05-24Fix ARM code in light of plotter changes.Robin Watts
2016-05-24fz_pixmap revamp: add stride and make alpha optionalRobin Watts
fz_pixmaps now have an explicit stride value. By default no change from before, but code all copes with extra gaps at the end of the line. The alpha data in fz_pixmaps is no longer compulsory. mudraw: use rgb not rgba (ppmraw), cmyk not cmyka (pkmraw). Update halftone code to not expect alpha plane. Update PNG writing to cope with alpha less input. Also hide repeated params within the png output context. ARM code needs updating.
2016-05-23Bug 696795: Proper fix.Robin Watts
When affine plotting with linear interpolation, we need to perform different calculations for the texture and for the edge of the shape. The edge of the shape needs to be calculated in exactly the same way as for non-linear interpolated shapes. The 'texture' position needs to be offset by 1/2 a texture unit in each direction so that the 'pure' color is given in the middle of the texture cells image, not in the top left corner. To achieve these aims, we actually offset the u/v positions by 1/2 (32768, given the fixed point we are using) and adjust for this in the boundary tests. I have a test file that shows this working, which I will attach to the bug, and add to the regression suite.
2016-05-20murun: Add Buffer#writeBuffer to allow for concatenating buffers.Tor Andersson
2016-05-20murun: Add graftObject to javascript bindings.Tor Andersson
Add some paranoid checks to pdf_graft_object to prevent user errors from crashing mupdf.
2016-05-20html: Add SVG image support.Tor Andersson
2016-05-20Add images based on display lists.Tor Andersson
2016-05-20Fix typo.Robin Watts
2016-05-20Remove voodoo from draw-affine.Robin Watts
We had some code in draw-affine that we didn't really understand. Change this for some code that seems more plausible. The voodoo code was showing up problems with the plotter rework (don't really know why), but the non-voodoo code seems happier.