Re: cdrtools-2.01.01a71 ready
On Sun, Jan 03, 2010 at 11:16:40PM +0100, Joerg Schilling wrote:
> NEW features of cdrtools-2.01.01a71:
> Cdrecord:
>
> - Cdrecord now is able to use -isosize even in case that the image data
> is read from stdin. This makes it easier to use "mkisofs | cdrecord".
For years I used tsize="$SIZE"s with a SIZE calculated from a small
command (see attached script) : should I change it ?
Thank you very much,
--
Grégoire Favre, Chemin de Mallieu 15, 1009 Pully, +41 21 550 61 93
prof -> Gymnase de Chamblandes, Avenue des Désertes 29, 1009 Pully
sip -> 310546@sip.freesip.ch / gsm -> +41 78 765 65 00
http://www.gycham.vd.ch/~greg / netvoip.ch : +41 21 544 77 44
#!/bin/bash
if [ -z "$2" ]; then
echo "usage : $0 DVD_title DVD_dir [write speed]"
echo "That will write a DVD with video structure if there a VIDEO_TS."
echo "And without video structure if without VIDEO_TS dir"
exit
fi
TITLE_SIZE=`echo $1|wc -c`
if [ $TITLE_SIZE -ge 33 ]; then
echo "$1 is $TITLE_SIZE long (33 is the limit)"
exit
fi
UDF=`find -L $2 -size +2G|wc -w`
unlock() {
cdrdao unlock --driver generic-mmc && sleep 1
}
secure() {
RETVAL=$?
if [ $RETVAL -eq 0 ]; then
echo OK, the size is $SIZE.
else
exit
fi
}
sync
ulimit -l unlimited
if [ -z "$3" ]; then
COMCD="-speed=4 -v dev=5,0,0 -dao fs=1000m "
else
COMCD="-speed=$3 -v dev=5,0,0 -dao fs=1000m "
fi
if [ $UDF -eq 0 ]; then
COM="-f -J -r -graft-points "
VIDEO=`ls $2|grep -i VIDEO_TS 2> /dev/null |wc -w`
if [ $VIDEO -eq 0 ]; then
OPTS=$COM
SIZE=`mkisofs -f -J -r -graft-points -quiet -print-size -V $1 $2`
secure
else
OPTS="$COM -dvd-video"
SIZE=`mkisofs -f -J -r -graft-points -quiet -print-size -dvd-video -V $1 $2`
secure
fi
mkisofs $OPTS -V $1 $2|cdrecord $COMCD tsize="$SIZE"s -
secure
else
COM="-iso-level 3 -UDF -udf -f -J -r -graft-points "
VIDEO=`ls $2|grep -i VIDEO_TS 2> /dev/null |wc -w`
if [ $VIDEO -eq 0 ]; then
OPTS=$COM
SIZE=`mkisofs -iso-level 3 -UDF -udf -f -J -r -graft-points -quiet -print-size -V $1 $2`
secure
else
OPTS="$COM -dvd-video"
SIZE=`mkisofs -iso-level 3 -UDF -udf -f -J -r -graft-points -quiet -print-size -dvd-video -V $1 $2`
secure
fi
mkisofs $OPTS -V $1 $2|cdrecord $COMCD tsize="$SIZE"s -
secure
fi
unlock
eject /dev/sr0
sleep 1
eject -t /dev/sr0
cdDir=0
while [ "$cdDir" == "0" ]; do
sleep 1
mount /mnt/cdrom && ls -alh /mnt/cdrom && DF && umount /mnt/cdrom && cdDir=1
done
sleep 1
#eject /dev/sr0
OPTIONS="delete reburn exit"
select opt in $OPTIONS; do
if [ "$opt" = "delete" ]; then
RM $2
exit
elif [ "$opt" = "reburn" ]; then
echo $0 $*
exit
elif [ "$opt" = "exit" ]; then
exit
else
echo bad option
fi
done
Reply to: