git.asbjorn.biz
/
swftools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Initial revision- not really working yet
[swftools.git]
/
pdf2swf
/
HOWTO_pdf2swf
diff --git
a/pdf2swf/HOWTO_pdf2swf
b/pdf2swf/HOWTO_pdf2swf
index
a2095b8
..
e85b895
100644
(file)
--- a/
pdf2swf/HOWTO_pdf2swf
+++ b/
pdf2swf/HOWTO_pdf2swf
@@
-1,17
+1,16
@@
-
Notice
This documentation is a little outdated. As with swftools-0.2.1 and
above, you can simply do
Notice
This documentation is a little outdated. As with swftools-0.2.1 and
above, you can simply do
- pdf2swf -bl -o document.swf document.pdf
+ pdf2swf -bl -o document.swf document.pdf
to link viewer and preloader.
to link viewer and preloader.
- However, the Steps below are still valid for jpeg2swf.
+ However, the Steps below are still valid for jpeg2swf.
Step 1: Converting the documents
Suppose you have an arbitrary pdf file, "document.pdf".
Call:
Step 1: Converting the documents
Suppose you have an arbitrary pdf file, "document.pdf".
Call:
- pdf2swf -o tmp.swf document.pdf
+ pdf2swf -o tmp.swf document.pdf
Now, tmp.swf is a Flash Movie generated from document.pdf. Movie means
that there are no navigation elements whatsoever. Just frames which
get displayed one by one, at a rate of approx. 1/2 frames/second. How
Now, tmp.swf is a Flash Movie generated from document.pdf. Movie means
that there are no navigation elements whatsoever. Just frames which
get displayed one by one, at a rate of approx. 1/2 frames/second. How
@@
-26,7
+25,7
@@
Step 2: Linking a viewer
Just take a viewer of your choice (e.g. [1]SimpleViewer.swf ) and put
it in the same directory where you entered the commands above.
Now call:
Just take a viewer of your choice (e.g. [1]SimpleViewer.swf ) and put
it in the same directory where you entered the commands above.
Now call:
- swfcombine -o flashfile.swf SimpleViewer.swf viewport=tmp.swf
+ swfcombine -o flashfile.swf SimpleViewer.swf viewport=tmp.swf
Now, 'flashfile.swf' is "browsable", i.e. there are some buttons in it
for turning pages.
Now, 'flashfile.swf' is "browsable", i.e. there are some buttons in it
for turning pages.
@@
-40,13
+39,13
@@
Step 3: Linking a Preloader
or just convert a "Loading" JPEG picture to swf (jpeg2swf -o
loading.swf picture.jpg)) Now use
swfcombine -o flashfile.swf PreLoader.swf loader=loading.swf
or just convert a "Loading" JPEG picture to swf (jpeg2swf -o
loading.swf picture.jpg)) Now use
swfcombine -o flashfile.swf PreLoader.swf loader=loading.swf
- movie=flashfile.swf
+ movie=flashfile.swf
(Most loaders are smaller than the document they load. They usually
need some centering so they appear in the middle of the page to be
displayed, not in the upper left corner. Replace the above command
with e.g.
swfcombine -o flashfile.swf PreLoader.swf -x 3000 -y 3000
(Most loaders are smaller than the document they load. They usually
need some centering so they appear in the middle of the page to be
displayed, not in the upper left corner. Replace the above command
with e.g.
swfcombine -o flashfile.swf PreLoader.swf -x 3000 -y 3000
- loader=loading.swf movie=flashfile.swf
+ loader=loading.swf movie=flashfile.swf
and try playing around with the values after -x and -y)
Step 4: Correcting the size and framerate
and try playing around with the values after -x and -y)
Step 4: Correcting the size and framerate
@@
-56,14
+55,14
@@
Step 4: Correcting the size and framerate
the SWFs, the new dimensions are those of the PreLoader and Viewer
templates, and not those of your pdf or jpeg files. To fix this, use
swfcombine --dummy `swfdump -XY tmp.swf` flashfile.swf -o
the SWFs, the new dimensions are those of the PreLoader and Viewer
templates, and not those of your pdf or jpeg files. To fix this, use
swfcombine --dummy `swfdump -XY tmp.swf` flashfile.swf -o
- flashfile.swf
+ flashfile.swf
(tmp.swf is your 'original' swf, generated like above)
You may also want to adjust the framerate of the movie to that of the
preloader. (As the preloader is usually the only animated part of e.g.
pdf viewers)
Use:
swfcombine --dummy `swfdump -r loading.swf` flashfile.swf -o
(tmp.swf is your 'original' swf, generated like above)
You may also want to adjust the framerate of the movie to that of the
preloader. (As the preloader is usually the only animated part of e.g.
pdf viewers)
Use:
swfcombine --dummy `swfdump -r loading.swf` flashfile.swf -o
- flashfile.swf
+ flashfile.swf
Step 5: Embedding the SWF into a html page
Step 5: Embedding the SWF into a html page
@@
-72,7
+71,7
@@
Step 5: Embedding the SWF into a html page
embed SWFs into html pages, it's explained at
[4]http://www.macromedia.com/support/flash/ts/documents/tn4150.html .
Also, you can simply type
embed SWFs into html pages, it's explained at
[4]http://www.macromedia.com/support/flash/ts/documents/tn4150.html .
Also, you can simply type
- swfdump --html flashfile.swf
+ swfdump --html flashfile.swf
and insert the output into your html document
Appendix A: Creating your own Viewers
and insert the output into your html document
Appendix A: Creating your own Viewers
@@
-82,7
+81,10
@@
Appendix A: Creating your own Viewers
1. There has to be some rectangle (Movieclip, whatever... ) in your
Viewer, named "viewport". (This name is used to reference the object
when using swfcombine for merging it with the converted pdfs)
1. There has to be some rectangle (Movieclip, whatever... ) in your
Viewer, named "viewport". (This name is used to reference the object
when using swfcombine for merging it with the converted pdfs)
- 2. Browsing buttons next to the rectangle (which turn pages in the
+ 2. The First frame should contain an actionscript "Stop" instruction.
+ (Otherwise, the browsing buttons turn pages, but pages get also
+ automatically turned every few seconds)
+ 3. Browsing buttons next to the rectangle (which turn pages in the
shown pdf) should trigger some Actionsscript events, like
SetTarget "viewport"
shown pdf) should trigger some Actionsscript events, like
SetTarget "viewport"
@@
-92,15
+94,19
@@
Appendix A: Creating your own Viewers
to set the frame in the to-be-replaced rectangle. (It will be replaced
with a MovieClip, therefore a SetTarget is neccessary)
It's important that the Target Name ist "viewport", not "/viewport",
to set the frame in the to-be-replaced rectangle. (It will be replaced
with a MovieClip, therefore a SetTarget is neccessary)
It's important that the Target Name ist "viewport", not "/viewport",
- as the Movie will get inserted into a Movieclip.
+ as the Movie will get inserted into a Movieclip (Sprite).
_________________________________________________________________
[5]Back to the SWFTools Project page
References
_________________________________________________________________
[5]Back to the SWFTools Project page
References
+ Visible links
1. http://www.quiss.org/swftools/SimpleViewer.swf
2. http://www.quiss.org/swftools/PreLoader.swf
3. http://www.quiss.org/swftools/loading.swf
4. http://www.macromedia.com/support/flash/ts/documents/tn4150.html
5. http://www.quiss.org/swftools
1. http://www.quiss.org/swftools/SimpleViewer.swf
2. http://www.quiss.org/swftools/PreLoader.swf
3. http://www.quiss.org/swftools/loading.swf
4. http://www.macromedia.com/support/flash/ts/documents/tn4150.html
5. http://www.quiss.org/swftools
+
+
+