Login or sign up Lost password?
Login or sign up
l=swftools-common&m=138732909815669&w=2 - would you have any idea how to make sure new images are not left aside? /bin/bash SWFFILE= MP4FILE=$.mp4 TMPFILE=$(cat /dev/urandom | tr -dc 'a-z A-Z' | fold -w 32 | head -n 1)TMPWAV=$(cat /dev/urandom | tr -dc 'a-z A-Z' | fold -w 32 | head -n 1)TMPMP4=$(cat /dev/urandom | tr -dc 'a-z A-Z' | fold -w 32 | head -n 1).mp4 # create raw-dump GNASHCMD="dump-gnash -1 -r 3 -v -D $TMPFILE -A $TMPWAV $SWFFILE" OUTPUT="$(exec $GNASHCMD)" # extract parameters WIDTH="$(echo $OUTPUT | grep -o 'WIDTH=[^, }]*' | sed 's/^.*=//')" HEIGHT="$(echo $OUTPUT | grep -o 'HEIGHT=[^, }]*' | sed 's/^.*=//')" FPS="$(echo $OUTPUT | grep -o 'FPS_ACTUAL=[^, }]*' | sed 's/^.*=//')" # create raw, uncompressed mp4 file mplayer $TMPFILE -vo yuv4mpeg:file=$TMPMP4 -demuxer rawvideo -rawvideo fps=$FPS:w=$WIDTH:h=$HEIGHT:format=bgra # create compressed mp4 with ffmpeg ffmpeg -i $TMPMP4 -i $TMPWAV $MP4FILE # clean up rm -rf $TMPFILE rm -rf $TMPMP4 rm -rf $TMPWAV I just would like to say that there is not reliable way to convert SWF to MP4. In simplest case SWF-file contains only video (and audio as well).