Using Kinc hxcpp backend, if you unload a Kha image calling it's unload method and then you assign another object to the same reference [1], a few seconds later the GC will call finalize, calling unload again, which would trigger this assertion → https://github.com/Kode/Kha/blob/master/Backends/Kinc-hxcpp/kha/Image.hx#L432
Using Kinc hxcpp backend, if you unload a Kha image calling it's
unload
method and then you assign another object to the same reference [1], a few seconds later the GC will callfinalize
, callingunload
again, which would trigger this assertion → https://github.com/Kode/Kha/blob/master/Backends/Kinc-hxcpp/kha/Image.hx#L432I think this happens since this commit → https://github.com/Kode/Kha/commit/a354a90e7b5399a05fe9ba688651e14a92ba8945#diff-6d8eac6ed9e4907561b445a6ec521a8eefbe4801487048aeb552ac3443ce9085R406
[1] As done for example here → https://github.com/armory3d/zui/blob/master/Sources/zui/Zui.hx#L1655-L1658