HI Mohammed,

I don't know whether PNG can handle what you want from it, whether
GDAL is buggy, or whether the OSG's plugin can't handle the niche type
of .png file GDAL is generating.  You are a programming, have all the
OSG source code available to you so if you want to delve deeper that
have a go at see what might being going astray.

As a general comment, GeoTiff is the standard image format for doing
geospatial work, one doesn't normally touch png for geospatial work as
it's not at all designed for it.  I don't know what you are looking at
.png in the convtex of geosptail work.

Robert.


On 3 August 2013 13:52, Mohammed Djeralfia <osgfo...@tevs.eu> wrote:
> Hi
>
> I have generated a png image from GDAL with no_data values to set the black 
> color to transparant with this command line:
> "gdal_translate.exe --a_nodata 0 -of PNG -ot byte thumbnail.png 
> thumbnail_no_data.png"
>
> the image is loaded correctly in any viewer (Windows , photoshop...)
> BUT when I load it with osgViewer --image thumbnail_no_data.png the image is 
> zoomed and not dispalyed correctly:
> [Image: http://forum.osgearth.org/file/n7581916/badImage.png ]
>
> if I don not specify the no_data in GDAL transformation it will be displayed 
> correctly in the osgViewer:
> [Image: http://forum.osgearth.org/file/n7581916/goodImage.png ]
>
> When I maked a comparison between them with photoshop , I see that both have 
> a GRAY CHANNEL , but for the image with no_data there is another CHANNEL that 
> is a mask(perhaps to specify  where there are the no_data???)
>
> So I think that the PNG Plugin can not read the mask generated by GDAL.
>
> I hope that someone can help me with this.
>
> I have post before  this probleme on the GENERAL brunch:
>  http://forum.openscenegraph.org/viewtopic.php?t=12492
>
> The attached images
>
> Thank you!
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=55752#55752
>
>
>
>
> Attachments:
> http://forum.openscenegraph.org//files/tempview_512.png
> http://forum.openscenegraph.org//files/tempview_hide_419.png
>
>
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to