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

Home » Public Forums » archive » Re: How to spatial subset files by ENVI vector file (EVF) or other shapefile ?
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: How to spatial subset files by ENVI vector file (EVF) or other shapefile ? [message #57583] Mon, 17 December 2007 06:01 Go to previous message
wita is currently offline  wita
Messages: 43
Registered: January 2005
Member
On Dec 17, 1:58 pm, Lucia <lucia...@gmail.com> wrote:
> I can spatial subset files by EVF in ENVI, but I need to do it by IDL.

Dear Lucia,

I have never tested this, but it seems to me that you need to use
ENVI_GET_ROI_DIMS_PTR to get the dimensions pointer for the ROI.
So you basically carry out the following steps:
roi_ids = envi_get_roi_ids(fid = fid)
dims = [envi_get_roi_dims_ptr(roi_ids[0]), 0, 0, 0, 0]
data = envi_get_data(fid=fid, dims=dims)

then you can write the data to a file and set up an ENVI header file
for it. I haven't figured out how to find the map coordinates for the
selected subset but I guess the ENVI manual will give a clue
somewhere.

with best regards,

Allard
[Message index]
 
Read Message
Read Message
Previous Topic: DELVAR in IDL7.0 for windows
Next Topic: How to spatial subset files by ENVI vector file (EVF) or other shapefile ?

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

Current Time: Fri Oct 10 02:51:47 PDT 2025

Total time taken to generate the page: 0.73418 seconds