我使用下面的代码将 url 流转换为 tiff 图像。但转换后,转换后的图像无法打开预览。有任何想法吗?
var myRequest = (HttpWebRequest)WebRequest.Create("http://www.google.com");
myRequest.Method = "GET";
var myResponse = myRequest.GetResponse();
var responseStream = myResponse.GetResponseStream();
var memoryStream = new MemoryStream();
responseStream.CopyTo(memoryStream);
var loadOptions = new LoadOptions();
loadOptions.LoadFormat = LoadFormat.Html;
var doc = new Document(memoryStream, loadOptions);
var htmlOptions = new HtmlFixedSaveOptions();
htmlOptions.ExportEmbeddedCss = true;
htmlOptions.ExportEmbeddedFonts = true;
htmlOptions.ExportEmbeddedImages = true;
doc.Save(@"C:\out.tif", htmlOptions);