summaryrefslogtreecommitdiff
path: root/image
Commit message (Collapse)AuthorAge
* No issue - Limit JPEG decoder memory allocation to surface cache size.Moonchild2023-05-10
| | | | | | This means that for trivial images whose header specifies large dimensions but with no image data, we don't waste a lot of memory. See BZ bug 1277397
* Issue #1656 - Remove more vim control lines.Moonchild2023-05-03
| | | | | | | Vim control lines were re-introduced or not entirely cleaned up. This nukes them again. Removing from the rest of js, caps, chrome, config, devtools, docshell, image, intl. More to come.
* Merge pull request 'Follow-up: Use internal Move instead of std::move for ↵Moonchild2023-04-30
|\ | | | | | | | | | | consistency in SurfaceCache' (#2220) from FranklinDM/UXP-contrib:work_image-followup-move into master Reviewed-on: https://repo.palemoon.org/MoonchildProductions/UXP/pulls/2220
| * Issue #2073 - Follow-up: Use internal Move instead of std::move for consistencyFranklinDM2023-04-30
| |
* | Issue #2218 - Part 2: Make SurfaceCache free ImageSurfaceCache objects ↵FranklinDM2023-04-30
|/ | | | | | outside of the lock Based on https://bugzilla.mozilla.org/show_bug.cgi?id=1389479
* Issue #2131 - Remove image.webp.enabled preferenceMoonchild2023-02-27
|
* Issue #1382 - Fix invalid assert for decoder type if JXL is not built on ↵FranklinDM2023-02-20
| | | | debug builds
* Issue #2073 - m-c 1454149: Do not advance animated images which are not ↵Martok2023-01-04
| | | | displayed
* Issue #2073 - m-c 1546500: Avoid dispatching synchronous thread shutdown ↵Martok2023-01-04
| | | | runnables
* Issue #2073 - m-c 1651587: Make image::Image release efficient on main threadMartok2023-01-04
|
* Issue #2073 - m-c 1383404: make SourceBuffer::Compact more efficient (squashed)Martok2023-01-04
| | | | | The first part also means that Compact no longer needs the SurfaceCache lock (used to be via CreateChunk->CanHold), which avoids potential deadlocks during shutdown that m-c 523950 would otherwise cause
* Issue #2073 - m-c 523950: Discard decoded frames of very large GIF ↵Martok2023-01-04
| | | | | | | | | | | | animations (squashed) Controlled by image.animated.decode-on-demand.threshold-kb, default 256MB Includes squashed bugfixes/regressions: - m-c 1444537: Shutting down the decode pool should make animated decoders bail early - m-c 1628606: Make sure to mark the surface cache entry available before sending the frame complete notification - m-c 1502275: Skip recreating the decoder after redecode errors if an animated image is reset - m-c 1443232: Don't insert frames into our AnimationFrameBuffer that we consider in error and unusable
* Issue #2073 - m-c 1343341: Infrastructure necessary to allow discarding of ↵Martok2023-01-03
| | | | | | | | | animated images (squashed) Includes squashed changes of: - m-c 1317907: Refactor FrameAnimator::GetCompositedFrame to be a bit simpler - m-c 1351434: bugfix - m-c 686905: Enable the pref image.mem.animated.discardable to allow discarding of animated images
* Issue #2073 - m-c 1382683: Accelerate GIF decoding to SurfacePipeMartok2023-01-03
| | | | | 1. Implement SurfacePipe::WritePixelBlocks for faster writing of pixels 2. Switch nsGIFDecoder2 to write pixels in blocks instead of individually
* Issue #2057 - Use gfxPackedPixel + WritePixels instead of WriteBuffer.Job Bautista2022-12-19
| | | | This means we no longer need the workarounds intended for #2033 and #2040!
* Issue #2041 follow-up - fix macro conditionlexx99992022-12-11
|
* Issue #2041 Follow-up - Remove opacity check from original patch.Job Bautista2022-12-02
| | | | | | | Per Issue #2033 we don't support expanding RGB to RGBA yet, so this opacity check will always return RGBX, which makes images with transparent backgrounds show up with a black background instead. Feel free to readd once we backport Mozilla bug 1551088.
* Issue #2048 - Add progressive decoding for JPEG-XL.Job Bautista2022-12-02
| | | | | | Based on Mozilla phab D122159, intended for bug 1709815. Also moved the temporary RGBA and premultiplication fixes to a macro, since progressive decoding also needs these fixes.
* Issue #2041 - Add animation support for JPEG-XL.Job Bautista2022-12-02
| | | | Based on Mozilla phab D122158, intended for bug 1709818.
* Issue #2040 - Pre-multiply the alpha values in our JXL decode buffer.Moonchild2022-11-30
| | | | | Using selective calculation (only if not opaque) and fast integer math here should optimize well in compilers.
* [no issue] fix whitespace.Moonchild2022-11-24
|
* Issue #2033 - Temporary fix of R<->B channel swap.Moonchild2022-11-24
| | | | | | | | | | | We have a BGR/RGB channel ordering mismatch here. to at least provide proper display, a quick&dirty byte swap on the output buffer will fix this for now, but we should look into seeing where the surface mismatch is caused. std::swap() should optimize pretty well in any of the used compilers, but if necessary, a full buffer ASM routine can be slotted in (although on current hardware I doubt this will be even noticeable as it is)
* Merge branch 'master' into 1769-take2Moonchild2022-11-07
|\
| * [No issue] Hold some strong references on nsRefreshDriverMoonchild2022-10-26
| |
* | Issue #1769 - Part 2 Follow-up: Do not use namespace parent::child {} for ↵Job Bautista2022-06-29
| | | | | | | | | | | | | | defining nested namespaces. It doesn't build for MSVC on Windows. Also other decoders are using the old way for defining nested namespaces, so better be consistent here.
* | Issue #1769 - Part 3: Cleanup nsJXLDecoder.Job Bautista2022-06-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The mp4parse Rust component has been removed in Issue #58. It doesn't seem like the decoder uses any mp4parse function, so seems like it's safe to remove it. Removed const DecoderType named GetType() because we don't have it in our Decoder.h. I've decided to abandon the OS_RGBA backporting effort and instead went for using OS_RGBA's value which is R8G8B8A8. Turns out that there is much more going on in Mozilla's version of CreateSurfacePipe than I've expected, like the aInFormat and aOutFormat thing which I really don't want to delve into right now. Looking at the code it looks like all JPEG-XL images are expected to have an alpha channel anyway, so I think my workaround should be safe. I also removed the dependency in OrientedIntSize and used Size() from gfx/2d/ Point.h like our PNG and GIF decoders currently do. Migrating our decoders to OrientedInt types should be done in another PR instead. Also also changed the coding style to be closer to UXP's. Also also also, I made a mistake in Part 1's commit message; the commit used for libjxl is 192ddd90fdf0c69cd1db1c8d7850db036dd87f4b.
* | Issue #1769 - Part 2: Implement JPEG-XL decoder and about:config and MIME ↵Job Bautista2022-06-29
|/ | | | | | plumbing. Backported from Mozilla bug 1707590 whereever possible.
* Issue #1926 - Update image/Orientation.hJob Bautista2022-06-19
|
* [Image] Image cleanupRandell Jesup2022-05-30
|
* [image] Add additional locks to imgFrame.Moonchild2022-05-30
|
* Merge branch 'master' into 1829Brian Smith2022-04-28
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: No issue - Update README and SECURITY Issue #1885 - Follow-up: Update error message if invalid rootMargin specified. Issue #1879 - Follow-up: Update config/external/nss/target to security/target. Issue #1885 - Allow unitless rootMargin entries for IntersectionObserver. Issue #1879 - Revert changes to cryptox.h Revert "Issue #1879 - spot-fix typo in cryptox.h" Issue #1879 - spot-fix typo in cryptox.h Issue #21 - Change MappedAttrParser to store its nsIPrincipal instead of nsSVGElement Issue #21 - Remove use counters telemetry Issue #1881 - Interpret empty or whitespace root margin string as zero length Issue #1877 - Resolve NIGHTLY_BUILD conditionals. Issue #1880 - Boot Comic Sans out of the font configuration.
| * Issue #21 - Remove use counters telemetryFranklinDM2022-04-24
| | | | | | | | | | | | This reverts Bug 968923 - Implement some equivalent of Chrome's use counters (on top of telemetry?) For reference: https://bugzilla.mozilla.org/show_bug.cgi?id=968923
* | Issue #1829 - Revert “Issue #1751 -- Remove XP_MACOSX conditionals from ↵Brian Smith2022-04-26
| | | | | | | | | | | | | | | | | | the rest of the tree.” This also removes some PP abuse and takes file entries out of PP when no longer needed without XP_MACOSX conditionals. This reverts commit 6f707bde95dab6998ac204f9ee6c925ee230c740.
* | Issue #1829 - Revert “Issue #1751 - Remove Mac code behind ↵Brian Smith2022-04-26
|/ | | | | | MOZ_WIDGET_TOOLKIT == 'cocoa’” This reverts commit 1fe9c19305dadf2d5bcaa0e589fcd250389dfa8a.
* Issue #21 - Remove remaining telemetry structs, callers and flags.Moonchild2022-04-02
|
* Issue #21 - Remove Telemetry plumbing and fix build.Moonchild2022-04-02
| | | | | Note this won't give working applications. Requires FE changes and additional js module changes (next part).
* Issue #1822 - Part 3: Remove LOAD_CLASSIFIER_URI and variousMoonchild2022-04-01
| | | | helper functions.
* Issue #1751 - Remove Mac code behind MOZ_WIDGET_TOOLKIT == 'cocoa'Moonchild2021-06-21
|
* Issue #1751 -- Remove XP_MACOSX conditionals from the rest of the tree.Moonchild2021-05-06
| | | | | This also removes some PP abuse and takes file entries out of PP when no longer needed without XP_MACOSX conditionals.
* Issue #1656 - Part 8: Devtools and misc.Moonchild2020-09-24
|
* Issue #1656 - Part 6: Clean up the build filesMoonchild2020-09-23
|
* Issue #1656 - Part 1: Nuke most vim config lines in the tree.Moonchild2020-09-23
| | | | | | Since these are just interpreted comments, there's 0 impact on actual code. This removes all lines that match /* vim: set(.*)tw=80: */ with S&R -- there are a few others scattered around which will be removed manually in a second part.
* Issue #1619 - Convert Intrinsic Ratio to FloatAndy2020-07-31
| | | | | | | | | https://bugzilla.mozilla.org/show_bug.cgi?id=1547792 Aspect Ratio handling simplified by using floating point integers: - Multiplication of value (or inverse value) to a known side for Scaling - No unequal equal values such as "4/3" vs "8/6" vs "20/15" - Truly "Empty" aspect ratios, even if one dimension is not 0
* [image] Add a sanity check to JPEG encoder buffer handling, just in case.Moonchild2020-07-09
|
* Issue #439 - Remove, fix and clean up automated testsMoonchild2020-06-08
| | | | | | | With the big amount of code churn around DOM a lot of tests broke severely enough that they caused build bustage. This commit cleans up, removes or otherwise fixes tests that are broken, no longer relevant or obsolete.
* Issue #1543 - Align <img> with no src to the updated spec.Moonchild2020-05-11
|
* Issue #1053 - Remove android support from imageMatt A. Tobin2020-02-23
|
* Convert dom/base/nsImageLoadingContent.cpp to use AsyncOpen2 and followups ↵win7-72019-08-08
| | | | | | along with it (1445670 and 1373780 part 2 and 3) Convert dom/base/nsImageLoadingContent.cpp to use AsyncOpen2 and followups along with it (1445670 and 1373780 part 2 and 3)
* Fix order of member variables in a couple of initializer listsadeshkp2019-03-14
|
* BMPs from the clipboard may include extra padding.Andrew Osmond2019-02-16
| | | | | | | | | | | | | In the original Windows clipboard BMP decoder implementation in nsImageFromClipboard::ConvertColorBitMap, if the bitmap used bitfields compression, it always adjusted the offset to the RGB data by 12 bytes. It did this even for newer BMP header formats which explicitly include space for the bitfields in their header sizes. This patch updates our BMP decoder to do the same for clipboard BMPs, since we have observed pasted BMPs using bitfield compression appearing incorrectly. To the user this appears as if we read a color mask; completely red, blue, green pixels at the start of the last row, causing all of the other rows to start with the last three pixels of the previous row.