Merge "GridView attribute updates"
diff --git a/docs/html/sdk/eclipse-adt.jd b/docs/html/sdk/eclipse-adt.jd
index c8bf12d..3019544 100644
--- a/docs/html/sdk/eclipse-adt.jd
+++ b/docs/html/sdk/eclipse-adt.jd
@@ -135,7 +135,9 @@
<li>Added feature to automatically setup JAR dependencies. Any {@code .jar} files in the
{@code /libs} folder are added to the build configuration (similar to how the Ant build
system works). Also, {@code .jar} files needed by library projects are also automatically
- added to projects that depend on those library projects.</li>
+ added to projects that depend on those library projects.
+ (<a href="http://tools.android.com/recent/dealingwithdependenciesinandroidprojects">more
+ info</a>)</li>
<li>Added a feature that allows you to run some code only in debug mode. Builds now
generate a class called {@code BuildConfig} containing a {@code DEBUG} constant that is
automatically set according to your build type. You can check the ({@code BuildConfig.DEBUG})
diff --git a/docs/html/sdk/tools-notes.jd b/docs/html/sdk/tools-notes.jd
index bbbca81..dea0c38 100644
--- a/docs/html/sdk/tools-notes.jd
+++ b/docs/html/sdk/tools-notes.jd
@@ -128,7 +128,8 @@
automatically set according to your build type. You can check the ({@code BuildConfig.DEBUG})
constant in your code to run debug-only functions.</li>
<li>Fixed issue when a project and its libraries include the same jar file in their libs
- folder.</li>
+ folder. (<a href="http://tools.android.com/recent/dealingwithdependenciesinandroidprojects">more
+ info</a>)</li>
<li>Added support for custom views with custom attributes in libraries. Layouts using
custom attributes must use the namespace URI {@code http://schemas.android.com/apk/res-auto} instead
of the URI that includes the app package name. This URI is replaced with the app specific one at
diff --git a/include/media/stagefright/MetaData.h b/include/media/stagefright/MetaData.h
index 00b8679..c3ccb56 100644
--- a/include/media/stagefright/MetaData.h
+++ b/include/media/stagefright/MetaData.h
@@ -24,6 +24,7 @@
#include <utils/RefBase.h>
#include <utils/KeyedVector.h>
+#include <utils/String8.h>
namespace android {
@@ -180,6 +181,8 @@
bool findData(uint32_t key, uint32_t *type,
const void **data, size_t *size) const;
+ void dumpToLog() const;
+
protected:
virtual ~MetaData();
@@ -194,6 +197,7 @@
void clear();
void setData(uint32_t type, const void *data, size_t size);
void getData(uint32_t *type, const void **data, size_t *size) const;
+ String8 asString() const;
private:
uint32_t mType;
diff --git a/libs/rs/scriptc/rs_graphics.rsh b/libs/rs/scriptc/rs_graphics.rsh
index e3fde828..80491ee 100644
--- a/libs/rs/scriptc/rs_graphics.rsh
+++ b/libs/rs/scriptc/rs_graphics.rsh
@@ -83,88 +83,6 @@
extern void __attribute__((overloadable))
rsgBindProgramStore(rs_program_store ps);
-
-/**
- * @hide
- * Get program store depth function
- *
- * @param ps
- */
-extern rs_depth_func __attribute__((overloadable))
- rsgProgramStoreGetDepthFunc(rs_program_store ps);
-
-/**
- * @hide
- * Get program store depth mask
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetDepthMask(rs_program_store ps);
-/**
- * @hide
- * Get program store red component color mask
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetColorMaskR(rs_program_store ps);
-
-/**
- * @hide
- * Get program store green component color mask
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetColorMaskG(rs_program_store ps);
-
-/**
- * @hide
- * Get program store blur component color mask
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetColorMaskB(rs_program_store ps);
-
-/**
- * @hide
- * Get program store alpha component color mask
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetColorMaskA(rs_program_store ps);
-
-/**
- * @hide
- * Get program store blend source function
- *
- * @param ps
- */
-extern rs_blend_src_func __attribute__((overloadable))
- rsgProgramStoreGetBlendSrcFunc(rs_program_store ps);
-
-/**
- * @hide
- * Get program store blend destination function
- *
- * @param ps
- */
-extern rs_blend_dst_func __attribute__((overloadable))
- rsgProgramStoreGetBlendDstFunc(rs_program_store ps);
-
-/**
- * @hide
- * Get program store dither state
- *
- * @param ps
- */
-extern bool __attribute__((overloadable))
- rsgProgramStoreGetDitherEnabled(rs_program_store ps);
-
-
/**
* Bind a new ProgramVertex to the rendering context.
*
@@ -182,24 +100,6 @@
rsgBindProgramRaster(rs_program_raster pr);
/**
- * @hide
- * Get program raster point sprite state
- *
- * @param pr
- */
-extern bool __attribute__((overloadable))
- rsgProgramRasterGetPointSpriteEnabled(rs_program_raster pr);
-
-/**
- * @hide
- * Get program raster cull mode
- *
- * @param pr
- */
-extern rs_cull_mode __attribute__((overloadable))
- rsgProgramRasterGetCullMode(rs_program_raster pr);
-
-/**
* Bind a new Sampler object to a ProgramFragment. The sampler will
* operate on the texture bound at the matching slot.
*
@@ -209,51 +109,6 @@
rsgBindSampler(rs_program_fragment, uint slot, rs_sampler);
/**
- * @hide
- * Get sampler minification value
- *
- * @param pr
- */
-extern rs_sampler_value __attribute__((overloadable))
- rsgSamplerGetMinification(rs_sampler s);
-
-/**
- * @hide
- * Get sampler magnification value
- *
- * @param pr
- */
-extern rs_sampler_value __attribute__((overloadable))
- rsgSamplerGetMagnification(rs_sampler s);
-
-/**
- * @hide
- * Get sampler wrap S value
- *
- * @param pr
- */
-extern rs_sampler_value __attribute__((overloadable))
- rsgSamplerGetWrapS(rs_sampler s);
-
-/**
- * @hide
- * Get sampler wrap T value
- *
- * @param pr
- */
-extern rs_sampler_value __attribute__((overloadable))
- rsgSamplerGetWrapT(rs_sampler s);
-
-/**
- * @hide
- * Get sampler anisotropy
- *
- * @param pr
- */
-extern float __attribute__((overloadable))
- rsgSamplerGetAnisotropy(rs_sampler s);
-
-/**
* Bind a new Allocation object to a ProgramFragment. The
* Allocation must be a valid texture for the Program. The sampling
* of the texture will be controled by the Sampler bound at the
diff --git a/media/libstagefright/MetaData.cpp b/media/libstagefright/MetaData.cpp
index 66dec90..755594a 100644
--- a/media/libstagefright/MetaData.cpp
+++ b/media/libstagefright/MetaData.cpp
@@ -14,6 +14,10 @@
* limitations under the License.
*/
+//#define LOG_NDEBUG 0
+#define LOG_TAG "MetaData"
+#include <utils/Log.h>
+
#include <stdlib.h>
#include <string.h>
@@ -282,5 +286,60 @@
mSize = 0;
}
+String8 MetaData::typed_data::asString() const {
+ String8 out;
+ const void *data = storage();
+ switch(mType) {
+ case TYPE_NONE:
+ out = String8::format("no type, size %d)", mSize);
+ break;
+ case TYPE_C_STRING:
+ out = String8::format("(char*) %s", (const char *)data);
+ break;
+ case TYPE_INT32:
+ out = String8::format("(int32_t) %d", *(int32_t *)data);
+ break;
+ case TYPE_INT64:
+ out = String8::format("(int64_t) %lld", *(int64_t *)data);
+ break;
+ case TYPE_FLOAT:
+ out = String8::format("(float) %f", *(float *)data);
+ break;
+ case TYPE_POINTER:
+ out = String8::format("(void*) %p", *(void **)data);
+ break;
+ case TYPE_RECT:
+ {
+ const Rect *r = (const Rect *)data;
+ out = String8::format("Rect(%d, %d, %d, %d)",
+ r->mLeft, r->mTop, r->mRight, r->mBottom);
+ break;
+ }
+
+ default:
+ out = String8::format("(unknown type %d, size %d)", mType, mSize);
+ break;
+ }
+ return out;
+}
+
+static void MakeFourCCString(uint32_t x, char *s) {
+ s[0] = x >> 24;
+ s[1] = (x >> 16) & 0xff;
+ s[2] = (x >> 8) & 0xff;
+ s[3] = x & 0xff;
+ s[4] = '\0';
+}
+
+void MetaData::dumpToLog() const {
+ for (int i = mItems.size(); --i >= 0;) {
+ int32_t key = mItems.keyAt(i);
+ char cc[5];
+ MakeFourCCString(key, cc);
+ const typed_data &item = mItems.valueAt(i);
+ ALOGI("%s: %s", cc, item.asString().string());
+ }
+}
+
} // namespace android
diff --git a/tests/RenderScriptTests/tests/src/com/android/rs/test/program_raster.rs b/tests/RenderScriptTests/tests/src/com/android/rs/test/program_raster.rs
index 11b8c30..0eaca4a 100644
--- a/tests/RenderScriptTests/tests/src/com/android/rs/test/program_raster.rs
+++ b/tests/RenderScriptTests/tests/src/com/android/rs/test/program_raster.rs
@@ -7,11 +7,11 @@
static bool test_program_raster_getters() {
bool failed = false;
- _RS_ASSERT(rsgProgramRasterGetPointSpriteEnabled(pointSpriteEnabled) == true);
- _RS_ASSERT(rsgProgramRasterGetCullMode(pointSpriteEnabled) == RS_CULL_BACK);
+ _RS_ASSERT(rsProgramRasterGetPointSpriteEnabled(pointSpriteEnabled) == true);
+ _RS_ASSERT(rsProgramRasterGetCullMode(pointSpriteEnabled) == RS_CULL_BACK);
- _RS_ASSERT(rsgProgramRasterGetPointSpriteEnabled(cullMode) == false);
- _RS_ASSERT(rsgProgramRasterGetCullMode(cullMode) == RS_CULL_FRONT);
+ _RS_ASSERT(rsProgramRasterGetPointSpriteEnabled(cullMode) == false);
+ _RS_ASSERT(rsProgramRasterGetCullMode(cullMode) == RS_CULL_FRONT);
if (failed) {
rsDebug("test_program_raster_getters FAILED", 0);
diff --git a/tests/RenderScriptTests/tests/src/com/android/rs/test/program_store.rs b/tests/RenderScriptTests/tests/src/com/android/rs/test/program_store.rs
index 3cd8a20..7b47408 100644
--- a/tests/RenderScriptTests/tests/src/com/android/rs/test/program_store.rs
+++ b/tests/RenderScriptTests/tests/src/com/android/rs/test/program_store.rs
@@ -14,95 +14,95 @@
static bool test_program_store_getters() {
bool failed = false;
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(depthFunc) == RS_DEPTH_FUNC_GREATER);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(depthFunc) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(depthFunc) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(depthFunc) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(depthFunc) == RS_DEPTH_FUNC_GREATER);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(depthFunc) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(depthFunc) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(depthFunc) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(depthWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(depthWriteEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(depthWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(depthWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(depthWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(depthWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(depthWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(depthWriteEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(depthWriteEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(depthWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(depthWriteEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(depthWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(depthWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(depthWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(depthWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(depthWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(depthWriteEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(depthWriteEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(colorRWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(colorRWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(colorRWriteEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(colorRWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(colorRWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(colorRWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(colorRWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(colorRWriteEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(colorRWriteEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(colorRWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(colorRWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(colorRWriteEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(colorRWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(colorRWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(colorRWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(colorRWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(colorRWriteEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(colorRWriteEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(colorGWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(colorGWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(colorGWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(colorGWriteEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(colorGWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(colorGWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(colorGWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(colorGWriteEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(colorGWriteEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(colorGWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(colorGWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(colorGWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(colorGWriteEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(colorGWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(colorGWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(colorGWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(colorGWriteEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(colorGWriteEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(colorBWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(colorBWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(colorBWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(colorBWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(colorBWriteEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(colorBWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(colorBWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(colorBWriteEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(colorBWriteEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(colorBWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(colorBWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(colorBWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(colorBWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(colorBWriteEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(colorBWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(colorBWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(colorBWriteEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(colorBWriteEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(colorAWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(colorAWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(colorAWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(colorAWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(colorAWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(colorAWriteEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(colorAWriteEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(colorAWriteEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(colorAWriteEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(colorAWriteEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(colorAWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(colorAWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(colorAWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(colorAWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(colorAWriteEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(colorAWriteEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(colorAWriteEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(colorAWriteEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(ditherEnable) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(ditherEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(ditherEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(ditherEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(ditherEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(ditherEnable) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(ditherEnable) == true);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(ditherEnable) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(ditherEnable) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(ditherEnable) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(ditherEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(ditherEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(ditherEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(ditherEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(ditherEnable) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(ditherEnable) == true);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(ditherEnable) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(ditherEnable) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(blendSrc) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(blendSrc) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(blendSrc) == RS_BLEND_SRC_DST_COLOR);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(blendSrc) == RS_BLEND_DST_ZERO);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(blendSrc) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(blendSrc) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(blendSrc) == RS_BLEND_SRC_DST_COLOR);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(blendSrc) == RS_BLEND_DST_ZERO);
- _RS_ASSERT(rsgProgramStoreGetDepthFunc(blendDst) == RS_DEPTH_FUNC_ALWAYS);
- _RS_ASSERT(rsgProgramStoreGetDepthMask(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskR(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskG(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskB(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetColorMaskA(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetDitherEnabled(blendDst) == false);
- _RS_ASSERT(rsgProgramStoreGetBlendSrcFunc(blendDst) == RS_BLEND_SRC_ZERO);
- _RS_ASSERT(rsgProgramStoreGetBlendDstFunc(blendDst) == RS_BLEND_DST_DST_ALPHA);
+ _RS_ASSERT(rsProgramStoreGetDepthFunc(blendDst) == RS_DEPTH_FUNC_ALWAYS);
+ _RS_ASSERT(rsProgramStoreGetDepthMask(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskR(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskG(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskB(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetColorMaskA(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetDitherEnabled(blendDst) == false);
+ _RS_ASSERT(rsProgramStoreGetBlendSrcFunc(blendDst) == RS_BLEND_SRC_ZERO);
+ _RS_ASSERT(rsProgramStoreGetBlendDstFunc(blendDst) == RS_BLEND_DST_DST_ALPHA);
if (failed) {
rsDebug("test_program_store_getters FAILED", 0);
diff --git a/tests/RenderScriptTests/tests/src/com/android/rs/test/sampler.rs b/tests/RenderScriptTests/tests/src/com/android/rs/test/sampler.rs
index ac9a549..ff1c0a7 100644
--- a/tests/RenderScriptTests/tests/src/com/android/rs/test/sampler.rs
+++ b/tests/RenderScriptTests/tests/src/com/android/rs/test/sampler.rs
@@ -9,35 +9,35 @@
static bool test_sampler_getters() {
bool failed = false;
- _RS_ASSERT(rsgSamplerGetMagnification(minification) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetMinification(minification) == RS_SAMPLER_LINEAR_MIP_LINEAR);
- _RS_ASSERT(rsgSamplerGetWrapS(minification) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetWrapT(minification) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetAnisotropy(minification) == 1.0f);
+ _RS_ASSERT(rsSamplerGetMagnification(minification) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetMinification(minification) == RS_SAMPLER_LINEAR_MIP_LINEAR);
+ _RS_ASSERT(rsSamplerGetWrapS(minification) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetWrapT(minification) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetAnisotropy(minification) == 1.0f);
- _RS_ASSERT(rsgSamplerGetMagnification(magnification) == RS_SAMPLER_LINEAR);
- _RS_ASSERT(rsgSamplerGetMinification(magnification) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetWrapS(magnification) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetWrapT(magnification) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetAnisotropy(magnification) == 1.0f);
+ _RS_ASSERT(rsSamplerGetMagnification(magnification) == RS_SAMPLER_LINEAR);
+ _RS_ASSERT(rsSamplerGetMinification(magnification) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetWrapS(magnification) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetWrapT(magnification) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetAnisotropy(magnification) == 1.0f);
- _RS_ASSERT(rsgSamplerGetMagnification(wrapS) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetMinification(wrapS) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetWrapS(wrapS) == RS_SAMPLER_WRAP);
- _RS_ASSERT(rsgSamplerGetWrapT(wrapS) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetAnisotropy(wrapS) == 1.0f);
+ _RS_ASSERT(rsSamplerGetMagnification(wrapS) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetMinification(wrapS) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetWrapS(wrapS) == RS_SAMPLER_WRAP);
+ _RS_ASSERT(rsSamplerGetWrapT(wrapS) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetAnisotropy(wrapS) == 1.0f);
- _RS_ASSERT(rsgSamplerGetMagnification(wrapT) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetMinification(wrapT) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetWrapS(wrapT) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetWrapT(wrapT) == RS_SAMPLER_WRAP);
- _RS_ASSERT(rsgSamplerGetAnisotropy(wrapT) == 1.0f);
+ _RS_ASSERT(rsSamplerGetMagnification(wrapT) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetMinification(wrapT) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetWrapS(wrapT) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetWrapT(wrapT) == RS_SAMPLER_WRAP);
+ _RS_ASSERT(rsSamplerGetAnisotropy(wrapT) == 1.0f);
- _RS_ASSERT(rsgSamplerGetMagnification(anisotropy) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetMinification(anisotropy) == RS_SAMPLER_NEAREST);
- _RS_ASSERT(rsgSamplerGetWrapS(anisotropy) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetWrapT(anisotropy) == RS_SAMPLER_CLAMP);
- _RS_ASSERT(rsgSamplerGetAnisotropy(anisotropy) == 8.0f);
+ _RS_ASSERT(rsSamplerGetMagnification(anisotropy) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetMinification(anisotropy) == RS_SAMPLER_NEAREST);
+ _RS_ASSERT(rsSamplerGetWrapS(anisotropy) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetWrapT(anisotropy) == RS_SAMPLER_CLAMP);
+ _RS_ASSERT(rsSamplerGetAnisotropy(anisotropy) == 8.0f);
if (failed) {
rsDebug("test_sampler_getters FAILED", 0);