The problem is this: how to decode avframe in skia...
# compose-desktop
l
The problem is this: how to decode avframe in skia image? Here is my code. Take an example from here. I dont know how to write it in kotlin.
k
What are you having trouble with? Skiko exposes a subset of Skia APIs via Kotlin bindings. Is there a particular API that is missing? Do you have trouble with a particular line that you want to convert? Otherwise that's a rather big chunk of code.
l
Here:
uint8_t*   dst[] = { (uint8_t*)bm.pixmap().writable_addr() };
int dst_stride[] = { SkToInt(bm.pixmap().rowBytes()) };
k
https://github.com/JetBrains/skiko/blob/master/skiko/src/commonMain/kotlin/org/jetbrains/skia/Bitmap.kt#L993 is the binding to SkBitmap.pixmap(). https://github.com/JetBrains/skiko/blob/master/skiko/src/commonMain/kotlin/org/jetbrains/skia/Pixmap.kt#L99 is the binding to rowBytes(). You'll need to go one by one like this and find the matching binding. If it doesn't exist, file a bug on
skiko