renderscript

Eclipse stops compiling RenderScript file

让人想犯罪 __ 提交于 2019-12-07 07:13:25
问题 I have a single RenderScript (.rs) file in my Android project: SomeScript.rs Which has been working fine as I've been developing it. But then I did a workspace clean inside Eclipse, and now it doesn't seem to be recognizing the file as a RenderScript file. Before, if I had a syntax error, it would notify me about the offending line. But now, no matter what I do to the file, it doesn't get upset. It also doesn't produce the CScript Java wrapper for the script inside /gen. It just errors out

Renderscript suddenly mysteriously gets a lot slower when handling Java for loop and C pointer memory access

岁酱吖の 提交于 2019-12-07 00:08:37
I'm working with Nexus 4 device with Android 4.3. This issue can also be reproduced in Lenovo K900 running Android 4.2.2. The code is NOT running on GPU, just running on CPU since I checked the CPU usage through ADB and it shows the CPU usage was more than 90% in running the program. Before pasting the code, I try to summarize the problem I met. In my project, I'll need to continuously process an image (or images) and store the processed result into another buffer. By the nature of the algorithm I use, I need to parallelize the image processing operation by image rows (process different image

Error when trying to blur image using RenderScript support library on android phone

∥☆過路亽.° 提交于 2019-12-06 15:35:22
I'm trying to blur my image, and display it blurred on an RelativeLayout's background with RenderScript, the app works in the emulator but my app in the phone keeps crashing with this error: 08-05 22:21:36.543: E/RenderScript_jni(11549): No GC methods 08-05 22:21:36.553: D/dalvikvm(11549): No JNI_OnLoad found in /system/lib/libRSSupport.so 0x41803ab8, skipping init 08-05 22:21:36.557: E/dalvikvm(11549): ERROR: couldn't find native method 08-05 22:21:36.557: E/dalvikvm(11549): Requested: Landroid/support/v8/renderscript/RenderScript;._nInit:()V 08-05 22:21:36.558: E/JNIHelp(11549):

Battery Power Consumption between C/Renderscript/Neon Intrinsics — Video filter (Edgedetection) APK

扶醉桌前 提交于 2019-12-06 15:09:50
I have developed 3 C/RS/Neon-Intrinsics versions of Video Processing Algorithm using Android NDK (using C++ APIs for Renderscript). Calls to C/RS/Neon will be made to Native level on NDK side from JAVA front end. I found that for some reason Neon version consumes lot of power in comparison with C and RS versions. I used Trepn 5.0 for my power testing. Can some one clarify me regarding the power consumption level for each of these methods C , Renderscript - GPU, Neon Intrinsics. Which one consumes most ? What would be the Ideal power consumption level for RS codes ?, since GPU runs with less

Renderscript limitation size of array

冷暖自知 提交于 2019-12-06 15:05:30
I'm doing matrix multiplication in Renderscript. I have my java file which prepares all the arrays. In my Renderscript I have global variables which will be set by the java file. But I have seen there is a limitation. If I want to do a multiplication with 37x37 matrix the results still right. If I do a 38x38 matrix multplication the results are no longer correct. After the first row of the final result the calculation results are not correct. I guess there is a limitation. 37*37 = 1369 int vectorcol[1369]; int matrixA[1369]; int matrixB[1369]; I did now a dynamic Array Allocation in Java and

Can't find ScriptC_saturation in BasicRenderScript Sample

℡╲_俬逩灬. 提交于 2019-12-06 08:33:25
问题 I've imported Basic RenderScript Sample project from Android Samples. Android Studio is showing error: cannot find symbol class ScriptC_saturation This is the imports. import android.app.Activity; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.AsyncTask; import android.os.Bundle; import android.widget.ImageView; import android.widget.SeekBar; import android.widget.SeekBar.OnSeekBarChangeListener; import android.support.v8.renderscript.*; I've searched

What are the available kernel-functions that you can create on Renderscript?

江枫思渺然 提交于 2019-12-06 06:31:45
问题 Background I'm learning how to use Renderscript, and I found this part in the docs: In most respects, this is identical to a standard C function. The first notable feature is the attribute ((kernel)) applied to the function prototype. and they show a sample code of a kernel function: uchar4 __attribute__((kernel)) invert(uchar4 in, uint32_t x, uint32_t y) { uchar4 out = in; out.r = 255 - in.r; out.g = 255 - in.g; out.b = 255 - in.b; return out; } The problem It seems that some samples show

Compiling renderscript code at runtime

走远了吗. 提交于 2019-12-06 06:13:37
问题 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 consist of an input and output image, with the possibility for code input. The basic functionality of this app is already working and this is an image of the interface. It would be useful to test renderscript code with direct feedback from the app.

Render script rendering is much slower than OpenGL rendering on Android

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-06 01:29:47
问题 BACKGROUND: I want to add live filter based on the code of Android camera app. But the architecture of Android camera app is based on OpenGL ES 1.x. I need to use shader to custom our filter implementation. However, it is too difficult to update the camera app to OpenGL ES 2.0. Then I have to find some other methods to implement live filter instead of OpenGL. I decided to use render script after some research. PROBLEM: I have wrote a demo of a simple filter by render script. It shows that the

Eclipse stops compiling RenderScript file

烂漫一生 提交于 2019-12-05 15:22:49
I have a single RenderScript (.rs) file in my Android project: SomeScript.rs Which has been working fine as I've been developing it. But then I did a workspace clean inside Eclipse, and now it doesn't seem to be recognizing the file as a RenderScript file. Before, if I had a syntax error, it would notify me about the offending line. But now, no matter what I do to the file, it doesn't get upset. It also doesn't produce the CScript Java wrapper for the script inside /gen. It just errors out with this cryptic message: Error executing Renderscript: Return code 1 line 1 Android AIDL Problem Some