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

Last change on this file since 268 was 268, checked in by pinsard, 17 years ago

typo and links in header in some pro files

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