Hello all,
I have read some previous mails about transparency issues in this list. It seems that older WMS versions cannot display many layers in a same image because the first layer was hidden the other ones, am I correct ?
Now all layers are perfectly composed in a same image but the image itself is not transparent, and we may need to compose the WMS image with other maps. Is it foreseen to manage transparency for PNG images (256 levels for alpha channel, so better anti-aliasing than GIF) ?
Regards
Charles Kolbowicz
PS : Nervertheless I have to tell you that you really have done a great job. Thanks for that.
Quoting Charles Kolbowicz <Charles.Kolbowicz@anonymised.com>:
Hello all,
I have read some previous mails about transparency issues in this
list.
It seems that older WMS versions cannot display many layers in a same
image because the first layer was hidden the other ones, am I correct
?
Older WMS versions of GeoSErver you mean? No, GeoServer WMS has always
been able to display multiple layers in one image. The issue was the
image returned by GeoSErver being transparent. The problem was that
jpegs can not be transparent (I believe), and transparent png's aren't
supported by internet explorer. And GeoServer did not offer GIF
support. Patrick Schlaepfer wrote GIF support, it is sitting in jira
task GEOS-199: http://jira.codehaus.org/browse/GEOS-199 and will be
rolled in shortly.
Now all layers are perfectly composed in a same image but the image
itself is not transparent, and we may need to compose the WMS image
with
other maps. Is it foreseen to manage transparency for PNG images
(256
levels for alpha channel, so better anti-aliasing than GIF) ?
I believe all layers always were perfectly composed in the same image.
PNG transparency support is available with GeoServer (I believe, Andrea
Aime was the one who provided this info, he wrote the LiteRenderer in
GeoTools that GeoServer uses, it's based on Java Advanced Imaging).
The problem is having the browsers that use it being able to read the
png transparency. Since ie does not, if you're doing a public website
it's probably not the best choice.
If anyone has more/better information, please correct me, I'm just
repeating my understanding of past emails.
best regards,
Chris
Regards
Charles Kolbowicz
PS : Nervertheless I have to tell you that you really have done a
great
job. Thanks for that.
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on
ITManagersJournal
Use IT products in your business? Tell us what you think of them.
Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find
out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
----------------------------------------------------------
This mail sent through IMP: https://webmail.limegroup.com/
PNG transparency support is available with GeoServer (I believe, Andrea
Aime was the one who provided this info, he wrote the LiteRenderer in
GeoTools that GeoServer uses, it's based on Java Advanced Imaging). The problem is having the browsers that use it being able to read the
png transparency. Since ie does not, if you're doing a public website
it's probably not the best choice.
You are right, IE does not manage PNG transparency. However Mozilla does and using GeoServer v1.2.2 with TRANSPARENCY parameter set to TRUE does not return a transparent image. The background is actually black... To be sure, I also saved the image in these two main browsers and open it under Photoshop. I also made a request using Java2D API (here is my real need for transparency): same problem.
I does not yet have a look in the source code, but maybe the problem is at the servlet output stream writing. I ever had this problem and I solved it using this code :
BufferedImage result = null;
HttpServletResponse response = null;
...
javax.imageio.ImageIO.write(result, "PNG", response.getOutputStream());
Best regards
Charles
Quoting Charles Kolbowicz <Charles.Kolbowicz@anonymised.com>:
>PNG transparency support is available with GeoServer (I believe,
Andrea
>Aime was the one who provided this info, he wrote the LiteRenderer
in
>GeoTools that GeoServer uses, it's based on Java Advanced Imaging).
>The problem is having the browsers that use it being able to read
the
>png transparency. Since ie does not, if you're doing a public
website
>it's probably not the best choice.
>
>
You are right, IE does not manage PNG transparency. However Mozilla
does
and using GeoServer v1.2.2 with TRANSPARENCY parameter set to TRUE
does
not return a transparent image. The background is actually black...
To
be sure, I also saved the image in these two main browsers and open
it
under Photoshop. I also made a request using Java2D API (here is my
real need for transparency): same problem.
Ok, I'll try to dig into the code today - I haven't actually looked into
it that much myself, was just repeating what people said in the past.
I'm not quite sure how a transparent image by itself looks different
though. Can I tell in microsoft's paint program? Does it actually
look different in some way? Do I try to overlay it on another image?
If you could open a bug on jira that would be great -
http://jira.codehaus.org/secure/BrowseProject.jspa?id=10311
And perhaps attach a transparent png so I can look at the difference.
And Ian, have you tested out geoserver transparency? Ian had
transparency working in the gt2wms that we've integrated into GeoServer
- so he may be able to better figure out the problem.
Chris
I does not yet have a look in the source code, but maybe the problem
is
at the servlet output stream writing. I ever had this problem and I
solved it using this code :
BufferedImage result = null;
HttpServletResponse response = null;
...
...
javax.imageio.ImageIO.write(result, "PNG",
response.getOutputStream());
Best regards
Charles
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on
ITManagersJournal
Use IT products in your business? Tell us what you think of them.
Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find
out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
----------------------------------------------------------
This mail sent through IMP: https://webmail.limegroup.com/
At 13:50 01/10/2004, cholmes@anonymised.com wrote:
Quoting Charles Kolbowicz <Charles.Kolbowicz@anonymised.com>:
>
> >PNG transparency support is available with GeoServer (I believe,
> Andrea
> >Aime was the one who provided this info, he wrote the LiteRenderer
> in
> >GeoTools that GeoServer uses, it's based on Java Advanced Imaging).
> >The problem is having the browsers that use it being able to read
> the
> >png transparency. Since ie does not, if you're doing a public
> website
> >it's probably not the best choice.
> >
> You are right, IE does not manage PNG transparency. However Mozilla
> does
> and using GeoServer v1.2.2 with TRANSPARENCY parameter set to TRUE
> does
> not return a transparent image. The background is actually black...
> To
> be sure, I also saved the image in these two main browsers and open
> it
> under Photoshop. I also made a request using Java2D API (here is my
> real need for transparency): same problem.
Ok, I'll try to dig into the code today - I haven't actually looked into
it that much myself, was just repeating what people said in the past.
I'm not quite sure how a transparent image by itself looks different
though. Can I tell in microsoft's paint program? Does it actually
look different in some way? Do I try to overlay it on another image?
If you could open a bug on jira that would be great -
http://jira.codehaus.org/secure/BrowseProject.jspa?id=10311
And perhaps attach a transparent png so I can look at the difference.
I've fixed this but I included it on http://jira.codehaus.org/browse/GEOS-11. Its a one line fix but I've also added a basic html page with which to test transparency.
Currently I've only tested it with png as I'm not sure how the gif code works, but since this is a ImageBuffer related fix I would guess it should work.
Ian
Quoting Ian Turton <ian@anonymised.com>:
At 13:50 01/10/2004, cholmes@anonymised.com wrote:
>Quoting Charles Kolbowicz <Charles.Kolbowicz@anonymised.com>:
>
> >
> > >PNG transparency support is available with GeoServer (I believe,
> > Andrea
> > >Aime was the one who provided this info, he wrote the
LiteRenderer
> > in
> > >GeoTools that GeoServer uses, it's based on Java Advanced
Imaging).
> > >The problem is having the browsers that use it being able to
read
> > the
> > >png transparency. Since ie does not, if you're doing a public
> > website
> > >it's probably not the best choice.
> > >
> > >
> > You are right, IE does not manage PNG transparency. However
Mozilla
> > does
> > and using GeoServer v1.2.2 with TRANSPARENCY parameter set to
TRUE
> > does
> > not return a transparent image. The background is actually
black...
> > To
> > be sure, I also saved the image in these two main browsers and
open
> > it
> > under Photoshop. I also made a request using Java2D API (here is
my
> > real need for transparency): same problem.
>Ok, I'll try to dig into the code today - I haven't actually looked
into
>it that much myself, was just repeating what people said in the
past.
>I'm not quite sure how a transparent image by itself looks different
>though. Can I tell in microsoft's paint program? Does it actually
>look different in some way? Do I try to overlay it on another
image?
>
>If you could open a bug on jira that would be great -
>http://jira.codehaus.org/secure/BrowseProject.jspa?id=10311
>And perhaps attach a transparent png so I can look at the
difference.
I've fixed this but I included it on
http://jira.codehaus.org/browse/GEOS-11. Its a one line fix but I've
also
added a basic html page with which to test transparency.
Currently I've only tested it with png as I'm not sure how the gif
code
works, but since this is a ImageBuffer related fix I would guess it
should
work.
Awesome, thanks a ton. Just committed to cvs on head, works on my
tests. Charles, can you work off of cvs/subversion (we're switching to
a new repository on monday). Or I can build a new geoserver.jar for
you...
Chris
Ian
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on
ITManagersJournal
Use IT products in your business? Tell us what you think of them.
Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find
out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
----------------------------------------------------------
This mail sent through IMP: https://webmail.limegroup.com/
I've fixed this but I included it on
http://jira.codehaus.org/browse/GEOS-11. Its a one line fix but I've
also
added a basic html page with which to test transparency.
Currently I've only tested it with png as I'm not sure how the gif
code
works, but since this is a ImageBuffer related fix I would guess it
should
work.
Awesome, thanks a ton. Just committed to cvs on head, works on my
tests. Charles, can you work off of cvs/subversion (we're switching to
a new repository on monday). Or I can build a new geoserver.jar for
you...
Chris
Many thanks. I will compile that as soon as the svn in on.
Charles.