#!/bin/csh

#######################################################################################################################################
#                                                                                                                                     #
#         M I S E   E N   M O N T A G N E   T E X T U R E E   E T   V U E   D E   C O T E                                             #
#         D ' U N E   I M A G E   E N   V R A I E S   C O U L E U R S   A P P R O X I M E E S  :                                      #
#                                                                                                                                     #
#                                                                                                                                     #
#         Utilisation :                                                                                                               #
#                                                                                                                                     #
#                   $xci/montagne.41$Z  <surface> <Texture> <paletteT> <depth-cueing> <imageR> [Ty=<translationY>]                    #
#                                                                                                                                     #
#                                                                         E  [0,1]                                                    #
#                                                                                                                                     #
#                                                                            |                                                        #
#                                                                           \|/                                                       #
#                                                                            .                                                        #
#                                                                                                                                     #
#                                                                   (0. = effet maximum)                                              #
#                                                                      (1.0 = absent)                                                 #
#                                                                                                                                     #
#                                                                                                                                     #
#         Author of '$xci/montagne.41$Z' :                                                                                            #
#                                                                                                                                     #
#                     Jean-Francois Colonna (LACTAMME, AAAAMMJJhhmmss).                                                               #
#                                                                                                                                     #
#######################################################################################################################################

set  surface=$1
set  Texture=$2
set  paletteT=$3
set  depth_cueing=$4
set  imageR=$5
set  Ty=$6

set  translation='Ty=0.50'" $Ty"
                                        # Pour translater verticalement l'image.                                                      #

set  depth='depth=FAUX'
                                        # Pour ne pas avoir de depth-cueing.                                                          #
set  depth="depth=VRAI min=$depth_cueing"
                                        # Pour avoir du depth-cueing.                                                                 #

set  avion='avion=FAUX alias=VRAI'
                                        # Pour faire une vue de cote.                                                                 #

set  sphere='s=1.00e2'
                                        # Pour definir la "sphere de voisinage" dans le cas de 'faux_HLS_02/3$X'.                     #

set  texture=`get_feuille$Z $Texture`
                                        # Recuperation du nom de la texture dans son directory.                                       #

$xci/vraies_C$X     A=$Texture p=$paletteT RR=$xiim/$texture$ROUGE RV=$xiim/$texture$VERTE RB=$xiim/$texture$BLEUE $formatI
                                        # Recuperation des trois composdantes 'RVB' de la texture.                                    #

$xci/montagne.01$X  A=$surface T=$xiim/$texture$ROUGE R=$imageR$ROUGE $depth $avion $translation $formatI
$xci/montagne.01$X  A=$surface T=$xiim/$texture$VERTE R=$imageR$VERTE $depth $avion $translation $formatI
$xci/montagne.01$X  A=$surface T=$xiim/$texture$BLEUE R=$imageR$BLEUE $depth $avion $translation $formatI
                                        # Mise en montagne ($imageR$RVB) de l'image argument ($surface) suivant                       #
                                        # les trois composantes avec une translation eventuellement imposee.                          #

if                  (-e $xci/faux_HLS.03$X) then
                    $xci/faux_HLS.03$X  AR=$imageR$ROUGE AV=$imageR$VERTE AB=$imageR$BLEUE p=$paletteT $sphere R=$imageR $formatI
                                        # Et reconstitution finale en fausses couleurs approximees.                                   #
else
endif

$DELETE             $xiim/$texture$ROUGE
$DELETE             $xiim/$texture$VERTE
$DELETE             $xiim/$texture$BLEUE
                                        # Et enfin, nettoyage...                                                                      #



Copyright © Jean-François Colonna, 2019-2021.
Copyright © CMAP (Centre de Mathématiques APpliquées) UMR CNRS 7641 / Ecole Polytechnique, 2019-2021.