Groups | Blog | Home
all groups > dotnet jscript > august 2005 >

dotnet jscript : Regarding to view tif image in Asp.Net application


Arun
8/2/2005 12:00:00 AM
Hi,

Give suggestion to view a tif image file("example.tif") in Asp.Net
application using C#.Net.
without using thirdparty controls.

Regards,
Arun.

Serge Baltic
8/4/2005 5:53:11 AM
[> By default, a tif image cannot be viewed in IE. Therefore, you had
[> better convert the tif image to other format like jpg first.

TIFF is lossless in most cases. So PNG seems to be a better thing as it's
lossless as well, while auto-converting to JPEG may affect the image quality.

[> I am
[> afraid there is no a way to show tif in ASP.NET directly.

Seems to me that .NET has built-in support for TIFF (as there's such thing
as ImageFormat.Tiff), so you can convert it even on-the-fly using ASPX by
loading the TIFF into a Bitmap object and then converting it into a stream
of PNG format, and setting all the response headers to a format appropriate,
of course. But that's a significant load on the server, so I wouldn't do
it on a regular basis.

(H) Serge

lukezhan NO[at]SPAM online.microsoft.com
8/4/2005 9:23:50 AM
Hello Arun,

By default, a tif image cannot be viewed in IE. Therefore, you had better
convert the tif image to other format like jpg first. I am afraid there is
no a way to show tif in ASP.NET directly.


Luke
Bruce Barker
8/4/2005 12:51:04 PM
IE doesn't support png, so you should pick jpeg or gif.

-- bruce (sqlwork.com)


[quoted text, click to view]

Serge Baltic
8/5/2005 4:43:05 AM
Hello,

bb> IE doesn't support png, so you should pick jpeg or gif.

IE does support PNG.

/* but not entirely, there are some issues around the transparency, it needs
special workarounds to work as expected */

(H) Serg

AddThis Social Bookmark Button