summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/Script.java
AgeCommit message (Collapse)Author
2017-06-13Do not CloseGuard KernelID or FieldIDYang Ni
Bug: 28053584 Stop CloseGuarding for two reasons: 1) KernelID and FieldID objects are constructed in auto-generated (RenderScript reflected) Java code. It would be impossible for a user to explicitly call destroy() on them. Guarding them would leave a lot of noisy warnings in logcat. 2) These KernelID and FieldID objects are not big compared to other RenderScript objects, e.g. Allocations. They occupy almost no native resources except for a native pointer. Leaving their destruction to Java GC would be completely acceptable, since any delay in reclaiming them is unlikely to cause memory pressure. Test: CTS on x86_64 emulator Change-Id: I587b5561a0b2bdbf0b2e95bf2995c20d5f5faf9d
2016-06-02Delete simple reduction implementation.David Gross
Bug: 27298560 Change-Id: I8a89c9df753d12ee8af06008d424e77bb916cd8f
2016-04-01Merge "Added CloseGuard for BaseObj" into nyc-devYang Ni
2016-03-31Added CloseGuard for BaseObjYang Ni
Bug: 27719830 To turn on warnings, apps have to add to their Activity.onCreate() method the following code. StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder() .detectLeakedClosableObjects() .penaltyLog() .build()); For Slang generated ScriptC derived classes, we assume their constructors won't throw exceptions after calling the ScriptC constructor. In addition, ScriptIntrinsic derived classes do not seem to throw exceptions in their constructors either. Therefore, we can leave the guard.open() call in the Script constructor. This may be only an approximation, but allows us to add CloseGuard for script objects without making changes to slang. Change-Id: I77ed45239a60b85af5c811dee6c124fb53da9060 (cherry picked from commit eb4dd08ec132f83745b8b28fa7da58eb4478b5b9)
2016-03-29[RenderScript] Update the documentation of Script.LaunchOptionsMiao Wang
Bug: 26916665 - Add description of the endArg. - Update the example. - Update the incorrect description. Change-Id: Idd07db5d790e2d6462fff9cb580115ec45cfd4f0
2016-01-25Unhide Script::reduce() interface for general reduction.David Gross
Bug: 23535724 Change-Id: I7a43622954de9f4168f7e4376f39d6ec54191c03
2016-01-15Add general reduction plumbing starting with Java Script::reduce().David Gross
Requires coordinated change in frameworks/rs. Bug: 23535724 Change-Id: I2fee6750cf542948d8fa87a98441002c4d84f36e
2015-07-23am ed3ffe0f: am 6430812a: Merge "RenderScript: implement a Script entry ↵Stephen Hines
point for calling a reduce-style kernel." * commit 'ed3ffe0fc86de016ff2b4231e2fcc74a6119f6c7': RenderScript: implement a Script entry point for calling a reduce-style kernel.
2015-07-21RenderScript: implement a Script entry point for calling aMatt Wala
reduce-style kernel. Bug: 22631253 This adds a new (currently hidden) API to the Script class and the corresponding code for the RenderScript JNI layer. Change-Id: I40f19aaeb90411b859bd6b0bffc3f071fa327c21
2015-05-05Fix Allocation-less launchesJason Sams
Cherry-pick fix from AOSP. Error check for kernel launch was generating a false positive. bug 20690242 Change-Id: Ic4c6644072a11aab9a273070be5734519136f685
2015-05-05Merge "Fix Allocation-less launches"Jason Sams
2015-04-22Move new script group API into ScriptGroup classYang Ni
And mark existing methods and builder deprecated. Removed ScriptGroup2 class. Renamed nested class UnboundValue to Input. Marked classes Closure, Future, and Input as final. Change-Id: I362910c115e9d0173dc515674e08bf4878232879
2015-04-16Fix Allocation-less launchesJason Sams
Change-Id: Ic4c6644072a11aab9a273070be5734519136f685
2015-03-30Update LaunchOptions descriptionJason Sams
Change-Id: I7425c9ea9d82ed54950557e93aa46b69ebc02c23
2015-03-30unhide RS apisJason Sams
Change-Id: I30c3349c9222765ad7850890e0431bc6a6d3757a
2015-03-18Frameworks/base: Fix potential NPE in ScriptAndreas Gampe
Bug: 19797138 Change-Id: I5cd9394bd2c0f7c044c1f2f24665384fa797cd97
2015-03-15Frameworks/base: Check before foreach in ScriptAndreas Gampe
According to the if below, ains == null is potentially valid. But the foreach loop would throw a NullPointerException. Change-Id: I4460fb1357eaa3abfe0ab9a21effb608f474ab51
2015-02-04Adds invocable functions to ScriptGroupYang Ni
This also includes InvokeID support Change-Id: I5b59df166ea30b309b8dd9623825ac0e72d03856
2014-08-18Collapse code paths for single- and multi-input kernels.Chris Wailes
This patch simplifies the RenderScript JNI layer by replacing six functions with a single funciton. This new function now handles all previous cases. Functions in android.renderscript.script have been updated to use this new JNI function. Change-Id: I6cd5448534c38123d51a589339bbeb7e98453e73
2014-08-13Revert "Collapse code paths for single- and multi-input kernels."Stephen Hines
This reverts commit eb3470219dea322efa93eb4b5457813ce71d0c5d. Change-Id: Id943abf953e832ef831318e6699d4b46e9b46201
2014-08-07Collapse code paths for single- and multi-input kernels.Chris Wailes
This patch simplifies the RenderScript JNI layer by replacing six functions with a single funciton. This new function now handles all previous cases. Functions in android.renderscript.script have been updated to use this new JNI function. Change-Id: I77e4b155cc7ca1581b05bf901c70ae53a9ff0b12
2014-07-07Adds support for multi-input kernels to Frameworks/Base/RS.Chris Wailes
* Added a new JNI call to pass arrays of Allocations to the RS runtime. * Added a new version of ForEach that takes an array of Allocations. * Added some casts to disambiguate existing calls to forEach. Change-Id: I46d2834c37075b2a2407fd8b010546818a4540d1
2014-03-05Validate objects are from the correct context.Jason Sams
Change-Id: I7d87b0e253b8d2e36d1aed790cfe3a7dd23e158f
2014-01-31Check that bound allocations are 1DJason Sams
We do not support higher order bound allocations. The stride is not available to the script so they cannot walk the allocation correctly. Change-Id: I9447a5d43c3ae1b88fc9522628a17bd5a317ffc6
2014-01-31Move RenderScript from graphics/ to new fw/base subdirectory rs.Tim Murray
Change-Id: I30b6633578f063840e1bdbcc9ba513b727912a6d