in reply to [SOLVED] SWF::Builder, printing the swf file, rather than saving it
SWF::BinStream::File allows writing to a file handle, so use IO::Scalar to create a file handle that writes to a string and then you can print the string.
I've not tested this code but something along these lines may do what you want.
use SWF::File; use IO::Scalar; my $swf_data = ''; my $swf_fh = IO::Scalar->new( \$swf_data ); my $swf = SWF::BinStream::Write->new($swf_fh); ... $swf->close(); close $swf_fh; print $swf_data;
|
|---|