KeCoDe_decoder_achrom

PURPOSE ^

KeCoDe_DECODER_ACHROM decompress the files encoded with KeCoDe_ENCODER_ACHROM

SYNOPSIS ^

function ImR = KeCoDe_decoder(directorio,fichero)

DESCRIPTION ^

 KeCoDe_DECODER_ACHROM decompress the files encoded with KeCoDe_ENCODER_ACHROM

 Given the folder and the name of the file to decompress, the program identifies the
 required decoder to recover the image.

 SYNTAX:

   im=KeCoDe_decoder_achrom('folder','name')

   Input
       'folder'   = String with the folder containing the file to decompress
       'name'     = String with the name of the file to decompress (do not include the '.zip' extension!)
                    Note that the names have to include the algorithm identifiers
                    given by KeCoDe_ENCODER_ACHROM.M.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 % KeCoDe_DECODER_ACHROM decompress the files encoded with KeCoDe_ENCODER_ACHROM
0002 %
0003 % Given the folder and the name of the file to decompress, the program identifies the
0004 % required decoder to recover the image.
0005 %
0006 % SYNTAX:
0007 %
0008 %   im=KeCoDe_decoder_achrom('folder','name')
0009 %
0010 %   Input
0011 %       'folder'   = String with the folder containing the file to decompress
0012 %       'name'     = String with the name of the file to decompress (do not include the '.zip' extension!)
0013 %                    Note that the names have to include the algorithm identifiers
0014 %                    given by KeCoDe_ENCODER_ACHROM.M.
0015 %
0016 
0017 function ImR = KeCoDe_decoder(directorio,fichero)
0018 you_are_here=pwd;
0019 cd(directorio);
0020 if(~isempty(findstr(fichero,'cte_svr')) || ~isempty(findstr(fichero,'robinson03')) || ~isempty(findstr(fichero,'gomez05')))
0021     K = kernel2d_variance(16,1);
0022     ImR = svr_dct_decoder(K,directorio,fichero);
0023 elseif(~isempty(findstr(fichero,'camps08')))
0024     K = kernel2d_variance(16,1);
0025     exponente = 1;
0026     ImR = svr_nl_decoder(K,exponente,directorio,fichero);
0027 elseif(~isempty(findstr(fichero,'nl2_svr')))
0028     K = kernel2d_variance(16,1);
0029     exponente = 2;
0030     ImR = svr_nl_decoder(K,exponente,directorio,fichero);
0031 elseif(~isempty(findstr(fichero,'jpeg91')))
0032     ImR = jpeg91_decoder(directorio,fichero);
0033 elseif(~isempty(findstr(fichero,'malo99')))
0034     ImR = malo99_decoder(directorio,fichero);
0035 elseif(~isempty(findstr(fichero,'malo06')))
0036     exponente = 1;
0037     ImR = malo06_decoder(exponente,directorio,fichero);
0038 elseif(~isempty(findstr(fichero,'malo06_2')))
0039     exponente = 2;
0040     ImR = malo06_decoder(exponente,directorio,fichero);
0041 else
0042     disp('The decoding algorithm cannot be obtained from the file name!');
0043 end
0044 cd(you_are_here);

Generated on Fri 07-Mar-2014 13:29:20 by m2html © 2005