summaryrefslogtreecommitdiffstats
path: root/libs/rs
diff options
context:
space:
mode:
authorMarco Nelissen <marcone@google.com>2009-10-28 15:10:56 -0700
committerMarco Nelissen <marcone@google.com>2009-10-28 15:10:56 -0700
commit911458a081e098b7b289ed7135e1719733d7e12d (patch)
tree041c812e679f09c011fa1933efbdc9b00d317b95 /libs/rs
parentfb872d1af3c775114ac7d241eb1924a9aafbb9df (diff)
downloadframeworks_base-911458a081e098b7b289ed7135e1719733d7e12d.zip
frameworks_base-911458a081e098b7b289ed7135e1719733d7e12d.tar.gz
frameworks_base-911458a081e098b7b289ed7135e1719733d7e12d.tar.bz2
Fix x offset for boxed textures
Diffstat (limited to 'libs/rs')
-rw-r--r--libs/rs/rsAllocation.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/rs/rsAllocation.cpp b/libs/rs/rsAllocation.cpp
index 8ac9c26..b7d1297 100644
--- a/libs/rs/rsAllocation.cpp
+++ b/libs/rs/rsAllocation.cpp
@@ -405,7 +405,7 @@ RsAllocation rsi_AllocationCreateFromBitmapBoxed(Context *rsc, uint32_t w, uint3
const uint8_t * src = static_cast<const uint8_t *>(data);
for (uint32_t y = 0; y < h; y++) {
uint8_t * ydst = &tmp[(y + ((h2 - h) >> 1)) * w2 * bpp];
- memcpy(&ydst[(w2 - w) >> 1], src, w * bpp);
+ memcpy(&ydst[((w2 - w) >> 1) * bpp], src, w * bpp);
src += w * bpp;
}