Muhammad Ali
Muhammad Ali

Reputation: 740

Renderscript error in Android Studio 2.0 stable

I updated Android Studio to 2.0 stable, then I got this error:

Renderscript support mode is not currently supported with renderscript target 21+

What should i do? tnx

Upvotes: 2

Views: 288

Answers (2)

Miao Wang
Miao Wang

Reputation: 1130

This has been fixed in gradle-plugin 2.1.0 and Build-Tools 23.0.3. Use the code below:

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.1.0'
    }
}


android {
    compileSdkVersion 23
    buildToolsVersion "23.0.3"
    ...
}

Upvotes: 2

Ahmad Vatani
Ahmad Vatani

Reputation: 1670

Renderscript isn't currently supported with Target 21+ so simply change the target to below API 20 and that error will be solved. replace your code with below code:

renderscriptTargetApi 20
renderscriptSupportModeEnabled true

Upvotes: 1

Related Questions