Hi,

I'm relatively new to this community, so please forgive me if I'm stating 
something wrong.
My current employee wants to transform flash animations into H264 videos.
Accomplishing that, I tried to get transparent jpegs (DEFINEBITSJPEG3) via 
swfextract.

the resulting error was 'Not a JPEG file: starts with 0x10 0x00'.

After looking into the contents of the swf via swfbytes I discovered an 
obviously misplaced object.

However swfrender just renders fine (without alpha channel though), so, in 
order to get it working,
I removed the lines 764-792 (handlejpeg(TAG*tag)), and replaced the code with:

unsigned char*image;
unsigned width=0, height=0;
image=swf_ExtractImage( tag, &width, &height);
png_write( filename, image, width, height);
free(image);
return 1;

By doing so I achieved extraction of transparent JPEGS to PNG files.
swfrender however turns transparency into black.

I do not know the motivation having the same functionality coded in different 
ways nor do I claim 
to understand it or to know better.

I rather took a pragmatic approach, if this is in any violation with the given 
architecture then it might
serve as a workaround, and should not be included in code.


Regards
CodeRookie


Reply via email to