Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android 0.7.86 Illegal Argument Exception: Failed Surface.makeRaster #824

Open
Siedlerchr opened this issue Nov 8, 2023 · 0 comments
Open

Comments

@Siedlerchr
Copy link

Siedlerchr commented Nov 8, 2023

When calling my method:
In 0.7.80 it worked. Haven't tested versions in between

    fun create1pxSurface(): Surface {
        val colorInfo = ColorInfo(ColorType.GRAY_8, ColorAlphaType.OPAQUE, ColorSpace.sRGB)
        return Surface.makeRaster(ImageInfo(colorInfo, 1, 1))
    }

I get this exception and the app crashes

 java.lang.IllegalArgumentException: Failed Surface.makeRaster(ImageInfo(_colorInfo=ColorInfo(_colorType=GRAY_8, _alphaType=OPAQUE, _colorSpace=ColorSpace(_ptr=0x79192ad220)), _width=1, _height=1), 1, null)
                                                                                                    	at org.jetbrains.skia.Surface$Companion.makeRaster(Surface.kt:217)
                                                                                                    	at org.jetbrains.skia.Surface$Companion.makeRaster(Surface.kt:143)

with

@Siedlerchr Siedlerchr changed the title Android 0.7.68 Illegal Argument Exception: Failed Surface.makeRaster Android 0.7.86 Illegal Argument Exception: Failed Surface.makeRaster Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant