You are not logged in.

#1 2013-07-18 13:20:53

GloW_on_dub
Member
Registered: 2013-03-13
Posts: 388

 [SOLVED]feh: no imlib2 loader for that file format with converted bmp

I got a lot of bmp image converted into bmp with convert utility wich cannot be opened by feh.
Here is an example : http://www.2shared.com/photo/2V90zxR1/1935_ete.html

It fails with :

feh WARNING: /home/glow/data/Images/Scan Diapo/Diapos/1935_ete.bmp - No Imlib2 loader for that file format
feh: No loadable images specified.
See 'feh --help' or 'man feh' for detailed usage information

in any other program , it can be opened without problem.

Other bmp files, wich have not be converted, can be opened. mediainfo allow to spot some differences between the working one and the others:
can be opened:

[glow@GlowArch ~/data/Images/Scan Diapo/Diapos]$ mediainfo 1967_06.bmp 
General
Complete name                            : 1967_06.bmp
Format                                   : Bitmap
File size                                : 4.32 MiB

Image
Format                                   : RGB
Width                                    : 1 568 pixels
Height                                   : 963 pixels
Bit depth                                : 24 bits

Cannot be opened

[glow@GlowArch ~/data/Images/Scan Diapo/Diapos]$ mediainfo 1973_04_2b.bmp 
General
Complete name                            : 1973_04_2b.bmp
Format                                   : Bitmap
File size                                : 4.18 MiB

Image

So right now I thinks that any bmp created with convert utility cannot be opened in feh.
If some people confirmed it i will report a bug.

Last edited by GloW_on_dub (2013-07-21 13:50:47)

Offline

#2 2013-07-19 00:22:38

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

$ file 1935_ete.bmp 
1935_ete.bmp: data

feh is not the only utility that has issues with this file (it should say it's a bitmap no just generic 'data').

sxiv can't open this file:

$ sxiv 1935_ete.bmp 
sxiv: warning: could not open image: 1935_ete.bmp
sxiv: no more files to display, aborting

but qiv can.
Both depend on imlib2.

Offline

#3 2013-07-19 01:48:30

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,556
Website

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

For another data point, gimp can open it and recognizes it as a windows bitmap.  Imagemagick can convert it to a png that seems readable by all of the above, but it gives the warning "convert: invalid chromaticities `1935.png' @ warning/png.c/MagickPNGWarningHandler/1830."


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#4 2013-07-20 11:59:19

GloW_on_dub
Member
Registered: 2013-03-13
Posts: 388

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

Well the worst part is every convert generated bmp have the problem :

wget http://www.thinkwiki.org/w/images/2/20/Simple_tux.png
convert Simple_tux.png tux.bmp
feh tux.bmp 
feh WARNING: tux.bmp - No Imlib2 loader for that file format

So it may be a convert bug ?

Offline

#5 2013-07-20 12:11:15

Cloudef
Member
Registered: 2010-10-12
Posts: 636

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

Try

convert Simple_tux.png BMP3:tux.bmp

IIRC convert converts to some newer BMP format by default.

Edit:
BMP4 according here: http://www.imagemagick.org/www/formats.html
Not sure why this wont be loaded by imlib2 though.

Last edited by Cloudef (2013-07-20 12:15:52)

Offline

#6 2013-07-20 12:14:22

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

Thanks, Cloudef, that seems to work.

Offline

#7 2013-07-20 12:17:43

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,556
Website

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

I can confirm that behavior.  Converting to bmp makes the image unable to be opened by feh.

I don't know if it would be a convert bug though for two reasons: 1) is feh supposed to be able to open all bitmaps?  Other programs can open the images just fine.  2) Does convert need any specific parameters to make a proper bitmap?  "Bitmap" is a very generic term for a wide range of actual file formats.

EDIT: this was crossposted with the above - BMP3 works here.

EDIT2: also feh does not use imlib2 directly, it uses the giblib wrapper to imlib2 which may explain this diffference.  Scratch that.  I have a tiny image tool that uses imlib2 directly, and a normal imlib_load_image() call with the BMP4 files fails.  Perhaps imlib2 can open these, but there must be a special function or setup that is required, the "normal" methods don't work.

EDIT3: qiv does not use imlib2 directly for loading images.  The function above has been commented out and replaced by im_from_pixbuf_loader() from gtk2 which uses gdk pixbuf which can open the new BMP format.

Last edited by Trilby (2013-07-20 12:59:30)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#8 2013-07-21 13:50:12

GloW_on_dub
Member
Registered: 2013-03-13
Posts: 388

Re:  [SOLVED]feh: no imlib2 loader for that file format with converted bmp

Thanks for the work around.
I hope newer version of  convert/feh/imlib2 will correct these.

Last edited by GloW_on_dub (2013-07-21 13:50:19)

Offline

Board footer

Powered by FluxBB