Kim Woelders
01424487e3
1.7.1
2020-12-09 17:46:24 +01:00
Kim Woelders
381e65f567
Silence a couple of sign-compare warnings
2020-12-09 17:44:16 +01:00
Kim Woelders
ae3d501f93
XPM loader: Get transparency right when doing header-only loading
...
We have to parse the colormap too to figure that out.
2020-12-08 20:07:48 +01:00
Kim Woelders
64df90de3d
WEBP loader: Add initial signature check
...
Avoid potentially wasting much time when loading/checking large
non-webp files.
2020-12-06 18:09:42 +01:00
Kim Woelders
e3be3eb0fc
grab.c: Support 30bpp display in __imlib_GrabXImageToRGBA()
...
Patch by the_third.
https://phab.enlightenment.org/T8808
2020-12-06 14:16:45 +01:00
Kim Woelders
9219b2c6a3
rend.c: Fix __imlib_generic_render() when jump != 0
...
Patch by the_third.
https://phab.enlightenment.org/T8799
2020-12-06 14:14:09 +01:00
Daniel Kolesa
92d3153fee
Fix big endian build
2020-08-09 21:00:46 +02:00
Kim Woelders
7066b54364
1.7.0
2020-08-01 07:02:26 +02:00
Kim Woelders
9e8978c6be
Remove a couple of unused includes
2020-07-28 21:35:39 +02:00
Kim Woelders
ea5da196cb
Fix build without X11
2020-07-28 19:57:11 +02:00
Kim Woelders
06aa6d1bfc
imlib2_load: Optionally use imlib_load_image_fd()
2020-04-14 17:47:00 +02:00
Kim Woelders
0547caa67a
configure.ac: Drop initial config.cache removal
...
Not removing config.cache does not seem to cause trouble elsewhere.
2020-04-14 17:36:55 +02:00
Alexander Volkov
204d994d8c
Don't rescan loaders
...
Summary:
Loaders from a newer version of imlib2 may be incompatible with an
older version of imlib2. Thus already running applications may
stop loading images after system upgrade, which can be extremely
unpleasant for the user.
Reviewers: kwo
Reviewed By: kwo
Differential Revision: https://phab.enlightenment.org/D11678
2020-04-14 17:34:41 +02:00
Alexander Volkov
5db012a35e
Introduce imlib_load_image_from_fd()
...
Summary:
It can be used to load files in a process, which has no access to the file,
by passing the file descriptor to it. For example, in a sandboxed process.
Also anonymous files created with O_TMPFILE or by memfd_create() can be loaded.
Reviewers: kwo
Differential Revision: https://phab.enlightenment.org/D10262
2020-03-04 17:15:23 +01:00
Kim Woelders
07e1601cd5
Reduce number of stat() calls during load
...
Also skip empty files entirely.
2020-03-01 06:28:28 +01:00
Kim Woelders
6c2fe14b82
Move loaders to load2()
2020-02-29 18:04:34 +01:00
Kim Woelders
b9166551ac
Add infrastructure for new loader entry - load2()
2020-02-29 18:04:34 +01:00
Kim Woelders
57a26386ba
JPG, PNG loaders: Avoid clobber warnings - Take N+1
2020-02-29 11:25:18 +01:00
Kim Woelders
c608354760
Revert "JPG, PNG loaders: Avoid clobber warnings"
...
This caused a segv in the jpg loader if trying to load a non-jpg image
(gcc 9.2.1 with -O2, not with -O).
This reverts commit f588650bb6
.
2020-02-29 06:55:15 +01:00
Kim Woelders
c913f97285
__imlib_FileExtension: Use basename if there are no dots
2020-02-27 21:20:36 +01:00
Kim Woelders
ac41eae7fa
GZ, BZ2 loaders: Accept more file names
...
E.g. ".png.gz", "png.gz", ".../png.gz".
2020-02-27 21:20:36 +01:00
Alexander Volkov
97865ad8ef
GIF loader: Don't close file descriptor twice
...
Summary:
DGifOpenFileHandle() closes it on failure and DGifCloseFile()
closes it when working normally.
Reviewers: kwo
Differential Revision: https://phab.enlightenment.org/D11425
2020-02-26 19:06:34 +01:00
Kim Woelders
4d191f6492
ID3 loader: Some mostly cosmetic rearrangements
2020-02-23 13:26:00 +01:00
Kim Woelders
4ec88a0dda
TIFF loader: Minor speedup
2020-02-23 13:26:00 +01:00
Kim Woelders
b059049034
Add a couple of consts
2020-02-23 13:26:00 +01:00
Kim Woelders
f588650bb6
JPG, PNG loaders: Avoid clobber warnings
2020-02-17 18:18:13 +01:00
Kim Woelders
8d9f33d365
Fix enum conversion warnings (gcc10)
2020-02-01 19:30:03 +01:00
Tobias Stoeckmann
d5400cc047
ICO loader: Handle malloc failures
...
If not enough memory is available and a program is run on a system
which returns NULL in such cases, then treat this error gracefully.
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2020-01-20 21:49:57 +01:00
Tobias Stoeckmann
c95f938ff1
ICO loader: Do not crash on invalid files
...
If an ICO file contains icons with an excessively large amount of colors
in its color map, an integer overflow can lead to 0 byte allocations of
the color map.
If such an icon is displayed later on, the color map access leads to
out of boundary reads.
Also verify that excessively large icons are not parsed at all to prevent
out of boundary reads of raw pixel data during display.
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2020-01-20 06:21:15 +01:00
Kim Woelders
106e2188ee
autogen.sh: Add -n as alternative to NOCONFIGURE
2020-01-11 12:56:43 +01:00
Kim Woelders
9eaed188d2
Make ImlibLoader struct opaque
...
Loaders should no longer directly access it.
2020-01-11 12:56:08 +01:00
Kim Woelders
875bc82b49
Introduce __imlib_LoaderSetFormats()
2020-01-11 12:55:08 +01:00
Kim Woelders
c02dc3c975
Introduce __imlib_LoadEmbedded()
2020-01-11 12:55:08 +01:00
Kim Woelders
10e21579fa
Savers: Simplify progress handling
2020-01-04 15:30:20 +01:00
Kim Woelders
0f5b4fb10a
Loaders: Simplify/fix progress handling
...
Progress handling was broken in at least bmp, gif, lbm, and png loaders.
2020-01-04 15:30:20 +01:00
Kim Woelders
87c84278ec
image.c: Add infrastructure to simplify progress handling
2020-01-04 15:30:20 +01:00
Kim Woelders
9f479126f9
image.c: Remove redundant pixmap unref
...
Already done in __imlib_ConsumeImage().
2020-01-04 15:30:20 +01:00
Kim Woelders
495527a74e
Fix loader cleanup breakage (gif)
2019-12-29 16:54:26 +01:00
Kim Woelders
f4ab8e10b1
imlib2_view: Various tweaks
...
- Only process latest key press
- Clear to background before drawing new image
- Skip redraw of current image
2019-12-29 16:54:26 +01:00
Kim Woelders
83e7e89348
image.c: Move data_memory_func assignment to better place
2019-12-28 12:06:22 +01:00
Kim Woelders
002df3c1fa
image.c: Minor refactoring of pixmap cache cleaners
2019-12-28 12:06:22 +01:00
Kim Woelders
a7be91805f
image.c: Enable non-dirty pixmap cache cleaning
...
For whatever reason this does not seem to have ever been active.
Let's activate it now.
2019-12-28 12:06:22 +01:00
Kim Woelders
6acfd27058
image.c: Move loader functions to separate file
2019-12-28 12:06:22 +01:00
Kim Woelders
02e85ee069
image.c: Move image tag functions to separate file
2019-12-28 12:06:22 +01:00
Kim Woelders
0c7464f0db
image.c/h: Cleanups
...
- Make a number of functions static
- Shuffle prototypes around for nicer grouping
- Remove unused __imlib_SetImageAlphaFlag()
- Remove __imlib_FlushCache() prototype (not implemented)
2019-12-28 12:06:22 +01:00
Kim Woelders
6a7eb67f46
Saver cleanups
...
- Do exit cleanups at exit.
- Use LOAD_FAIL/SUCCESS/BREAK for save() exit code.
- Cosmetics.
2019-12-23 12:55:46 +01:00
Kim Woelders
bd3aa88242
Loader cleanups
...
- Do exit cleanups at exit.
- Merge data load conditions.
- Use LOAD_FAIL/SUCCESS/BREAK for load() exit code.
- Cosmetics.
2019-12-23 12:07:48 +01:00
Kim Woelders
540a98870b
image.c: Use loader return value, not im->w to determine load success
2019-12-23 10:53:26 +01:00
Kim Woelders
670c8428a4
image.c: Introduce __imlib_ErrorFromErrno()
2019-12-23 10:53:26 +01:00
Kim Woelders
c60ad00b1e
image.c: Use real_file to get file time
2019-12-23 10:53:26 +01:00