Hi, I am facing the need to use a transparent OpenFL canvas when exporting for HTML5. this is quite simple to do when leveraging only OpenFL: Just declare background as null in the XML config and it works great.
Thanks in advance. OpenFL is simply amazing and it was the only tool that I found reliable yet simple enough to perform what I need to do for a client.
Thanks for the kind words
Please check your HTML template, are you sure that the default template is not the one setting the black color? This happened in a previous project I was testing for transparency – it was actually transparent, but the default HTML template set a black background color in the CSS for it’s parent DIV, making it look like it had a black background.
If not, then I believe there was a bug I fixed in Starling for supporting transparent backgrounds, it might be that your version needs to be updated (or I need to update the haxelib version)
Hey, it wasnt any css that was causing the problem. I just had to change stage.color to 0x000000 after the starling root sprite gets added to the stage. It is now working fine. Great!