legacy-imlib2/src/modules/loaders
Chema Gonzalez a780b47892 Y4M loader: fix support for unexpected framerates
Add support for F1:1 images, and in general with any framerate ratio.

Also added "F60:1" mode support.

Tested:

Added a test frame with a 1:1 framerate. This is produced by ffmpeg when
converting from another image format.
```
$ ffmpeg -i in.265 out.y4m
$ head -1 out.y4m
YUV4MPEG2 W490 H490 F1:1 Ip A0:0 C420jpeg XYSCSS=420JPEG XCOLORRANGE=FULL
```

Before
```
$ imlib2_view -v ./test/images/icon-64.framerate_1_1.y4m
Show  0: './test/images/icon-64.framerate_1_1.y4m'
*** Error -2:'Imlib2: No loader for file format' loading image: './test/images/icon-64.framerate_1_1.y4m'
```

After:
```
$ IMLIB2_DEBUG=31:0 IMLIB2_LOADER_PATH=./src/modules/loaders/.libs/ LD_LIBRARY_PATH=./src/lib/.libs:${LD_LIBRARY_PATH} ./src/bin/imlib2_view -v ./test/images/icon-64.framerate_1_1.y4m
Show  0: './test/images/icon-64.framerate_1_1.y4m'
IMG : __imlib_FindCachedImage: './test/images/icon-64.framerate_1_1.y4m' frame 1
IMG :  got none
LOAD: __imlib_FindBestLoader: file='./test/images/icon-64.framerate_1_1.y4m' fmt='(null)'
FILE: __imlib_FileExtension: './test/images/icon-64.framerate_1_1.y4m'
FILE: __imlib_FileIsFile: './src/modules/loaders/.libs//y4m.so'
FILE: __imlib_FileStat: './src/modules/loaders/.libs//y4m.so'
LOAD: __imlib_ProduceLoader: ./src/modules/loaders/.libs//y4m.so
LOAD: __imlib_LookupKnownLoader: 'y4m' -> 'y4m': 0x524d50
LOAD: __imlib_FindBestLoader: fmt='y4m': ./src/modules/loaders/.libs//y4m.so
IMG : __imlib_LoadImageWrapper: fmt='y4m' file='./test/images/icon-64.framerate_1_1.y4m'(./test/images/icon-64.framerate_1_1.y4m) frame=1, imm=1
IMG : __imlib_LoadImageWrapper: y4m : ./test/images/icon-64.framerate_1_1.y4m: Elapsed time: 18.099 ms
IMG : __imlib_AddImageToCache: 0x5139e0: './test/images/icon-64.framerate_1_1.y4m' frame 1
```
2023-12-27 14:41:59 -08:00
..
Makefile.am loaders: Fix CPPFLAGS order 2023-09-04 17:01:33 +02:00
compression.h Loaders: decompress_load() is not part of the loader API 2023-02-04 10:15:05 +01:00
decompress_load.c Loaders: decompress_load() is not part of the loader API 2023-02-04 10:15:05 +01:00
exif.c Avoid signedness warning 2021-12-02 18:10:18 +01:00
exif.h JPEG loader: Parse EXIF data and handle orientation 2021-09-25 13:02:06 +02:00
loader_ani.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_argb.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_bmp.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_bz2.c Loaders: decompress_load() is not part of the loader API 2023-02-04 10:15:05 +01:00
loader_ff.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_gif.c loaders: Use common function to print error messages 2023-05-08 18:52:57 +02:00
loader_heif.c HEIF loader: Call heif_[de]init() on loader load/unload 2023-05-20 08:42:05 +02:00
loader_ico.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_id3.c loaders: Use common function to print error messages 2023-05-08 18:52:57 +02:00
loader_j2k.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_jpeg.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_jxl.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_lbm.c loading: Centralize mmap handling 2022-07-10 12:51:06 +02:00
loader_lzma.c Loaders: decompress_load() is not part of the loader API 2023-02-04 10:15:05 +01:00
loader_png.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_pnm.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_ps.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_qoi.c Loaders: Static constify some data that may as well be 2023-06-18 07:12:51 +02:00
loader_raw.c RAW loader: Don't unload loader 2023-09-03 20:16:12 +02:00
loader_svg.c loaders: Change method used to not unload loaders 2023-04-04 20:53:49 +02:00
loader_tga.c TGA loader: Fix TGA v2.0 signature check 2023-06-20 10:56:06 +02:00
loader_tiff.c loaders: Fix build with -m32 --enable-debug 2023-09-03 17:11:21 +02:00
loader_webp.c WEBP saver: allow lossless and respect compression tag 2023-05-12 16:21:35 +02:00
loader_xbm.c loaders: Cosmetics 2023-05-01 11:19:24 +02:00
loader_xpm.c loaders: Use common function to print error messages 2023-05-08 18:52:57 +02:00
loader_y4m.c Y4M loader: fix support for unexpected framerates 2023-12-27 14:41:59 -08:00
loader_zlib.c Loaders: decompress_load() is not part of the loader API 2023-02-04 10:15:05 +01:00