diff options
Diffstat (limited to 'tests/RenderScriptTests/SceneGraph')
-rw-r--r-- | tests/RenderScriptTests/SceneGraph/src/com/android/scenegraph/render.rs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/RenderScriptTests/SceneGraph/src/com/android/scenegraph/render.rs b/tests/RenderScriptTests/SceneGraph/src/com/android/scenegraph/render.rs index 4b85d72..8187fbc 100644 --- a/tests/RenderScriptTests/SceneGraph/src/com/android/scenegraph/render.rs +++ b/tests/RenderScriptTests/SceneGraph/src/com/android/scenegraph/render.rs @@ -150,8 +150,14 @@ static void sortToBucket(SgRenderable *obj) { } const SgRenderState *renderState = (const SgRenderState *)rsGetElementAt(obj->render_state, 0); if (rsIsObject(renderState->ps)) { - if ((rsgProgramStoreGetBlendSrcFunc(renderState->ps) == RS_BLEND_SRC_ONE) && - (rsgProgramStoreGetBlendDstFunc(renderState->ps) == RS_BLEND_DST_ZERO)) { +#define MR1_API +#ifndef MR1_API + bool isOpaque = (rsgProgramStoreGetBlendSrcFunc(renderState->ps) == RS_BLEND_SRC_ONE) && + (rsgProgramStoreGetBlendDstFunc(renderState->ps) == RS_BLEND_DST_ZERO); +#else + bool isOpaque = false; +#endif + if (isOpaque) { gFrontToBack[gFrontToBackCount++] = (uint32_t)obj; } else { gBackToFront[gBackToFrontCount++] = (uint32_t)obj; |