2011-10-23, 06:05 AM
mvallevand Wrote:UJB, that is the code I modified (before Response.ContentType...) I tried .Png first but that gave a GDI+ error. Returning the byte[] for channel.Icon works too
ImageConverter converter = new ImageConverter();
Response.BinaryWrite((byte[])converter.ConvertTo(img, typeof(byte[])));
Martin
I had to go with .jpeg due to browser versions....not sure if we are far enough out from windows 7 (I don' think it supported .png very well) to switch to that....I'll look into the last code you posted to see how/what exactly that is doing...the first code altered the image by clearing a color which I don't want to do......I just want to take whatever the image is and return it to the browser....unmodified. The last code you posted may do that......I'll check it out.
Intel Core i7 @ 4.00GHz Skylake 14nm
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's
ASUSTeK COMPUTER INC. Z170-DELUXE
Windows 10 Pro x64
PVR Software: NPVR 5.1.1
SiliconDust HDHomeRun HDHR5-4US Connect Quatro 4 Channel Tuner
Roku Ultra
2 PCH A-100's