Commit e65daf01 authored by PENGUEN Julien's avatar PENGUEN Julien
Browse files

ajout options "--resolution_col" et "--resolution_line"

parent 8bce4f29
......@@ -150,6 +150,8 @@ function_message()
echo ""
echo "--angular run photos_montage_aladin with this angular dimension value instead of "
echo "the default angular value define on .env file. the angular value must be on second of arc"
echo "--resolution_col run photos_montage_aladin with this number of pixel by columns for the Image Magick montages"
echo "--resolution_line run photos_montage_aladin with this number of pixel by lines for the Image Magick montages"
echo ""
fi
......@@ -197,6 +199,8 @@ function_build_tab_hach()
ARRAY["--survey"]="PATH FILE SURVEYS";
ARRAY["--area"]="PATH FILE AREAS";
ARRAY["--angular"]="NUMBER";
ARRAY["--resolution_line"]="NUMBER";
ARRAY["--resolution_col"]="NUMBER";
# ---------------------- #
# ARRAY_WEIGHT[key]=value
......@@ -228,6 +232,8 @@ function_build_tab_hach()
ARGS_WEIGHT["--survey"]=2;
ARGS_WEIGHT["--area"]=2;
ARGS_WEIGHT["--angular"]=2;
ARGS_WEIGHT["--resolution_line"]=2;
ARGS_WEIGHT["--resolution_col"]=2;
# -------- #
......@@ -263,13 +269,11 @@ function_build_tab_hach()
FOUND=$(echo ${!ARRAY[*]} | grep -- "${tab_params[$indice +1]}")
if [[ ${tab_params[$indice +1]} != "" && $FOUND == "" && ${tab_params[$indice +1]} != -* ]]; then
#if [[ ${tab_params[$indice +1]} != "" && $FOUND == "" ]]; then
#case argument needed for the option is present on input argument
tab_values[$indice]=${tab_params[$indice +1]}
elements_ok=$(($elements_ok + 1))
else
#case argument needed for the option is missing on input argument
#val_element=${elem}
message="Missing argument for the option "${elem}
val_error="TRUE"
fi
......@@ -756,6 +760,26 @@ if [[ "${sort_arg_keys[@]}" =~ "--angular" ]]; then
ANGULAR=${sort_arg_values[$RESULT_INDICE_ANGULAR]}
fi
#-------------------------------------#
#check resolution line input args
if [[ "${sort_arg_keys[@]}" =~ "--resolution_line" ]]; then
RESULT_INDICE_RESOLUTION_LINE=`function_return_indice_arg "${sort_arg_keys[*]}" "--resolution_line"`
RESOLUTION_BY_LINE=${sort_arg_values[$RESULT_INDICE_RESOLUTION_LINE]}
fi
#-------------------------------------#
#check resolution col input args
if [[ "${sort_arg_keys[@]}" =~ "--resolution_col" ]]; then
RESULT_INDICE_RESOLUTION_COL=`function_return_indice_arg "${sort_arg_keys[*]}" "--resolution_col"`
RESOLUTION_BY_COL=${sort_arg_values[$RESULT_INDICE_RESOLUTION_COL]}
fi
#---------------------#
# --no_select management
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment