开发者

Silverlight 4 BitmapImage - bmp file support

MSDN mentions support for PNG and JPG, but many people are trying setSource(file.bmp) and complaining about "Catastrophic failures".

Can someone clarify this, is bmp supported or not 开发者_运维知识库?

And if not, what is the best way for displaying a bmp in silverlight ?


BMP is not supported in Silverlight. BMP is a very old and not a very efficient format (compared with PNG & JPG) so they have not bothered to support it.

Silverlight only supports JPG & PNG format images.

The best way to display them is to convert them on the web server so they can be served up as PNGs. The webserver will have access to enough .Net libraries that BMP=>PNG conversion will be easy. I would not bother to create a BMP loader client-side.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜