source: trunk/SRC/ToBeReviewed/CALCULS/depth2mask.pro

Last change on this file was 370, checked in by pinsard, 16 years ago

improvemnts of headers (typo, links)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 1.3 KB
Line 
1;+
2;
3; @file_comments
4; Allows to pass from a 2d depth sill array to a 3d array of mask
5; with one of levels above the sill depth and 0s below.
6;
7; @categories
8; Without loop
9;
10; @param TAB {type=3d array}
11; 2d sill depth array (or a structure respecting <pro>litchamp</pro> criterions)
12;
13; @keyword _EXTRA
14; Used to pass keywords
15;
16; @returns
17; It is a 3d array containing the mask associated to the 2d sill depth array
18;
19; @uses
20; <pro>common</pro>
21;
22; @history
23; Sebastien Masson (smasson\@lodyc.jussieu.fr)
24;                       17/6/1999
25;
26; @version
27; $Id$
28;
29;-
30FUNCTION depth2mask, tab, _EXTRA=ex
31;
32  compile_opt idl2, strictarrsubs
33;
34   tempsun = systime(1)         ; For key_performance
35@common
36;------------------------------------------------------------
37; We transform the 2d depth value in a 2d array of levels corresponding to depths
38;------------------------------------------------------------
39   niveaux = depth2level(tab, _extra = ex)
40   IF niveaux[0] EQ -1 THEN return,  -1
41;------------------------------------------------------------
42; We transform the 2d array in a 3d array of mask
43;------------------------------------------------------------
44   mask = level2mask(niveaux)
45;------------------------------------------------------------
46   if keyword_set(key_performance) NE 0 THEN print, 'temps depth2mask', systime(1)-tempsun
47   return, mask
48end
Note: See TracBrowser for help on using the repository browser.