Closed dhikshithrm closed 10 months ago
https://github.com/folksable/blurhash_ffi/pull/10#issuecomment-1840703640
I just tested them and I also got the blank image view when decoding. However, it looks like the decoding result from the native C code is good. I added some code to print the decoding result and tested them on both Windows and Linux, then I got the same result.
Test result for the 3 images in the example
(They are identical)
So I guess it's something wrong in the Dart side.
Same problem exists on linux/android too. On this os image in most cases fine, in rare cases first pixels get corrupted and contains garbage values. I found some memory problems and fix it. After that on linux/android image always correct. Not tested on windows.
@iliser I just tested your fork on Windows and it is fixed. Thanks!
(Ah how could I forget to deallocate the memory in #10)
Thank you @iliser for the fix and memory leak observation and thank you @wh201906 for confirming this fixed #13
thanks to @wh201906 for the vla fix with #10 pr, there seems to be a dart side issue while constructing an image sent from the native side.