#!/bin/bash

SINSY="/opt/local/bin/sinsy"
VOICE_DIR="/opt/local/lib/sinsy/voice/hts_voice_nitech_jp_song070_f001-0.90"
VOICE_FILE="${VOICE_DIR}/nitech_jp_song070_f001.htsvoice"
DIC_DIR="/opt/local/lib/sinsy/dic"
WAVFILE="/tmp/sinsy-demo-$$.wav"
INFILE="${VOICE_DIR}/SAMPLE.xml"

echo "${SINSY} -m ${VOICE_FILE} -o ${WAVFILE} -x ${DIC_DIR} ${INFILE}"
${SINSY} -m ${VOICE_FILE} -o ${WAVFILE} -x ${DIC_DIR} ${INFILE} && \
afplay ${WAVFILE}

rm -f ${WAVFILE}
exit 0
