summaryrefslogtreecommitdiffstats
path: root/carousel
diff options
context:
space:
mode:
authorStephen Hines <srhines@google.com>2011-05-02 17:39:42 -0700
committerStephen Hines <srhines@google.com>2011-05-02 17:39:42 -0700
commit55392759e4f1fd3b17799ef8bd75d959dcf3b0a7 (patch)
tree4deafe4b250ac4495937e315464d9435a661e770 /carousel
parentdd570db14b403c59edb96d5c754736a1995cfe17 (diff)
downloadandroid_frameworks_ex-55392759e4f1fd3b17799ef8bd75d959dcf3b0a7.tar.gz
android_frameworks_ex-55392759e4f1fd3b17799ef8bd75d959dcf3b0a7.tar.bz2
android_frameworks_ex-55392759e4f1fd3b17799ef8bd75d959dcf3b0a7.zip
Clean up use of rsSetObject/rsClearObject.
Change-Id: Iee58e5260654883beece74a04fc5f3a2eae329cb
Diffstat (limited to 'carousel')
-rw-r--r--carousel/java/com/android/ex/carousel/carousel.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/carousel/java/com/android/ex/carousel/carousel.rs b/carousel/java/com/android/ex/carousel/carousel.rs
index 003af79..4632031 100644
--- a/carousel/java/com/android/ex/carousel/carousel.rs
+++ b/carousel/java/com/android/ex/carousel/carousel.rs
@@ -311,12 +311,12 @@ static void updateAllocationVars()
{
// Cards
rs_allocation cardAlloc;
- rsSetObject(&cardAlloc, rsGetAllocation(cards));
+ cardAlloc = rsGetAllocation(cards);
cardCount = (cardAllocationValid && rsIsObject(cardAlloc)) ? rsAllocationGetDimX(cardAlloc) : 0;
// Program stores
rs_allocation psAlloc;
- rsSetObject(&psAlloc, rsGetAllocation(programStoresCard));
+ psAlloc = rsGetAllocation(programStoresCard);
programStoresCardCount = (programStoresAllocationValid && rsIsObject(psAlloc) ?
rsAllocationGetDimX(psAlloc) : 0);
}
@@ -489,7 +489,7 @@ static bool textureEverLoaded(int state) {
void setTexture(int n, rs_allocation texture)
{
if (n < 0 || n >= cardCount) return;
- rsSetObject(&cards[n].texture, texture);
+ cards[n].texture = texture;
if (cards[n].textureState != STATE_STALE &&
cards[n].textureState != STATE_UPDATING) {
cards[n].textureTimeStamp = rsUptimeMillis();
@@ -500,7 +500,7 @@ void setTexture(int n, rs_allocation texture)
void setDetailTexture(int n, float offx, float offy, float loffx, float loffy, rs_allocation texture)
{
if (n < 0 || n >= cardCount) return;
- rsSetObject(&cards[n].detailTexture, texture);
+ cards[n].detailTexture = texture;
if (cards[n].detailTextureState != STATE_STALE &&
cards[n].detailTextureState != STATE_UPDATING) {
cards[n].detailTextureTimeStamp = rsUptimeMillis();
@@ -539,7 +539,7 @@ void invalidateDetailTexture(int n, bool eraseCurrent)
void setGeometry(int n, rs_mesh geometry)
{
if (n < 0 || n >= cardCount) return;
- rsSetObject(&cards[n].geometry, geometry);
+ cards[n].geometry = geometry;
if (cards[n].geometry.p != 0)
cards[n].geometryState = STATE_LOADED;
else
@@ -554,7 +554,7 @@ void setMatrix(int n, rs_matrix4x4 matrix) {
void setProgramStoresCard(int n, rs_program_store programStore)
{
- rsSetObject(&programStoresCard[n].programStore, programStore);
+ programStoresCard[n].programStore = programStore;
programStoresAllocationValid = true;
}