diff options
author | Duane Sand <duanes@mips.com> | 2012-05-24 22:09:24 -0700 |
---|---|---|
committer | Duane Sand <duanes@mips.com> | 2012-05-30 11:48:53 -0700 |
commit | 068f9f3bf9d09ebca0016cfcbb682d8ca27480f5 (patch) | |
tree | 0f57cb8eee296a653252f14e287d560e410e8140 /libpixelflinger/scanline.cpp | |
parent | a36e1aa3db254d008f220a45899e1d70f4192619 (diff) | |
download | system_core-068f9f3bf9d09ebca0016cfcbb682d8ca27480f5.tar.gz system_core-068f9f3bf9d09ebca0016cfcbb682d8ca27480f5.tar.bz2 system_core-068f9f3bf9d09ebca0016cfcbb682d8ca27480f5.zip |
Add Mips support to libpixelflinger
Change-Id: Ib81cb01b8d90ed1afa1fd54b3cc009d7fec0f814
Diffstat (limited to 'libpixelflinger/scanline.cpp')
-rw-r--r-- | libpixelflinger/scanline.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/libpixelflinger/scanline.cpp b/libpixelflinger/scanline.cpp index 93440f521..d1f3d9677 100644 --- a/libpixelflinger/scanline.cpp +++ b/libpixelflinger/scanline.cpp @@ -110,10 +110,14 @@ static void scanline_clear(context_t* c); static void rect_generic(context_t* c, size_t yc); static void rect_memcpy(context_t* c, size_t yc); +#if defined( __arm__) extern "C" void scanline_t32cb16blend_arm(uint16_t*, uint32_t*, size_t); extern "C" void scanline_t32cb16_arm(uint16_t *dst, uint32_t *src, size_t ct); extern "C" void scanline_col32cb16blend_neon(uint16_t *dst, uint32_t *col, size_t ct); extern "C" void scanline_col32cb16blend_arm(uint16_t *dst, uint32_t col, size_t ct); +#elif defined(__mips__) +extern "C" void scanline_t32cb16blend_mips(uint16_t*, uint32_t*, size_t); +#endif // ---------------------------------------------------------------------------- @@ -2136,7 +2140,7 @@ last_one: void scanline_t32cb16blend(context_t* c) { -#if ((ANDROID_CODEGEN >= ANDROID_CODEGEN_ASM) && defined(__arm__)) +#if ((ANDROID_CODEGEN >= ANDROID_CODEGEN_ASM) && (defined(__arm__) || defined(__mips))) int32_t x = c->iterators.xl; size_t ct = c->iterators.xr - x; int32_t y = c->iterators.y; @@ -2148,8 +2152,12 @@ void scanline_t32cb16blend(context_t* c) const int32_t v = (c->state.texture[0].shade.it0>>16) + y; uint32_t *src = reinterpret_cast<uint32_t*>(tex->data)+(u+(tex->stride*v)); +#ifdef __arm__ scanline_t32cb16blend_arm(dst, src, ct); #else + scanline_t32cb16blend_mips(dst, src, ct); +#endif +#else dst_iterator16 di(c); horz_iterator32 hi(c); blender_32to16 bl(c); |