A (standalone) node module for reading SWF format properties. This is a ES6 fork of swf-reader, with a simplier intend (no internal tags/clip lookup, just main scene properties).
$ npm install swf-properties
var SWFReader = require('swf-properties');
SWFReader( 'swf_path.swf', function(err, props) {
if ( err ) {
// handle error
...
}
console.log(props);
});
Returns a SWF Object to callback
function. If it's not possible to read the SWF, an error object is passed as the first argument of callback
.
The SWF Object method has the following properties :
-
version
: The SWF version. -
fileLength
: An Object containing the following properties :-
compressed
: The SWF compressed size in bytes. -
uncompressed
: The SWF uncompressed size in bytes.
-
-
frameSize
: An Object containing thewidth
andheight
of the SWF. -
frameRate
: The SWF framerate. -
frameCount
: Number of frames in the SWF.
MIT