Converting swf to pdf

In my case using Ubuntu

# apt-get install libjpeg62-dev libgif-dev libpng12-dev git g++ libfontconfig1-dev libfftw3-dev libpoppler-dev ghostscript imagemagick
# apt-get install libzzip-dev
# wget http://www.pdflib.com/binaries/PDFlib/705/PDFlib-Lite-7.0.5p3.tar.gz
# tar zxf PDFlib-Lite-7.0.5p3.tar.gz
# cd PDFlib-Lite-7.0.5p3/
# ./configure;make;make install
# cd ..
# git clone git://github.com/matthiaskramm/swftools
# cd swftools
# ./configure;make;make install
# cd ..

-check swf location
open FireFox
download and install “Flash and Video” FireFox plugin from http://www.fnvfox.com/downloads.html
go to http://company.com/ccie-lab-manual/
check total pages
go to page1

Image

# cat wget.sh
#!/bin/sh
if [ $# -lt 3 ]; then
echo “Usage: $0 url_format seq_start seq_end [wget_args]”
exit
fi
url_format=$1
seq_start=$2
seq_end=$3
shift 3
printf “$url_format\\n” `seq $seq_start $seq_end` | wget -i- “$@”

# chmod 755 wget.sh

# cat swf2png.sh
#!/bin/bash
for x in *.swf; do
swfrender ${x} -o ${x%.swf}.png
done

# chmod 755 swf2png.sh

# mkdir CCIEslide
# cd CCIEslide
# ./wget.sh http://company.com/ccie-slides-ppt/content/vector/page%d.swf 1 291
# ./swf2png.sh
# cd ..

download and install CutePDF
using winscp, copy all .png to your pc
open Word and insert all png
print to CutePDF from Word

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s