 mode(-1);
if ~isdef('%SCIFEM')
  funcprot(0);
  %path_femt=get_absolute_file_path('loader-5.1.sce');
  %execu=%path_femt+'/bin/';
  %nnw=and(sciargs()<>"-nw")
  %sci3=(grep(SCI,"scilab-3")==1)&(sciargs()<>"-nw")&%tk
  if %sci3 then %nw=progressionbar("sciFEM is loading"); end
  %SCIFEM=%path_femt
    
  write(%io(2),'---------------------------------------')
  write(%io(2),'---------------- sciFEM ---------------');
  write(%io(2),'---------------------------------------')
  
  // librairie de la géométrie
  write(%io(2),'| Geometrie :');
  write(%io(2),'|-----------');
  for dir=['tet3d']
    write(%io(2),'| '+dir+' loaded');
    getd(%path_femt+'/macros/'+dir);
    if %sci3 then progressionbar(%nw); end
  end
  write(%io(2),'|-----------');
  write(%io(2),'| Variables :');
  write(%io(2),'|-----------');
  for dir=['p1_3d' 'p0_3d' ]
    write(%io(2),'| '+dir+' loaded');
    getd(%path_femt+'/macros/'+dir);
    if %sci3 then progressionbar(%nw); end
  end


  write(%io(2),'|----------------');
  write(%io(2),'| Visualisation :');
  write(%io(2),'|----------------');
  for dir=['base' 'export' 'import']
    write(%io(2),'| '+dir+' loaded');
    getd(%path_femt+'/macros/'+dir);
    if %sci3 then progressionbar(%nw); end
  end
  write(%io(2),'---------------------------------------')

  if ~isdef("%exclud")
    global %exclud;
    %exclud=who('get');
    %exclud=%exclud(length(%exclud)>2);
    %exclud=[%exclud;'%'];
  end
  if %sci3 then progressionbar(%nw); end
  // nouvelle fonctions
  if %sci3 then winclose(%nw);clear %nw; end
else
  disp('sciFEM  deja charge (clear %SCIFEM et reloader)') 
end

