这个构造函数生成的Bitmap对象的PropertyItems 为空,是bug么?还是有其他的问题,小弟代码如下
public static void GetProperty()
{
Image image1 = Image.FromFile(@"C:\5.jpg");
Bitmap myBitmap = new Bitmap(image1);
我在VS 的immediate window中查看是这样结果
tempImage.PropertyItems
{System.Drawing.Imaging.PropertyItem[2]}
[0]: {System.Drawing.Imaging.PropertyItem}
[1]: {System.Drawing.Imaging.PropertyItem}
tempMap.PropertyItems
{System.Drawing.Imaging.PropertyItem[0]}
求大神指点,file肯定没有问题,路径也没有问题,我试了几种方式,从bitMap转换为image就不会有这个问题,只用以这种方式new一个BitMap对象时会有这个问题
文件是否路径正确,估计没加载成功
PropertyItems 这个东西都看不到额……
只有这么点看不出问题额
还是C:\5.jpg这个对应的文件根本就不是图片??