Questions tagged [renderscript]

RenderScript is an Android-specific compute API offered by Google. It offers accelerated compute performance with portability between Android devices.

RenderScript is an Android compute API offered by Google. It offers accelerated compute performance with portability between Android devices.

The RenderScript runtime operates as an asynchronous low-level interface to the traditional Android application controlling it. Memory allocation and binding is performed by the controlling Android application, with both the application and runtime environment able to read and write the memory asynchronously.

For graphics operations, RenderScript is essentially a wrapper for the OpenGL ES 2.0 API's, guaranteed to run on all Android devices supporting an API level of 11 (3.0) or higher. It allows for the use of OpenGL ES 2.0's programmable pipeline while providing easy support for a fixed function pipeline if desired.

Documentation for RenderScript is currently very limited, however the example applications included in

sdk_root/samples/android-11/RenderScript

provide a great deal in the way of examples demonstrating the capabilities of RenderScript.

Some links of interest for RenderScript are:

727 questions
6
votes
1 answer

Android ABI split migrating to App Bundle

I'm planning to migrate from ABI split to App Bundle feature. Currently I'm using this code: def versionCodesAbi = ['x86': 1, 'x86_64': 2, 'armeabi-v7a': 3, 'arm64-v8a': 4] splits { abi { enable true reset() …
snachmsm
  • 17,866
  • 3
  • 32
  • 74
6
votes
1 answer

androidx renderscript crash "Error loading RS jni library: java.lang.UnsatisfiedLinkError: JNI_ERR returned from JNI_OnLoad"

I'm using Android DS-Photo-Editor-SDK v1.5 ("ds-photo-editor-sdk-v6.aar") and androidx in my project. I get the following error when opening the editor filters: 2018-10-26 19:36:27.949 16826-16898/com.levionsoftware.photos E/software.photo: -----…
Denny Weinberg
  • 2,492
  • 1
  • 21
  • 34
6
votes
2 answers

Samsung Galaxy S9+ renderscript error

I'm working with the Camera2 API and I'm using Renderscript to perform some image processing. Everything works as expected on a range of devices(Nexus 5/5x, Pixel, Pixel 2, S8+, Note 8) except for the S9+. Basically what I'm doing is creating an…
Stelian Morariu
  • 505
  • 7
  • 16
6
votes
1 answer

RenderScript wrongly manipulating output of kernel

I'm trying to use Android's RenderScript to render a semi-transparent circle behind an image, but things go very wrong when returning a value from the RenderScript kernel. This is my kernel: #pragma version(1) #pragma rs…
user4424299
6
votes
1 answer

Camera2 api Imageformat.yuv_420_888 results on rotated image

Lots of questions have been made about camera2 api and RAW image format, but searching online I have still not found the answer (that's why I am here btw). I am trying to do some real-time image processing on camera-captured frames using ImageReader…
jackops
  • 776
  • 5
  • 15
6
votes
2 answers

Blur a bitmap with Renderscript and more than 25 radius Android

I have blurred a bitmap with Androids Rederscript private Bitmap createBitmap_ScriptIntrinsicBlur(Bitmap src, float r) { //Radius range (0 < r <= 25) if(r <= 0){ r = 0.1f; }else if(r > 25){ r = 25.0f; } Bitmap…
RoterBaron
  • 103
  • 2
  • 10
6
votes
2 answers

RenderScript not rendering ScriptIntrinsicBlur correctly, causing the ScriptIntrinsicBlur to render a rainbow of colors

Using the glide android library I get the image as a bitmap (see glide documentation) and then I try to blur the bitmap, using renderscript and ScriptIntrinsicBlur, which is a gaussian blur. (Taken from this stackoverflow post) …
HaloMediaz
  • 1,251
  • 2
  • 13
  • 31
6
votes
1 answer

Using renderscript for processing and mediacodec for encoding

I am trying to develop a camera app that does some video processing before recording the video. I have decided to use Rendrscript for the processing since it provides many of the operations that I want to use. And I want to use MediaCodec for…
Phyxle
  • 61
  • 2
6
votes
1 answer

Compiling renderscript code at runtime

I was wondering if it's possible to write/modify renderscript code when the android application is running. My main goal is to make an app where users can learn to work with renderscript without any java knowledge. The basic layout of the app would…
DeGoosseZ
  • 628
  • 5
  • 20
6
votes
1 answer

How to get Android Render Script Group work?

I can get two separate intrinsics working, but not together in a ScriptGroup. I found document on how to use Script Group is extremely sparse. Here is my code: mRS = RenderScript.create(getActivity()); mInAllocation =…
X.Y.
  • 13,726
  • 10
  • 50
  • 63
6
votes
2 answers

How to share a Renderscript allocation with OpenGL in Android

I have a Renderscript which processes an image that is given in output to an Allocation. I want to use this Allocation as a texture in my OpenGL program but I don't know how to get a texture ID from the Allocation. On the other hand, I know I could…
Mario Demontis
  • 469
  • 3
  • 11
5
votes
1 answer

Renderscript Fatal signal 11 (SIGSEGV) code 1 (SEGV_MAPERR) fault addr

I am using the camera2 API to get a stream of images of format ImageFormat.YUV_420_888. I need to do some processing on them with a library that requires sending the image as an RGB byte array (so the byte array length = width * height * 3) I used…
Victor Motogna
  • 731
  • 1
  • 12
  • 22
5
votes
3 answers

android studio no longer run/debug (install) RenderScript app to mobile device anymore

This issue started after I updated Android Studio from 2.1.2 to 2.3.3, with an existing RenderScript project. The error message I get is: Error:Execution failed for task ':app:mergeDebugResources'. Error: java.io.FileNotFoundException: C:\<…
vims liu
  • 643
  • 1
  • 9
  • 20
5
votes
1 answer

Android Fourier Transform Realtime - Renderscript

I am trying to apply a 2D Fourier Transform on incoming preview camera frames. So here is my renderScript code that executes on each onSurfaceTextureUpdated: #pragma version(1) #pragma rs java_package_name(foo.camerarealtimefilters) rs_allocation…
Trt Trt
  • 5,330
  • 13
  • 53
  • 86
5
votes
2 answers

Android RenderScript to blur video in VideoView

I know that I can use RenderScript on Android to blur images, but does anybody know if I can apply the same to video views so that my complete video is gaussian blurred?
Florian
  • 2,048
  • 3
  • 28
  • 36