Setup

To integrate the Ink API, first add the dependencies in your app. From there, you can access the different modules for your inking needs.

The Ink API library is available from the Google Maven repository. Add the dependency to your app's build.gradle file as shown:

Kotlin

dependencies {
    val ink_version = "1.0.0-alpha01"

    implementation("androidx.ink:ink-authoring:$ink_version")
    implementation("androidx.ink:ink-brush:$ink_version")
    implementation("androidx.ink:ink-geometry:$ink_version")
    implementation("androidx.ink:ink-nativeloader:$ink_version1")
    implementation("androidx.ink:ink-rendering:$ink_version")
    implementation("androidx.ink:ink-strokes:$ink_version")
}

Groovy

dependencies {
    def ink_version = "1.0.0-alpha01"

    implementation "androidx.ink:ink-authoring:$ink_version"
    implementation "androidx.ink:ink-brush:$ink_version"
    implementation "androidx.ink:ink-geometry:$ink_version"
    implementation "androidx.ink:ink-nativeloader:$ink_version"
    implementation "androidx.ink:ink-rendering:$ink_version"
    implementation "androidx.ink:ink-strokes:$ink_version"
}