swftools | swftools git repository
kandi X-RAY | swftools Summary
kandi X-RAY | swftools Summary
clone of swftools git repository +mouse scrolling in the PDF viewer
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of swftools
swftools Key Features
swftools Examples and Code Snippets
Community Discussions
Trending Discussions on swftools
QUESTION
When I run the example here: https://haxe.org/manual/target-flash-resources.html
Then process the output swf using http://www.swftools.org the png file is being embedded with the "DEFINEBITSJPEG2" tag
How do I tell Haxe to embed the png file with the "DEFINEBITSLOSSLESS2" tag?
...ANSWER
Answered 2021-Mar-13 at 13:53It would seem the compiler detects PNG based on header (so it's best to doublecheck that the file is actually an PNG) and if it does, it tries to store it as BitsLossless2
(no idea if that tag is any different from BitsLossless
), but there seems to be an exception for 24bit PNGs exceeding a certain size, which indeed falls back to BitsJPEG2
(for reasons I don't quite understand). You should be seeing a warning telling you to add an alpha channel. I would suggest trying that.
If all else fails, you can use resources instead, which are embedded as BinaryData
. With haxe.Resource.getBytes(nameOfTheResource).getData()
you get a flash.utils.ByteArray
and you can stick that into a flash.display.Loader
via loadBytes
.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install swftools
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page