+static const struct
+{
+ vlc_fourcc_t i_codec;
+ const char *psz_mime;
+} mime_table[] =
+{
+ { VLC_FOURCC('b','m','p',' '), "image/bmp" },
+ { VLC_FOURCC('b','m','p',' '), "image/x-bmp" },
+ { VLC_FOURCC('b','m','p',' '), "image/x-bitmap" },
+ { VLC_FOURCC('b','m','p',' '), "image/x-ms-bmp" },
+ { VLC_FOURCC('p','n','m',' '), "image/x-portable-anymap" },
+ { VLC_FOURCC('p','n','m',' '), "image/x-portable-bitmap" },
+ { VLC_FOURCC('p','n','m',' '), "image/x-portable-graymap" },
+ { VLC_FOURCC('p','n','m',' '), "image/x-portable-pixmap" },
+ { VLC_FOURCC('g','i','f',' '), "image/gif" },
+ { VLC_FOURCC('j','p','e','g'), "image/jpeg" },
+ { VLC_FOURCC('p','c','x',' '), "image/pcx" },
+ { VLC_FOURCC('p','n','g',' '), "image/png" },
+ { VLC_FOURCC('t','i','f','f'), "image/tiff" },
+ { VLC_FOURCC('t','g','a',' '), "iamge/x-tga" },
+ { VLC_FOURCC('x','p','m',' '), "image/x-xpixmap" },
+ { 0, NULL }
+};
+
+vlc_fourcc_t image_Mime2Fourcc( const char *psz_mime )
+{
+ int i;
+ for( i = 0; mime_table[i].i_codec; i++ )
+ if( !strcmp( psz_mime, mime_table[i].psz_mime ) )
+ return mime_table[i].i_codec;
+ return 0;
+}
+
+