Blame Scripts/Bash/Functions/Render/render_doIdentity.sh

4c79b5
#!/bin/bash
4c79b5
#
4c79b5
# render_doIdentity.sh -- This function provides identity
4c79b5
# rendering features for centos-art.sh script.
4c79b5
#
4c79b5
# Copyright (C) 2009-2010 Alain Reguera Delgado
4c79b5
# 
4c79b5
# This program is free software; you can redistribute it and/or modify
4c79b5
# it under the terms of the GNU General Public License as published by
4c79b5
# the Free Software Foundation; either version 2 of the License, or
4c79b5
# (at your option) any later version.
4c79b5
# 
4c79b5
# This program is distributed in the hope that it will be useful, but
4c79b5
# WITHOUT ANY WARRANTY; without even the implied warranty of
4c79b5
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
4c79b5
# General Public License for more details.
4c79b5
#
4c79b5
# You should have received a copy of the GNU General Public License
4c79b5
# along with this program; if not, write to the Free Software
4c79b5
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
4c79b5
# USA.
4c79b5
# 
4c79b5
# ----------------------------------------------------------------------
4c79b5
# $Id: render_doIdentity.sh 96 2010-09-19 06:39:32Z al $
4c79b5
# ----------------------------------------------------------------------
4c79b5
4c79b5
function render_doIdentity {
4c79b5
4c79b5
    # Define variables as local to avoid conflicts outside.
4c79b5
    local TRANSLATIONPATH=''
4c79b5
    local SVG=''
4c79b5
    local IMG=''
4c79b5
    local PARENTDIR=''
4c79b5
    local LOCATION=''
4c79b5
    local EXTENSION=''
4c79b5
    local FILTER=''
4c79b5
    local FILES=''
4c79b5
4c79b5
    # Re-define absolute path to artwork's related translation entry.
4c79b5
    render_getIdentityTranslationDir
4c79b5
4c79b5
    # Re-define absolute path to artwork's related design template
4c79b5
    # directory. By default design templates are stored in the Tpl/
4c79b5
    # directory which is stored in the workplace's root. 
4c79b5
    render_getIdentityTemplateDir
4c79b5
4c79b5
    # Re-define absolute path to artwork's related final output
4c79b5
    # directory. 
4c79b5
    render_getIdentityOutputDir
4c79b5
4c79b5
    # Re-define parent directory for current workplace.
4c79b5
    PARENTDIR=$(basename $OPTIONVAL)
4c79b5
4c79b5
    # Re-define directory path used as reference to build the list of
4c79b5
    # files that will be rendered.
4c79b5
    render_getIdentityFileslist
4c79b5
1d64a6
    # Define which type of features does centos-art.sh script is able
1d64a6
    # to performs.
f3bce7
    for ACTION in "${BASEACTIONS[@]}"; do
4c79b5
f3bce7
        case $ACTION in
4c79b5
1d64a6
            renderText )
f3bce7
                # Provides text rendering feature.
f3bce7
                render_doIdentityTexts
f3bce7
                ;;
4c79b5
1d64a6
            renderImage )
f3bce7
                # Provides image rendering feature.
f3bce7
                render_doIdentityImages
f3bce7
                ;;
f3bce7
f3bce7
        esac
f3bce7
f3bce7
    done 
4c79b5
4c79b5
}