In OpenFL and in heaps they use a Ref or an Asset folder for the objects and images. But I want to display any picture stored on the computer. Is there a way to do that using the path of the file? I look for a library that allows me to move or even delete the file.
1 Answers
0
votes
How an image is loaded is going to depend on the library you're using.
- OpenFL has a
openfl.display.BitmapData.fromFile(path)API. - The Heaps API looks similar, there's
hxd.BitmapData.fromNative(data)(though the argument type depends on the target).
For file manipulation, simply use the sys package from the stadand library: