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

Home » Public Forums » archive » Re: save image from ENVI to TIFF file
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: save image from ENVI to TIFF file [message #52194 is a reply to message #52192] Mon, 15 January 2007 06:15 Go to previous messageGo to previous message
Mort Canty is currently offline  Mort Canty
Messages: 134
Registered: March 2003
Senior Member
skymaxwell@gmail.com schrieb:
> here is my last variant for EXTERNAL_FORMAT and new variant for
> WRITE_TIFF as recommended
>
> ;ENVI_OUTPUT_TO_EXTERNAL_FORMAT,OUT_NAME=full_file_name+'_MY _.TIFF',DIMS=pan_dims,$
> ; POS=pos_mul,/TIFF,FID=pansharp_fid
>
> image=MAKE_ARRAY(number_bands,pan_dims[2],pan_dims[4],/BYTE)
>
> FOR I=0,number_bands-1 DO BEGIN
> image[I,*,*]=ENVI_GET_DATA(DIMS=pan_dims,POS=I,FID=fid_Src_m ul)
> ;image[I,*,*]=ENVI_GET_IMAGE(BAND_POS=I,DIMS=pan_dims)
> ENDFOR
> WRITE_TIFF,full_file_name+'_MY_.TIFF',image
>

Your MAKE_ARRAY() is incorrect. Try

ns = pan_dims[2]-pan_dims[1]+1
nl = pan_dims[4]-pan_dims[3]+1
image=MAKE_ARRAY(number_bands,ns,nl,/BYTE)


Cheers

Mort
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: How to highlight procedure and function names in idlwave-mode?
Next Topic: Re: accessing image data from Windows-clipboard

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

Current Time: Fri Oct 10 19:37:53 PDT 2025

Total time taken to generate the page: 0.73887 seconds