Gdal driver prevents null being less than default null

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Gdal driver prevents null being less than default null

RolandH
Hi All,

ossimGdalTileSource.cpp resets the null value read from the file to a default value if it is less than the default. It's not really a valid assumption that. In geophysics, it is very common to use -1.0e30 as the null value for float data.

I propose removing this test on line 1706.

-              if((!nullOk)||(theNullPixValues[band] < ossim::defaultNull(getOutputScalarType())))
+              if(!nullOk)



Roland

--

--
ROLAND HILL
Director
Four Winds Technology Pty Ltd
Ph/Fax :  +61 (0)2 6366 9425
Mobile :  +61 (0)41 880 7472
[hidden email]

Privacy and Confidentiality Notice
The information contained herein and any attachments are intended solely for the named recipients. It may contain privileged confidential information. If you are not an intended recipient, please delete the message and any attachments then notify the sender of miss-delivery. Any use or disclosure of the contents of either is unauthorised and may be unlawful. All liability for viruses are excluded to the fullest extent permitted by law.


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer
Reply | Threaded
Open this post in threaded view
|

Re: Gdal driver prevents null being less than default null

David Burken
Not sure why that was in there.  Removed in svn.

Thanks,
Dave

On 03/12/2015 07:22 PM, Roland Hill wrote:
Hi All,

ossimGdalTileSource.cpp resets the null value read from the file to a default value if it is less than the default. It's not really a valid assumption that. In geophysics, it is very common to use -1.0e30 as the null value for float data.

I propose removing this test on line 1706.

-              if((!nullOk)||(theNullPixValues[band] < ossim::defaultNull(getOutputScalarType())))
+              if(!nullOk)



Roland

--

--
ROLAND HILL
Director
Four Winds Technology Pty Ltd
Ph/Fax :  +61 (0)2 6366 9425
Mobile :  +61 (0)41 880 7472
[hidden email]

Privacy and Confidentiality Notice
The information contained herein and any attachments are intended solely for the named recipients. It may contain privileged confidential information. If you are not an intended recipient, please delete the message and any attachments then notify the sender of miss-delivery. Any use or disclosure of the contents of either is unauthorised and may be unlawful. All liability for viruses are excluded to the fullest extent permitted by law.



------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/


_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer
Reply | Threaded
Open this post in threaded view
|

Re: Gdal driver prevents null being less than default null

RolandH
Thanks Dave.

--
ROLAND HILL
Director
Four Winds Technology Pty Ltd
Ph/Fax :  +61 (0)2 6366 9425
Mobile :  +61 (0)41 880 7472
[hidden email]

Privacy and Confidentiality Notice
The information contained herein and any attachments are intended solely for the named recipients. It may contain privileged confidential information. If you are not an intended recipient, please delete the message and any attachments then notify the sender of miss-delivery. Any use or disclosure of the contents of either is unauthorised and may be unlawful. All liability for viruses are excluded to the fullest extent permitted by law.

On 15/03/15 02:02, David Burken wrote:
Not sure why that was in there.  Removed in svn.

Thanks,
Dave

On 03/12/2015 07:22 PM, Roland Hill wrote:
Hi All,

ossimGdalTileSource.cpp resets the null value read from the file to a default value if it is less than the default. It's not really a valid assumption that. In geophysics, it is very common to use -1.0e30 as the null value for float data.

I propose removing this test on line 1706.

-              if((!nullOk)||(theNullPixValues[band] < ossim::defaultNull(getOutputScalarType())))
+              if(!nullOk)



Roland

--

--
ROLAND HILL
Director
Four Winds Technology Pty Ltd
Ph/Fax :  +61 (0)2 6366 9425
Mobile :  +61 (0)41 880 7472
[hidden email]

Privacy and Confidentiality Notice
The information contained herein and any attachments are intended solely for the named recipients. It may contain privileged confidential information. If you are not an intended recipient, please delete the message and any attachments then notify the sender of miss-delivery. Any use or disclosure of the contents of either is unauthorised and may be unlawful. All liability for viruses are excluded to the fullest extent permitted by law.



------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/


_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer



------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/


_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
www.ossim.org
Ossim-developer mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/ossim-developer