comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: DNs independent from Datatypes for ENVI-Mosaics
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: DNs independent from Datatypes for ENVI-Mosaics [message #36923] Sat, 15 November 2003 08:34
R.Bauer is currently offline  R.Bauer
Messages: 1424
Registered: November 1998
Senior Member
H. U. Zimmerer wrote:
> I want to set the SEE_THROUGH_VALUE of an ENVI Mosaic I create with an
> IDL-Program alwas to the DN of Black without writing a CASE-Statement
> for the different Datatypes. Is there a way of doing it?


Yes,

this is a piece of code of the rewritten deftype routine from our
library. But be carefull with this. You should read this article:
http://www.dfanning.com/math_tips/double.html



type_var=SIZE(data_with_type,/TYPE)


result = MAKE_ARRAY(TYPE=type_var,SIZE(value_without_type,/dim)>1)
result[*]=value_without_type

IF (SIZE(value_without_type,/DIM))[0] EQ 0 THEN result=result[0]


regards
Reimar

--
Reimar Bauer

Institut fuer Stratosphaerische Chemie (ICG-I)
Forschungszentrum Juelich
email: R.Bauer@fz-juelich.de
------------------------------------------------------------ -------
a IDL library at ForschungsZentrum Juelich
http://www.fz-juelich.de/icg/icg-i/idl_icglib/idl_lib_intro. html
============================================================ =======
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: DNs independent from Datatypes for ENVI-Mosaics
Next Topic: IDL crashes using CONTAINSPOINTS when array exceeds 16x16?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 13:38:15 PDT 2025

Total time taken to generate the page: 1.76358 seconds