Kode / Kha

Ultra-portable, high performance, open source multimedia framework.
http://kha.tech
zlib License
1.48k stars 174 forks source link

Implement new array types for HL #1392

Closed MoritzBrueckner closed 2 years ago

MoritzBrueckner commented 2 years ago

This PR implements the new array types in HL and fixes compilation.

I'm not particularly happy with the now missing setData() function that existed in the HL backend. I had to remove/replace it because the typed arrays no longer have their own Haxe sources in the backend, should I reimplement this function for ByteArray with the byte length instead of the number of typed elements as a parameter?

Also, does anyone know if it is possible in HL to set a finalizer like you can do it for hxcpp? This could make calls like (cast myTypedArray: ByteArray).free() obsolete.