Opened 5 years ago

Closed 5 years ago

#723 closed defect (fixed)

bmp: support 16bpp x4 r4 g4 b4

Reported by: ami_stuff Owned by:
Priority: normal Component: avcodec
Version: git-master Keywords: bmp
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

ffmpeg -i 16bpp_x4_r4_g4_b4.bmp
ffmpeg version 0.8.7.git-31a1342, Copyright (c) 2000-2011 the FFmpeg developers
  built on Nov 26 2011 14:05:22 with gcc 4.5.0
  libavutil    51. 29. 1 / 51. 29. 1
  libavcodec   53. 37. 1 / 53. 37. 1
  libavformat  53. 21. 0 / 53. 21. 0
  libavdevice  53.  4. 0 / 53.  4. 0
  libavfilter   2. 49. 1 /  2. 49. 1
  libswscale    2.  1. 0 /  2.  1. 0
  libpostproc  51.  2. 0 / 51.  2. 0
[bmp @ 0x112042d0] Warning: not compiled with thread support, using thread emulation
Input #0, image2, from '16bpp_x4_r4_g4_b4.bmp':
  Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
Codec 0x50 is not in the full list.
    Stream #0:0: Video: bmp, rgb555be, 1024x768, 25 tbr, 25 tbn, 25 tbc
At least one output file must be specified

I will create tickets for

16bpp a4 r4 g4 b4
32bpp x8 r8 g8 b8

when this will be supported.

Attachments (1)

16bpp_x4_r4_g4_b4.bmp (1.5 MB) - added by ami_stuff 5 years ago.

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by ami_stuff

comment:1 Changed 5 years ago by cehoyos

  • Keywords bmp added
  • Reproduced by developer set
  • Status changed from new to open
  • Version changed from unspecified to git-master

Output looks very broken, the original file works fine with GIMP.

$ ffmpeg -i 16bpp_x4_r4_g4_b4.bmp out.tga
ffmpeg version N-35569-g74436ad, Copyright (c) 2000-2011 the FFmpeg developers
  built on Dec  8 2011 21:29:41 with gcc 4.5.3
  configuration: --cc=/usr/local/gcc-4.5.3/bin/gcc
  libavutil    51. 31. 0 / 51. 31. 0
  libavcodec   53. 41. 2 / 53. 41. 2
  libavformat  53. 24. 0 / 53. 24. 0
  libavdevice  53.  4. 0 / 53.  4. 0
  libavfilter   2. 52. 0 /  2. 52. 0
  libswscale    2.  1. 0 /  2.  1. 0
Input #0, image2, from '16bpp_x4_r4_g4_b4.bmp':
  Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
    Stream #0:0: Video: bmp, rgb555le, 1024x768, 25 tbr, 25 tbn, 25 tbc
[buffer @ 0x13a6ac0] w:1024 h:768 pixfmt:rgb555le tb:1/1000000 sar:0/1 sws_param:
Output #0, image2, to 'out.tga':
  Metadata:
    encoder         : Lavf53.24.0
    Stream #0:0: Video: targa, rgb555le, 1024x768, q=2-31, 200 kb/s, 90k tbn, 25 tbc
Stream mapping:
  Stream #0:0 -> #0:0 (bmp -> targa)
Press [q] to stop, [?] for help
frame=    1 fps=  0 q=0.0 Lsize=       0kB time=00:00:00.04 bitrate=   0.0kbits/s
video:992kB audio:0kB global headers:0kB muxing overhead -100.000000%

comment:2 Changed 5 years ago by cehoyos

  • Component changed from undetermined to avcodec

comment:3 Changed 5 years ago by ami_stuff

more info:

X4 R4 G4 B4—16 bits per pixel: 4 each for the RGB channels and 4 unused bits.

http://www.kxcad.net/autodesk/3ds_max/Autodesk_3ds_Max_9_Reference/dds_files.html

comment:4 Changed 5 years ago by cehoyos

  • Resolution set to fixed
  • Status changed from open to closed

Fixed by Paul B Mahol, there might still be a problem with the (non-existing) alpha channel, but that is impossible to test with this sample.

Note: See TracTickets for help on using tickets.