Start seperating out RS compute implementation. Create hal

layer to seperate from runtime.

Change-Id: Idf5c1261be4131690d25c15948e98324e979b4f9
This commit is contained in:
Jason Sams
2011-03-16 16:29:28 -07:00
parent ce06ebfda4
commit e4a06c5fc7
21 changed files with 1286 additions and 826 deletions

View File

@@ -92,16 +92,13 @@ public class ScriptC extends Script {
throw new Resources.NotFoundException();
}
rs.nScriptCBegin();
rs.nScriptCSetScript(pgm, 0, pgmLength);
// E.g, /system/apps/Fountain.apk
String packageName = rs.getApplicationContext().getPackageResourcePath();
//String packageName = rs.getApplicationContext().getPackageResourcePath();
// For res/raw/fountain.bc, it wil be /com.android.fountain:raw/fountain
String resName = resources.getResourceName(resourceID);
String cacheDir = rs.getApplicationContext().getCacheDir().toString();
Log.v(TAG, "Create script for resource = " + resName);
return rs.nScriptCCreate(packageName, resName, cacheDir);
return rs.nScriptCCreate(resName, cacheDir, pgm, pgmLength);
}
}