12 KineticFusion FAQ
12.1 Question List
12.1.1 Installation
What is Java and do I need it?
What Version of Java do I need?
Do I need the Java Development kit?
How do I install KineticFusion?
How do I run KineticFusion?
12.1.2 Running KineticFusion
Can I use my favourite XML parser?
Can I use KineticFusion with {Insert favorite Logging package here}?
How can KineticFusion be configured?
12.1.3 Integration
Can KineticFusion be run as part of a script?
Can I embed KineticFusion in my JavaServer?
Can we get access to the KineticFusion source code?
Can you provide a library API for creating SWF movies?
12.1.4 General
Why do you keep taking about 'documents' instead of 'files'? What's the difference?
How are the decompiled symbols named?
Why do some of my SWF images have red parts when there was no red in the original SWF image?
12.1.5 RVML
Who created RVML?
Is there an RVML namespace?
Can RVML support {favorite feature here}?
Why is UpperCamelCase used for elements and lowerCamelCase used for attributes?
Why is my compiled RVML a different size to the input SWF movie?
Why do I get an error "WARN XMLModelReader - Uncommited symbol already resides at depth: XX"?
12.1.6 RVML and SVG
What is the difference between RVML and SVG?
Can KineticFusion translate SWF to SVG?
Can KineticFusion translate SVG to SWF?
12.1.7 SWF
What is SWF?
Do you provide information on the SWF format?
Is the SWF produced by KineticFusion compatible with that from other major authoring tool creators?
How do I debug an SWF movie?
12.1.8 ActionScript
What is ActionScript?
What versions of ActionScript does KineticFusion support?
Does KineticFusion support ActionScript Slash notation?
I get errors when decompiling ActionScript?
Who owns the copyright to the decompiled ActionScript?
My ActionScript works fine with Flash MX but generates errors in KineticFusion?
Does KineticFusion support the #include directive?
What is the maximum size of ActionScript code that can be placed in a single tag?
12.1.9 ActionScript 2.0
Why is there a separate System class path?
My Macromedia classes still generate errors?
So many error messages - how can I turn them off?
Can I use KineticFusion as a Class Analyzer without writing RVML?
How does KineticFusion resolve dependencies?
How can I check that all dependencies are included in analysis and output?
Can I include dynamic classes in my SWF i.e. those to which no explicit reference is made in ActionScript?
I've changed a class on which another class depends, however KineticFusion is still using the cached copy?
Why doesn't KineticFusion use a persistent class cache?
Does KineticFusion support Ant tasks?
I know my SWFs will be loaded into movies that already have the required classes. Can I prevent these classes from being output for a particular SWF movie?
What is the maximum size of an ActionScript 2.0 class?
I get the following message: Error processing class path - Too many non-as files on path: <Some Path >. What does this mean?
12.1.10 Fonts
Can Kinesis Software supply fonts for use with KineticFusion?
Can existing SWF fonts be used when authoring with RVML?
12.1.11 Sounds
Why does my MP3 sound play at a lower pitch when added to an SWF?
Does KineticFusion support WAV or other raw sound formats?
Why does KineticFusion tell me there are multiple sound streams in an SWF?
12.2 Installation
Java is a cross-platform environment for developing applications that can run on any computer supporting a Java Virtual Machine (VM). This allows a single application to run without modification on multiple computer types. Previously it would have been necessary for a development company to produce a different version of the software for each computer type and support each version independently. In practice this normally meant that certain features would not be available on one system at the same time as others. However currently most modern computers now support Java technology. In order to use any Java application on your computer you need to download the environment from the Java website here:
www.java.com. The download is free and the size is approximately 13 MB. This download will also enable you to run Java applets and Java WebStart applications.
KineticFusion requires Java 1.4 or higher in order to run. We recommend a minimum Java version of 1.4.2, though you should consider always using the latest version of Java, currently 1.4.2_05, to ensure the application looks and run optimally.
No. The Java Development Kit (or JDK) is only for those users that wish to write Java programs. It is not necessary for any user who simply wants to run Java programs.
Store the KineticFusion JAR file in a temporary directory. If you have not modified your computer's default file associations (some users like to associate Jar files with their favorite Zip program), you should be able to execute the installer by opening the Jar file, normally by double-clicking. Alternatively, the JAR file can be executed from a command window using the command:
java -jar {NameOfJarFile}.jar
This will start the installation (not the application). The installation will permit you to define the permanent folder on your computer to store the application. After installation, the Installable jar file can be safely deleted.
KineticFusion is a Java application. This means that you need a Java environment set up on your computer. If you have a Java environment then, on Windows, you need only double-click on the installed KineticFusion.bat file and the application will run. If you are using a non-Windows computer, then open a command window in your installation directory and type:
(For KineticFusion 1.0.*)
java -classpath "KineticFusion.jar" com.kinesis.KineticFusion
(For KineticFusion Starter Edition)
java -classpath "KFStarter.jar" com.kinesis.KineticFusion
(For KineticFusion Developer Edition)
java -classpath "KFDeveloper.jar" com.kinesis.KineticFusion
(For KineticFusion Server Edition)
java -classpath "KFServer.jar" com.kinesis.KineticFusion
The application can also be run directly from the command-line to process one or more files. See
here for more details.
12.3 Running KineticFusion
Yes. KineticFusion used the standard Java library JAXP to locate a suitable XML parser to use with the application. Simply add your XML parser to the classpath of the application and the application will pick it up. Performance gains may be achieved by using a parser other than the default parser however Kinesis Software will not directly support their use.
Yes. Future details will be provided on integrating and using KineticFusion with both Java Logging, Apache's log4j, and Apache Common Logging.
The KineticFusion has a number of configurable options for specifying RVML output and parsing options. See
here for more information.
12.4 Integration
Yes. KineticFusion can be run on the command-line and will translate a single file or directory or files from RVML or SWF. When run from the command line there are five forms of arguments that can be passed:
com.kinesis.KineticFusion -r -f RVMLFileName -o OutputSWFFileName
This will translate an RVML document to an SWF movie. If the specified SWF document already exists it will be overwritten without confirmation.
com.kinesis.KineticFusion -s -f SWFFileName -o OutputRVMLFileName
This will translate an SWF movie to an RVML document. If the specified RVML document already exists it will be overwritten without confirmation.
com.kinesis.KineticFusion -r -d [-x <RVML Extension> ] RVMLFolderName -o OutputSWFFolderName
This will translate all RVML documents in the specified folder to SWF documents in the output folder. The default RVML file extension is ".rvml". To process files with a different extension, use the '-x' option with the full document extension (including the leading dot, if applicable).
com.kinesis.KineticFusion -s -d [-x <RVML Extension> ] SWFFolderName -o OutputRVMLFolderName
This will translate all SWF movies in the specified folder to RVML documents in the output folder. The default RVML output file extension is ".rvml". To output files with a different extension, use the '-x' option with the full document extension (including the leading dot, if applicable).
If AS2.0 support is enabled, a third additional set of command-line options are available for the analysis of AS2.0 class files.
com.kinesis.KineticFusion -check classID classID....
This will analyze the specified classes and all dependent classes sending messages to the console.
When running KineticFusion in a command-line script be sure to use the 'java' command instead of 'javaw', which is intended for running windowing applications and discards all console output.
A server component for KineticFusion has been designed allowing multithreaded generation of SWF movies. We expect to announce a Beta Trial of the component shortly. Contact us for more information on participating in the trial.
While the KineticFusion Community Edition application is made freely available the source code to all our applications remains the property of Kinesis Software. We will consider licensing Source Code under a strict licensing agreement with selected customers only where desirable. If this is a requirement, please contact us via our website for further information.
WE currently do not provide an API for creating SWF movies. We expect to release both a stream-oriented API for RVML stream processing and an extended programmatic API as part of our next product suite.
12.5 General
Yes, we use the word 'document' a lot in this documentation. RVML files are referred to as RVML documents.
SWF files are referred to as SWF movies. For KineticFusion, there is little essential difference between
a file and document, or a file and a movie. Nevertheless, since we do not restrict ourselves to
the idea of plain old files we try to keep our intention general e.g. a HTML web page only becomes a
file when its stored on your filesystem, otherwise its a document. If this confuses, just replace all
occurrences of document with 'file' in your head.
If a movie has been compiled with KineticFusion, then the value of the property 'kinesis.swf.outputSymbolNames'
determines whether a list of all original symbol names is appended onto the output swf movie. When set to true, an unused SWF tag is used to store the mapping between SWF symbols and the names used in the original RVML movie, and on input these names are restored to the SWF symbols.
However when the property is set to false, or if the original SWF movie was not created by KineticFusion, then the following naming process is used:
- All exported symbols are labelled with their export name
- All imported symbols are labelled with their imported name
- All fonts are labelled with their font name
- All symbols that are assigned an instanceName in a Place element on the main timeline are labelled with the instance name
For all other symbols, the following process is used:
- All symbols receive a default name represented by their symbol type and a unique index.
- All symbols placed on the main timeline are prefixed by 'Main.'
- All symbols placed on the timeline of a MovieClip are prefixed by the MovieClip name.
- All symbols that are assigned an instanceName in a Place element on a movieclip timeline are labelled with the instance name.
- Symbols used in button layers are prefixed by the button name and suffixed by the states in which the symbol appears in the order "UpOverDownHit".
The SWF format permits the use of JPEGs with an alpha channel. In order to highlight the alpha channel, the image is stored in an SWF with a red background colour. Hence, the presence of red in a image may be indicative of an alpha channel.
12.6 RVML
RVML is an XML vocabulary created by Kinesis Software. We will accept submissions for modifications for additional features and enhancements from interested parties.
Yes. Version 1.0.5 of KineticFusion uses the XML namespace identifier:http://www.kineticfusion.org/RVML/1.0. KineticFusion 2.0 uses the XML namespace identifier:http://www.kineticfusion.org/RVML/2.0
There are many high-level features not currently supported in RVML however every SWF movie can currently be completely represented in RVML, providing ActionScript has not been optimised. This was the initial goal of KineticFusion. Additional high-level features will continue to be added to RVML over time providing support for components and easier translation to and from other XML vocabularies.
It seemed like a good idea at the time. We will work with the RVML community to standardise the vocabulary and the KinesisSoftware forums currently have discussions for this purpose.
There are multiple means of specifying features within the SWF format, which can be made highly optimised. Different optimisation and compression techniques have different strengths depending on the nature of the SWF. Any size difference does not indicate the addition or loss of functionality.
Some SWF generators use separate Place and Alter elements for the same symbol on a single frame. The KineticRVML Engine only permits a single operation per frame on a symbol at any particular depth. These elements should be combined to a single Place element by adding the Transform element specified in the Alter element to the Place element.
12.7 RVML and SVG
There is a huge difference between the two vocabularies. SVG is a W3C-endorsed specification for the definition of vector graphic documents and is is gaining support across many communities. RVML is an attempt to provide many of the same facilities to contents creators using the SWF binary format who wish to retain the full features of the underlying SWF rendering player while working within a XML-centric model. It may also be used to provide an intermediate vocabulary for users wishing to have the choice of publishing to either format. Consequently, it is hoped that in the future there will be many features in RVML compatible with those in SVG.
No, not directly. The features in both vocabularies have many differences. However, it is possible to translate a subset of the RVML vocabulary to SVG/SMIL using XSLT or more dedicated transformations technologies but none are provided with KineticFusion.
No, not directly. The features in both vocabularies have many differences. However, RVML does implement several of the key drawing elements of SVG and it would also be possible to translate a subset of the SVG/SMIL into RVML using XSLT or more dedicated transformations technologies but none are provided with KineticFusion.
12.8 SWF
SWF is the binary format used to distribute movies that can be rendered in Macromedia's Flash player. It is an optimized compressed format and is documented by many sources on the web
No. A good place for SWF information is on the Script SWF project site at: sswf.sourceforge.net
If you can handle the legal restrictions of the Macromedia license, they also provide a reasonably full PDF description of the format.
The Flasm project is a good place to start when looking for information on ActionScript bytecodes though much of the documentation is implicit in the well-written source code.
Yes. We have strived to provide 100% compatibility will all leading SWF authoring tools.
If you own the Macromedia Flash MX authoring tool then the debugger associated with this application can be used to debug your SWF movies. You will need to activate the debugger in your authoring tool, and then launch your SWF movie in a DebugPlayer. Select the debug option on the player and this will connect to the debugger. When asked for a password leave the password field blank and continue. All trace actions, and symbols properties can now be inspected in the debugger however it is not currently possible to step through source code since this requires a proprietary Macromedia debug file.
Additionally, it is possible to output trace statements to an external text file if you have the Flash Debug Player. See the Macromedia FLex documentation online user Developing Flex Applications/Debugging Flex Applications/ Configuring Flash Debug Player
If you do not have this authoring tool, the easiest solution is to use one of the publicly available Flash consoles that can be used for output tracing.
12.9 ActionScript
ActionScript is the scripting language used by the SWF format. It is based on ECMAScript, a scripting language very similar to JavaScript. The SWF Player implements a complete library of classes for animation, multimedia, and communications among others that can be used in any ActionScript fragment. Many books have been written on ActionScript and can be found in any technical bookstore.
KineticFusion supports all versions of ActionScript used in players from version 4 to version 7. We support all other features of AS2.0 support found in the Version 7 player using synthetic functions for the 'cast', 'extends' and 'implements' functionality which is translated to the appropriate code by KineticFusion on compilation.
KineticFusion Developer Edition also includes full AS2.0 with an intelligent class analyzer, configurable warning messages, and class caching for fast compilations.
Yes, using an optional configuration setting.
There are several possible reasons for getting errors on ActionScript decompilation. ActionScript is compiled inside the SWF movie and needs to be decompiled in order to be viewed. While most ActionScript authoring systems translate ActionScript into a similar low-level structure, there is no reason why compiled ActionScript need have any intelligible high-level ActionScript representation. Some authoring systems allow users to obfuscate, optimize, or hand code their scripts and KineticFusion will not be able to decompile these. The intention of KineticFusion is aid authors wishing to round-trip and verify produced movies.
Some of the warnings produced during decompilation are ignorable. Errors such as
- 'Found a loop that extends beyond given block. Hmmm...??'
- 'Found a spare label and it's not on an End Block...'
are only indications of possible error conditions detected when following label references and are often ignorable.
We don't know. In principle, we believe the original author of the SWF should hold the IP rights to all code, compiled or otherwise. However this is a complex legal area and users are encouraged to seek professional legal advice on this issue.
KineticFusion provides full ActionScript support except for the following restrictions:
- If slash identifier support is not enabled then no slash identifiers can be used.
Yes. The property kinesis.actionscript.includePath defines possible locations for included files and uses similar syntax to the Java classpath specification except the mandatory separator is a semicolon. If not specified, then the application class path is used. When a #include directive is found, this path is searched in specified order for the required file. Once found, all subsequent nested #include directives will initially be loaded relative to the position of the parent file. Only if the include file is not found relative to the parent file is the include path property used to locate the file. This allows multiple nested hierarchies of script files to be used.
This include path is also used when resolving src attributes for ActionScript elements. When a relative URL is specified as the src attribute on FrameActions, MovieClipActions, InitClipActions, or ButtonActions elements then the url is automatically converted to a single-line script consisting of a #include directive with the file extracted from the specified src attribute.
While there is no official limit, generally a maximum of limit of 64K should be maintained for each block of compiled ActionScript code, represented by a single RVML tag. Exceeding this may cause scripts to misbehave. . Should this occur, it will be necessary to split the code used into multiple tags.
12.10 ActionScript 2.0
KineticFusion is initially configured to perform extremely thorough checking of all user scripts. Since these scripts are under user control, it is assumed that these can be altered to limit the number of ambiguities within the code. For 3rd-party classes not created by the user, any errors generated while analyzing will only be distracting. Hence, for all classes on the System class path, all non-fatal messages are all disabled.
In general, classes and packages are not allowed to have the same name. However, the intrinsic class System and TextField share the same name the intrinsic packages System and TextField. These two exceptions are only permitted for classes on the System class path. Additionally, in order to use some of the Macromedia sample classes, the user must make certain modifications to the classes to enable them to be compiled successfully. It is recommended that all these classes are copied to a temporary directory before being modified. Reasons for compilation errors include the existence of fields in classes with the same name as other members, differing only in case e.g. a field STOP and method stop(). As these will give the wrong results when run in a V6 player, they are not permitted by default in the KineticFusion compiler.
While we recommend not disabling the error message but, instead, resolve the underly conflicts, for most this is not feasible. There are three possible means of disabling error messages:
- The preferred method is to disable individual message types using the ErrorConfiguration.properties file. Within this file, each error message ID is assigned a default logging level. By setting a message level to 'Ignore', all messages with that ID will no longer be logged. A user cannot override certain messages that cause processing to abort e.g. when a class file name does not correspond to the name of the contained class.
- When a user is happy that all classes referenced by a single RVML file can be safely ignored, a property can be set within the RVML document turning off compiler warning messages. This property is called 'enableWarningMessages' and when set to false, will disable warning output.
- Warning messages can be disabled for the entire KineticFusion application by setting the global property 'kinesis.actionscript.enableWarningMessages' to false. This should only be used if you are processing multiple documents are you are sure that no ActionScript errors occur in any document.
Yes, there is a new panel in the KineticFusion GUI allowing the user to select classes that are on the defined class path. Multiple classes can be selected and those classes along with all their dependencies are analyzed, with all message output to the console. Alternatively, classes can be analyzed from the command-line. See
here for more details.
Dependencies are resolved from a wide source of class references derived from the AS2.0 class information.
There are three new logging options in KineticFusion 2.0 to cater for this. A user can log all references to classes that are cached, classes that are parsed, and finally, classes that are output to any SWF movie and the order in which they are output. A complex graph analysis of output dependencies ensure that classes are output in the correct order.
A new element has been added to RVML ('IncludeClass') to cater for this. In addition, you can specify the location of the included class in relation to any other class in case output order is important. This feature can also be used to change the ordering of classes that KineticFusion has already discovered.
KineticFusion will only rebuild a class if the structure of any of it's dependent classes is changed. For classes in its inheritance tree, it will recompile a class if the public or private members have changed in any way. For all other references, it will recompile a class only if the public interface of the referenced class is altered.
It's currently more efficient to rebuild the class cache every time KineticFusion is invoked, however, should this become a desired feature we will include this in a future release.
We are currently working on providing Ant support and it will be available in the next release.
Yes. A new element has been added to RVML ('ExcludeClass') to cater for this. You can specify the name of a single class for each ExcludeClass element, or you can exclude all classes in a package using the 'package.*' notation for the name attribute. All excluded classes will still be parsed and analyzed but will not be output in the destination SWF movie.
The SWF format has a limit of 64K for each block of compiled ActionScript code, however, due to the implementation of classes, this is effectively reduced to 32K for each ActionScript 2.0 class. While there are several ways of circumventing this restriction, doing so would mean that these classes would no longer compile with other ActionScript compilers.
KineticFusion will generate an error if it detects that the 32K threshold has been exceeded by a developer. Should this occur, it may be necessary to split the class definition into multiple classes to reduce the size.
KineticFusion analyzes the contents of all class path components to determine the classes that are available and their location. When a class path is expressed wrongly it is possible that KineticFusion could index the entire contents of a hard-drive. To prevent this from happening, KineticFusion maintains a count of the number of non-ActionScript files encountered. If this count exceeds a predefined maximum (default is 1000) processing of the class path component is aborted and all files on the path component are ignored. To prevent files in SCM folders from being included, KineticFusion automatically excludes all CVS and .svn folders from indexing. It is also possible to configure KineticFusion to excude other folders or change the unknown file threshold. There are two undocumented properties available to change these - we may get around to documenting these but we'd prefer KineticFusion to handle this automatically so just let us know if you think you have a problem.
12.11 Fonts
No, currently we do not supply any fonts with the application due to licensing restrictions. KineticFusion 3.0 now provides full support for TrueType fonts that are found on most modern computers.
Yes. If you have an SWF authoring tool then you will also be licensed to distribute those fonts. Consequently these fonts can be added to an SWF and decompiled by KineticFusion, creating a font repository. To do this, add text for every font you require to a movie, remembering to use both normal, bold and italic versions for each font and specify that the authoring tool embed the entire font definition on output.
12.12 Sounds
All MP3 sounds must be have a sampling rate of either 11KHz, 22KHz or 44KHz. If the sampling rate of the input sound does not not match any of these rates then the nearest lower rate will be selected resulting in distorted sounds on playback.
No. All sounds must either be in native SWF format or CBR(Constant Bit Rate) MP3 format. If you require conversion of other sound formats use an external encoding tool such as LAME.
When KineticFusion encounters a pause in streaming audio, it will create a new stream to conserve storage space. Many SWFs with streaming sound have a lot of redundant frames for sound gaps and these are automatically eliminated by splitting the sound stream into multiple output streams. This behaviour can be changed on request.
Copyright 2003-2005 Kinesis Software. All rights reserved.