Merge "Fix issues with reentrant SQLite triggers."
diff --git a/api/current.txt b/api/current.txt
index 971db1d..ab2ef54 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -17657,7 +17657,8 @@
 
   public static class UserDictionary.Words implements android.provider.BaseColumns {
     ctor public UserDictionary.Words();
-    method public static void addWord(android.content.Context, java.lang.String, int, int);
+    method public static deprecated void addWord(android.content.Context, java.lang.String, int, int);
+    method public static void addWord(android.content.Context, java.lang.String, int, java.lang.String, java.util.Locale);
     field public static final java.lang.String APP_ID = "appid";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.google.userword";
     field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/vnd.google.userword";
@@ -17665,8 +17666,9 @@
     field public static final java.lang.String DEFAULT_SORT_ORDER = "frequency DESC";
     field public static final java.lang.String FREQUENCY = "frequency";
     field public static final java.lang.String LOCALE = "locale";
-    field public static final int LOCALE_TYPE_ALL = 0; // 0x0
-    field public static final int LOCALE_TYPE_CURRENT = 1; // 0x1
+    field public static final deprecated int LOCALE_TYPE_ALL = 0; // 0x0
+    field public static final deprecated int LOCALE_TYPE_CURRENT = 1; // 0x1
+    field public static final java.lang.String SHORTCUT = "shortcut";
     field public static final java.lang.String WORD = "word";
     field public static final java.lang.String _ID = "_id";
   }
@@ -24619,6 +24621,7 @@
     field public static final int IME_ACTION_SEARCH = 3; // 0x3
     field public static final int IME_ACTION_SEND = 4; // 0x4
     field public static final int IME_ACTION_UNSPECIFIED = 0; // 0x0
+    field public static final int IME_FLAG_FORCE_ASCII = -2147483648; // 0x80000000
     field public static final int IME_FLAG_NAVIGATE_NEXT = 134217728; // 0x8000000
     field public static final int IME_FLAG_NAVIGATE_PREVIOUS = 67108864; // 0x4000000
     field public static final int IME_FLAG_NO_ACCESSORY_ACTION = 536870912; // 0x20000000
diff --git a/cmds/requestsync/Android.mk b/cmds/requestsync/Android.mk
new file mode 100644
index 0000000..fe2ffd8
--- /dev/null
+++ b/cmds/requestsync/Android.mk
@@ -0,0 +1,16 @@
+# Copyright 2012 The Android Open Source Project
+#
+LOCAL_PATH:= $(call my-dir)
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES := $(call all-subdir-java-files)
+LOCAL_MODULE := requestsync
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_JAVA_LIBRARY)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := requestsync
+LOCAL_SRC_FILES := requestsync
+LOCAL_MODULE_CLASS := EXECUTABLES
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_PREBUILT)
diff --git a/cmds/requestsync/MODULE_LICENSE_APACHE2 b/cmds/requestsync/MODULE_LICENSE_APACHE2
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/cmds/requestsync/MODULE_LICENSE_APACHE2
diff --git a/cmds/requestsync/NOTICE b/cmds/requestsync/NOTICE
new file mode 100644
index 0000000..c5b1efa
--- /dev/null
+++ b/cmds/requestsync/NOTICE
@@ -0,0 +1,190 @@
+
+   Copyright (c) 2005-2008, The Android Open Source Project
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
diff --git a/cmds/requestsync/requestsync b/cmds/requestsync/requestsync
new file mode 100755
index 0000000..9315675
--- /dev/null
+++ b/cmds/requestsync/requestsync
@@ -0,0 +1,6 @@
+# Script to start "requestsync" on the device
+#
+base=/system
+export CLASSPATH=$base/framework/requestsync.jar
+exec app_process $base/bin com.android.commands.requestsync.RequestSync "$@"
+
diff --git a/cmds/requestsync/src/com/android/commands/requestsync/RequestSync.java b/cmds/requestsync/src/com/android/commands/requestsync/RequestSync.java
new file mode 100644
index 0000000..808618f
--- /dev/null
+++ b/cmds/requestsync/src/com/android/commands/requestsync/RequestSync.java
@@ -0,0 +1,237 @@
+/*
+**
+** Copyright 2012, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+**     http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+
+package com.android.commands.requestsync;
+
+import android.accounts.Account;
+import android.content.ContentResolver;
+import android.os.Bundle;
+
+import java.net.URISyntaxException;
+
+public class RequestSync {
+    // agr parsing fields
+    private String[] mArgs;
+    private int mNextArg;
+    private String mCurArgData;
+
+    // account & authority
+    private String mAccountName = null;
+    private String mAccountType = null;
+    private String mAuthority = null;
+
+    // extras
+    private Bundle mExtras = new Bundle();
+
+    /**
+     * Command-line entry point.
+     *
+     * @param args The command-line arguments
+     */
+    public static void main(String[] args) {
+        try {
+            (new RequestSync()).run(args);
+        } catch (IllegalArgumentException e) {
+            showUsage();
+            System.err.println("Error: " + e);
+            e.printStackTrace();
+        } catch (Exception e) {
+            e.printStackTrace(System.err);
+            System.exit(1);
+        }
+    }
+
+    private void run(String[] args) throws Exception {
+        mArgs = args;
+        mNextArg = 0;
+
+        final boolean ok = parseArgs();
+        if (ok) {
+            final Account account = mAccountName != null && mAccountType != null
+                    ? new Account(mAccountName, mAccountType) : null;
+
+            System.out.printf("Requesting sync for: \n");
+            if (account != null) {
+                System.out.printf("  Account: %s (%s)\n", account.name, account.type);
+            } else {
+                System.out.printf("  Account: all\n");
+            }
+
+            System.out.printf("  Authority: %s\n", mAuthority != null ? mAuthority : "All");
+
+            if (mExtras.size() > 0) {
+                System.out.printf("  Extras:\n");
+                for (String key : mExtras.keySet()) {
+                    System.out.printf("    %s: %s\n", key, mExtras.get(key));
+                }
+            }
+
+            ContentResolver.requestSync(account, mAuthority, mExtras);
+        }
+    }
+
+    private boolean parseArgs() throws URISyntaxException {
+        String opt;
+        while ((opt=nextOption()) != null) {
+            if (opt.equals("-h") || opt.equals("--help")) {
+                showUsage();
+                return false;
+            } else if (opt.equals("-n") || opt.equals("--account-name")) {
+                mAccountName = nextArgRequired();
+            } else if (opt.equals("-t") || opt.equals("--account-type")) {
+                mAccountType = nextArgRequired();
+            } else if (opt.equals("-a") || opt.equals("--authority")) {
+                mAuthority = nextArgRequired();
+            } else if (opt.equals("--is") || opt.equals("--ignore-settings")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_IGNORE_SETTINGS, true);
+            } else if (opt.equals("--ib") || opt.equals("--ignore-backoff")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_IGNORE_BACKOFF, true);
+            } else if (opt.equals("--dd") || opt.equals("--discard-deletions")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_DISCARD_LOCAL_DELETIONS, true);
+            } else if (opt.equals("--nr") || opt.equals("--no-retry")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_DO_NOT_RETRY, true);
+            } else if (opt.equals("--ex") || opt.equals("--expedited")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_EXPEDITED, true);
+            } else if (opt.equals("-i") || opt.equals("--initialize")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_INITIALIZE, true);
+            } else if (opt.equals("-m") || opt.equals("--manual")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
+            } else if (opt.equals("--od") || opt.equals("--override-deletions")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_OVERRIDE_TOO_MANY_DELETIONS, true);
+            } else if (opt.equals("-u") || opt.equals("--upload-only")) {
+                mExtras.putBoolean(ContentResolver.SYNC_EXTRAS_UPLOAD, true);
+            } else if (opt.equals("-e") || opt.equals("--es") || opt.equals("--extra-string")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putString(key, value);
+            } else if (opt.equals("--esn") || opt.equals("--extra-string-null")) {
+                final String key = nextArgRequired();
+                mExtras.putString(key, null);
+            } else if (opt.equals("--ei") || opt.equals("--extra-int")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putInt(key, Integer.valueOf(value));
+            } else if (opt.equals("--el") || opt.equals("--extra-long")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putLong(key, Long.valueOf(value));
+            } else if (opt.equals("--ef") || opt.equals("--extra-float")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putFloat(key, Long.valueOf(value));
+            } else if (opt.equals("--ed") || opt.equals("--extra-double")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putFloat(key, Long.valueOf(value));
+            } else if (opt.equals("--ez") || opt.equals("--extra-bool")) {
+                final String key = nextArgRequired();
+                final String value = nextArgRequired();
+                mExtras.putBoolean(key, Boolean.valueOf(value));
+            } else {
+                System.err.println("Error: Unknown option: " + opt);
+                showUsage();
+                return false;
+            }
+        }
+
+        if (mNextArg < mArgs.length) {
+            showUsage();
+            return false;
+        }
+        return true;
+    }
+
+    private String nextOption() {
+        if (mCurArgData != null) {
+            String prev = mArgs[mNextArg - 1];
+            throw new IllegalArgumentException("No argument expected after \"" + prev + "\"");
+        }
+        if (mNextArg >= mArgs.length) {
+            return null;
+        }
+        String arg = mArgs[mNextArg];
+        if (!arg.startsWith("-")) {
+            return null;
+        }
+        mNextArg++;
+        if (arg.equals("--")) {
+            return null;
+        }
+        if (arg.length() > 1 && arg.charAt(1) != '-') {
+            if (arg.length() > 2) {
+                mCurArgData = arg.substring(2);
+                return arg.substring(0, 2);
+            } else {
+                mCurArgData = null;
+                return arg;
+            }
+        }
+        mCurArgData = null;
+        return arg;
+    }
+
+    private String nextArg() {
+        if (mCurArgData != null) {
+            String arg = mCurArgData;
+            mCurArgData = null;
+            return arg;
+        } else if (mNextArg < mArgs.length) {
+            return mArgs[mNextArg++];
+        } else {
+            return null;
+        }
+    }
+
+    private String nextArgRequired() {
+        String arg = nextArg();
+        if (arg == null) {
+            String prev = mArgs[mNextArg - 1];
+            throw new IllegalArgumentException("Argument expected after \"" + prev + "\"");
+        }
+        return arg;
+    }
+
+    private static void showUsage() {
+        System.err.println(
+                "usage: requestsync [options]\n" +
+                "With no options, a sync will be requested for all account and all sync\n" +
+                "authorities with no extras. Options can be:\n" +
+                "    -h|--help: Display this message\n" +
+                "    -n|--account-name <ACCOUNT-NAME>\n" +
+                "    -t|--account-type <ACCOUNT-TYPE>\n" +
+                "    -a|--authority <AUTHORITY>\n" +
+                "  Add ContentResolver extras:\n" +
+                "    --is|--ignore-settings: Add SYNC_EXTRAS_IGNORE_SETTINGS\n" +
+                "    --ib|--ignore-backoff: Add SYNC_EXTRAS_IGNORE_BACKOFF\n" +
+                "    --dd|--discard-deletions: Add SYNC_EXTRAS_DISCARD_LOCAL_DELETIONS\n" +
+                "    --nr|--no-retry: Add SYNC_EXTRAS_DO_NOT_RETRY\n" +
+                "    --ex|--expedited: Add SYNC_EXTRAS_EXPEDITED\n" +
+                "    --i|--initialize: Add SYNC_EXTRAS_INITIALIZE\n" +
+                "    --m|--manual: Add SYNC_EXTRAS_MANUAL\n" +
+                "    --od|--override-deletions: Add SYNC_EXTRAS_OVERRIDE_TOO_MANY_DELETIONS\n" +
+                "    --u|--upload-only: Add SYNC_EXTRAS_UPLOAD\n" +
+                "  Add custom extras:\n" +
+                "    -e|--es|--extra-string <KEY> <VALUE>\n" +
+                "    --esn|--extra-string-null <KEY>\n" +
+                "    --ei|--extra-int <KEY> <VALUE>\n" +
+                "    --el|--extra-long <KEY> <VALUE>\n" +
+                "    --ef|--extra-float <KEY> <VALUE>\n" +
+                "    --ed|--extra-double <KEY> <VALUE>\n" +
+                "    --ez|--extra-bool <KEY> <VALUE>\n"
+                );
+    }
+}
diff --git a/core/java/android/app/Notification.java b/core/java/android/app/Notification.java
index f5add25..d569e20 100644
--- a/core/java/android/app/Notification.java
+++ b/core/java/android/app/Notification.java
@@ -113,7 +113,10 @@
      * {@link android.content.Intent#FLAG_ACTIVITY_NEW_TASK} flag, which requires
      * that you take care of task management as described in the
      * <a href="{@docRoot}guide/topics/fundamentals/tasks-and-back-stack.html">Tasks and Back
-     * Stack</a> document.
+     * Stack</a> document.  In particular, make sure to read the notification section
+     * <a href="{@docRoot}guide/topics/ui/notifiers/notifications.html#HandlingNotifications">Handling
+     * Notifications</a> for the correct ways to launch an application from a
+     * notification.
      */
     public PendingIntent contentIntent;
 
@@ -765,7 +768,9 @@
          * Supply a {@link PendingIntent} to send when the notification is clicked.
          * If you do not supply an intent, you can now add PendingIntents to individual
          * views to be launched when clicked by calling {@link RemoteViews#setOnClickPendingIntent
-         * RemoteViews.setOnClickPendingIntent(int,PendingIntent)}.
+         * RemoteViews.setOnClickPendingIntent(int,PendingIntent)}.  Be sure to
+         * read {@link Notification#contentIntent Notification.contentIntent} for
+         * how to correctly use this.
          */
         public Builder setContentIntent(PendingIntent intent) {
             mContentIntent = intent;
diff --git a/core/java/android/content/SyncManager.java b/core/java/android/content/SyncManager.java
index 3c4e545..ba24036 100644
--- a/core/java/android/content/SyncManager.java
+++ b/core/java/android/content/SyncManager.java
@@ -1034,6 +1034,7 @@
 
     protected void dumpSyncState(PrintWriter pw) {
         pw.print("data connected: "); pw.println(mDataConnectionIsConnected);
+        pw.print("auto sync: "); pw.println(mSyncStorageEngine.getMasterSyncAutomatically());
         pw.print("memory low: "); pw.println(mStorageIsLow);
 
         final Account[] accounts = mAccounts;
@@ -1272,57 +1273,17 @@
 
             }
 
-            pw.println();
-            pw.printf("Detailed Statistics (Recent history):  %d (# of times) %ds (sync time)\n",
-                    totalTimes, totalElapsedTime / 1000);
+            if (totalElapsedTime > 0) {
+                pw.println();
+                pw.printf("Detailed Statistics (Recent history):  "
+                        + "%d (# of times) %ds (sync time)\n",
+                        totalTimes, totalElapsedTime / 1000);
 
-            final List<AuthoritySyncStats> sortedAuthorities =
-                    new ArrayList<AuthoritySyncStats>(authorityMap.values());
-            Collections.sort(sortedAuthorities, new Comparator<AuthoritySyncStats>() {
-                @Override
-                public int compare(AuthoritySyncStats lhs, AuthoritySyncStats rhs) {
-                    // reverse order
-                    int compare = Integer.compare(rhs.times, lhs.times);
-                    if (compare == 0) {
-                        compare = Long.compare(rhs.elapsedTime, lhs.elapsedTime);
-                    }
-                    return compare;
-                }
-            });
-
-            final int maxLength = Math.max(maxAuthority, maxAccount + 3);
-            final int padLength = 2 + 2 + maxLength + 2 + 10 + 11;
-            final char chars[] = new char[padLength];
-            Arrays.fill(chars, '-');
-            final String separator = new String(chars);
-
-            final String authorityFormat = String.format("  %%-%ds: %%-9s  %%-11s\n", maxLength + 2);
-            final String accountFormat = String.format("    %%-%ds:   %%-9s  %%-11s\n", maxLength);
-
-            pw.println(separator);
-            for (AuthoritySyncStats authoritySyncStats : sortedAuthorities) {
-                String name = authoritySyncStats.name;
-                long elapsedTime;
-                int times;
-                String timeStr;
-                String timesStr;
-
-                elapsedTime = authoritySyncStats.elapsedTime;
-                times = authoritySyncStats.times;
-                timeStr = String.format("%ds/%d%%",
-                        elapsedTime / 1000,
-                        elapsedTime * 100 / totalElapsedTime);
-                timesStr = String.format("%d/%d%%",
-                        times,
-                        times * 100 / totalTimes);
-                pw.printf(authorityFormat, name, timesStr, timeStr);
-
-                final List<AccountSyncStats> sortedAccounts =
-                        new ArrayList<AccountSyncStats>(
-                                authoritySyncStats.accountMap.values());
-                Collections.sort(sortedAccounts, new Comparator<AccountSyncStats>() {
+                final List<AuthoritySyncStats> sortedAuthorities =
+                        new ArrayList<AuthoritySyncStats>(authorityMap.values());
+                Collections.sort(sortedAuthorities, new Comparator<AuthoritySyncStats>() {
                     @Override
-                    public int compare(AccountSyncStats lhs, AccountSyncStats rhs) {
+                    public int compare(AuthoritySyncStats lhs, AuthoritySyncStats rhs) {
                         // reverse order
                         int compare = Integer.compare(rhs.times, lhs.times);
                         if (compare == 0) {
@@ -1331,18 +1292,63 @@
                         return compare;
                     }
                 });
-                for (AccountSyncStats stats: sortedAccounts) {
-                    elapsedTime = stats.elapsedTime;
-                    times = stats.times;
+
+                final int maxLength = Math.max(maxAuthority, maxAccount + 3);
+                final int padLength = 2 + 2 + maxLength + 2 + 10 + 11;
+                final char chars[] = new char[padLength];
+                Arrays.fill(chars, '-');
+                final String separator = new String(chars);
+
+                final String authorityFormat =
+                        String.format("  %%-%ds: %%-9s  %%-11s\n", maxLength + 2);
+                final String accountFormat =
+                        String.format("    %%-%ds:   %%-9s  %%-11s\n", maxLength);
+
+                pw.println(separator);
+                for (AuthoritySyncStats authoritySyncStats : sortedAuthorities) {
+                    String name = authoritySyncStats.name;
+                    long elapsedTime;
+                    int times;
+                    String timeStr;
+                    String timesStr;
+
+                    elapsedTime = authoritySyncStats.elapsedTime;
+                    times = authoritySyncStats.times;
                     timeStr = String.format("%ds/%d%%",
                             elapsedTime / 1000,
                             elapsedTime * 100 / totalElapsedTime);
                     timesStr = String.format("%d/%d%%",
                             times,
                             times * 100 / totalTimes);
-                    pw.printf(accountFormat, stats.name, timesStr, timeStr);
+                    pw.printf(authorityFormat, name, timesStr, timeStr);
+
+                    final List<AccountSyncStats> sortedAccounts =
+                            new ArrayList<AccountSyncStats>(
+                                    authoritySyncStats.accountMap.values());
+                    Collections.sort(sortedAccounts, new Comparator<AccountSyncStats>() {
+                        @Override
+                        public int compare(AccountSyncStats lhs, AccountSyncStats rhs) {
+                            // reverse order
+                            int compare = Integer.compare(rhs.times, lhs.times);
+                            if (compare == 0) {
+                                compare = Long.compare(rhs.elapsedTime, lhs.elapsedTime);
+                            }
+                            return compare;
+                        }
+                    });
+                    for (AccountSyncStats stats: sortedAccounts) {
+                        elapsedTime = stats.elapsedTime;
+                        times = stats.times;
+                        timeStr = String.format("%ds/%d%%",
+                                elapsedTime / 1000,
+                                elapsedTime * 100 / totalElapsedTime);
+                        timesStr = String.format("%d/%d%%",
+                                times,
+                                times * 100 / totalTimes);
+                        pw.printf(accountFormat, stats.name, timesStr, timeStr);
+                    }
+                    pw.println(separator);
                 }
-                pw.println(separator);
             }
 
             pw.println();
diff --git a/core/java/android/nfc/LlcpPacket.aidl b/core/java/android/nfc/LlcpPacket.aidl
deleted file mode 100644
index 80f424d..0000000
--- a/core/java/android/nfc/LlcpPacket.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package android.nfc;
-
-/**
- * @hide
- */
-parcelable LlcpPacket;
\ No newline at end of file
diff --git a/core/java/android/nfc/LlcpPacket.java b/core/java/android/nfc/LlcpPacket.java
deleted file mode 100644
index 9919dc4..0000000
--- a/core/java/android/nfc/LlcpPacket.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package android.nfc;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Represents a LLCP packet received in a LLCP Connectionless communication;
- * @hide
- */
-public class LlcpPacket implements Parcelable {
-
-    private final int mRemoteSap;
-
-    private final byte[] mDataBuffer;
-
-    /**
-     * Creates a LlcpPacket to be sent to a remote Service Access Point number
-     * (SAP)
-     *
-     * @param sap Remote Service Access Point number
-     * @param data Data buffer
-     */
-    public LlcpPacket(int sap, byte[] data) {
-        mRemoteSap = sap;
-        mDataBuffer = data;
-    }
-
-    /**
-     * Returns the remote Service Access Point number
-     */
-    public int getRemoteSap() {
-        return mRemoteSap;
-    }
-
-    /**
-     * Returns the data buffer
-     */
-    public byte[] getDataBuffer() {
-        return mDataBuffer;
-    }
-
-    public int describeContents() {
-        return 0;
-    }
-
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeInt(mRemoteSap);
-        dest.writeInt(mDataBuffer.length);
-        dest.writeByteArray(mDataBuffer);
-    }
-
-    public static final Parcelable.Creator<LlcpPacket> CREATOR = new Parcelable.Creator<LlcpPacket>() {
-        public LlcpPacket createFromParcel(Parcel in) {
-            // Remote SAP
-            short sap = (short)in.readInt();
-
-            // Data Buffer
-            int dataLength = in.readInt();
-            byte[] data = new byte[dataLength];
-            in.readByteArray(data);
-
-            return new LlcpPacket(sap, data);
-        }
-
-        public LlcpPacket[] newArray(int size) {
-            return new LlcpPacket[size];
-        }
-    };
-}
\ No newline at end of file
diff --git a/core/java/android/os/Process.java b/core/java/android/os/Process.java
index e1bc275..cdf235d 100644
--- a/core/java/android/os/Process.java
+++ b/core/java/android/os/Process.java
@@ -219,6 +219,36 @@
     public static final int THREAD_PRIORITY_LESS_FAVORABLE = +1;
 
     /**
+     * Default scheduling policy
+     * @hide
+     */
+    public static final int SCHED_OTHER = 0;
+
+    /**
+     * First-In First-Out scheduling policy
+     * @hide
+     */
+    public static final int SCHED_FIFO = 1;
+
+    /**
+     * Round-Robin scheduling policy
+     * @hide
+     */
+    public static final int SCHED_RR = 2;
+
+    /**
+     * Batch scheduling policy
+     * @hide
+     */
+    public static final int SCHED_BATCH = 3;
+
+    /**
+     * Idle scheduling policy
+     * @hide
+     */
+    public static final int SCHED_IDLE = 5;
+
+    /**
      * Default thread group - gets a 'normal' share of the CPU
      * @hide
      */
@@ -675,6 +705,24 @@
             throws IllegalArgumentException;
     
     /**
+     * Set the scheduling policy and priority of a thread, based on Linux.
+     *
+     * @param tid The identifier of the thread/process to change.
+     * @param policy A Linux scheduling policy such as SCHED_OTHER etc.
+     * @param priority A Linux priority level in a range appropriate for the given policy.
+     *
+     * @throws IllegalArgumentException Throws IllegalArgumentException if
+     * <var>tid</var> does not exist, or if <var>priority</var> is out of range for the policy.
+     * @throws SecurityException Throws SecurityException if your process does
+     * not have permission to modify the given thread, or to use the given
+     * scheduling policy or priority.
+     *
+     * {@hide}
+     */
+    public static final native void setThreadScheduler(int tid, int policy, int priority)
+            throws IllegalArgumentException;
+
+    /**
      * Determine whether the current environment supports multiple processes.
      * 
      * @return Returns true if the system can run in multiple processes, else
diff --git a/core/java/android/provider/UserDictionary.java b/core/java/android/provider/UserDictionary.java
index 5a7ef85..a9b106a 100644
--- a/core/java/android/provider/UserDictionary.java
+++ b/core/java/android/provider/UserDictionary.java
@@ -40,6 +40,9 @@
     public static final Uri CONTENT_URI =
         Uri.parse("content://" + AUTHORITY);
 
+    private static final int FREQUENCY_MIN = 0;
+    private static final int FREQUENCY_MAX = 255;
+
     /**
      * Contains the user defined words.
      */
@@ -87,12 +90,24 @@
          */
         public static final String APP_ID = "appid";
 
-        /** The locale type to specify that the word is common to all locales. */
+        /**
+         * An optional shortcut for this word. When the shortcut is typed, supporting IMEs should
+         * suggest the word in this row as an alternate spelling too.
+         */
+        public static final String SHORTCUT = "shortcut";
+
+        /**
+         * @deprecated Use {@link #addWord(Context, String, int, String, Locale)}.
+         */
+        @Deprecated
         public static final int LOCALE_TYPE_ALL = 0;
-        
-        /** The locale type to specify that the word is for the current locale. */
+
+        /**
+         * @deprecated Use {@link #addWord(Context, String, int, String, Locale)}.
+         */
+        @Deprecated
         public static final int LOCALE_TYPE_CURRENT = 1;
-        
+
         /**
          * Sort by descending order of frequency.
          */
@@ -100,35 +115,65 @@
 
         /** Adds a word to the dictionary, with the given frequency and the specified
          *  specified locale type.
+         *
+         *  @deprecated Please use
+         *  {@link #addWord(Context, String, int, String, Locale)} instead.
+         *
          *  @param context the current application context
          *  @param word the word to add to the dictionary. This should not be null or
          *  empty.
          *  @param localeType the locale type for this word. It should be one of
          *  {@link #LOCALE_TYPE_ALL} or {@link #LOCALE_TYPE_CURRENT}.
          */
-        public static void addWord(Context context, String word, 
+        @Deprecated
+        public static void addWord(Context context, String word,
                 int frequency, int localeType) {
-            final ContentResolver resolver = context.getContentResolver();
 
-            if (TextUtils.isEmpty(word) || localeType < 0 || localeType > 1) {
+            if (localeType != LOCALE_TYPE_ALL && localeType != LOCALE_TYPE_CURRENT) {
                 return;
             }
-            
-            if (frequency < 0) frequency = 0;
-            if (frequency > 255) frequency = 255;
 
-            String locale = null;
+            final Locale locale;
 
-            // TODO: Verify if this is the best way to get the current locale
             if (localeType == LOCALE_TYPE_CURRENT) {
-                locale = Locale.getDefault().toString();
+                locale = Locale.getDefault();
+            } else {
+                locale = null;
             }
-            ContentValues values = new ContentValues(4);
+
+            addWord(context, word, frequency, null, locale);
+        }
+
+        /** Adds a word to the dictionary, with the given frequency and the specified
+         *  locale type.
+         *
+         *  @param context the current application context
+         *  @param word the word to add to the dictionary. This should not be null or
+         *  empty.
+         *  @param shortcut optional shortcut spelling for this word. When the shortcut
+         *  is typed, the word may be suggested by applications that support it. May be null.
+         *  @param locale the locale to insert the word for, or null to insert the word
+         *  for all locales.
+         */
+        public static void addWord(Context context, String word,
+                int frequency, String shortcut, Locale locale) {
+            final ContentResolver resolver = context.getContentResolver();
+
+            if (TextUtils.isEmpty(word)) {
+                return;
+            }
+
+            if (frequency < FREQUENCY_MIN) frequency = FREQUENCY_MIN;
+            if (frequency > FREQUENCY_MAX) frequency = FREQUENCY_MAX;
+
+            final int COLUMN_COUNT = 5;
+            ContentValues values = new ContentValues(COLUMN_COUNT);
 
             values.put(WORD, word);
             values.put(FREQUENCY, frequency);
-            values.put(LOCALE, locale);
+            values.put(LOCALE, null == locale ? null : locale.toString());
             values.put(APP_ID, 0); // TODO: Get App UID
+            values.put(SHORTCUT, shortcut);
 
             Uri result = resolver.insert(CONTENT_URI, values);
             // It's ok if the insert doesn't succeed because the word
diff --git a/core/java/android/view/DisplayList.java b/core/java/android/view/DisplayList.java
index 8f4ece0..fec0d4b 100644
--- a/core/java/android/view/DisplayList.java
+++ b/core/java/android/view/DisplayList.java
@@ -32,20 +32,20 @@
      * 
      * @return A canvas to record drawing operations.
      */
-    abstract HardwareCanvas start();
+    public abstract HardwareCanvas start();
 
     /**
      * Ends the recording for this display list. A display list cannot be
      * replayed if recording is not finished. 
      */
-    abstract void end();
+    public abstract void end();
 
     /**
      * Invalidates the display list, indicating that it should be repopulated
      * with new drawing commands prior to being used again. Calling this method
      * causes calls to {@link #isValid()} to return <code>false</code>.
      */
-    abstract void invalidate();
+    public abstract void invalidate();
 
     /**
      * Returns whether the display list is currently usable. If this returns false,
@@ -53,12 +53,12 @@
      *
      * @return boolean true if the display list is able to be replayed, false otherwise.
      */
-    abstract boolean isValid();
+    public abstract boolean isValid();
 
     /**
      * Return the amount of memory used by this display list.
      * 
      * @return The size of this display list in bytes
      */
-    abstract int getSize();
+    public abstract int getSize();
 }
diff --git a/core/java/android/view/GLES20Canvas.java b/core/java/android/view/GLES20Canvas.java
index 43a451d..5a436c4 100644
--- a/core/java/android/view/GLES20Canvas.java
+++ b/core/java/android/view/GLES20Canvas.java
@@ -61,6 +61,7 @@
     private final float[] mLine = new float[4];
     
     private final Rect mClipBounds = new Rect();
+    private final RectF mPathBounds = new RectF();
 
     private DrawFilter mFilter;
 
@@ -247,7 +248,7 @@
     private static native void nDisableVsync();
 
     @Override
-    void onPreDraw(Rect dirty) {
+    public void onPreDraw(Rect dirty) {
         if (dirty != null) {
             nPrepareDirty(mRenderer, dirty.left, dirty.top, dirty.right, dirty.bottom, mOpaque);
         } else {
@@ -260,7 +261,7 @@
             boolean opaque);
 
     @Override
-    void onPostDraw() {
+    public void onPostDraw() {
         nFinish(mRenderer);
     }
 
@@ -406,12 +407,18 @@
 
     @Override
     public boolean clipPath(Path path) {
-        throw new UnsupportedOperationException();
+        // TODO: Implement
+        path.computeBounds(mPathBounds, true);
+        return nClipRect(mRenderer, mPathBounds.left, mPathBounds.top,
+                mPathBounds.right, mPathBounds.bottom, Region.Op.INTERSECT.nativeInt);
     }
 
     @Override
     public boolean clipPath(Path path, Region.Op op) {
-        throw new UnsupportedOperationException();
+        // TODO: Implement
+        path.computeBounds(mPathBounds, true);
+        return nClipRect(mRenderer, mPathBounds.left, mPathBounds.top,
+                mPathBounds.right, mPathBounds.bottom, op.nativeInt);
     }
 
     @Override
@@ -459,12 +466,18 @@
 
     @Override
     public boolean clipRegion(Region region) {
-        throw new UnsupportedOperationException();
+        // TODO: Implement
+        region.getBounds(mClipBounds);
+        return nClipRect(mRenderer, mClipBounds.left, mClipBounds.top,
+                mClipBounds.right, mClipBounds.bottom, Region.Op.INTERSECT.nativeInt);
     }
 
     @Override
     public boolean clipRegion(Region region, Region.Op op) {
-        throw new UnsupportedOperationException();
+        // TODO: Implement
+        region.getBounds(mClipBounds);
+        return nClipRect(mRenderer, mClipBounds.left, mClipBounds.top,
+                mClipBounds.right, mClipBounds.bottom, op.nativeInt);
     }
 
     @Override
@@ -484,12 +497,14 @@
 
     @Override
     public boolean quickReject(Path path, EdgeType type) {
-        throw new UnsupportedOperationException();
+        path.computeBounds(mPathBounds, true);
+        return nQuickReject(mRenderer, mPathBounds.left, mPathBounds.top,
+                mPathBounds.right, mPathBounds.bottom, type.nativeInt);
     }
 
     @Override
     public boolean quickReject(RectF rect, EdgeType type) {
-        return quickReject(rect.left, rect.top, rect.right, rect.bottom, type);
+        return nQuickReject(mRenderer, rect.left, rect.top, rect.right, rect.bottom, type.nativeInt);
     }
 
     ///////////////////////////////////////////////////////////////////////////
@@ -893,17 +908,30 @@
 
     @Override
     public void drawPicture(Picture picture) {
-        throw new UnsupportedOperationException();
+        picture.endRecording();
+        // TODO: Implement rendering
     }
 
     @Override
     public void drawPicture(Picture picture, Rect dst) {
-        throw new UnsupportedOperationException();
+        save();
+        translate(dst.left, dst.top);
+        if (picture.getWidth() > 0 && picture.getHeight() > 0) {
+            scale(dst.width() / picture.getWidth(), dst.height() / picture.getHeight());
+        }
+        drawPicture(picture);
+        restore();
     }
 
     @Override
     public void drawPicture(Picture picture, RectF dst) {
-        throw new UnsupportedOperationException();
+        save();
+        translate(dst.left, dst.top);
+        if (picture.getWidth() > 0 && picture.getHeight() > 0) {
+            scale(dst.width() / picture.getWidth(), dst.height() / picture.getHeight());
+        }
+        drawPicture(picture);
+        restore();
     }
 
     @Override
@@ -930,14 +958,38 @@
 
     @Override
     public void drawPosText(char[] text, int index, int count, float[] pos, Paint paint) {
-        // TODO: Implement
+        if (index < 0 || index + count > text.length || count * 2 > pos.length) {
+            throw new IndexOutOfBoundsException();
+        }
+
+        int modifiers = setupModifiers(paint);
+        try {
+            nDrawPosText(mRenderer, text, index, count, pos, paint.mNativePaint);
+        } finally {
+            if (modifiers != MODIFIER_NONE) nResetModifiers(mRenderer, modifiers);
+        }
     }
 
+    private static native void nDrawPosText(int renderer, char[] text, int index, int count,
+            float[] pos, int paint);
+
     @Override
     public void drawPosText(String text, float[] pos, Paint paint) {
-        // TODO: Implement
+        if (text.length() * 2 > pos.length) {
+            throw new ArrayIndexOutOfBoundsException();
+        }
+
+        int modifiers = setupModifiers(paint);
+        try {
+            nDrawPosText(mRenderer, text, 0, text.length(), pos, paint.mNativePaint);
+        } finally {
+            if (modifiers != MODIFIER_NONE) nResetModifiers(mRenderer, modifiers);
+        }
     }
 
+    private static native void nDrawPosText(int renderer, String text, int start, int end,
+            float[] pos, int paint);
+
     @Override
     public void drawRect(float left, float top, float right, float bottom, Paint paint) {
         int modifiers = setupModifiers(paint);
diff --git a/core/java/android/view/GLES20DisplayList.java b/core/java/android/view/GLES20DisplayList.java
index 4ca5e98..0cb9449 100644
--- a/core/java/android/view/GLES20DisplayList.java
+++ b/core/java/android/view/GLES20DisplayList.java
@@ -43,7 +43,7 @@
     }
 
     @Override
-    HardwareCanvas start() {
+    public HardwareCanvas start() {
         if (mCanvas != null) {
             throw new IllegalStateException("Recording has already started");
         }
@@ -55,7 +55,7 @@
     }
 
     @Override
-    void invalidate() {
+    public void invalidate() {
         if (mCanvas != null) {
             mCanvas.recycle();
             mCanvas = null;
@@ -64,12 +64,12 @@
     }
 
     @Override
-    boolean isValid() {
+    public boolean isValid() {
         return mValid;
     }
 
     @Override
-    void end() {
+    public void end() {
         if (mCanvas != null) {
             if (mFinalizer != null) {
                 mCanvas.end(mFinalizer.mNativeDisplayList);
@@ -83,7 +83,7 @@
     }
 
     @Override
-    int getSize() {
+    public int getSize() {
         if (mFinalizer == null) return 0;
         return GLES20Canvas.getDisplayListSize(mFinalizer.mNativeDisplayList);
     }
diff --git a/core/java/android/view/HardwareCanvas.java b/core/java/android/view/HardwareCanvas.java
index 23b3abc..cbdbbde 100644
--- a/core/java/android/view/HardwareCanvas.java
+++ b/core/java/android/view/HardwareCanvas.java
@@ -42,12 +42,12 @@
      * 
      * @param dirty The dirty rectangle to update, can be null.
      */
-    abstract void onPreDraw(Rect dirty);
+    public abstract void onPreDraw(Rect dirty);
 
     /**
      * Invoked after all drawing operation have been performed.
      */
-    abstract void onPostDraw();
+    public abstract void onPostDraw();
     
     /**
      * Draws the specified display list onto this canvas.
@@ -61,7 +61,7 @@
      * @return True if the content of the display list requires another
      *         drawing pass (invalidate()), false otherwise
      */
-    abstract boolean drawDisplayList(DisplayList displayList, int width, int height, Rect dirty);
+    public abstract boolean drawDisplayList(DisplayList displayList, int width, int height, Rect dirty);
 
     /**
      * Outputs the specified display list to the log. This method exists for use by
diff --git a/core/java/android/view/HardwareRenderer.java b/core/java/android/view/HardwareRenderer.java
index 3f793bb..4592ae6 100644
--- a/core/java/android/view/HardwareRenderer.java
+++ b/core/java/android/view/HardwareRenderer.java
@@ -276,7 +276,7 @@
      * 
      * @return A new display list.
      */
-    abstract DisplayList createDisplayList();
+    public abstract DisplayList createDisplayList();
 
     /**
      * Creates a new hardware layer. A hardware layer built by calling this
@@ -316,14 +316,13 @@
      * potentially lost the hardware renderer. The hardware renderer should be
      * reinitialized and setup when the render {@link #isRequested()} and
      * {@link #isEnabled()}.
-     * 
+     *
      * @param width The width of the drawing surface.
      * @param height The height of the drawing surface.
-     * @param attachInfo The 
-     * @param holder
+     * @param holder The target surface
      */
-    void initializeIfNeeded(int width, int height, View.AttachInfo attachInfo,
-            SurfaceHolder holder) throws Surface.OutOfResourcesException {
+    void initializeIfNeeded(int width, int height, SurfaceHolder holder)
+            throws Surface.OutOfResourcesException {
         if (isRequested()) {
             // We lost the gl context, so recreate it.
             if (!isEnabled()) {
@@ -1083,7 +1082,7 @@
         }
 
         @Override
-        DisplayList createDisplayList() {
+        public DisplayList createDisplayList() {
             return new GLES20DisplayList();
         }
 
diff --git a/core/java/android/view/VelocityTracker.java b/core/java/android/view/VelocityTracker.java
index dfb2c32..1c35e31 100644
--- a/core/java/android/view/VelocityTracker.java
+++ b/core/java/android/view/VelocityTracker.java
@@ -29,7 +29,7 @@
  * to begin tracking.  Put the motion events you receive into it with
  * {@link #addMovement(MotionEvent)}.  When you want to determine the velocity call
  * {@link #computeCurrentVelocity(int)} and then call {@link #getXVelocity(int)}
- * and {@link #getXVelocity(int)} to retrieve the velocity for each pointer id.
+ * and {@link #getYVelocity(int)} to retrieve the velocity for each pointer id.
  */
 public final class VelocityTracker implements Poolable<VelocityTracker> {
     private static final Pool<VelocityTracker> sPool = Pools.synchronizedPool(
@@ -39,6 +39,7 @@
                 }
 
                 public void onAcquired(VelocityTracker element) {
+                    // Intentionally empty
                 }
 
                 public void onReleased(VelocityTracker element) {
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index 64f862a..a9d6cdf 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -4107,7 +4107,7 @@
      */
     void onInitializeAccessibilityEventInternal(AccessibilityEvent event) {
         event.setSource(this);
-        event.setClassName(getClass().getName());
+        event.setClassName(View.class.getName());
         event.setPackageName(getContext().getPackageName());
         event.setEnabled(isEnabled());
         event.setContentDescription(mContentDescription);
@@ -4212,7 +4212,7 @@
         }
 
         info.setPackageName(mContext.getPackageName());
-        info.setClassName(getClass().getName());
+        info.setClassName(View.class.getName());
         info.setContentDescription(getContentDescription());
 
         info.setEnabled(isEnabled());
@@ -7597,15 +7597,17 @@
      */
     public void setAlpha(float alpha) {
         ensureTransformationInfo();
-        mTransformationInfo.mAlpha = alpha;
-        invalidateParentCaches();
-        if (onSetAlpha((int) (alpha * 255))) {
-            mPrivateFlags |= ALPHA_SET;
-            // subclass is handling alpha - don't optimize rendering cache invalidation
-            invalidate(true);
-        } else {
-            mPrivateFlags &= ~ALPHA_SET;
-            invalidate(false);
+        if (mTransformationInfo.mAlpha != alpha) {
+            mTransformationInfo.mAlpha = alpha;
+            invalidateParentCaches();
+            if (onSetAlpha((int) (alpha * 255))) {
+                mPrivateFlags |= ALPHA_SET;
+                // subclass is handling alpha - don't optimize rendering cache invalidation
+                invalidate(true);
+            } else {
+                mPrivateFlags &= ~ALPHA_SET;
+                invalidate(false);
+            }
         }
     }
 
@@ -7616,18 +7618,22 @@
      * alpha (the return value for onSetAlpha()).
      *
      * @param alpha The new value for the alpha property
-     * @return true if the View subclass handles alpha (the return value for onSetAlpha())
+     * @return true if the View subclass handles alpha (the return value for onSetAlpha()) and
+     *         the new value for the alpha property is different from the old value
      */
     boolean setAlphaNoInvalidation(float alpha) {
         ensureTransformationInfo();
-        mTransformationInfo.mAlpha = alpha;
-        boolean subclassHandlesAlpha = onSetAlpha((int) (alpha * 255));
-        if (subclassHandlesAlpha) {
-            mPrivateFlags |= ALPHA_SET;
-        } else {
-            mPrivateFlags &= ~ALPHA_SET;
+        if (mTransformationInfo.mAlpha != alpha) {
+            mTransformationInfo.mAlpha = alpha;
+            boolean subclassHandlesAlpha = onSetAlpha((int) (alpha * 255));
+            if (subclassHandlesAlpha) {
+                mPrivateFlags |= ALPHA_SET;
+                return true;
+            } else {
+                mPrivateFlags &= ~ALPHA_SET;
+            }
         }
-        return subclassHandlesAlpha;
+        return false;
     }
 
     /**
@@ -10433,6 +10439,19 @@
     }
 
     /**
+     * @return The HardwareRenderer associated with that view or null if hardware rendering
+     * is not supported or this this has not been attached to a window.
+     *
+     * @hide
+     */
+    public HardwareRenderer getHardwareRenderer() {
+        if (mAttachInfo != null) {
+            return mAttachInfo.mHardwareRenderer;
+        }
+        return null;
+    }
+
+    /**
      * <p>Returns a display list that can be used to draw this view again
      * without executing its draw method.</p>
      *
diff --git a/core/java/android/view/ViewGroup.java b/core/java/android/view/ViewGroup.java
index 09901ff..5c63366 100644
--- a/core/java/android/view/ViewGroup.java
+++ b/core/java/android/view/ViewGroup.java
@@ -2229,6 +2229,7 @@
     @Override
     void onInitializeAccessibilityNodeInfoInternal(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfoInternal(info);
+        info.setClassName(ViewGroup.class.getName());
         for (int i = 0, count = mChildrenCount; i < count; i++) {
             View child = mChildren[i];
             if ((child.mViewFlags & VISIBILITY_MASK) == VISIBLE
@@ -2238,6 +2239,12 @@
         }
     }
 
+    @Override
+    void onInitializeAccessibilityEventInternal(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEventInternal(event);
+        event.setClassName(ViewGroup.class.getName());
+    }
+
     /**
      * {@inheritDoc}
      */
diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java
index 72966ef4..1a4bdf4 100644
--- a/core/java/android/view/ViewRootImpl.java
+++ b/core/java/android/view/ViewRootImpl.java
@@ -57,7 +57,6 @@
 import android.util.PoolableManager;
 import android.util.Pools;
 import android.util.Slog;
-import android.util.SparseArray;
 import android.util.TypedValue;
 import android.view.View.MeasureSpec;
 import android.view.accessibility.AccessibilityEvent;
@@ -2530,7 +2529,7 @@
                         mFullRedrawNeeded = true;
                         try {
                             mAttachInfo.mHardwareRenderer.initializeIfNeeded(mWidth, mHeight,
-                                    mAttachInfo, mHolder);
+                                    mHolder);
                         } catch (Surface.OutOfResourcesException e) {
                             Log.e(TAG, "OutOfResourcesException locking surface", e);
                             try {
diff --git a/core/java/android/view/WindowManagerPolicy.java b/core/java/android/view/WindowManagerPolicy.java
index c7cd662..994565a 100644
--- a/core/java/android/view/WindowManagerPolicy.java
+++ b/core/java/android/view/WindowManagerPolicy.java
@@ -298,6 +298,11 @@
         boolean isDisplayedLw();
 
         /**
+         * Is this window considered to be gone for purposes of layout?
+         */
+        boolean isGoneForLayoutLw();
+
+        /**
          * Returns true if this window has been shown on screen at some time in 
          * the past.  Must be called with the window manager lock held.
          * 
diff --git a/core/java/android/view/WindowOrientationListener.java b/core/java/android/view/WindowOrientationListener.java
index c3c74a7..c28b220 100755
--- a/core/java/android/view/WindowOrientationListener.java
+++ b/core/java/android/view/WindowOrientationListener.java
@@ -21,6 +21,7 @@
 import android.hardware.SensorEvent;
 import android.hardware.SensorEventListener;
 import android.hardware.SensorManager;
+import android.util.FloatMath;
 import android.util.Log;
 import android.util.Slog;
 
@@ -48,6 +49,8 @@
     private static final boolean DEBUG = false;
     private static final boolean localLOGV = DEBUG || false;
 
+    private static final boolean USE_GRAVITY_SENSOR = false;
+
     private SensorManager mSensorManager;
     private boolean mEnabled;
     private int mRate;
@@ -79,7 +82,8 @@
     private WindowOrientationListener(Context context, int rate) {
         mSensorManager = (SensorManager)context.getSystemService(Context.SENSOR_SERVICE);
         mRate = rate;
-        mSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);
+        mSensor = mSensorManager.getDefaultSensor(USE_GRAVITY_SENSOR
+                ? Sensor.TYPE_GRAVITY : Sensor.TYPE_ACCELEROMETER);
         if (mSensor != null) {
             // Create listener only if sensors do exist
             mSensorEventListener = new SensorEventListenerImpl(this);
@@ -179,7 +183,7 @@
      *    cartesian space because the orientation calculations are sensitive to the
      *    absolute magnitude of the acceleration.  In particular, there are singularities
      *    in the calculation as the magnitude approaches 0.  By performing the low-pass
-     *    filtering early, we can eliminate high-frequency impulses systematically.
+     *    filtering early, we can eliminate most spurious high-frequency impulses due to noise.
      *
      *  - Convert the acceleromter vector from cartesian to spherical coordinates.
      *    Since we're dealing with rotation of the device, this is the sensible coordinate
@@ -204,11 +208,17 @@
      *    new orientation proposal.
      *
      * Details are explained inline.
+     *
+     * See http://en.wikipedia.org/wiki/Low-pass_filter#Discrete-time_realization for
+     * signal processing background.
      */
     static final class SensorEventListenerImpl implements SensorEventListener {
         // We work with all angles in degrees in this class.
         private static final float RADIANS_TO_DEGREES = (float) (180 / Math.PI);
 
+        // Number of nanoseconds per millisecond.
+        private static final long NANOS_PER_MS = 1000000;
+
         // Indices into SensorEvent.values for the accelerometer sensor.
         private static final int ACCELEROMETER_DATA_X = 0;
         private static final int ACCELEROMETER_DATA_Y = 1;
@@ -216,38 +226,41 @@
 
         private final WindowOrientationListener mOrientationListener;
 
-        /* State for first order low-pass filtering of accelerometer data.
-         * See http://en.wikipedia.org/wiki/Low-pass_filter#Discrete-time_realization for
-         * signal processing background.
-         */
+        // The minimum amount of time that a predicted rotation must be stable before it
+        // is accepted as a valid rotation proposal.  This value can be quite small because
+        // the low-pass filter already suppresses most of the noise so we're really just
+        // looking for quick confirmation that the last few samples are in agreement as to
+        // the desired orientation.
+        private static final long PROPOSAL_SETTLE_TIME_NANOS = 40 * NANOS_PER_MS;
 
-        private long mLastTimestamp = Long.MAX_VALUE; // in nanoseconds
-        private float mLastFilteredX, mLastFilteredY, mLastFilteredZ;
+        // The minimum amount of time that must have elapsed since the device last exited
+        // the flat state (time since it was picked up) before the proposed rotation
+        // can change.
+        private static final long PROPOSAL_MIN_TIME_SINCE_FLAT_ENDED_NANOS = 500 * NANOS_PER_MS;
 
-        // The current proposal.  We wait for the proposal to be stable for a
-        // certain amount of time before accepting it.
-        //
-        // The basic idea is to ignore intermediate poses of the device while the
-        // user is picking up, putting down or turning the device.
-        private int mProposalRotation;
-        private long mProposalAgeMS;
+        // The mininum amount of time that must have elapsed since the device stopped
+        // swinging (time since device appeared to be in the process of being put down
+        // or put away into a pocket) before the proposed rotation can change.
+        private static final long PROPOSAL_MIN_TIME_SINCE_SWING_ENDED_NANOS = 300 * NANOS_PER_MS;
 
-        // A historical trace of tilt and orientation angles.  Used to determine whether
-        // the device posture has settled down.
-        private static final int HISTORY_SIZE = 20;
-        private int mHistoryIndex; // index of most recent sample
-        private int mHistoryLength; // length of historical trace
-        private final long[] mHistoryTimestampMS = new long[HISTORY_SIZE];
-        private final float[] mHistoryMagnitudes = new float[HISTORY_SIZE];
-        private final int[] mHistoryTiltAngles = new int[HISTORY_SIZE];
-        private final int[] mHistoryOrientationAngles = new int[HISTORY_SIZE];
+        // If the tilt angle remains greater than the specified angle for a minimum of
+        // the specified time, then the device is deemed to be lying flat
+        // (just chillin' on a table).
+        private static final float FLAT_ANGLE = 75;
+        private static final long FLAT_TIME_NANOS = 1000 * NANOS_PER_MS;
+
+        // If the tilt angle has increased by at least delta degrees within the specified amount
+        // of time, then the device is deemed to be swinging away from the user
+        // down towards flat (tilt = 90).
+        private static final float SWING_AWAY_ANGLE_DELTA = 20;
+        private static final long SWING_TIME_NANOS = 300 * NANOS_PER_MS;
 
         // The maximum sample inter-arrival time in milliseconds.
         // If the acceleration samples are further apart than this amount in time, we reset the
         // state of the low-pass filter and orientation properties.  This helps to handle
         // boundary conditions when the device is turned on, wakes from suspend or there is
         // a significant gap in samples.
-        private static final float MAX_FILTER_DELTA_TIME_MS = 1000;
+        private static final long MAX_FILTER_DELTA_TIME_NANOS = 1000 * NANOS_PER_MS;
 
         // The acceleration filter time constant.
         //
@@ -267,8 +280,10 @@
         //
         // Filtering adds latency proportional the time constant (inversely proportional
         // to the cutoff frequency) so we don't want to make the time constant too
-        // large or we can lose responsiveness.
-        private static final float FILTER_TIME_CONSTANT_MS = 100.0f;
+        // large or we can lose responsiveness.  Likewise we don't want to make it too
+        // small or we do a poor job suppressing acceleration spikes.
+        // Empirically, 100ms seems to be too small and 500ms is too large.
+        private static final float FILTER_TIME_CONSTANT_MS = 200.0f;
 
         /* State for orientation detection. */
 
@@ -286,9 +301,9 @@
         //
         // In both cases, we postpone choosing an orientation.
         private static final float MIN_ACCELERATION_MAGNITUDE =
-                SensorManager.STANDARD_GRAVITY * 0.5f;
+                SensorManager.STANDARD_GRAVITY * 0.3f;
         private static final float MAX_ACCELERATION_MAGNITUDE =
-            SensorManager.STANDARD_GRAVITY * 1.5f;
+            SensorManager.STANDARD_GRAVITY * 1.25f;
 
         // Maximum absolute tilt angle at which to consider orientation data.  Beyond this (i.e.
         // when screen is facing the sky or ground), we completely ignore orientation data.
@@ -306,10 +321,10 @@
         // The ideal tilt angle is 0 (when the device is vertical) so the limits establish
         // how close to vertical the device must be in order to change orientation.
         private static final int[][] TILT_TOLERANCE = new int[][] {
-            /* ROTATION_0   */ { -20, 70 },
-            /* ROTATION_90  */ { -20, 60 },
-            /* ROTATION_180 */ { -20, 50 },
-            /* ROTATION_270 */ { -20, 60 }
+            /* ROTATION_0   */ { -25, 70 },
+            /* ROTATION_90  */ { -25, 65 },
+            /* ROTATION_180 */ { -25, 60 },
+            /* ROTATION_270 */ { -25, 65 }
         };
 
         // The gap angle in degrees between adjacent orientation angles for hysteresis.
@@ -319,29 +334,38 @@
         // orientation.
         private static final int ADJACENT_ORIENTATION_ANGLE_GAP = 45;
 
-        // The number of milliseconds for which the device posture must be stable
-        // before we perform an orientation change.  If the device appears to be rotating
-        // (being picked up, put down) then we keep waiting until it settles.
-        private static final int SETTLE_TIME_MS = 200;
+        // Timestamp and value of the last accelerometer sample.
+        private long mLastFilteredTimestampNanos;
+        private float mLastFilteredX, mLastFilteredY, mLastFilteredZ;
 
-        // The maximum change in magnitude that can occur during the settle time.
-        // Tuning this constant particularly helps to filter out situations where the
-        // device is being picked up or put down by the user.
-        private static final float SETTLE_MAGNITUDE_MAX_DELTA =
-                SensorManager.STANDARD_GRAVITY * 0.2f;
+        // The last proposed rotation, -1 if unknown.
+        private int mProposedRotation;
 
-        // The maximum change in tilt angle that can occur during the settle time.
-        private static final int SETTLE_TILT_ANGLE_MAX_DELTA = 5;
+        // Value of the current predicted rotation, -1 if unknown.
+        private int mPredictedRotation;
 
-        // The maximum change in orientation angle that can occur during the settle time.
-        private static final int SETTLE_ORIENTATION_ANGLE_MAX_DELTA = 5;
+        // Timestamp of when the predicted rotation most recently changed.
+        private long mPredictedRotationTimestampNanos;
+
+        // Timestamp when the device last appeared to be flat for sure (the flat delay elapsed).
+        private long mFlatTimestampNanos;
+
+        // Timestamp when the device last appeared to be swinging.
+        private long mSwingTimestampNanos;
+
+        // History of observed tilt angles.
+        private static final int TILT_HISTORY_SIZE = 40;
+        private float[] mTiltHistory = new float[TILT_HISTORY_SIZE];
+        private long[] mTiltHistoryTimestampNanos = new long[TILT_HISTORY_SIZE];
+        private int mTiltHistoryIndex;
 
         public SensorEventListenerImpl(WindowOrientationListener orientationListener) {
             mOrientationListener = orientationListener;
+            reset();
         }
 
         public int getProposedRotation() {
-            return mProposalAgeMS >= SETTLE_TIME_MS ? mProposalRotation : -1;
+            return mProposedRotation;
         }
 
         @Override
@@ -359,8 +383,9 @@
             float z = event.values[ACCELEROMETER_DATA_Z];
 
             if (log) {
-                Slog.v(TAG, "Raw acceleration vector: " +
-                        "x=" + x + ", y=" + y + ", z=" + z);
+                Slog.v(TAG, "Raw acceleration vector: "
+                        + "x=" + x + ", y=" + y + ", z=" + z
+                        + ", magnitude=" + FloatMath.sqrt(x * x + y * y + z * z));
             }
 
             // Apply a low-pass filter to the acceleration up vector in cartesian space.
@@ -368,14 +393,16 @@
             // or when we see values of (0, 0, 0) which indicates that we polled the
             // accelerometer too soon after turning it on and we don't have any data yet.
             final long now = event.timestamp;
-            final float timeDeltaMS = (now - mLastTimestamp) * 0.000001f;
-            boolean skipSample;
-            if (timeDeltaMS <= 0 || timeDeltaMS > MAX_FILTER_DELTA_TIME_MS
+            final long then = mLastFilteredTimestampNanos;
+            final float timeDeltaMS = (now - then) * 0.000001f;
+            final boolean skipSample;
+            if (now < then
+                    || now > then + MAX_FILTER_DELTA_TIME_NANOS
                     || (x == 0 && y == 0 && z == 0)) {
                 if (log) {
                     Slog.v(TAG, "Resetting orientation listener.");
                 }
-                clearProposal();
+                reset();
                 skipSample = true;
             } else {
                 final float alpha = timeDeltaMS / (FILTER_TIME_CONSTANT_MS + timeDeltaMS);
@@ -383,27 +410,28 @@
                 y = alpha * (y - mLastFilteredY) + mLastFilteredY;
                 z = alpha * (z - mLastFilteredZ) + mLastFilteredZ;
                 if (log) {
-                    Slog.v(TAG, "Filtered acceleration vector: " +
-                            "x=" + x + ", y=" + y + ", z=" + z);
+                    Slog.v(TAG, "Filtered acceleration vector: "
+                            + "x=" + x + ", y=" + y + ", z=" + z
+                            + ", magnitude=" + FloatMath.sqrt(x * x + y * y + z * z));
                 }
                 skipSample = false;
             }
-            mLastTimestamp = now;
+            mLastFilteredTimestampNanos = now;
             mLastFilteredX = x;
             mLastFilteredY = y;
             mLastFilteredZ = z;
 
-            final int oldProposedRotation = getProposedRotation();
+            boolean isFlat = false;
+            boolean isSwinging = false;
             if (!skipSample) {
                 // Calculate the magnitude of the acceleration vector.
-                final float magnitude = (float) Math.sqrt(x * x + y * y + z * z);
+                final float magnitude = FloatMath.sqrt(x * x + y * y + z * z);
                 if (magnitude < MIN_ACCELERATION_MAGNITUDE
                         || magnitude > MAX_ACCELERATION_MAGNITUDE) {
                     if (log) {
-                        Slog.v(TAG, "Ignoring sensor data, magnitude out of range: "
-                                + "magnitude=" + magnitude);
+                        Slog.v(TAG, "Ignoring sensor data, magnitude out of range.");
                     }
-                    clearProposal();
+                    clearPredictedRotation();
                 } else {
                     // Calculate the tilt angle.
                     // This is the angle between the up vector and the x-y plane (the plane of
@@ -414,14 +442,25 @@
                     final int tiltAngle = (int) Math.round(
                             Math.asin(z / magnitude) * RADIANS_TO_DEGREES);
 
+                    // Determine whether the device appears to be flat or swinging.
+                    if (isFlat(now)) {
+                        isFlat = true;
+                        mFlatTimestampNanos = now;
+                    }
+                    if (isSwinging(now, tiltAngle)) {
+                        isSwinging = true;
+                        mSwingTimestampNanos = now;
+                    }
+                    addTiltHistoryEntry(now, tiltAngle);
+
                     // If the tilt angle is too close to horizontal then we cannot determine
                     // the orientation angle of the screen.
                     if (Math.abs(tiltAngle) > MAX_TILT) {
                         if (log) {
                             Slog.v(TAG, "Ignoring sensor data, tilt angle too high: "
-                                    + "magnitude=" + magnitude + ", tiltAngle=" + tiltAngle);
+                                    + "tiltAngle=" + tiltAngle);
                         }
-                        clearProposal();
+                        clearPredictedRotation();
                     } else {
                         // Calculate the orientation angle.
                         // This is the angle between the x-y projection of the up vector onto
@@ -439,89 +478,93 @@
                             nearestRotation = 0;
                         }
 
-                        // Determine the proposed orientation.
-                        // The confidence of the proposal is 1.0 when it is ideal and it
-                        // decays exponentially as the proposal moves further from the ideal
-                        // angle, tilt and magnitude of the proposed orientation.
-                        if (!isTiltAngleAcceptable(nearestRotation, tiltAngle)
-                                || !isOrientationAngleAcceptable(nearestRotation,
+                        // Determine the predicted orientation.
+                        if (isTiltAngleAcceptable(nearestRotation, tiltAngle)
+                                && isOrientationAngleAcceptable(nearestRotation,
                                         orientationAngle)) {
+                            updatePredictedRotation(now, nearestRotation);
                             if (log) {
-                                Slog.v(TAG, "Ignoring sensor data, no proposal: "
-                                        + "magnitude=" + magnitude + ", tiltAngle=" + tiltAngle
-                                        + ", orientationAngle=" + orientationAngle);
+                                Slog.v(TAG, "Predicted: "
+                                        + "tiltAngle=" + tiltAngle
+                                        + ", orientationAngle=" + orientationAngle
+                                        + ", predictedRotation=" + mPredictedRotation
+                                        + ", predictedRotationAgeMS="
+                                                + ((now - mPredictedRotationTimestampNanos)
+                                                        * 0.000001f));
                             }
-                            clearProposal();
                         } else {
                             if (log) {
-                                Slog.v(TAG, "Proposal: "
-                                        + "magnitude=" + magnitude
-                                        + ", tiltAngle=" + tiltAngle
-                                        + ", orientationAngle=" + orientationAngle
-                                        + ", proposalRotation=" + mProposalRotation);
+                                Slog.v(TAG, "Ignoring sensor data, no predicted rotation: "
+                                        + "tiltAngle=" + tiltAngle
+                                        + ", orientationAngle=" + orientationAngle);
                             }
-                            updateProposal(nearestRotation, now / 1000000L,
-                                    magnitude, tiltAngle, orientationAngle);
+                            clearPredictedRotation();
                         }
                     }
                 }
             }
 
+            // Determine new proposed rotation.
+            final int oldProposedRotation = mProposedRotation;
+            if (mPredictedRotation < 0 || isPredictedRotationAcceptable(now)) {
+                mProposedRotation = mPredictedRotation;
+            }
+
             // Write final statistics about where we are in the orientation detection process.
-            final int proposedRotation = getProposedRotation();
             if (log) {
-                final float proposalConfidence = Math.min(
-                        mProposalAgeMS * 1.0f / SETTLE_TIME_MS, 1.0f);
                 Slog.v(TAG, "Result: currentRotation=" + mOrientationListener.mCurrentRotation
-                        + ", proposedRotation=" + proposedRotation
+                        + ", proposedRotation=" + mProposedRotation
+                        + ", predictedRotation=" + mPredictedRotation
                         + ", timeDeltaMS=" + timeDeltaMS
-                        + ", proposalRotation=" + mProposalRotation
-                        + ", proposalAgeMS=" + mProposalAgeMS
-                        + ", proposalConfidence=" + proposalConfidence);
+                        + ", isFlat=" + isFlat
+                        + ", isSwinging=" + isSwinging
+                        + ", timeUntilSettledMS=" + remainingMS(now,
+                                mPredictedRotationTimestampNanos + PROPOSAL_SETTLE_TIME_NANOS)
+                        + ", timeUntilFlatDelayExpiredMS=" + remainingMS(now,
+                                mFlatTimestampNanos + PROPOSAL_MIN_TIME_SINCE_FLAT_ENDED_NANOS)
+                        + ", timeUntilSwingDelayExpiredMS=" + remainingMS(now,
+                                mSwingTimestampNanos + PROPOSAL_MIN_TIME_SINCE_SWING_ENDED_NANOS));
             }
 
             // Tell the listener.
-            if (proposedRotation != oldProposedRotation && proposedRotation >= 0) {
+            if (mProposedRotation != oldProposedRotation && mProposedRotation >= 0) {
                 if (log) {
-                    Slog.v(TAG, "Proposed rotation changed!  proposedRotation=" + proposedRotation
+                    Slog.v(TAG, "Proposed rotation changed!  proposedRotation=" + mProposedRotation
                             + ", oldProposedRotation=" + oldProposedRotation);
                 }
-                mOrientationListener.onProposedRotationChanged(proposedRotation);
+                mOrientationListener.onProposedRotationChanged(mProposedRotation);
             }
         }
 
         /**
-         * Returns true if the tilt angle is acceptable for a proposed
-         * orientation transition.
+         * Returns true if the tilt angle is acceptable for a given predicted rotation.
          */
-        private boolean isTiltAngleAcceptable(int proposedRotation,
-                int tiltAngle) {
-            return tiltAngle >= TILT_TOLERANCE[proposedRotation][0]
-                    && tiltAngle <= TILT_TOLERANCE[proposedRotation][1];
+        private boolean isTiltAngleAcceptable(int rotation, int tiltAngle) {
+            return tiltAngle >= TILT_TOLERANCE[rotation][0]
+                    && tiltAngle <= TILT_TOLERANCE[rotation][1];
         }
 
         /**
-         * Returns true if the orientation angle is acceptable for a proposed
-         * orientation transition.
+         * Returns true if the orientation angle is acceptable for a given predicted rotation.
          *
          * This function takes into account the gap between adjacent orientations
          * for hysteresis.
          */
-        private boolean isOrientationAngleAcceptable(int proposedRotation, int orientationAngle) {
+        private boolean isOrientationAngleAcceptable(int rotation, int orientationAngle) {
             // If there is no current rotation, then there is no gap.
             // The gap is used only to introduce hysteresis among advertised orientation
             // changes to avoid flapping.
             final int currentRotation = mOrientationListener.mCurrentRotation;
             if (currentRotation >= 0) {
-                // If the proposed rotation is the same or is counter-clockwise adjacent,
-                // then we set a lower bound on the orientation angle.
+                // If the specified rotation is the same or is counter-clockwise adjacent
+                // to the current rotation, then we set a lower bound on the orientation angle.
                 // For example, if currentRotation is ROTATION_0 and proposed is ROTATION_90,
                 // then we want to check orientationAngle > 45 + GAP / 2.
-                if (proposedRotation == currentRotation
-                        || proposedRotation == (currentRotation + 1) % 4) {
-                    int lowerBound = proposedRotation * 90 - 45
+                if (rotation == currentRotation
+                        || rotation == (currentRotation + 1) % 4) {
+                    int lowerBound = rotation * 90 - 45
                             + ADJACENT_ORIENTATION_ANGLE_GAP / 2;
-                    if (proposedRotation == 0) {
+                    if (rotation == 0) {
                         if (orientationAngle >= 315 && orientationAngle < lowerBound + 360) {
                             return false;
                         }
@@ -532,15 +575,15 @@
                     }
                 }
 
-                // If the proposed rotation is the same or is clockwise adjacent,
+                // If the specified rotation is the same or is clockwise adjacent,
                 // then we set an upper bound on the orientation angle.
-                // For example, if currentRotation is ROTATION_0 and proposed is ROTATION_270,
+                // For example, if currentRotation is ROTATION_0 and rotation is ROTATION_270,
                 // then we want to check orientationAngle < 315 - GAP / 2.
-                if (proposedRotation == currentRotation
-                        || proposedRotation == (currentRotation + 3) % 4) {
-                    int upperBound = proposedRotation * 90 + 45
+                if (rotation == currentRotation
+                        || rotation == (currentRotation + 3) % 4) {
+                    int upperBound = rotation * 90 + 45
                             - ADJACENT_ORIENTATION_ANGLE_GAP / 2;
-                    if (proposedRotation == 0) {
+                    if (rotation == 0) {
                         if (orientationAngle <= 45 && orientationAngle > upperBound) {
                             return false;
                         }
@@ -554,58 +597,97 @@
             return true;
         }
 
-        private void clearProposal() {
-            mProposalRotation = -1;
-            mProposalAgeMS = 0;
+        /**
+         * Returns true if the predicted rotation is ready to be advertised as a
+         * proposed rotation.
+         */
+        private boolean isPredictedRotationAcceptable(long now) {
+            // The predicted rotation must have settled long enough.
+            if (now < mPredictedRotationTimestampNanos + PROPOSAL_SETTLE_TIME_NANOS) {
+                return false;
+            }
+
+            // The last flat state (time since picked up) must have been sufficiently long ago.
+            if (now < mFlatTimestampNanos + PROPOSAL_MIN_TIME_SINCE_FLAT_ENDED_NANOS) {
+                return false;
+            }
+
+            // The last swing state (time since last movement to put down) must have been
+            // sufficiently long ago.
+            if (now < mSwingTimestampNanos + PROPOSAL_MIN_TIME_SINCE_SWING_ENDED_NANOS) {
+                return false;
+            }
+
+            // Looks good!
+            return true;
         }
 
-        private void updateProposal(int rotation, long timestampMS,
-                float magnitude, int tiltAngle, int orientationAngle) {
-            if (mProposalRotation != rotation) {
-                mProposalRotation = rotation;
-                mHistoryIndex = 0;
-                mHistoryLength = 0;
-            }
-
-            final int index = mHistoryIndex;
-            mHistoryTimestampMS[index] = timestampMS;
-            mHistoryMagnitudes[index] = magnitude;
-            mHistoryTiltAngles[index] = tiltAngle;
-            mHistoryOrientationAngles[index] = orientationAngle;
-            mHistoryIndex = (index + 1) % HISTORY_SIZE;
-            if (mHistoryLength < HISTORY_SIZE) {
-                mHistoryLength += 1;
-            }
-
-            long age = 0;
-            for (int i = 1; i < mHistoryLength; i++) {
-                final int olderIndex = (index + HISTORY_SIZE - i) % HISTORY_SIZE;
-                if (Math.abs(mHistoryMagnitudes[olderIndex] - magnitude)
-                        > SETTLE_MAGNITUDE_MAX_DELTA) {
-                    break;
-                }
-                if (angleAbsoluteDelta(mHistoryTiltAngles[olderIndex],
-                        tiltAngle) > SETTLE_TILT_ANGLE_MAX_DELTA) {
-                    break;
-                }
-                if (angleAbsoluteDelta(mHistoryOrientationAngles[olderIndex],
-                        orientationAngle) > SETTLE_ORIENTATION_ANGLE_MAX_DELTA) {
-                    break;
-                }
-                age = timestampMS - mHistoryTimestampMS[olderIndex];
-                if (age >= SETTLE_TIME_MS) {
-                    break;
-                }
-            }
-            mProposalAgeMS = age;
+        private void reset() {
+            mLastFilteredTimestampNanos = Long.MIN_VALUE;
+            mProposedRotation = -1;
+            mFlatTimestampNanos = Long.MIN_VALUE;
+            mSwingTimestampNanos = Long.MIN_VALUE;
+            clearPredictedRotation();
+            clearTiltHistory();
         }
 
-        private static int angleAbsoluteDelta(int a, int b) {
-            int delta = Math.abs(a - b);
-            if (delta > 180) {
-                delta = 360 - delta;
+        private void clearPredictedRotation() {
+            mPredictedRotation = -1;
+            mPredictedRotationTimestampNanos = Long.MIN_VALUE;
+        }
+
+        private void updatePredictedRotation(long now, int rotation) {
+            if (mPredictedRotation != rotation) {
+                mPredictedRotation = rotation;
+                mPredictedRotationTimestampNanos = now;
             }
-            return delta;
+        }
+
+        private void clearTiltHistory() {
+            mTiltHistoryTimestampNanos[0] = Long.MIN_VALUE;
+            mTiltHistoryIndex = 1;
+        }
+
+        private void addTiltHistoryEntry(long now, float tilt) {
+            mTiltHistory[mTiltHistoryIndex] = tilt;
+            mTiltHistoryTimestampNanos[mTiltHistoryIndex] = now;
+            mTiltHistoryIndex = (mTiltHistoryIndex + 1) % TILT_HISTORY_SIZE;
+            mTiltHistoryTimestampNanos[mTiltHistoryIndex] = Long.MIN_VALUE;
+        }
+
+        private boolean isFlat(long now) {
+            for (int i = mTiltHistoryIndex; (i = nextTiltHistoryIndex(i)) >= 0; ) {
+                if (mTiltHistory[i] < FLAT_ANGLE) {
+                    break;
+                }
+                if (mTiltHistoryTimestampNanos[i] + FLAT_TIME_NANOS <= now) {
+                    // Tilt has remained greater than FLAT_TILT_ANGLE for FLAT_TIME_NANOS.
+                    return true;
+                }
+            }
+            return false;
+        }
+
+        private boolean isSwinging(long now, float tilt) {
+            for (int i = mTiltHistoryIndex; (i = nextTiltHistoryIndex(i)) >= 0; ) {
+                if (mTiltHistoryTimestampNanos[i] + SWING_TIME_NANOS < now) {
+                    break;
+                }
+                if (mTiltHistory[i] + SWING_AWAY_ANGLE_DELTA <= tilt) {
+                    // Tilted away by SWING_AWAY_ANGLE_DELTA within SWING_TIME_NANOS.
+                    return true;
+                }
+            }
+            return false;
+        }
+
+        private int nextTiltHistoryIndex(int index) {
+            index = (index == 0 ? TILT_HISTORY_SIZE : index) - 1;
+            return mTiltHistoryTimestampNanos[index] != Long.MIN_VALUE ? index : -1;
+        }
+
+        private static float remainingMS(long now, long until) {
+            return now >= until ? 0 : (until - now) * 0.000001f;
         }
     }
 }
diff --git a/core/java/android/view/inputmethod/EditorInfo.java b/core/java/android/view/inputmethod/EditorInfo.java
index ac378fc..5146567 100644
--- a/core/java/android/view/inputmethod/EditorInfo.java
+++ b/core/java/android/view/inputmethod/EditorInfo.java
@@ -168,6 +168,22 @@
     public static final int IME_FLAG_NO_ENTER_ACTION = 0x40000000;
 
     /**
+     * Flag of {@link #imeOptions}: used to request that the IME is capable of
+     * inputting ASCII characters.  The intention of this flag is to ensure that
+     * the user can type Roman alphabet characters in a {@link android.widget.TextView}
+     * used for, typically, account ID or password input.  It is expected that IMEs
+     * normally are able to input ASCII even without being told so (such IMEs
+     * already respect this flag in a sense), but there could be some cases they
+     * aren't when, for instance, only non-ASCII input languagaes like Arabic,
+     * Greek, Hebrew, Russian are enabled in the IME.  Applications need to be
+     * aware that the flag is not a guarantee, and not all IMEs will respect it.
+     * However, it is strongly recommended for IME authors to respect this flag
+     * especially when their IME could end up with a state that has only non-ASCII
+     * input languages enabled.
+     */
+    public static final int IME_FLAG_FORCE_ASCII = 0x80000000;
+
+    /**
      * Generic unspecified type for {@link #imeOptions}.
      */
     public static final int IME_NULL = 0x00000000;
diff --git a/core/java/android/webkit/HTML5VideoViewProxy.java b/core/java/android/webkit/HTML5VideoViewProxy.java
index 7c2dc38..1c09bb9 100644
--- a/core/java/android/webkit/HTML5VideoViewProxy.java
+++ b/core/java/android/webkit/HTML5VideoViewProxy.java
@@ -162,6 +162,16 @@
                 mHTML5VideoView.enterFullScreenVideoState(layerId, proxy, webView);
         }
 
+        public static void exitFullScreenVideo(HTML5VideoViewProxy proxy,
+                WebView webView) {
+            if (!mHTML5VideoView.fullScreenExited() && mHTML5VideoView.isFullScreenMode()) {
+                WebChromeClient client = webView.getWebChromeClient();
+                if (client != null) {
+                    client.onHideCustomView();
+                }
+            }
+        }
+
         // This is on the UI thread.
         // When native tell Java to play, we need to check whether or not it is
         // still the same video by using videoLayerId and treat it differently.
@@ -682,6 +692,10 @@
         VideoPlayer.enterFullScreenVideo(layerId, url, this, mWebView);
     }
 
+    public void exitFullScreenVideo() {
+        VideoPlayer.exitFullScreenVideo(this, mWebView);
+    }
+
     /**
      * The factory for HTML5VideoViewProxy instances.
      * @param webViewCore is the WebViewCore that is requesting the proxy.
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java
index 168baad..69c15a6 100644
--- a/core/java/android/webkit/WebView.java
+++ b/core/java/android/webkit/WebView.java
@@ -327,6 +327,15 @@
  * property to {@code device-dpi}. This stops Android from performing scaling in your web page and
  * allows you to make the necessary adjustments for each density via CSS and JavaScript.</p>
  *
+ * <h3>HTML5 Video support</h3>
+ *
+ * <p>In order to support inline HTML5 video in your application, you need to have hardware
+ * acceleration turned on, and set a {@link android.webkit.WebChromeClient}. For full screen support,
+ * implementations of {@link WebChromeClient#onShowCustomView(View, WebChromeClient.CustomViewCallback)}
+ * and {@link WebChromeClient#onHideCustomView()} are required,
+ * {@link WebChromeClient#getVideoLoadingProgressView()} is optional.
+ * </p>
+ *
  *
  */
 @Widget
@@ -413,7 +422,7 @@
     private final Rect mViewRectViewport = new Rect();
     private final RectF mVisibleContentRect = new RectF();
     private boolean mGLViewportEmpty = false;
-    WebViewInputConnection mInputConnection = new WebViewInputConnection();
+    WebViewInputConnection mInputConnection = null;
 
 
     /**
@@ -611,6 +620,7 @@
     private boolean mIsPaused;
 
     private HitTestResult mInitialHitTestResult;
+    private WebKitHitTest mFocusedNode;
 
     /**
      * Customizable constant
@@ -702,13 +712,11 @@
 
     static boolean sDisableNavcache = false;
     // the color used to highlight the touch rectangles
-    private static final int HIGHLIGHT_COLOR = 0x6633b5e5;
-    // the round corner for the highlight path
-    private static final float TOUCH_HIGHLIGHT_ARC = 5.0f;
+    static final int HIGHLIGHT_COLOR = 0x6633b5e5;
     // the region indicating where the user touched on the screen
     private Region mTouchHighlightRegion = new Region();
     // the paint for the touch highlight
-    private Paint mTouchHightlightPaint;
+    private Paint mTouchHightlightPaint = new Paint();
     // debug only
     private static final boolean DEBUG_TOUCH_HIGHLIGHT = true;
     private static final int TOUCH_HIGHLIGHT_ELAPSE_TIME = 2000;
@@ -787,6 +795,7 @@
     static final int ENTER_FULLSCREEN_VIDEO             = 137;
     static final int UPDATE_SELECTION                   = 138;
     static final int UPDATE_ZOOM_DENSITY                = 139;
+    static final int EXIT_FULLSCREEN_VIDEO              = 140;
 
     private static final int FIRST_PACKAGE_MSG_ID = SCROLL_TO_MSG_ID;
     private static final int LAST_PACKAGE_MSG_ID = HIT_TEST_RESULT;
@@ -1073,6 +1082,15 @@
     }
 
     /**
+     * Refer to {@link WebView#requestFocusNodeHref(Message)} for more information
+     */
+    static class FocusNodeHref {
+        static final String TITLE = "title";
+        static final String URL = "url";
+        static final String SRC = "src";
+    }
+
+    /**
      * Construct a new WebView with a Context object.
      * @param context A Context object used to access application assets.
      */
@@ -2704,6 +2722,14 @@
         }
         int contentX = viewToContentX(mLastTouchX + mScrollX);
         int contentY = viewToContentY(mLastTouchY + mScrollY);
+        if (mFocusedNode != null && mFocusedNode.mHitTestX == contentX
+                && mFocusedNode.mHitTestY == contentY) {
+            hrefMsg.getData().putString(FocusNodeHref.URL, mFocusedNode.mLinkUrl);
+            hrefMsg.getData().putString(FocusNodeHref.TITLE, mFocusedNode.mAnchorText);
+            hrefMsg.getData().putString(FocusNodeHref.SRC, mFocusedNode.mImageUrl);
+            hrefMsg.sendToTarget();
+            return;
+        }
         if (nativeHasCursorNode()) {
             Rect cursorBounds = nativeGetCursorRingBounds();
             if (!cursorBounds.contains(contentX, contentY)) {
@@ -3742,6 +3768,8 @@
         nativeScrollLayer(mCurrentScrollingLayerId, x, y);
         mScrollingLayerRect.left = x;
         mScrollingLayerRect.top = y;
+        mWebViewCore.sendMessage(WebViewCore.EventHub.SCROLL_LAYER, mCurrentScrollingLayerId,
+                mScrollingLayerRect);
         onScrollChanged(mScrollX, mScrollY, mScrollX, mScrollY);
         invalidate();
     }
@@ -4400,10 +4428,6 @@
                 Rect r = mTouchHighlightRegion.getBounds();
                 postInvalidateDelayed(delay, r.left, r.top, r.right, r.bottom);
             } else {
-                if (mTouchHightlightPaint == null) {
-                    mTouchHightlightPaint = new Paint();
-                    mTouchHightlightPaint.setColor(HIGHLIGHT_COLOR);
-                }
                 RegionIterator iter = new RegionIterator(mTouchHighlightRegion);
                 Rect r = new Rect();
                 while (iter.next(r)) {
@@ -4918,15 +4942,13 @@
     }
 
     @Override
-    public boolean onCheckIsTextEditor() {
-        return true;
-    }
-
-    @Override
     public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
         outAttrs.imeOptions = EditorInfo.IME_FLAG_NO_FULLSCREEN
                 | EditorInfo.TYPE_CLASS_TEXT
                 | EditorInfo.TYPE_TEXT_VARIATION_NORMAL;
+        if (mInputConnection == null) {
+            mInputConnection = new WebViewInputConnection();
+        }
         return mInputConnection;
     }
 
@@ -8743,6 +8765,12 @@
                     }
                     break;
 
+                case EXIT_FULLSCREEN_VIDEO:
+                    if (mHTML5VideoViewProxy != null) {
+                        mHTML5VideoViewProxy.exitFullScreenVideo();
+                    }
+                    break;
+
                 case SHOW_FULLSCREEN: {
                     View view = (View) msg.obj;
                     int orientation = msg.arg1;
@@ -8837,13 +8865,25 @@
 
                 case HIT_TEST_RESULT:
                     WebKitHitTest hit = (WebKitHitTest) msg.obj;
-                    setTouchHighlightRects(hit != null ? hit.mTouchRects : null);
+                    mFocusedNode = hit;
+                    setTouchHighlightRects(hit);
                     if (hit == null) {
                         mInitialHitTestResult = null;
                     } else {
                         mInitialHitTestResult = new HitTestResult();
-                        mInitialHitTestResult.mType = hit.mType;
-                        mInitialHitTestResult.mExtra = hit.mExtra;
+                        if (hit.mLinkUrl != null) {
+                            mInitialHitTestResult.mType = HitTestResult.SRC_ANCHOR_TYPE;
+                            mInitialHitTestResult.mExtra = hit.mLinkUrl;
+                            if (hit.mImageUrl != null) {
+                                mInitialHitTestResult.mType = HitTestResult.SRC_IMAGE_ANCHOR_TYPE;
+                                mInitialHitTestResult.mExtra = hit.mImageUrl;
+                            }
+                        } else if (hit.mImageUrl != null) {
+                            mInitialHitTestResult.mType = HitTestResult.IMAGE_TYPE;
+                            mInitialHitTestResult.mExtra = hit.mImageUrl;
+                        } else if (hit.mEditable) {
+                            mInitialHitTestResult.mType = HitTestResult.EDIT_TEXT_TYPE;
+                        }
                     }
                     break;
 
@@ -8881,10 +8921,14 @@
         }
     }
 
-    private void setTouchHighlightRects(Rect[] rects) {
-        invalidate(mTouchHighlightRegion.getBounds());
-        mTouchHighlightRegion.setEmpty();
+    private void setTouchHighlightRects(WebKitHitTest hit) {
+        Rect[] rects = hit != null ? hit.mTouchRects : null;
+        if (!mTouchHighlightRegion.isEmpty()) {
+            invalidate(mTouchHighlightRegion.getBounds());
+            mTouchHighlightRegion.setEmpty();
+        }
         if (rects != null) {
+            mTouchHightlightPaint.setColor(hit.mTapHighlightColor);
             for (Rect rect : rects) {
                 Rect viewRect = contentToViewRect(rect);
                 // some sites, like stories in nytimes.com, set
diff --git a/core/java/android/webkit/WebViewCore.java b/core/java/android/webkit/WebViewCore.java
index 824f556..c4981e1 100644
--- a/core/java/android/webkit/WebViewCore.java
+++ b/core/java/android/webkit/WebViewCore.java
@@ -26,6 +26,7 @@
 import android.media.MediaFile;
 import android.net.ProxyProperties;
 import android.net.Uri;
+import android.os.Bundle;
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
@@ -37,6 +38,7 @@
 import android.view.MotionEvent;
 import android.view.SurfaceView;
 import android.view.View;
+import android.webkit.WebView.FocusNodeHref;
 
 import junit.framework.Assert;
 
@@ -502,6 +504,17 @@
     }
 
     /**
+     * Notify the webview that we want to exit the video fullscreen.
+     * This is called through JNI by webcore.
+     */
+    protected void exitFullscreenVideo() {
+        if (mWebView == null) return;
+        Message message = Message.obtain(mWebView.mPrivateHandler,
+                       WebView.EXIT_FULLSCREEN_VIDEO);
+        message.sendToTarget();
+    }
+
+    /**
      * Clear the picture set. To be called only on the WebCore thread.
      */
     /* package */ void clearContent() {
@@ -861,9 +874,20 @@
     }
 
     static class WebKitHitTest {
-        int mType;
-        String mExtra;
+        String mLinkUrl;
+        String mAnchorText;
+        String mImageUrl;
+        String mAltDisplayString;
+        String mTitle;
         Rect[] mTouchRects;
+        boolean mEditable;
+        int mTapHighlightColor = WebView.HIGHLIGHT_COLOR;
+
+        // These are the input values that produced this hit test
+        int mHitTestX;
+        int mHitTestY;
+        int mHitTestSlop;
+        boolean mHitTestMovedMouse;
     }
 
     static class AutoFillData {
@@ -1097,6 +1121,8 @@
 
         static final int HEARTBEAT = 197;
 
+        static final int SCROLL_LAYER = 198;
+
         // private message ids
         private static final int DESTROY =     200;
 
@@ -1512,13 +1538,12 @@
                             break;
 
                         case REQUEST_CURSOR_HREF: {
+                            WebKitHitTest hit = performHitTest(msg.arg1, msg.arg2, 1, false);
                             Message hrefMsg = (Message) msg.obj;
-                            hrefMsg.getData().putString("url",
-                                    nativeRetrieveHref(mNativeClass, msg.arg1, msg.arg2));
-                            hrefMsg.getData().putString("title",
-                                    nativeRetrieveAnchorText(mNativeClass, msg.arg1, msg.arg2));
-                            hrefMsg.getData().putString("src",
-                                    nativeRetrieveImageSource(mNativeClass, msg.arg1, msg.arg2));
+                            Bundle data = hrefMsg.getData();
+                            data.putString(FocusNodeHref.URL,hit.mLinkUrl);
+                            data.putString(FocusNodeHref.TITLE, hit.mAnchorText);
+                            data.putString(FocusNodeHref.SRC, hit.mImageUrl);
                             hrefMsg.sendToTarget();
                             break;
                         }
@@ -1683,8 +1708,7 @@
                                 nativeScrollLayer(mNativeClass,
                                         d.mNativeLayer, d.mNativeLayerRect);
                             }
-                            WebKitHitTest hit = nativeHitTest(mNativeClass,
-                                    d.mX, d.mY, d.mSlop);
+                            WebKitHitTest hit = performHitTest(d.mX, d.mY, d.mSlop, true);
                             mWebView.mPrivateHandler.obtainMessage(
                                     WebView.HIT_TEST_RESULT, hit)
                                     .sendToTarget();
@@ -1708,6 +1732,11 @@
                                 mBrowserFrame.stringByEvaluatingJavaScriptFromString((String) msg.obj);
                             }
                             break;
+                        case SCROLL_LAYER:
+                            int nativeLayer = msg.arg1;
+                            Rect rect = (Rect) msg.obj;
+                            nativeScrollLayer(mNativeClass, nativeLayer,
+                                    rect);
                     }
                 }
             };
@@ -1883,6 +1912,15 @@
     // WebViewCore private methods
     //-------------------------------------------------------------------------
 
+    private WebKitHitTest performHitTest(int x, int y, int slop, boolean moveMouse) {
+        WebKitHitTest hit = nativeHitTest(mNativeClass, x, y, slop, moveMouse);
+        hit.mHitTestX = x;
+        hit.mHitTestY = y;
+        hit.mHitTestSlop = slop;
+        hit.mHitTestMovedMouse = moveMouse;
+        return hit;
+    }
+
     private void clearCache(boolean includeDiskFiles) {
         mBrowserFrame.clearCache();
         if (includeDiskFiles) {
@@ -2933,7 +2971,8 @@
     private native boolean nativeValidNodeAndBounds(int nativeClass, int frame,
             int node, Rect bounds);
 
-    private native WebKitHitTest nativeHitTest(int nativeClass, int x, int y, int slop);
+    private native WebKitHitTest nativeHitTest(int nativeClass, int x, int y,
+            int slop, boolean moveMouse);
 
     private native void nativeAutoFillForm(int nativeClass, int queryId);
     private native void nativeScrollLayer(int nativeClass, int layer, Rect rect);
diff --git a/core/java/android/widget/AbsListView.java b/core/java/android/widget/AbsListView.java
index 38bb2e1..e94b1cb 100644
--- a/core/java/android/widget/AbsListView.java
+++ b/core/java/android/widget/AbsListView.java
@@ -20,7 +20,6 @@
 
 import android.content.Context;
 import android.content.Intent;
-import android.content.res.Resources;
 import android.content.res.TypedArray;
 import android.graphics.Canvas;
 import android.graphics.Rect;
@@ -1297,6 +1296,18 @@
         super.sendAccessibilityEvent(eventType);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AbsListView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AbsListView.class.getName());
+    }
+
     /**
      * Indicates whether the children's drawing cache is used during a scroll.
      * By default, the drawing cache is enabled but this will consume more memory.
@@ -5572,6 +5583,16 @@
     }
 
     /**
+     * Hints the RemoteViewsAdapter, if it exists, about which views are currently
+     * being displayed by the AbsListView.
+     */
+    void setVisibleRangeHint(int start, int end) {
+        if (mRemoteAdapter != null) {
+            mRemoteAdapter.setVisibleRangeHint(start, end);
+        }
+    }
+
+    /**
      * Sets the recycler listener to be notified whenever a View is set aside in
      * the recycler for later reuse. This listener can be used to free resources
      * associated to the View.
diff --git a/core/java/android/widget/AbsSeekBar.java b/core/java/android/widget/AbsSeekBar.java
index bdaf89e..e36afa3 100644
--- a/core/java/android/widget/AbsSeekBar.java
+++ b/core/java/android/widget/AbsSeekBar.java
@@ -25,6 +25,8 @@
 import android.view.KeyEvent;
 import android.view.MotionEvent;
 import android.view.ViewConfiguration;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 public abstract class AbsSeekBar extends ProgressBar {
     private Drawable mThumb;
@@ -464,4 +466,15 @@
         return super.onKeyDown(keyCode, event);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AbsSeekBar.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AbsSeekBar.class.getName());
+    }
 }
diff --git a/core/java/android/widget/AbsSpinner.java b/core/java/android/widget/AbsSpinner.java
index 3d79205..efdfae3 100644
--- a/core/java/android/widget/AbsSpinner.java
+++ b/core/java/android/widget/AbsSpinner.java
@@ -28,6 +28,8 @@
 import android.util.SparseArray;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * An abstract base class for spinner widgets. SDK users will probably not
@@ -40,7 +42,6 @@
 
     int mHeightMeasureSpec;
     int mWidthMeasureSpec;
-    boolean mBlockLayoutRequests;
 
     int mSelectionLeftPadding = 0;
     int mSelectionTopPadding = 0;
@@ -463,4 +464,16 @@
             scrapHeap.clear();
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AbsSpinner.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AbsSpinner.class.getName());
+    }
 }
diff --git a/core/java/android/widget/AdapterView.java b/core/java/android/widget/AdapterView.java
index 40df168..97a864c 100644
--- a/core/java/android/widget/AdapterView.java
+++ b/core/java/android/widget/AdapterView.java
@@ -913,6 +913,7 @@
     @Override
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AdapterView.class.getName());
         info.setScrollable(isScrollableForAccessibility());
         View selectedView = getSelectedView();
         if (selectedView != null) {
@@ -923,6 +924,7 @@
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AdapterView.class.getName());
         event.setScrollable(isScrollableForAccessibility());
         View selectedView = getSelectedView();
         if (selectedView != null) {
diff --git a/core/java/android/widget/AdapterViewAnimator.java b/core/java/android/widget/AdapterViewAnimator.java
index c83c780..e226d37 100644
--- a/core/java/android/widget/AdapterViewAnimator.java
+++ b/core/java/android/widget/AdapterViewAnimator.java
@@ -29,6 +29,8 @@
 import android.view.View;
 import android.view.ViewConfiguration;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import java.util.ArrayList;
 import java.util.HashMap;
@@ -555,6 +557,9 @@
             mCurrentWindowStart = newWindowStart;
             mCurrentWindowEnd = newWindowEnd;
             mCurrentWindowStartUnbounded = newWindowStartUnbounded;
+            if (mRemoteViewsAdapter != null) {
+                mRemoteViewsAdapter.setVisibleRangeHint(mCurrentWindowStart, mCurrentWindowEnd);
+            }
         }
         requestLayout();
         invalidate();
@@ -1045,4 +1050,16 @@
      */
     public void fyiWillBeAdvancedByHostKThx() {
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AdapterViewAnimator.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AdapterViewAnimator.class.getName());
+    }
 }
diff --git a/core/java/android/widget/AdapterViewFlipper.java b/core/java/android/widget/AdapterViewFlipper.java
index 4419886..5096227 100644
--- a/core/java/android/widget/AdapterViewFlipper.java
+++ b/core/java/android/widget/AdapterViewFlipper.java
@@ -16,7 +16,6 @@
 
 package android.widget;
 
-import android.animation.ObjectAnimator;
 import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
@@ -27,7 +26,8 @@
 import android.util.AttributeSet;
 import android.util.Log;
 import android.view.RemotableViewMethod;
-import android.view.animation.AlphaAnimation;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 /**
@@ -268,4 +268,16 @@
         mAdvancedByHost = true;
         updateRunning(false);
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(AdapterViewFlipper.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(AdapterViewFlipper.class.getName());
+    }
 }
diff --git a/core/java/android/widget/Button.java b/core/java/android/widget/Button.java
index 8d58a6d..99f4cae 100644
--- a/core/java/android/widget/Button.java
+++ b/core/java/android/widget/Button.java
@@ -18,9 +18,8 @@
 
 import android.content.Context;
 import android.util.AttributeSet;
-import android.util.Log;
-import android.view.MotionEvent;
-import android.view.KeyEvent;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 
@@ -107,4 +106,16 @@
     public Button(Context context, AttributeSet attrs, int defStyle) {
         super(context, attrs, defStyle);
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(Button.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(Button.class.getName());
+    }
 }
diff --git a/core/java/android/widget/CalendarView.java b/core/java/android/widget/CalendarView.java
index e0403ff..85252af 100644
--- a/core/java/android/widget/CalendarView.java
+++ b/core/java/android/widget/CalendarView.java
@@ -39,6 +39,8 @@
 import android.view.MotionEvent;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.AbsListView.OnScrollListener;
 
 import com.android.internal.R;
@@ -431,6 +433,18 @@
         setCurrentLocale(newConfig.locale);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(CalendarView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(CalendarView.class.getName());
+    }
+
     /**
      * Gets the minimal date supported by this {@link CalendarView} in milliseconds
      * since January 1, 1970 00:00:00 in {@link TimeZone#getDefault()} time
diff --git a/core/java/android/widget/CheckBox.java b/core/java/android/widget/CheckBox.java
index 2788846..0685eea 100644
--- a/core/java/android/widget/CheckBox.java
+++ b/core/java/android/widget/CheckBox.java
@@ -19,6 +19,7 @@
 import android.content.Context;
 import android.util.AttributeSet;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import com.android.internal.R;
 
@@ -78,4 +79,16 @@
             event.getText().add(mContext.getString(R.string.checkbox_not_checked));
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(CheckBox.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(CheckBox.class.getName());
+    }
 }
diff --git a/core/java/android/widget/CheckedTextView.java b/core/java/android/widget/CheckedTextView.java
index 0a54743..5c7e5a3 100644
--- a/core/java/android/widget/CheckedTextView.java
+++ b/core/java/android/widget/CheckedTextView.java
@@ -220,6 +220,7 @@
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(CheckedTextView.class.getName());
         event.setChecked(mChecked);
     }
 
@@ -236,6 +237,7 @@
     @Override
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(CheckedTextView.class.getName());
         info.setChecked(mChecked);
     }
 }
diff --git a/core/java/android/widget/Chronometer.java b/core/java/android/widget/Chronometer.java
index 7e66722..0370049 100644
--- a/core/java/android/widget/Chronometer.java
+++ b/core/java/android/widget/Chronometer.java
@@ -25,6 +25,8 @@
 import android.text.format.DateUtils;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 import java.util.Formatter;
@@ -276,4 +278,16 @@
             mOnChronometerTickListener.onChronometerTick(this);
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(Chronometer.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(Chronometer.class.getName());
+    }
 }
diff --git a/core/java/android/widget/CompoundButton.java b/core/java/android/widget/CompoundButton.java
index d3cdad8..02c4c4f 100644
--- a/core/java/android/widget/CompoundButton.java
+++ b/core/java/android/widget/CompoundButton.java
@@ -211,12 +211,14 @@
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(CompoundButton.class.getName());
         event.setChecked(mChecked);
     }
 
     @Override
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(CompoundButton.class.getName());
         info.setCheckable(true);
         info.setChecked(mChecked);
     }
diff --git a/core/java/android/widget/DatePicker.java b/core/java/android/widget/DatePicker.java
index 0f462ff..110c8f3 100644
--- a/core/java/android/widget/DatePicker.java
+++ b/core/java/android/widget/DatePicker.java
@@ -31,6 +31,7 @@
 import android.view.LayoutInflater;
 import android.view.accessibility.AccessibilityEvent;
 import android.view.accessibility.AccessibilityManager;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.InputMethodManager;
 import android.widget.NumberPicker.OnValueChangeListener;
@@ -391,6 +392,18 @@
     }
 
     @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(DatePicker.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(DatePicker.class.getName());
+    }
+
+    @Override
     protected void onConfigurationChanged(Configuration newConfig) {
         super.onConfigurationChanged(newConfig);
         setCurrentLocale(newConfig.locale);
diff --git a/core/java/android/widget/DigitalClock.java b/core/java/android/widget/DigitalClock.java
index 379883a..add9d9b 100644
--- a/core/java/android/widget/DigitalClock.java
+++ b/core/java/android/widget/DigitalClock.java
@@ -24,6 +24,8 @@
 import android.provider.Settings;
 import android.text.format.DateFormat;
 import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import java.util.Calendar;
 
@@ -126,4 +128,16 @@
             setFormat();
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(DigitalClock.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(DigitalClock.class.getName());
+    }
 }
diff --git a/core/java/android/widget/EditText.java b/core/java/android/widget/EditText.java
index 0da68a4..2fd8768 100644
--- a/core/java/android/widget/EditText.java
+++ b/core/java/android/widget/EditText.java
@@ -24,6 +24,8 @@
 import android.text.method.ArrowKeyMovementMethod;
 import android.text.method.MovementMethod;
 import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 /*
@@ -114,4 +116,16 @@
         }
         super.setEllipsize(ellipsis);
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(EditText.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(EditText.class.getName());
+    }
 }
diff --git a/core/java/android/widget/ExpandableListView.java b/core/java/android/widget/ExpandableListView.java
index ead9b4f..badfaa7 100644
--- a/core/java/android/widget/ExpandableListView.java
+++ b/core/java/android/widget/ExpandableListView.java
@@ -30,6 +30,8 @@
 import android.view.SoundEffectConstants;
 import android.view.View;
 import android.view.ContextMenu.ContextMenuInfo;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.ExpandableListConnector.PositionMetadata;
 
 import java.util.ArrayList;
@@ -1167,4 +1169,15 @@
         }
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ExpandableListView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ExpandableListView.class.getName());
+    }
 }
diff --git a/core/java/android/widget/FrameLayout.java b/core/java/android/widget/FrameLayout.java
index 74a57b0..da98884 100644
--- a/core/java/android/widget/FrameLayout.java
+++ b/core/java/android/widget/FrameLayout.java
@@ -29,6 +29,8 @@
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 
@@ -555,6 +557,19 @@
         return new LayoutParams(p);
     }
 
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(FrameLayout.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(FrameLayout.class.getName());
+    }
+
     /**
      * Per-child layout information for layouts that support margins.
      * See {@link android.R.styleable#FrameLayout_Layout FrameLayout Layout Attributes}
diff --git a/core/java/android/widget/Gallery.java b/core/java/android/widget/Gallery.java
index 5e37fa8..03fdc39 100644
--- a/core/java/android/widget/Gallery.java
+++ b/core/java/android/widget/Gallery.java
@@ -32,6 +32,8 @@
 import android.view.View;
 import android.view.ViewConfiguration;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.Transformation;
 
 import com.android.internal.R;
@@ -1355,6 +1357,18 @@
 
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(Gallery.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(Gallery.class.getName());
+    }
+
     /**
      * Responsible for fling behavior. Use {@link #startUsingVelocity(int)} to
      * initiate a fling. Each frame of the fling is handled in {@link #run()}.
diff --git a/core/java/android/widget/GridLayout.java b/core/java/android/widget/GridLayout.java
index 7cf5168..7d58011 100644
--- a/core/java/android/widget/GridLayout.java
+++ b/core/java/android/widget/GridLayout.java
@@ -27,6 +27,9 @@
 import android.view.Gravity;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
+
 import com.android.internal.R;
 
 import java.lang.reflect.Array;
@@ -1041,6 +1044,18 @@
         }
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(GridLayout.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(GridLayout.class.getName());
+    }
+
     // Inner classes
 
     /*
diff --git a/core/java/android/widget/GridView.java b/core/java/android/widget/GridView.java
index 5d406de..be2df8e 100644
--- a/core/java/android/widget/GridView.java
+++ b/core/java/android/widget/GridView.java
@@ -27,6 +27,8 @@
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.GridLayoutAnimationController;
 import android.widget.RemoteViews.RemoteView;
 
@@ -290,6 +292,7 @@
             pos += mNumColumns;
         }
 
+        setVisibleRangeHint(mFirstPosition, mFirstPosition + getChildCount() - 1);
         return selectedView;
     }
 
@@ -382,6 +385,7 @@
             mFirstPosition = Math.max(0, pos + 1);
         }
 
+        setVisibleRangeHint(mFirstPosition, mFirstPosition + getChildCount() - 1);
         return selectedView;
     }
 
@@ -2116,5 +2120,16 @@
         }
         return result;
     }
-}
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(GridView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(GridView.class.getName());
+    }
+}
diff --git a/core/java/android/widget/HorizontalScrollView.java b/core/java/android/widget/HorizontalScrollView.java
index 1683d20..0b4ebf4 100644
--- a/core/java/android/widget/HorizontalScrollView.java
+++ b/core/java/android/widget/HorizontalScrollView.java
@@ -721,12 +721,14 @@
     @Override
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(HorizontalScrollView.class.getName());
         info.setScrollable(getScrollRange() > 0);
     }
 
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(HorizontalScrollView.class.getName());
         event.setScrollable(getScrollRange() > 0);
         event.setScrollX(mScrollX);
         event.setScrollY(mScrollY);
diff --git a/core/java/android/widget/ImageButton.java b/core/java/android/widget/ImageButton.java
index d680fad..59a8f28 100644
--- a/core/java/android/widget/ImageButton.java
+++ b/core/java/android/widget/ImageButton.java
@@ -21,6 +21,8 @@
 import android.os.Message;
 import android.util.AttributeSet;
 import android.view.MotionEvent;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 import java.util.Map;
@@ -90,4 +92,16 @@
     protected boolean onSetAlpha(int alpha) {
         return false;
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ImageButton.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ImageButton.class.getName());
+    }
 }
diff --git a/core/java/android/widget/ImageSwitcher.java b/core/java/android/widget/ImageSwitcher.java
index bcb750a..c048970 100644
--- a/core/java/android/widget/ImageSwitcher.java
+++ b/core/java/android/widget/ImageSwitcher.java
@@ -16,12 +16,12 @@
 
 package android.widget;
 
-import java.util.Map;
-
 import android.content.Context;
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
 import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 public class ImageSwitcher extends ViewSwitcher
@@ -55,5 +55,16 @@
         image.setImageDrawable(drawable);
         showNext();
     }
-}
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ImageSwitcher.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ImageSwitcher.class.getName());
+    }
+}
diff --git a/core/java/android/widget/ImageView.java b/core/java/android/widget/ImageView.java
index 73e1273..07ae93b 100644
--- a/core/java/android/widget/ImageView.java
+++ b/core/java/android/widget/ImageView.java
@@ -37,6 +37,7 @@
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 /**
@@ -1060,4 +1061,16 @@
             mDrawable.setVisible(false, false);
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ImageView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ImageView.class.getName());
+    }
 }
diff --git a/core/java/android/widget/LinearLayout.java b/core/java/android/widget/LinearLayout.java
index 427fd3e..b5deec7 100644
--- a/core/java/android/widget/LinearLayout.java
+++ b/core/java/android/widget/LinearLayout.java
@@ -27,6 +27,8 @@
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 
@@ -1729,7 +1731,19 @@
     protected boolean checkLayoutParams(ViewGroup.LayoutParams p) {
         return p instanceof LinearLayout.LayoutParams;
     }
-    
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(LinearLayout.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(LinearLayout.class.getName());
+    }
+
     /**
      * Per-child layout information associated with ViewLinearLayout.
      * 
diff --git a/core/java/android/widget/ListView.java b/core/java/android/widget/ListView.java
index 7f7a3a7..e20d12a 100644
--- a/core/java/android/widget/ListView.java
+++ b/core/java/android/widget/ListView.java
@@ -32,13 +32,13 @@
 import android.util.SparseBooleanArray;
 import android.view.FocusFinder;
 import android.view.KeyEvent;
-import android.view.MotionEvent;
 import android.view.SoundEffectConstants;
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.ViewGroup;
 import android.view.ViewParent;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 import java.util.ArrayList;
@@ -678,6 +678,7 @@
             pos++;
         }
 
+        setVisibleRangeHint(mFirstPosition, mFirstPosition + getChildCount() - 1);
         return selectedView;
     }
 
@@ -711,7 +712,7 @@
         }
 
         mFirstPosition = pos + 1;
-
+        setVisibleRangeHint(mFirstPosition, mFirstPosition + getChildCount() - 1);
         return selectedView;
     }
 
@@ -3609,4 +3610,16 @@
         }
         return new long[0];
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ListView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ListView.class.getName());
+    }
 }
diff --git a/core/java/android/widget/MediaController.java b/core/java/android/widget/MediaController.java
index f2ea3fc..fc35f05 100644
--- a/core/java/android/widget/MediaController.java
+++ b/core/java/android/widget/MediaController.java
@@ -31,6 +31,8 @@
 import android.view.ViewGroup;
 import android.view.Window;
 import android.view.WindowManager;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.SeekBar.OnSeekBarChangeListener;
 
 import com.android.internal.policy.PolicyManager;
@@ -592,6 +594,18 @@
         super.setEnabled(enabled);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(MediaController.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(MediaController.class.getName());
+    }
+
     private View.OnClickListener mRewListener = new View.OnClickListener() {
         public void onClick(View v) {
             int pos = mPlayer.getCurrentPosition();
diff --git a/core/java/android/widget/MultiAutoCompleteTextView.java b/core/java/android/widget/MultiAutoCompleteTextView.java
index 134e4c4..0b30c84 100644
--- a/core/java/android/widget/MultiAutoCompleteTextView.java
+++ b/core/java/android/widget/MultiAutoCompleteTextView.java
@@ -23,7 +23,8 @@
 import android.text.TextUtils;
 import android.text.method.QwertyKeyListener;
 import android.util.AttributeSet;
-import android.widget.MultiAutoCompleteTextView.Tokenizer;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * An editable text view, extending {@link AutoCompleteTextView}, that
@@ -196,6 +197,18 @@
         editable.replace(start, end, mTokenizer.terminateToken(text));
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(MultiAutoCompleteTextView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(MultiAutoCompleteTextView.class.getName());
+    }
+
     public static interface Tokenizer {
         /**
          * Returns the start of the token that ends at offset
diff --git a/core/java/android/widget/NumberPicker.java b/core/java/android/widget/NumberPicker.java
index 7d0f98e..a210f0b 100644
--- a/core/java/android/widget/NumberPicker.java
+++ b/core/java/android/widget/NumberPicker.java
@@ -47,6 +47,7 @@
 import android.view.ViewConfiguration;
 import android.view.accessibility.AccessibilityEvent;
 import android.view.accessibility.AccessibilityManager;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.DecelerateInterpolator;
 import android.view.inputmethod.InputMethodManager;
 
@@ -1382,6 +1383,18 @@
         // perceive this widget as several controls rather as a whole.
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(NumberPicker.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(NumberPicker.class.getName());
+    }
+
     /**
      * Makes a measure spec that tries greedily to use the max value.
      *
diff --git a/core/java/android/widget/ProgressBar.java b/core/java/android/widget/ProgressBar.java
index df88fec..ace3f60 100644
--- a/core/java/android/widget/ProgressBar.java
+++ b/core/java/android/widget/ProgressBar.java
@@ -45,6 +45,7 @@
 import android.view.ViewDebug;
 import android.view.accessibility.AccessibilityEvent;
 import android.view.accessibility.AccessibilityManager;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.AlphaAnimation;
 import android.view.animation.Animation;
 import android.view.animation.AnimationUtils;
@@ -1124,10 +1125,17 @@
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ProgressBar.class.getName());
         event.setItemCount(mMax);
         event.setCurrentItemIndex(mProgress);
     }
 
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ProgressBar.class.getName());
+    }
+
     /**
      * Schedule a command for sending an accessibility event.
      * </br>
diff --git a/core/java/android/widget/QuickContactBadge.java b/core/java/android/widget/QuickContactBadge.java
index adc0fb0..786afe2 100644
--- a/core/java/android/widget/QuickContactBadge.java
+++ b/core/java/android/widget/QuickContactBadge.java
@@ -36,6 +36,8 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.View.OnClickListener;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * Widget used to show an image with the standard QuickContact badge
@@ -228,6 +230,18 @@
         }
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(QuickContactBadge.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(QuickContactBadge.class.getName());
+    }
+
     /**
      * Set a list of specific MIME-types to exclude and not display. For
      * example, this can be used to hide the {@link Contacts#CONTENT_ITEM_TYPE}
diff --git a/core/java/android/widget/RadioButton.java b/core/java/android/widget/RadioButton.java
index 9fa649f..b6dac3e 100644
--- a/core/java/android/widget/RadioButton.java
+++ b/core/java/android/widget/RadioButton.java
@@ -19,6 +19,7 @@
 import android.content.Context;
 import android.util.AttributeSet;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import com.android.internal.R;
 
@@ -85,4 +86,16 @@
             event.getText().add(mContext.getString(R.string.radiobutton_not_selected));
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(RadioButton.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(RadioButton.class.getName());
+    }
 }
diff --git a/core/java/android/widget/RadioGroup.java b/core/java/android/widget/RadioGroup.java
index 393346a..7f53ffd 100644
--- a/core/java/android/widget/RadioGroup.java
+++ b/core/java/android/widget/RadioGroup.java
@@ -23,6 +23,8 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 /**
@@ -236,6 +238,18 @@
         return new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(RadioGroup.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(RadioGroup.class.getName());
+    }
+
     /**
      * <p>This set of layout parameters defaults the width and the height of
      * the children to {@link #WRAP_CONTENT} when they are not specified in the
diff --git a/core/java/android/widget/RatingBar.java b/core/java/android/widget/RatingBar.java
index 9e6ff4b..e69577b 100644
--- a/core/java/android/widget/RatingBar.java
+++ b/core/java/android/widget/RatingBar.java
@@ -21,6 +21,8 @@
 import android.graphics.drawable.shapes.RectShape;
 import android.graphics.drawable.shapes.Shape;
 import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import com.android.internal.R;
 
@@ -324,4 +326,15 @@
         super.setMax(max);
     }
     
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(RatingBar.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(RatingBar.class.getName());
+    }
 }
diff --git a/core/java/android/widget/RelativeLayout.java b/core/java/android/widget/RelativeLayout.java
index a452fec..e4b8f34 100644
--- a/core/java/android/widget/RelativeLayout.java
+++ b/core/java/android/widget/RelativeLayout.java
@@ -40,6 +40,7 @@
 import android.view.ViewDebug;
 import android.view.ViewGroup;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 import static android.util.Log.d;
@@ -985,6 +986,18 @@
         return false;
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(RelativeLayout.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(RelativeLayout.class.getName());
+    }
+
     /**
      * Compares two views in left-to-right and top-to-bottom fashion.
      */
diff --git a/core/java/android/widget/RemoteViewsAdapter.java b/core/java/android/widget/RemoteViewsAdapter.java
index 7b43032..586fdf4 100644
--- a/core/java/android/widget/RemoteViewsAdapter.java
+++ b/core/java/android/widget/RemoteViewsAdapter.java
@@ -68,6 +68,8 @@
     private RemoteViewsAdapterServiceConnection mServiceConnection;
     private WeakReference<RemoteAdapterConnectionCallback> mCallback;
     private FixedSizeRemoteViewsCache mCache;
+    private int mVisibleWindowLowerBound;
+    private int mVisibleWindowUpperBound;
 
     // A flag to determine whether we should notify data set changed after we connect
     private boolean mNotifyDataSetChangedAfterOnServiceConnected = false;
@@ -765,7 +767,7 @@
                     }
                     if (position > -1) {
                         // Load the item, and notify any existing RemoteViewsFrameLayouts
-                        updateRemoteViews(position, isRequested);
+                        updateRemoteViews(position, isRequested, true);
 
                         // Queue up for the next one to load
                         loadNextIndexInBackground();
@@ -827,8 +829,8 @@
         }
     }
 
-    private void updateRemoteViews(final int position, boolean isRequested) {
-        if (!mServiceConnection.isConnected()) return;
+    private void updateRemoteViews(final int position, boolean isRequested, boolean
+            notifyWhenLoaded) {
         IRemoteViewsFactory factory = mServiceConnection.getRemoteViewsFactory();
 
         // Load the item information from the remote service
@@ -864,12 +866,14 @@
             // there is new data for it.
             final RemoteViews rv = remoteViews;
             final int typeId = mCache.getMetaDataAt(position).typeId;
-            mMainQueue.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRequestedViews.notifyOnRemoteViewsLoaded(position, rv, typeId);
-                }
-            });
+            if (notifyWhenLoaded) {
+                mMainQueue.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        mRequestedViews.notifyOnRemoteViewsLoaded(position, rv, typeId);
+                    }
+                });
+            }
         }
     }
 
@@ -929,6 +933,16 @@
         return typeId;
     }
 
+    /**
+     * This method allows an AdapterView using this Adapter to provide information about which
+     * views are currently being displayed. This allows for certain optimizations and preloading
+     * which  wouldn't otherwise be possible.
+     */
+    public void setVisibleRangeHint(int lowerBound, int upperBound) {
+        mVisibleWindowLowerBound = lowerBound;
+        mVisibleWindowUpperBound = upperBound;
+    }
+
     public View getView(int position, View convertView, ViewGroup parent) {
         // "Request" an index so that we can queue it for loading, initiate subsequent
         // preloading, etc.
@@ -1059,6 +1073,13 @@
         // Re-request the new metadata (only after the notification to the factory)
         updateTemporaryMetaData();
 
+        // Pre-load (our best guess of) the views which are currently visible in the AdapterView.
+        // This mitigates flashing and flickering of loading views when a widget notifies that
+        // its data has changed.
+        for (int i = mVisibleWindowLowerBound; i <= mVisibleWindowUpperBound; i++) {
+            updateRemoteViews(i, false, false);
+        }
+
         // Propagate the notification back to the base adapter
         mMainQueue.post(new Runnable() {
             @Override
diff --git a/core/java/android/widget/ScrollView.java b/core/java/android/widget/ScrollView.java
index 767eaee..3ffc0fe 100644
--- a/core/java/android/widget/ScrollView.java
+++ b/core/java/android/widget/ScrollView.java
@@ -721,12 +721,14 @@
     @Override
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ScrollView.class.getName());
         info.setScrollable(getScrollRange() > 0);
     }
 
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ScrollView.class.getName());
         final boolean scrollable = getScrollRange() > 0;
         event.setScrollable(scrollable);
         event.setScrollX(mScrollX);
diff --git a/core/java/android/widget/SearchView.java b/core/java/android/widget/SearchView.java
index 9d2ff2e..99cd0b8 100644
--- a/core/java/android/widget/SearchView.java
+++ b/core/java/android/widget/SearchView.java
@@ -35,7 +35,6 @@
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
 import android.os.Bundle;
-import android.os.Handler;
 import android.speech.RecognizerIntent;
 import android.text.Editable;
 import android.text.InputType;
@@ -51,6 +50,8 @@
 import android.view.KeyEvent;
 import android.view.LayoutInflater;
 import android.view.View;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.InputMethodManager;
 import android.widget.AdapterView.OnItemClickListener;
@@ -1206,6 +1207,18 @@
         setIconified(false);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(SearchView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(SearchView.class.getName());
+    }
+
     private void adjustDropDownSizeAndPosition() {
         if (mDropDownAnchor.getWidth() > 1) {
             Resources res = getContext().getResources();
diff --git a/core/java/android/widget/SeekBar.java b/core/java/android/widget/SeekBar.java
index c76728f..2737f94 100644
--- a/core/java/android/widget/SeekBar.java
+++ b/core/java/android/widget/SeekBar.java
@@ -18,6 +18,8 @@
 
 import android.content.Context;
 import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 
@@ -117,5 +119,16 @@
             mOnSeekBarChangeListener.onStopTrackingTouch(this);
         }
     }
-    
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(SeekBar.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(SeekBar.class.getName());
+    }
 }
diff --git a/core/java/android/widget/SlidingDrawer.java b/core/java/android/widget/SlidingDrawer.java
index bdeb5c2..14edd10 100644
--- a/core/java/android/widget/SlidingDrawer.java
+++ b/core/java/android/widget/SlidingDrawer.java
@@ -32,6 +32,7 @@
 import android.view.View;
 import android.view.ViewGroup;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * SlidingDrawer hides content out of the screen and allows the user to drag a handle
@@ -810,6 +811,18 @@
         }
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(SlidingDrawer.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(SlidingDrawer.class.getName());
+    }
+
     private void closeDrawer() {
         moveHandle(COLLAPSED_FULL_CLOSED);
         mContent.setVisibility(View.GONE);
diff --git a/core/java/android/widget/Spinner.java b/core/java/android/widget/Spinner.java
index ec3790e..ecf19b3 100644
--- a/core/java/android/widget/Spinner.java
+++ b/core/java/android/widget/Spinner.java
@@ -29,6 +29,8 @@
 import android.view.Gravity;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 /**
@@ -456,12 +458,24 @@
 
         return handled;
     }
-    
+
     public void onClick(DialogInterface dialog, int which) {
         setSelection(which);
         dialog.dismiss();
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(Spinner.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(Spinner.class.getName());
+    }
+
     /**
      * Sets the prompt to display when the dialog is shown.
      * @param prompt the prompt to set
diff --git a/core/java/android/widget/StackView.java b/core/java/android/widget/StackView.java
index 03e6e99..22df3bc 100644
--- a/core/java/android/widget/StackView.java
+++ b/core/java/android/widget/StackView.java
@@ -40,6 +40,8 @@
 import android.view.View;
 import android.view.ViewConfiguration;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.LinearInterpolator;
 import android.widget.RemoteViews.RemoteView;
 
@@ -1216,6 +1218,18 @@
         measureChildren();
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(StackView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(StackView.class.getName());
+    }
+
     class LayoutParams extends ViewGroup.LayoutParams {
         int horizontalOffset;
         int verticalOffset;
diff --git a/core/java/android/widget/Switch.java b/core/java/android/widget/Switch.java
index 02c9d03..334b9c4 100644
--- a/core/java/android/widget/Switch.java
+++ b/core/java/android/widget/Switch.java
@@ -35,6 +35,7 @@
 import android.view.VelocityTracker;
 import android.view.ViewConfiguration;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import com.android.internal.R;
 
@@ -651,4 +652,16 @@
         mThumbDrawable.jumpToCurrentState();
         mTrackDrawable.jumpToCurrentState();
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(Switch.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(Switch.class.getName());
+    }
 }
diff --git a/core/java/android/widget/TabHost.java b/core/java/android/widget/TabHost.java
index 88d7230..9b292be 100644
--- a/core/java/android/widget/TabHost.java
+++ b/core/java/android/widget/TabHost.java
@@ -33,6 +33,8 @@
 import android.view.ViewGroup;
 import android.view.ViewTreeObserver;
 import android.view.Window;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -321,6 +323,18 @@
         }
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TabHost.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TabHost.class.getName());
+    }
+
     public void setCurrentTab(int index) {
         if (index < 0 || index >= mTabSpecs.size()) {
             return;
diff --git a/core/java/android/widget/TabWidget.java b/core/java/android/widget/TabWidget.java
index 80bfe99..8901037 100644
--- a/core/java/android/widget/TabWidget.java
+++ b/core/java/android/widget/TabWidget.java
@@ -29,6 +29,7 @@
 import android.view.View.OnFocusChangeListener;
 import android.view.ViewGroup;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  *
@@ -416,10 +417,28 @@
     @Override
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TabWidget.class.getName());
         event.setItemCount(getTabCount());
         event.setCurrentItemIndex(mSelectedTab);
     }
 
+
+    @Override
+    public void sendAccessibilityEventUnchecked(AccessibilityEvent event) {
+        // this class fires events only when tabs are focused or selected
+        if (event.getEventType() == AccessibilityEvent.TYPE_VIEW_FOCUSED && isFocused()) {
+            event.recycle();
+            return;
+        }
+        super.sendAccessibilityEventUnchecked(event);
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TabWidget.class.getName());
+    }
+
     /**
      * Sets the current tab and focuses the UI on it.
      * This method makes sure that the focused tab matches the selected
@@ -485,16 +504,6 @@
         mSelectedTab = -1;
     }
 
-    @Override
-    public void sendAccessibilityEventUnchecked(AccessibilityEvent event) {
-        // this class fires events only when tabs are focused or selected
-        if (event.getEventType() == AccessibilityEvent.TYPE_VIEW_FOCUSED && isFocused()) {
-            event.recycle();
-            return;
-        }
-        super.sendAccessibilityEventUnchecked(event);
-    }
-
     /**
      * Provides a way for {@link TabHost} to be notified that the user clicked on a tab indicator.
      */
diff --git a/core/java/android/widget/TableLayout.java b/core/java/android/widget/TableLayout.java
index 842b087..f5d3746 100644
--- a/core/java/android/widget/TableLayout.java
+++ b/core/java/android/widget/TableLayout.java
@@ -24,6 +24,8 @@
 import android.util.SparseBooleanArray;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import java.util.regex.Pattern;
 
@@ -658,6 +660,18 @@
         return new LayoutParams(p);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TableLayout.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TableLayout.class.getName());
+    }
+
     /**
      * <p>This set of layout parameters enforces the width of each child to be
      * {@link #MATCH_PARENT} and the height of each child to be
diff --git a/core/java/android/widget/TableRow.java b/core/java/android/widget/TableRow.java
index 3fd4631..01c4c2c 100644
--- a/core/java/android/widget/TableRow.java
+++ b/core/java/android/widget/TableRow.java
@@ -24,6 +24,8 @@
 import android.view.View;
 import android.view.ViewDebug;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 
 /**
@@ -377,6 +379,18 @@
         return new LayoutParams(p);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TableRow.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TableRow.class.getName());
+    }
+
     /**
      * <p>Set of layout parameters used in table rows.</p>
      *
diff --git a/core/java/android/widget/TextSwitcher.java b/core/java/android/widget/TextSwitcher.java
index a8794a3..1aefd2b 100644
--- a/core/java/android/widget/TextSwitcher.java
+++ b/core/java/android/widget/TextSwitcher.java
@@ -21,6 +21,8 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * Specialized {@link android.widget.ViewSwitcher} that contains
@@ -88,4 +90,16 @@
     public void setCurrentText(CharSequence text) {
         ((TextView)getCurrentView()).setText(text);
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TextSwitcher.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TextSwitcher.class.getName());
+    }
 }
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index 3dd7a9f..02144a8 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -84,6 +84,7 @@
 import android.text.method.TransformationMethod;
 import android.text.method.TransformationMethod2;
 import android.text.method.WordIterator;
+import android.text.style.CharacterStyle;
 import android.text.style.ClickableSpan;
 import android.text.style.EasyEditSpan;
 import android.text.style.ParagraphStyle;
@@ -101,9 +102,11 @@
 import android.util.TypedValue;
 import android.view.ActionMode;
 import android.view.ActionMode.Callback;
+import android.view.DisplayList;
 import android.view.DragEvent;
 import android.view.Gravity;
 import android.view.HapticFeedbackConstants;
+import android.view.HardwareCanvas;
 import android.view.KeyCharacterMap;
 import android.view.KeyEvent;
 import android.view.LayoutInflater;
@@ -283,6 +286,9 @@
     }
     private Drawables mDrawables;
 
+    private DisplayList mTextDisplayList;
+    private boolean mTextDisplayListIsValid;
+
     private CharSequence mError;
     private boolean mErrorWasChanged;
     private ErrorPopup mPopup;
@@ -4520,6 +4526,10 @@
 
         resetResolvedDrawables();
 
+        if (mTextDisplayList != null) {
+            mTextDisplayList.invalidate();
+        }
+
         if (mSpellChecker != null) {
             mSpellChecker.closeSession();
             // Forces the creation of a new SpellChecker next time this window is created.
@@ -4970,17 +4980,6 @@
             }
         }
 
-        /*  Comment out until we decide what to do about animations
-        boolean isLinearTextOn = false;
-        if (currentTransformation != null) {
-            isLinearTextOn = mTextPaint.isLinearTextOn();
-            Matrix m = currentTransformation.getMatrix();
-            if (!m.isIdentity()) {
-                // mTextPaint.setLinearTextOn(true);
-            }
-        }
-        */
-
         final InputMethodState ims = mInputMethodState;
         final int cursorOffsetVertical = voffsetCursor - voffsetText;
         if (ims != null && ims.mBatchEditNesting == 0) {
@@ -5038,19 +5037,39 @@
             highlight = null;
         }
 
-        layout.draw(canvas, highlight, mHighlightPaint, cursorOffsetVertical);
+        if (canHaveDisplayList() && canvas.isHardwareAccelerated()) {
+            final int width = mRight - mLeft;
+            final int height = mBottom - mTop;
+
+            if (mTextDisplayList == null || !mTextDisplayList.isValid() ||
+                    !mTextDisplayListIsValid) {
+                if (mTextDisplayList == null) {
+                    mTextDisplayList = getHardwareRenderer().createDisplayList();
+                }
+
+                final HardwareCanvas hardwareCanvas = mTextDisplayList.start();
+                try {
+                    hardwareCanvas.setViewport(width, height);
+                    // The dirty rect should always be null for a display list
+                    hardwareCanvas.onPreDraw(null);
+                    layout.draw(hardwareCanvas, highlight, mHighlightPaint, cursorOffsetVertical);
+                } finally {
+                    hardwareCanvas.onPostDraw();
+                    mTextDisplayList.end();
+                    mTextDisplayListIsValid = true;
+                }
+            }
+            ((HardwareCanvas) canvas).drawDisplayList(mTextDisplayList,
+                    mScrollX + width, mScrollY + height, null);
+        } else {
+            layout.draw(canvas, highlight, mHighlightPaint, cursorOffsetVertical);
+        }
 
         if (mMarquee != null && mMarquee.shouldDrawGhost()) {
             canvas.translate((int) mMarquee.getGhostOffset(), 0.0f);
             layout.draw(canvas, highlight, mHighlightPaint, cursorOffsetVertical);
         }
 
-        /*  Comment out until we decide what to do about animations
-        if (currentTransformation != null) {
-            mTextPaint.setLinearTextOn(isLinearTextOn);
-        }
-        */
-
         canvas.restore();
     }
 
@@ -7562,6 +7581,7 @@
      */
     protected void onSelectionChanged(int selStart, int selEnd) {
         sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_TEXT_SELECTION_CHANGED);
+        mTextDisplayListIsValid = false;
     }
 
     /**
@@ -7641,6 +7661,7 @@
         }
 
         updateSpellCheckSpans(start, start + after, false);
+        mTextDisplayListIsValid = false;
 
         // Hide the controllers as soon as text is modified (typing, procedural...)
         // We do not hide the span controllers, since they can be added when a new text is
@@ -7743,7 +7764,8 @@
             }
         }
 
-        if (what instanceof UpdateAppearance || what instanceof ParagraphStyle) {
+        if (what instanceof UpdateAppearance || what instanceof ParagraphStyle ||
+                what instanceof CharacterStyle) {
             if (ims == null || ims.mBatchEditNesting == 0) {
                 invalidate();
                 mHighlightPathBogus = true;
@@ -7751,6 +7773,7 @@
             } else {
                 ims.mContentChanged = true;
             }
+            mTextDisplayListIsValid = false;
         }
 
         if (MetaKeyKeyListener.isMetaTracker(buf, what)) {
@@ -9006,6 +9029,7 @@
     public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
         super.onInitializeAccessibilityEvent(event);
 
+        event.setClassName(TextView.class.getName());
         final boolean isPassword = hasPasswordTransformationMethod();
         event.setPassword(isPassword);
 
@@ -9020,11 +9044,13 @@
     public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
         super.onInitializeAccessibilityNodeInfo(info);
 
+        info.setClassName(TextView.class.getName());
         final boolean isPassword = hasPasswordTransformationMethod();
+        info.setPassword(isPassword);
+
         if (!isPassword) {
             info.setText(getTextForAccessibility());
         }
-        info.setPassword(isPassword);
     }
 
     @Override
diff --git a/core/java/android/widget/TimePicker.java b/core/java/android/widget/TimePicker.java
index afca2db..8f10fff 100644
--- a/core/java/android/widget/TimePicker.java
+++ b/core/java/android/widget/TimePicker.java
@@ -27,6 +27,7 @@
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.InputMethodManager;
 import android.widget.NumberPicker.OnValueChangeListener;
@@ -476,6 +477,18 @@
         event.getText().add(selectedDateUtterance);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TimePicker.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TimePicker.class.getName());
+    }
+
     private void updateHourControl() {
         if (is24HourView()) {
             mHourSpinner.setMinValue(0);
diff --git a/core/java/android/widget/ToggleButton.java b/core/java/android/widget/ToggleButton.java
index a754268..a0edafe 100644
--- a/core/java/android/widget/ToggleButton.java
+++ b/core/java/android/widget/ToggleButton.java
@@ -23,6 +23,7 @@
 import android.graphics.drawable.LayerDrawable;
 import android.util.AttributeSet;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 import com.android.internal.R;
 
@@ -161,4 +162,16 @@
             event.getText().add(mContext.getString(R.string.togglebutton_not_pressed));
         }
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ToggleButton.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ToggleButton.class.getName());
+    }
 }
diff --git a/core/java/android/widget/TwoLineListItem.java b/core/java/android/widget/TwoLineListItem.java
index eab6f2d..e707ea3 100644
--- a/core/java/android/widget/TwoLineListItem.java
+++ b/core/java/android/widget/TwoLineListItem.java
@@ -16,14 +16,12 @@
 
 package android.widget;
 
-import com.android.internal.R;
-
-
 import android.annotation.Widget;
 import android.content.Context;
 import android.content.res.TypedArray;
 import android.util.AttributeSet;
-import android.view.View;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RelativeLayout;
 
 /**
@@ -86,4 +84,16 @@
     public TextView getText2() {
         return mText2;
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(TwoLineListItem.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(TwoLineListItem.class.getName());
+    }
 }
diff --git a/core/java/android/widget/VideoView.java b/core/java/android/widget/VideoView.java
index 64fdf34..0fba498 100644
--- a/core/java/android/widget/VideoView.java
+++ b/core/java/android/widget/VideoView.java
@@ -34,6 +34,8 @@
 import android.view.SurfaceHolder;
 import android.view.SurfaceView;
 import android.view.View;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.MediaController.MediaPlayerControl;
 
 import java.io.IOException;
@@ -124,6 +126,18 @@
         setMeasuredDimension(width, height);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(VideoView.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(VideoView.class.getName());
+    }
+
     public int resolveAdjustedSize(int desiredSize, int measureSpec) {
         int result = desiredSize;
         int specMode = MeasureSpec.getMode(measureSpec);
diff --git a/core/java/android/widget/ViewAnimator.java b/core/java/android/widget/ViewAnimator.java
index 71ff66b..6a68240 100644
--- a/core/java/android/widget/ViewAnimator.java
+++ b/core/java/android/widget/ViewAnimator.java
@@ -22,6 +22,8 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.Animation;
 import android.view.animation.AnimationUtils;
 
@@ -341,4 +343,16 @@
     public int getBaseline() {
         return (getCurrentView() != null) ? getCurrentView().getBaseline() : super.getBaseline();
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ViewAnimator.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ViewAnimator.class.getName());
+    }
 }
diff --git a/core/java/android/widget/ViewFlipper.java b/core/java/android/widget/ViewFlipper.java
index c6f6e81..061bb00 100644
--- a/core/java/android/widget/ViewFlipper.java
+++ b/core/java/android/widget/ViewFlipper.java
@@ -25,6 +25,8 @@
 import android.os.Message;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.RemoteViews.RemoteView;
 
 /**
@@ -139,6 +141,18 @@
         updateRunning();
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ViewFlipper.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ViewFlipper.class.getName());
+    }
+
     /**
      * Internal method to start or stop dispatching flip {@link Message} based
      * on {@link #mRunning} and {@link #mVisible} state.
diff --git a/core/java/android/widget/ViewSwitcher.java b/core/java/android/widget/ViewSwitcher.java
index 71ae624..0376918 100644
--- a/core/java/android/widget/ViewSwitcher.java
+++ b/core/java/android/widget/ViewSwitcher.java
@@ -20,6 +20,8 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 /**
  * {@link ViewAnimator} that switches between two views, and has a factory
@@ -66,6 +68,18 @@
         super.addView(child, index, params);
     }
 
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ViewSwitcher.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ViewSwitcher.class.getName());
+    }
+
     /**
      * Returns the next view to be displayed.
      *
diff --git a/core/java/android/widget/ZoomButton.java b/core/java/android/widget/ZoomButton.java
index eb372ca..af17c94 100644
--- a/core/java/android/widget/ZoomButton.java
+++ b/core/java/android/widget/ZoomButton.java
@@ -23,6 +23,8 @@
 import android.view.MotionEvent;
 import android.view.View;
 import android.view.View.OnLongClickListener;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 
 public class ZoomButton extends ImageButton implements OnLongClickListener {
 
@@ -96,4 +98,16 @@
         clearFocus();
         return super.dispatchUnhandledMove(focused, direction);
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ZoomButton.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ZoomButton.class.getName());
+    }
 }
diff --git a/core/java/android/widget/ZoomControls.java b/core/java/android/widget/ZoomControls.java
index a12aee5..8897875 100644
--- a/core/java/android/widget/ZoomControls.java
+++ b/core/java/android/widget/ZoomControls.java
@@ -22,6 +22,8 @@
 import android.view.LayoutInflater;
 import android.view.MotionEvent;
 import android.view.View;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.view.animation.AlphaAnimation;
 
 import com.android.internal.R;
@@ -106,4 +108,16 @@
     public boolean hasFocus() {
         return mZoomIn.hasFocus() || mZoomOut.hasFocus();
     }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(ZoomControls.class.getName());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(ZoomControls.class.getName());
+    }
 }
diff --git a/core/java/com/android/internal/backup/BackupConstants.java b/core/java/com/android/internal/backup/BackupConstants.java
index 906b5d5..4c276b7 100644
--- a/core/java/com/android/internal/backup/BackupConstants.java
+++ b/core/java/com/android/internal/backup/BackupConstants.java
@@ -24,4 +24,5 @@
     public static final int TRANSPORT_ERROR = 1;
     public static final int TRANSPORT_NOT_INITIALIZED = 2;
     public static final int AGENT_ERROR = 3;
+    public static final int AGENT_UNKNOWN = 4;
 }
diff --git a/core/java/com/android/internal/util/FileRotator.java b/core/java/com/android/internal/util/FileRotator.java
new file mode 100644
index 0000000..3ce95e7
--- /dev/null
+++ b/core/java/com/android/internal/util/FileRotator.java
@@ -0,0 +1,330 @@
+/*
+ * Copyright (C) 2012 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.internal.util;
+
+import android.os.FileUtils;
+
+import com.android.internal.util.FileRotator.Reader;
+import com.android.internal.util.FileRotator.Writer;
+
+import java.io.BufferedInputStream;
+import java.io.BufferedOutputStream;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+
+import libcore.io.IoUtils;
+
+/**
+ * Utility that rotates files over time, similar to {@code logrotate}. There is
+ * a single "active" file, which is periodically rotated into historical files,
+ * and eventually deleted entirely. Files are stored under a specific directory
+ * with a well-known prefix.
+ * <p>
+ * Instead of manipulating files directly, users implement interfaces that
+ * perform operations on {@link InputStream} and {@link OutputStream}. This
+ * enables atomic rewriting of file contents in
+ * {@link #combineActive(Reader, Writer, long)}.
+ * <p>
+ * Users must periodically call {@link #maybeRotate(long)} to perform actual
+ * rotation. Not inherently thread safe.
+ */
+public class FileRotator {
+    private final File mBasePath;
+    private final String mPrefix;
+    private final long mRotateAgeMillis;
+    private final long mDeleteAgeMillis;
+
+    private static final String SUFFIX_BACKUP = ".backup";
+    private static final String SUFFIX_NO_BACKUP = ".no_backup";
+
+    // TODO: provide method to append to active file
+
+    /**
+     * External class that reads data from a given {@link InputStream}. May be
+     * called multiple times when reading rotated data.
+     */
+    public interface Reader {
+        public void read(InputStream in) throws IOException;
+    }
+
+    /**
+     * External class that writes data to a given {@link OutputStream}.
+     */
+    public interface Writer {
+        public void write(OutputStream out) throws IOException;
+    }
+
+    /**
+     * Create a file rotator.
+     *
+     * @param basePath Directory under which all files will be placed.
+     * @param prefix Filename prefix used to identify this rotator.
+     * @param rotateAgeMillis Age in milliseconds beyond which an active file
+     *            may be rotated into a historical file.
+     * @param deleteAgeMillis Age in milliseconds beyond which a rotated file
+     *            may be deleted.
+     */
+    public FileRotator(File basePath, String prefix, long rotateAgeMillis, long deleteAgeMillis) {
+        mBasePath = Preconditions.checkNotNull(basePath);
+        mPrefix = Preconditions.checkNotNull(prefix);
+        mRotateAgeMillis = rotateAgeMillis;
+        mDeleteAgeMillis = deleteAgeMillis;
+
+        // ensure that base path exists
+        mBasePath.mkdirs();
+
+        // recover any backup files
+        for (String name : mBasePath.list()) {
+            if (!name.startsWith(mPrefix)) continue;
+
+            if (name.endsWith(SUFFIX_BACKUP)) {
+                final File backupFile = new File(mBasePath, name);
+                final File file = new File(
+                        mBasePath, name.substring(0, name.length() - SUFFIX_BACKUP.length()));
+
+                // write failed with backup; recover last file
+                backupFile.renameTo(file);
+
+            } else if (name.endsWith(SUFFIX_NO_BACKUP)) {
+                final File noBackupFile = new File(mBasePath, name);
+                final File file = new File(
+                        mBasePath, name.substring(0, name.length() - SUFFIX_NO_BACKUP.length()));
+
+                // write failed without backup; delete both
+                noBackupFile.delete();
+                file.delete();
+            }
+        }
+    }
+
+    /**
+     * Atomically combine data with existing data in currently active file.
+     * Maintains a backup during write, which is restored if the write fails.
+     */
+    public void combineActive(Reader reader, Writer writer, long currentTimeMillis)
+            throws IOException {
+        final String activeName = getActiveName(currentTimeMillis);
+
+        final File file = new File(mBasePath, activeName);
+        final File backupFile;
+
+        if (file.exists()) {
+            // read existing data
+            readFile(file, reader);
+
+            // backup existing data during write
+            backupFile = new File(mBasePath, activeName + SUFFIX_BACKUP);
+            file.renameTo(backupFile);
+
+            try {
+                writeFile(file, writer);
+
+                // write success, delete backup
+                backupFile.delete();
+            } catch (IOException e) {
+                // write failed, delete file and restore backup
+                file.delete();
+                backupFile.renameTo(file);
+                throw e;
+            }
+
+        } else {
+            // create empty backup during write
+            backupFile = new File(mBasePath, activeName + SUFFIX_NO_BACKUP);
+            backupFile.createNewFile();
+
+            try {
+                writeFile(file, writer);
+
+                // write success, delete empty backup
+                backupFile.delete();
+            } catch (IOException e) {
+                // write failed, delete file and empty backup
+                file.delete();
+                backupFile.delete();
+                throw e;
+            }
+        }
+    }
+
+    /**
+     * Read any rotated data that overlap the requested time range.
+     */
+    public void readMatching(Reader reader, long matchStartMillis, long matchEndMillis)
+            throws IOException {
+        final FileInfo info = new FileInfo(mPrefix);
+        for (String name : mBasePath.list()) {
+            if (!info.parse(name)) continue;
+
+            // read file when it overlaps
+            if (info.startMillis <= matchEndMillis && matchStartMillis <= info.endMillis) {
+                final File file = new File(mBasePath, name);
+                readFile(file, reader);
+            }
+        }
+    }
+
+    /**
+     * Return the currently active file, which may not exist yet.
+     */
+    private String getActiveName(long currentTimeMillis) {
+        String oldestActiveName = null;
+        long oldestActiveStart = Long.MAX_VALUE;
+
+        final FileInfo info = new FileInfo(mPrefix);
+        for (String name : mBasePath.list()) {
+            if (!info.parse(name)) continue;
+
+            // pick the oldest active file which covers current time
+            if (info.isActive() && info.startMillis < currentTimeMillis
+                    && info.startMillis < oldestActiveStart) {
+                oldestActiveName = name;
+                oldestActiveStart = info.startMillis;
+            }
+        }
+
+        if (oldestActiveName != null) {
+            return oldestActiveName;
+        } else {
+            // no active file found above; create one starting now
+            info.startMillis = currentTimeMillis;
+            info.endMillis = Long.MAX_VALUE;
+            return info.build();
+        }
+    }
+
+    /**
+     * Examine all files managed by this rotator, renaming or deleting if their
+     * age matches the configured thresholds.
+     */
+    public void maybeRotate(long currentTimeMillis) {
+        final long rotateBefore = currentTimeMillis - mRotateAgeMillis;
+        final long deleteBefore = currentTimeMillis - mDeleteAgeMillis;
+
+        final FileInfo info = new FileInfo(mPrefix);
+        for (String name : mBasePath.list()) {
+            if (!info.parse(name)) continue;
+
+            if (info.isActive()) {
+                // found active file; rotate if old enough
+                if (info.startMillis < rotateBefore) {
+                    info.endMillis = currentTimeMillis;
+
+                    final File file = new File(mBasePath, name);
+                    final File destFile = new File(mBasePath, info.build());
+                    file.renameTo(destFile);
+                }
+            } else if (info.endMillis < deleteBefore) {
+                // found rotated file; delete if old enough
+                final File file = new File(mBasePath, name);
+                file.delete();
+            }
+        }
+    }
+
+    private static void readFile(File file, Reader reader) throws IOException {
+        final FileInputStream fis = new FileInputStream(file);
+        final BufferedInputStream bis = new BufferedInputStream(fis);
+        try {
+            reader.read(bis);
+        } finally {
+            IoUtils.closeQuietly(bis);
+        }
+    }
+
+    private static void writeFile(File file, Writer writer) throws IOException {
+        final FileOutputStream fos = new FileOutputStream(file);
+        final BufferedOutputStream bos = new BufferedOutputStream(fos);
+        try {
+            writer.write(bos);
+            bos.flush();
+        } finally {
+            FileUtils.sync(fos);
+            IoUtils.closeQuietly(bos);
+        }
+    }
+
+    /**
+     * Details for a rotated file, either parsed from an existing filename, or
+     * ready to be built into a new filename.
+     */
+    private static class FileInfo {
+        public final String prefix;
+
+        public long startMillis;
+        public long endMillis;
+
+        public FileInfo(String prefix) {
+            this.prefix = Preconditions.checkNotNull(prefix);
+        }
+
+        /**
+         * Attempt parsing the given filename.
+         *
+         * @return Whether parsing was successful.
+         */
+        public boolean parse(String name) {
+            startMillis = endMillis = -1;
+
+            final int dotIndex = name.lastIndexOf('.');
+            final int dashIndex = name.lastIndexOf('-');
+
+            // skip when missing time section
+            if (dotIndex == -1 || dashIndex == -1) return false;
+
+            // skip when prefix doesn't match
+            if (!prefix.equals(name.substring(0, dotIndex))) return false;
+
+            try {
+                startMillis = Long.parseLong(name.substring(dotIndex + 1, dashIndex));
+
+                if (name.length() - dashIndex == 1) {
+                    endMillis = Long.MAX_VALUE;
+                } else {
+                    endMillis = Long.parseLong(name.substring(dashIndex + 1));
+                }
+
+                return true;
+            } catch (NumberFormatException e) {
+                return false;
+            }
+        }
+
+        /**
+         * Build current state into filename.
+         */
+        public String build() {
+            final StringBuilder name = new StringBuilder();
+            name.append(prefix).append('.').append(startMillis).append('-');
+            if (endMillis != Long.MAX_VALUE) {
+                name.append(endMillis);
+            }
+            return name.toString();
+        }
+
+        /**
+         * Test if current file is active (no end timestamp).
+         */
+        public boolean isActive() {
+            return endMillis == Long.MAX_VALUE;
+        }
+    }
+}
diff --git a/core/jni/android/graphics/Canvas.cpp b/core/jni/android/graphics/Canvas.cpp
index 4aa13f9..3e9ab86 100644
--- a/core/jni/android/graphics/Canvas.cpp
+++ b/core/jni/android/graphics/Canvas.cpp
@@ -820,7 +820,12 @@
             posPtr[indx].fX = SkFloatToScalar(posArray[indx << 1]);
             posPtr[indx].fY = SkFloatToScalar(posArray[(indx << 1) + 1]);
         }
+        
+        SkPaint::TextEncoding encoding = paint->getTextEncoding();
+        paint->setTextEncoding(SkPaint::kUTF16_TextEncoding);
         canvas->drawPosText(textArray + index, count << 1, posPtr, *paint);
+        paint->setTextEncoding(encoding);
+        
         if (text) {
             env->ReleaseCharArrayElements(text, textArray, 0);
         }
@@ -844,7 +849,12 @@
             posPtr[indx].fX = SkFloatToScalar(posArray[indx << 1]);
             posPtr[indx].fY = SkFloatToScalar(posArray[(indx << 1) + 1]);
         }
+
+        SkPaint::TextEncoding encoding = paint->getTextEncoding();
+        paint->setTextEncoding(SkPaint::kUTF16_TextEncoding);
         canvas->drawPosText(text_, byteLength << 1, posPtr, *paint);
+        paint->setTextEncoding(encoding);
+
         if (text) {
             env->ReleaseStringChars(text, (const jchar*) text_);
         }
diff --git a/core/jni/android/graphics/TextLayoutCache.cpp b/core/jni/android/graphics/TextLayoutCache.cpp
index 1b7623d..d26f563 100644
--- a/core/jni/android/graphics/TextLayoutCache.cpp
+++ b/core/jni/android/graphics/TextLayoutCache.cpp
@@ -659,6 +659,13 @@
             continue;
         }
 
+#if DEBUG_GLYPHS
+        ALOGD("Returned logclusters");
+        for (size_t i = 0; i < mShaperItem.num_glyphs; i++) {
+            ALOGD("         -- lc[%d] = %d, hb-adv[%d] = %0.2f", i, mShaperItem.log_clusters[i],
+                    i, HBFixedToFloat(mShaperItem.advances[i]));
+        }
+#endif
         // Get Advances and their total
         jfloat currentAdvance = HBFixedToFloat(mShaperItem.advances[mShaperItem.log_clusters[0]]);
         jfloat totalFontRunAdvance = currentAdvance;
@@ -670,11 +677,14 @@
                 outAdvances->add(0);
             } else {
                 currentAdvance = HBFixedToFloat(mShaperItem.advances[mShaperItem.log_clusters[i]]);
-                totalFontRunAdvance += currentAdvance;
                 outAdvances->add(currentAdvance);
             }
         }
-
+        // TODO: can be removed and go back in the previous loop when Harfbuzz log clusters are fixed
+        for (size_t i = 1; i < mShaperItem.num_glyphs; i++) {
+            currentAdvance = HBFixedToFloat(mShaperItem.advances[i]);
+            totalFontRunAdvance += currentAdvance;
+        }
         totalAdvance += totalFontRunAdvance;
 
 #if DEBUG_ADVANCES
@@ -684,7 +694,6 @@
                     (*outAdvances)[i], mShaperItem.log_clusters[i], totalFontRunAdvance);
         }
 #endif
-
         // Get Glyphs and reverse them in place if RTL
         if (outGlyphs) {
             size_t countGlyphs = mShaperItem.num_glyphs;
diff --git a/core/jni/android_media_AudioSystem.cpp b/core/jni/android_media_AudioSystem.cpp
index 0c5101f..8341e4c 100644
--- a/core/jni/android_media_AudioSystem.cpp
+++ b/core/jni/android_media_AudioSystem.cpp
@@ -72,7 +72,7 @@
 android_media_AudioSystem_isStreamActive(JNIEnv *env, jobject thiz, jint stream, jint inPastMs)
 {
     bool state = false;
-    AudioSystem::isStreamActive(stream, &state, inPastMs);
+    AudioSystem::isStreamActive((audio_stream_type_t) stream, &state, inPastMs);
     return state;
 }
 
@@ -152,7 +152,7 @@
 static int
 android_media_AudioSystem_setPhoneState(JNIEnv *env, jobject thiz, jint state)
 {
-    return check_AudioSystem_Command(AudioSystem::setPhoneState(state));
+    return check_AudioSystem_Command(AudioSystem::setPhoneState((audio_mode_t) state));
 }
 
 static int
@@ -183,16 +183,29 @@
 }
 
 static int
-android_media_AudioSystem_setStreamVolumeIndex(JNIEnv *env, jobject thiz, jint stream, jint index)
+android_media_AudioSystem_setStreamVolumeIndex(JNIEnv *env,
+                                               jobject thiz,
+                                               jint stream,
+                                               jint index,
+                                               jint device)
 {
-    return check_AudioSystem_Command(AudioSystem::setStreamVolumeIndex(static_cast <audio_stream_type_t>(stream), index));
+    return check_AudioSystem_Command(
+            AudioSystem::setStreamVolumeIndex(static_cast <audio_stream_type_t>(stream),
+                                              index,
+                                              (audio_devices_t)device));
 }
 
 static int
-android_media_AudioSystem_getStreamVolumeIndex(JNIEnv *env, jobject thiz, jint stream)
+android_media_AudioSystem_getStreamVolumeIndex(JNIEnv *env,
+                                               jobject thiz,
+                                               jint stream,
+                                               jint device)
 {
     int index;
-    if (AudioSystem::getStreamVolumeIndex(static_cast <audio_stream_type_t>(stream), &index) != NO_ERROR) {
+    if (AudioSystem::getStreamVolumeIndex(static_cast <audio_stream_type_t>(stream),
+                                          &index,
+                                          (audio_devices_t)device)
+            != NO_ERROR) {
         index = -1;
     }
     return index;
@@ -219,8 +232,8 @@
     {"setForceUse",         "(II)I",    (void *)android_media_AudioSystem_setForceUse},
     {"getForceUse",         "(I)I",     (void *)android_media_AudioSystem_getForceUse},
     {"initStreamVolume",    "(III)I",   (void *)android_media_AudioSystem_initStreamVolume},
-    {"setStreamVolumeIndex","(II)I",    (void *)android_media_AudioSystem_setStreamVolumeIndex},
-    {"getStreamVolumeIndex","(I)I",     (void *)android_media_AudioSystem_getStreamVolumeIndex},
+    {"setStreamVolumeIndex","(III)I",   (void *)android_media_AudioSystem_setStreamVolumeIndex},
+    {"getStreamVolumeIndex","(II)I",    (void *)android_media_AudioSystem_getStreamVolumeIndex},
     {"getDevicesForStream", "(I)I",     (void *)android_media_AudioSystem_getDevicesForStream},
 };
 
diff --git a/core/jni/android_media_AudioTrack.cpp b/core/jni/android_media_AudioTrack.cpp
index d921685..4aa49f4 100644
--- a/core/jni/android_media_AudioTrack.cpp
+++ b/core/jni/android_media_AudioTrack.cpp
@@ -75,7 +75,7 @@
         sp<MemoryHeapBase>         mMemHeap;
         sp<MemoryBase>             mMemBase;
         audiotrack_callback_cookie mCallbackData;
-        int                        mStreamType;
+        audio_stream_type_t        mStreamType;
 
     AudioTrackJniStorage() {
         mCallbackData.audioTrack_class = 0;
@@ -175,11 +175,11 @@
     int afSampleRate;
     int afFrameCount;
 
-    if (AudioSystem::getOutputFrameCount(&afFrameCount, streamType) != NO_ERROR) {
+    if (AudioSystem::getOutputFrameCount(&afFrameCount, (audio_stream_type_t) streamType) != NO_ERROR) {
         ALOGE("Error creating AudioTrack: Could not get AudioSystem frame count.");
         return AUDIOTRACK_ERROR_SETUP_AUDIOSYSTEM;
     }
-    if (AudioSystem::getOutputSamplingRate(&afSampleRate, streamType) != NO_ERROR) {
+    if (AudioSystem::getOutputSamplingRate(&afSampleRate, (audio_stream_type_t) streamType) != NO_ERROR) {
         ALOGE("Error creating AudioTrack: Could not get AudioSystem sampling rate.");
         return AUDIOTRACK_ERROR_SETUP_AUDIOSYSTEM;
     }
diff --git a/core/jni/android_media_ToneGenerator.cpp b/core/jni/android_media_ToneGenerator.cpp
index 49be1c7..53a0501 100644
--- a/core/jni/android_media_ToneGenerator.cpp
+++ b/core/jni/android_media_ToneGenerator.cpp
@@ -79,7 +79,7 @@
 
 static void android_media_ToneGenerator_native_setup(JNIEnv *env, jobject thiz,
         jint streamType, jint volume) {
-    ToneGenerator *lpToneGen = new ToneGenerator(streamType, AudioSystem::linearToLog(volume), true);
+    ToneGenerator *lpToneGen = new ToneGenerator((audio_stream_type_t) streamType, AudioSystem::linearToLog(volume), true);
 
     env->SetIntField(thiz, fields.context, 0);
 
diff --git a/core/jni/android_util_Process.cpp b/core/jni/android_util_Process.cpp
index 8234f1b..07a7f22 100644
--- a/core/jni/android_util_Process.cpp
+++ b/core/jni/android_util_Process.cpp
@@ -50,7 +50,7 @@
 static pthread_key_t gBgKey = -1;
 #endif
 
-static void signalExceptionForPriorityError(JNIEnv* env, jobject obj, int err)
+static void signalExceptionForPriorityError(JNIEnv* env, int err)
 {
     switch (err) {
         case EINVAL:
@@ -71,7 +71,7 @@
     }
 }
 
-static void signalExceptionForGroupError(JNIEnv* env, jobject obj, int err)
+static void signalExceptionForGroupError(JNIEnv* env, int err)
 {
     switch (err) {
         case EINVAL:
@@ -173,7 +173,7 @@
 {
     int res = androidSetThreadSchedulingGroup(pid, grp);
     if (res != NO_ERROR) {
-        signalExceptionForGroupError(env, clazz, res == BAD_VALUE ? EINVAL : errno);
+        signalExceptionForGroupError(env, res == BAD_VALUE ? EINVAL : errno);
         return;
     }
 }
@@ -186,7 +186,7 @@
     struct dirent *de;
 
     if (grp > ANDROID_TGROUP_MAX || grp < 0) {
-        signalExceptionForGroupError(env, clazz, EINVAL);
+        signalExceptionForGroupError(env, EINVAL);
         return;
     }
 
@@ -214,7 +214,7 @@
     if (!(d = opendir(proc_path))) {
         // If the process exited on us, don't generate an exception
         if (errno != ENOENT)
-            signalExceptionForGroupError(env, clazz, errno);
+            signalExceptionForGroupError(env, errno);
         return;
     }
 
@@ -240,7 +240,7 @@
         }
 
         if (androidSetThreadSchedulingGroup(t_pid, grp) != NO_ERROR) {
-            signalExceptionForGroupError(env, clazz, errno);
+            signalExceptionForGroupError(env, errno);
             break;
         }
     }
@@ -264,6 +264,21 @@
 #endif
 }
 
+void android_os_Process_setThreadScheduler(JNIEnv* env, jclass clazz,
+                                              jint tid, jint policy, jint pri)
+{
+#ifdef HAVE_SCHED_SETSCHEDULER
+    struct sched_param param;
+    param.sched_priority = pri;
+    int rc = sched_setscheduler(tid, policy, &param);
+    if (rc) {
+        signalExceptionForPriorityError(env, errno);
+    }
+#else
+    signalExceptionForPriorityError(env, ENOSYS);
+#endif
+}
+
 void android_os_Process_setThreadPriority(JNIEnv* env, jobject clazz,
                                               jint pid, jint pri)
 {
@@ -285,9 +300,9 @@
     int rc = androidSetThreadPriority(pid, pri);
     if (rc != 0) {
         if (rc == INVALID_OPERATION) {
-            signalExceptionForPriorityError(env, clazz, errno);
+            signalExceptionForPriorityError(env, errno);
         } else {
-            signalExceptionForGroupError(env, clazz, errno);
+            signalExceptionForGroupError(env, errno);
         }
     }
 
@@ -308,7 +323,7 @@
     errno = 0;
     jint pri = getpriority(PRIO_PROCESS, pid);
     if (errno != 0) {
-        signalExceptionForPriorityError(env, clazz, errno);
+        signalExceptionForPriorityError(env, errno);
     }
     //ALOGI("Returning priority of %d: %d\n", pid, pri);
     return pri;
@@ -852,6 +867,7 @@
     {"getUidForName",       "(Ljava/lang/String;)I", (void*)android_os_Process_getUidForName},
     {"getGidForName",       "(Ljava/lang/String;)I", (void*)android_os_Process_getGidForName},
     {"setThreadPriority",   "(II)V", (void*)android_os_Process_setThreadPriority},
+    {"setThreadScheduler",  "(III)V", (void*)android_os_Process_setThreadScheduler},
     {"setCanSelfBackground", "(Z)V", (void*)android_os_Process_setCanSelfBackground},
     {"setThreadPriority",   "(I)V", (void*)android_os_Process_setCallingThreadPriority},
     {"getThreadPriority",   "(I)I", (void*)android_os_Process_getThreadPriority},
diff --git a/core/jni/android_view_GLES20Canvas.cpp b/core/jni/android_view_GLES20Canvas.cpp
index 23ad154..064dcac 100644
--- a/core/jni/android_view_GLES20Canvas.cpp
+++ b/core/jni/android_view_GLES20Canvas.cpp
@@ -44,6 +44,7 @@
 #include <SkiaColorFilter.h>
 #include <Rect.h>
 
+#include <TextLayout.h>
 #include <TextLayoutCache.h>
 
 namespace android {
@@ -566,6 +567,54 @@
     env->ReleaseStringChars(text, textArray);
 }
 
+static void renderPosText(OpenGLRenderer* renderer, const jchar* text, int count,
+        const jfloat* positions, jint dirFlags, SkPaint* paint) {
+    sp<TextLayoutCacheValue> value;
+#if USE_TEXT_LAYOUT_CACHE
+    value = TextLayoutCache::getInstance().getValue(paint, text, 0, count, count, dirFlags);
+    if (value == NULL) {
+        ALOGE("Cannot get TextLayoutCache value for text = '%s'",
+                String8(text, count).string());
+        return;
+    }
+#else
+    value = new TextLayoutCacheValue(count);
+    TextLayoutEngine::getInstance().computeValues(value.get(), paint,
+            text, 0, count, count, dirFlags);
+#endif
+
+    const jchar* glyphs = value->getGlyphs();
+    size_t glyphsCount = value->getGlyphsCount();
+    if (count < int(glyphsCount)) glyphsCount = count;
+    int bytesCount = glyphsCount * sizeof(jchar);
+
+    renderer->drawPosText((const char*) glyphs, bytesCount, glyphsCount, positions, paint);
+}
+
+static void android_view_GLES20Canvas_drawPosTextArray(JNIEnv* env, jobject clazz,
+        OpenGLRenderer* renderer, jcharArray text, jint index, jint count,
+        jfloatArray pos, SkPaint* paint) {
+    jchar* textArray = env->GetCharArrayElements(text, NULL);
+    jfloat* positions = env->GetFloatArrayElements(pos, NULL);
+
+    renderPosText(renderer, textArray + index, count, positions, kBidi_LTR, paint);
+
+    env->ReleaseFloatArrayElements(pos, positions, JNI_ABORT);
+    env->ReleaseCharArrayElements(text, textArray, JNI_ABORT);
+}
+
+static void android_view_GLES20Canvas_drawPosText(JNIEnv* env, jobject clazz,
+        OpenGLRenderer* renderer, jstring text, jint start, jint end,
+        jfloatArray pos, SkPaint* paint) {
+    const jchar* textArray = env->GetStringChars(text, NULL);
+    jfloat* positions = env->GetFloatArrayElements(pos, NULL);
+
+    renderPosText(renderer, textArray + start, end - start, positions, kBidi_LTR, paint);
+
+    env->ReleaseFloatArrayElements(pos, positions, JNI_ABORT);
+    env->ReleaseStringChars(text, textArray);
+}
+
 // ----------------------------------------------------------------------------
 // Display lists
 // ----------------------------------------------------------------------------
@@ -829,6 +878,10 @@
     { "nDrawTextRun",       "(ILjava/lang/String;IIIIFFII)V",
             (void*) android_view_GLES20Canvas_drawTextRun },
 
+    { "nDrawPosText",       "(I[CII[FI)V",     (void*) android_view_GLES20Canvas_drawPosTextArray },
+    { "nDrawPosText",       "(ILjava/lang/String;II[FI)V",
+            (void*) android_view_GLES20Canvas_drawPosText },
+
     { "nGetClipBounds",     "(ILandroid/graphics/Rect;)Z",
             (void*) android_view_GLES20Canvas_getClipBounds },
 
diff --git a/core/jni/com_android_internal_content_NativeLibraryHelper.cpp b/core/jni/com_android_internal_content_NativeLibraryHelper.cpp
index a5b85b4..b68c97a 100644
--- a/core/jni/com_android_internal_content_NativeLibraryHelper.cpp
+++ b/core/jni/com_android_internal_content_NativeLibraryHelper.cpp
@@ -283,6 +283,7 @@
     const int N = zipFile.getNumEntries();
 
     char fileName[PATH_MAX];
+    bool hasPrimaryAbi = false;
 
     for (int i = 0; i < N; i++) {
         const ZipEntryRO entry = zipFile.findEntryByIndex(i);
@@ -318,11 +319,22 @@
         if (cpuAbi.size() == cpuAbiRegionSize
                 && *(cpuAbiOffset + cpuAbi.size()) == '/'
                 && !strncmp(cpuAbiOffset, cpuAbi.c_str(), cpuAbiRegionSize)) {
-            ALOGV("Using ABI %s\n", cpuAbi.c_str());
+            ALOGV("Using primary ABI %s\n", cpuAbi.c_str());
+            hasPrimaryAbi = true;
         } else if (cpuAbi2.size() == cpuAbiRegionSize
                 && *(cpuAbiOffset + cpuAbi2.size()) == '/'
                 && !strncmp(cpuAbiOffset, cpuAbi2.c_str(), cpuAbiRegionSize)) {
-            ALOGV("Using ABI %s\n", cpuAbi2.c_str());
+
+            /*
+             * If this library matches both the primary and secondary ABIs,
+             * only use the primary ABI.
+             */
+            if (hasPrimaryAbi) {
+                ALOGV("Already saw primary ABI, skipping secondary ABI %s\n", cpuAbi2.c_str());
+                continue;
+            } else {
+                ALOGV("Using secondary ABI %s\n", cpuAbi2.c_str());
+            }
         } else {
             ALOGV("abi didn't match anything: %s (end at %zd)\n", cpuAbiOffset, cpuAbiRegionSize);
             continue;
diff --git a/core/res/res/layout-sw600dp/keyguard_screen_password_landscape.xml b/core/res/res/layout-sw600dp/keyguard_screen_password_landscape.xml
index 568933c..43d0a2c 100644
--- a/core/res/res/layout-sw600dp/keyguard_screen_password_landscape.xml
+++ b/core/res/res/layout-sw600dp/keyguard_screen_password_landscape.xml
@@ -97,8 +97,7 @@
                     android:textAppearance="?android:attr/textAppearanceMedium"
                     android:background="@null"
                     android:textColor="#ffffffff"
-                    android:imeOptions="flagNoFullscreen|actionDone"
-                    android:privateImeOptions="com.google.android.inputmethod.latin.forceAscii"
+                    android:imeOptions="flagForceAscii|flagNoFullscreen|actionDone"
                     />
 
                 <!-- This delete button is only visible for numeric PIN entry -->
diff --git a/core/res/res/layout-sw600dp/keyguard_screen_password_portrait.xml b/core/res/res/layout-sw600dp/keyguard_screen_password_portrait.xml
index 335a641..8c02888 100644
--- a/core/res/res/layout-sw600dp/keyguard_screen_password_portrait.xml
+++ b/core/res/res/layout-sw600dp/keyguard_screen_password_portrait.xml
@@ -98,7 +98,7 @@
                     android:textAppearance="?android:attr/textAppearanceMedium"
                     android:background="@null"
                     android:textColor="#ffffffff"
-                    android:privateImeOptions="com.google.android.inputmethod.latin.forceAscii"
+                    android:imeOptions="flagForceAscii"
                 />
 
                 <!-- This delete button is only visible for numeric PIN entry -->
diff --git a/core/res/res/layout/keyguard_screen_password_landscape.xml b/core/res/res/layout/keyguard_screen_password_landscape.xml
index e95553f..66d7fd7 100644
--- a/core/res/res/layout/keyguard_screen_password_landscape.xml
+++ b/core/res/res/layout/keyguard_screen_password_landscape.xml
@@ -153,8 +153,7 @@
             android:textAppearance="?android:attr/textAppearanceMedium"
             android:background="@null"
             android:textColor="?android:attr/textColorPrimary"
-            android:imeOptions="flagNoFullscreen|actionDone"
-            android:privateImeOptions="com.google.android.inputmethod.latin.forceAscii"
+            android:imeOptions="flagForceAscii|flagNoFullscreen|actionDone"
             />
 
         <!-- This delete button is only visible for numeric PIN entry -->
diff --git a/core/res/res/layout/keyguard_screen_password_portrait.xml b/core/res/res/layout/keyguard_screen_password_portrait.xml
index cfcc794..426b2f7 100644
--- a/core/res/res/layout/keyguard_screen_password_portrait.xml
+++ b/core/res/res/layout/keyguard_screen_password_portrait.xml
@@ -119,8 +119,7 @@
             android:background="@null"
             android:textAppearance="?android:attr/textAppearanceMedium"
             android:textColor="#ffffffff"
-            android:imeOptions="actionDone"
-            android:privateImeOptions="com.google.android.inputmethod.latin.forceAscii"
+            android:imeOptions="flagForceAscii|actionDone"
             />
 
         <!-- This delete button is only visible for numeric PIN entry -->
diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml
index 71e3575..545a555 100755
--- a/core/res/res/values/attrs.xml
+++ b/core/res/res/values/attrs.xml
@@ -1154,6 +1154,21 @@
              <p>Corresponds to
              {@link android.view.inputmethod.EditorInfo#IME_FLAG_NO_ENTER_ACTION}. -->
         <flag name="flagNoEnterAction" value="0x40000000" />
+        <!-- Used to request that the IME should be capable of inputting ASCII
+             characters.  The intention of this flag is to ensure that the user
+             can type Roman alphabet characters in a {@link android.widget.TextView}
+             used for, typically, account ID or password input.  It is expected that IMEs
+             normally are able to input ASCII even without being told so (such IMEs
+             already respect this flag in a sense), but there could be some cases they
+             aren't when, for instance, only non-ASCII input languagaes like Arabic,
+             Greek, Hebrew, Russian are enabled in the IME.  Applications need to be
+             aware that the flag is not a guarantee, and not all IMEs will respect it.
+             However, it is strongly recommended for IME authors to respect this flag
+             especially when their IME could end up with a state that has only non-ASCII
+             input languages enabled.
+             <p>Corresponds to
+             {@link android.view.inputmethod.EditorInfo#IME_FLAG_FORCE_ASCII}. -->
+        <flag name="flagForceAscii" value="0x80000000" />
     </attr>
 
     <!-- A coordinate in the X dimension. -->
diff --git a/core/res/res/values/styles_device_defaults.xml b/core/res/res/values/styles_device_defaults.xml
index 7f1891e..6419872 100644
--- a/core/res/res/values/styles_device_defaults.xml
+++ b/core/res/res/values/styles_device_defaults.xml
@@ -687,7 +687,7 @@
     <style name="AlertDialog.DeviceDefault" parent="AlertDialog.Holo">
 
     </style>
-    <style name="AlertDialog.DeviceDefault.Light" parent="AlertDialog.DeviceDefault.Light" >
+    <style name="AlertDialog.DeviceDefault.Light" parent="AlertDialog.Holo.Light" >
 
     </style>
 
diff --git a/core/res/res/values/themes_device_defaults.xml b/core/res/res/values/themes_device_defaults.xml
index 94d2c38..8135986 100644
--- a/core/res/res/values/themes_device_defaults.xml
+++ b/core/res/res/values/themes_device_defaults.xml
@@ -411,13 +411,13 @@
     <style name="Theme.DeviceDefault.Dialog.Alert" parent="Theme.Holo.Dialog.Alert">
         <item name="windowTitleStyle">@android:style/DialogWindowTitle.DeviceDefault</item>
     </style>
-    <style name="Theme.DeviceDefault.Light.Dialog.Alert" parent="Theme.DeviceDefault.Light.Dialog.Alert">
+    <style name="Theme.DeviceDefault.Light.Dialog.Alert" parent="Theme.Holo.Light.Dialog.Alert">
         <item name="windowTitleStyle">@android:style/DialogWindowTitle.DeviceDefault.Light</item>
     </style>
-    <style name="Theme.DeviceDefault.SearchBar" parent="Theme.DeviceDefault.SearchBar">
+    <style name="Theme.DeviceDefault.SearchBar" parent="Theme.Holo.SearchBar">
 
     </style>
-    <style name="Theme.DeviceDefault.Light.SearchBar" parent="Theme.DeviceDefault.Light.SearchBar">
+    <style name="Theme.DeviceDefault.Light.SearchBar" parent="Theme.Holo.Light.SearchBar">
 
     </style>
 
diff --git a/core/tests/coretests/src/com/android/internal/util/FileRotatorTest.java b/core/tests/coretests/src/com/android/internal/util/FileRotatorTest.java
new file mode 100644
index 0000000..94d1cb6
--- /dev/null
+++ b/core/tests/coretests/src/com/android/internal/util/FileRotatorTest.java
@@ -0,0 +1,428 @@
+/*
+ * Copyright (C) 2012 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.internal.util;
+
+import static android.text.format.DateUtils.DAY_IN_MILLIS;
+import static android.text.format.DateUtils.HOUR_IN_MILLIS;
+import static android.text.format.DateUtils.MINUTE_IN_MILLIS;
+import static android.text.format.DateUtils.SECOND_IN_MILLIS;
+import static android.text.format.DateUtils.WEEK_IN_MILLIS;
+import static android.text.format.DateUtils.YEAR_IN_MILLIS;
+
+import android.test.AndroidTestCase;
+import android.test.suitebuilder.annotation.Suppress;
+import android.util.Log;
+
+import com.android.internal.util.FileRotator.Reader;
+import com.android.internal.util.FileRotator.Writer;
+import com.google.android.collect.Lists;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.net.ProtocolException;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Random;
+
+import libcore.io.IoUtils;
+
+/**
+ * Tests for {@link FileRotator}.
+ */
+public class FileRotatorTest extends AndroidTestCase {
+    private static final String TAG = "FileRotatorTest";
+
+    private File mBasePath;
+
+    private static final String PREFIX = "rotator";
+    private static final String ANOTHER_PREFIX = "another_rotator";
+
+    private static final long TEST_TIME = 1300000000000L;
+
+    // TODO: test throwing rolls back correctly
+
+    @Override
+    protected void setUp() throws Exception {
+        super.setUp();
+
+        mBasePath = getContext().getFilesDir();
+        IoUtils.deleteContents(mBasePath);
+    }
+
+    public void testEmpty() throws Exception {
+        final FileRotator rotate1 = new FileRotator(
+                mBasePath, PREFIX, DAY_IN_MILLIS, WEEK_IN_MILLIS);
+        final FileRotator rotate2 = new FileRotator(
+                mBasePath, ANOTHER_PREFIX, DAY_IN_MILLIS, WEEK_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // write single new value
+        rotate1.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+
+        // assert that one rotator doesn't leak into another
+        assertReadAll(rotate1, "foo");
+        assertReadAll(rotate2);
+    }
+
+    public void testCombine() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, DAY_IN_MILLIS, WEEK_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // first combine should have empty read, but still write data.
+        rotate.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "foo");
+
+        // second combine should replace contents; should read existing data,
+        // and write final data to disk.
+        currentTime += SECOND_IN_MILLIS;
+        reader.reset();
+        rotate.combineActive(reader, writer("bar"), currentTime);
+        reader.assertRead("foo");
+        assertReadAll(rotate, "bar");
+    }
+
+    public void testRotate() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, DAY_IN_MILLIS, WEEK_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // combine first record into file
+        rotate.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "foo");
+
+        // push time a few minutes forward; shouldn't rotate file
+        reader.reset();
+        currentTime += MINUTE_IN_MILLIS;
+        rotate.combineActive(reader, writer("bar"), currentTime);
+        reader.assertRead("foo");
+        assertReadAll(rotate, "bar");
+
+        // push time forward enough to rotate file; should still have same data
+        currentTime += DAY_IN_MILLIS + SECOND_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+        assertReadAll(rotate, "bar");
+
+        // combine a second time, should leave rotated value untouched, and
+        // active file should be empty.
+        reader.reset();
+        rotate.combineActive(reader, writer("baz"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "bar", "baz");
+    }
+
+    public void testDelete() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, MINUTE_IN_MILLIS, DAY_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // create first record and trigger rotating it
+        rotate.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+        currentTime += MINUTE_IN_MILLIS + SECOND_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+
+        // create second record
+        reader.reset();
+        rotate.combineActive(reader, writer("bar"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "foo", "bar");
+
+        // push time far enough to expire first record
+        currentTime = TEST_TIME + DAY_IN_MILLIS + (2 * MINUTE_IN_MILLIS);
+        rotate.maybeRotate(currentTime);
+        assertReadAll(rotate, "bar");
+
+        // push further to delete second record
+        currentTime += WEEK_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+        assertReadAll(rotate);
+    }
+
+    public void testThrowRestoresBackup() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, MINUTE_IN_MILLIS, DAY_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // first, write some valid data
+        rotate.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "foo");
+
+        try {
+            // now, try writing which will throw
+            reader.reset();
+            rotate.combineActive(reader, new Writer() {
+                public void write(OutputStream out) throws IOException {
+                    new DataOutputStream(out).writeUTF("bar");
+                    throw new ProtocolException("yikes");
+                }
+            }, currentTime);
+
+            fail("woah, somehow able to write exception");
+        } catch (ProtocolException e) {
+            // expected from above
+        }
+
+        // assert that we read original data, and that it's still intact after
+        // the failed write above.
+        reader.assertRead("foo");
+        assertReadAll(rotate, "foo");
+    }
+
+    public void testOtherFilesAndMalformed() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, SECOND_IN_MILLIS, SECOND_IN_MILLIS);
+
+        // should ignore another prefix
+        touch("another_rotator.1024");
+        touch("another_rotator.1024-2048");
+        assertReadAll(rotate);
+
+        // verify that broken filenames don't crash
+        touch("rotator");
+        touch("rotator...");
+        touch("rotator.-");
+        touch("rotator.---");
+        touch("rotator.a-b");
+        touch("rotator_but_not_actually");
+        assertReadAll(rotate);
+
+        // and make sure that we can read something from a legit file
+        write("rotator.100-200", "meow");
+        assertReadAll(rotate, "meow");
+    }
+
+    private static final String RED = "red";
+    private static final String GREEN = "green";
+    private static final String BLUE = "blue";
+    private static final String YELLOW = "yellow";
+
+    public void testQueryMatch() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, HOUR_IN_MILLIS, YEAR_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // rotate a bunch of historical data
+        rotate.maybeRotate(currentTime);
+        rotate.combineActive(reader, writer(RED), currentTime);
+
+        currentTime += DAY_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+        rotate.combineActive(reader, writer(GREEN), currentTime);
+
+        currentTime += DAY_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+        rotate.combineActive(reader, writer(BLUE), currentTime);
+
+        currentTime += DAY_IN_MILLIS;
+        rotate.maybeRotate(currentTime);
+        rotate.combineActive(reader, writer(YELLOW), currentTime);
+
+        final String[] FULL_SET = { RED, GREEN, BLUE, YELLOW };
+
+        assertReadAll(rotate, FULL_SET);
+        assertReadMatching(rotate, Long.MIN_VALUE, Long.MAX_VALUE, FULL_SET);
+        assertReadMatching(rotate, Long.MIN_VALUE, currentTime, FULL_SET);
+        assertReadMatching(rotate, TEST_TIME + SECOND_IN_MILLIS, currentTime, FULL_SET);
+
+        // should omit last value, since it only touches at currentTime
+        assertReadMatching(rotate, TEST_TIME + SECOND_IN_MILLIS, currentTime - SECOND_IN_MILLIS,
+                RED, GREEN, BLUE);
+
+        // check boundary condition
+        assertReadMatching(rotate, TEST_TIME + DAY_IN_MILLIS, Long.MAX_VALUE, FULL_SET);
+        assertReadMatching(rotate, TEST_TIME + DAY_IN_MILLIS + SECOND_IN_MILLIS, Long.MAX_VALUE,
+                GREEN, BLUE, YELLOW);
+
+        // test range smaller than file
+        final long blueStart = TEST_TIME + (DAY_IN_MILLIS * 2);
+        final long blueEnd = TEST_TIME + (DAY_IN_MILLIS * 3);
+        assertReadMatching(rotate, blueStart + SECOND_IN_MILLIS, blueEnd - SECOND_IN_MILLIS, BLUE);
+
+        // outside range should return nothing
+        assertReadMatching(rotate, Long.MIN_VALUE, TEST_TIME - DAY_IN_MILLIS);
+    }
+
+    public void testClockRollingBackwards() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, DAY_IN_MILLIS, YEAR_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // create record at current time
+        // --> foo
+        rotate.combineActive(reader, writer("foo"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "foo");
+
+        // record a day in past; should create a new active file
+        // --> bar
+        currentTime -= DAY_IN_MILLIS;
+        reader.reset();
+        rotate.combineActive(reader, writer("bar"), currentTime);
+        reader.assertRead();
+        assertReadAll(rotate, "bar", "foo");
+
+        // verify that we rewrite current active file
+        // bar --> baz
+        currentTime += SECOND_IN_MILLIS;
+        reader.reset();
+        rotate.combineActive(reader, writer("baz"), currentTime);
+        reader.assertRead("bar");
+        assertReadAll(rotate, "baz", "foo");
+
+        // return to present and verify we write oldest active file
+        // baz --> meow
+        currentTime = TEST_TIME + SECOND_IN_MILLIS;
+        reader.reset();
+        rotate.combineActive(reader, writer("meow"), currentTime);
+        reader.assertRead("baz");
+        assertReadAll(rotate, "meow", "foo");
+
+        // current time should trigger rotate of older active file
+        rotate.maybeRotate(currentTime);
+
+        // write active file, verify this time we touch original
+        // foo --> yay
+        reader.reset();
+        rotate.combineActive(reader, writer("yay"), currentTime);
+        reader.assertRead("foo");
+        assertReadAll(rotate, "meow", "yay");
+    }
+
+    @Suppress
+    public void testFuzz() throws Exception {
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, HOUR_IN_MILLIS, DAY_IN_MILLIS);
+
+        final RecordingReader reader = new RecordingReader();
+        long currentTime = TEST_TIME;
+
+        // walk forward through time, ensuring that files are cleaned properly
+        final Random random = new Random();
+        for (int i = 0; i < 1024; i++) {
+            currentTime += Math.abs(random.nextLong()) % DAY_IN_MILLIS;
+
+            reader.reset();
+            rotate.combineActive(reader, writer("meow"), currentTime);
+
+            if (random.nextBoolean()) {
+                rotate.maybeRotate(currentTime);
+            }
+        }
+
+        rotate.maybeRotate(currentTime);
+
+        Log.d(TAG, "currentTime=" + currentTime);
+        Log.d(TAG, Arrays.toString(mBasePath.list()));
+    }
+
+    public void testRecoverAtomic() throws Exception {
+        write("rotator.1024-2048", "foo");
+        write("rotator.1024-2048.backup", "bar");
+        write("rotator.2048-4096", "baz");
+        write("rotator.2048-4096.no_backup", "");
+
+        final FileRotator rotate = new FileRotator(
+                mBasePath, PREFIX, SECOND_IN_MILLIS, SECOND_IN_MILLIS);
+
+        // verify backup value was recovered; no_backup indicates that
+        // corresponding file had no backup and should be discarded.
+        assertReadAll(rotate, "bar");
+    }
+
+    private void touch(String... names) throws IOException {
+        for (String name : names) {
+            final OutputStream out = new FileOutputStream(new File(mBasePath, name));
+            out.close();
+        }
+    }
+
+    private void write(String name, String value) throws IOException {
+        final DataOutputStream out = new DataOutputStream(
+                new FileOutputStream(new File(mBasePath, name)));
+        out.writeUTF(value);
+        out.close();
+    }
+
+    private static Writer writer(final String value) {
+        return new Writer() {
+            public void write(OutputStream out) throws IOException {
+                new DataOutputStream(out).writeUTF(value);
+            }
+        };
+    }
+
+    private static void assertReadAll(FileRotator rotate, String... expected) throws IOException {
+        assertReadMatching(rotate, Long.MIN_VALUE, Long.MAX_VALUE, expected);
+    }
+
+    private static void assertReadMatching(
+            FileRotator rotate, long matchStartMillis, long matchEndMillis, String... expected)
+            throws IOException {
+        final RecordingReader reader = new RecordingReader();
+        rotate.readMatching(reader, matchStartMillis, matchEndMillis);
+        reader.assertRead(expected);
+    }
+
+    private static class RecordingReader implements Reader {
+        private ArrayList<String> mActual = Lists.newArrayList();
+
+        public void read(InputStream in) throws IOException {
+            mActual.add(new DataInputStream(in).readUTF());
+        }
+
+        public void reset() {
+            mActual.clear();
+        }
+
+        public void assertRead(String... expected) {
+            assertEquals(expected.length, mActual.size());
+
+            final ArrayList<String> actualCopy = new ArrayList<String>(mActual);
+            for (String value : expected) {
+                if (!actualCopy.remove(value)) {
+                    final String expectedString = Arrays.toString(expected);
+                    final String actualString = Arrays.toString(mActual.toArray());
+                    fail("expected: " + expectedString + " but was: " + actualString);
+                }
+            }
+        }
+    }
+}
diff --git a/data/fonts/DroidSansFallback.ttf b/data/fonts/DroidSansFallback.ttf
index 391755e..2379b2d 100644
--- a/data/fonts/DroidSansFallback.ttf
+++ b/data/fonts/DroidSansFallback.ttf
Binary files differ
diff --git a/data/fonts/DroidSansFallbackFull.ttf b/data/fonts/DroidSansFallbackFull.ttf
index 8bd5e63..41b015d 100644
--- a/data/fonts/DroidSansFallbackFull.ttf
+++ b/data/fonts/DroidSansFallbackFull.ttf
Binary files differ
diff --git a/data/fonts/Roboto-Bold.ttf b/data/fonts/Roboto-Bold.ttf
index 6d32fba..40ecd14 100644
--- a/data/fonts/Roboto-Bold.ttf
+++ b/data/fonts/Roboto-Bold.ttf
Binary files differ
diff --git a/data/fonts/Roboto-BoldItalic.ttf b/data/fonts/Roboto-BoldItalic.ttf
index fc2da4c..d9067c5 100644
--- a/data/fonts/Roboto-BoldItalic.ttf
+++ b/data/fonts/Roboto-BoldItalic.ttf
Binary files differ
diff --git a/data/fonts/Roboto-Italic.ttf b/data/fonts/Roboto-Italic.ttf
index ce2e072..88e4a5b 100644
--- a/data/fonts/Roboto-Italic.ttf
+++ b/data/fonts/Roboto-Italic.ttf
Binary files differ
diff --git a/data/fonts/Roboto-Regular.ttf b/data/fonts/Roboto-Regular.ttf
index 465dfc1..f592adf 100644
--- a/data/fonts/Roboto-Regular.ttf
+++ b/data/fonts/Roboto-Regular.ttf
Binary files differ
diff --git a/docs/html/guide/appendix/market-filters.jd b/docs/html/guide/appendix/market-filters.jd
index 6610f5f..07b9370 100644
--- a/docs/html/guide/appendix/market-filters.jd
+++ b/docs/html/guide/appendix/market-filters.jd
@@ -398,8 +398,8 @@
       the device's SIM (for GSM devices), not the current roaming carrier.</p></li></ul>
 </td> </tr> <tr>
   <td valign="top">Native Platform</td> <td valign="top"><p>An application that includes native
-    libraries that target a specific platform (ARM EABI v7, for example) will only be
-    visible on devices that support that platform. For details about the NDK and using
+    libraries that target a specific platform (ARM EABI v7 or x86, for example) are
+    visible only on devices that support that platform. For details about the NDK and using
     native libraries, see <a href="{@docRoot}sdk/ndk/index.html#overview">What is the
       Android NDK?</a></p> </tr> <tr>
         <td valign="top">Copy-Protected Applications</td> <td valign="top"><p>To
diff --git a/docs/html/guide/guide_toc.cs b/docs/html/guide/guide_toc.cs
index 7f3894d..be0ca0e 100644
--- a/docs/html/guide/guide_toc.cs
+++ b/docs/html/guide/guide_toc.cs
@@ -282,6 +282,10 @@
                 <span class="en">Compute</span>
               </a>
           </li>
+          <li><a href="<?cs var:toroot ?>guide/topics/renderscript/reference.html">
+                <span class="en">Runtime API Reference</span>
+              </a>
+          </li>
         </ul>
       </li>
 
diff --git a/docs/html/guide/practices/ui_guidelines/activity_task_design.jd b/docs/html/guide/practices/ui_guidelines/activity_task_design.jd
index 31ad466..5faa7ec 100644
--- a/docs/html/guide/practices/ui_guidelines/activity_task_design.jd
+++ b/docs/html/guide/practices/ui_guidelines/activity_task_design.jd
@@ -40,7 +40,7 @@
       <li><a href=#reusing_tip>Handle case where no activity matches</a></li>
       <li><a href=#activity_launching_tip>Consider how to launch your activities</a></li>
       <li><a href=#activities_added_to_task_tip>Allow activities to add to current task</a></li>
-      <li><a href=#notifications_get_back_tip>Notifications should let user easily get back</li>
+      <li><a href=#notifications_get_back_tip>Notifications and App Widgets should provide consistent back behavior</li>
       <li><a href=#use_notification_tip>Use the notification system</a></li>
       <li><a href=#taking_over_back_key>Don't take over BACK key unless you absolutely need to</a></li>
     </ol>
@@ -1063,110 +1063,23 @@
 </p>
 
     
-<h3 id="notifications_get_back_tip">Notifications should let the user easily get back to the previous activity</h3>
+<h3 id="notifications_get_back_tip">Notifications and App Widgets should provide consistent back behavior</h3>
 <p>
-  Applications that are in the background or not running can have
-  services that send out notifications to the user letting them know about
-  events of interest. Two examples are Calendar, which can send out notifications of
-  upcoming events, and Email, which can send out notifications when new
-  messages arrive. One of the user interface guidelines is that when the
-  user is in activity A, gets a notification for activity B and
-  picks that notification, when they press the BACK key, they should
-  go back to activity A.&nbsp;
+  Notifications and app widgets are two common ways that a user can launch
+  your app through something besides its main icon in Launcher.  You must
+  take care when implementing these so that the user has a consistent experience
+  with the back button, not causing surprises in where they return to or the
+  state the application ends up in.
 </p>
 
 <p>
-  The following scenario shows how the activity stack should work
-  when the user responds to a notification.
-</p>
-
-<ol>
-  <li>
-    User is creating a new event in Calendar. They realize they
-    need to copy part of an email message into this event
-  </li>
-  <li>
-    The user chooses Home &gt; Gmail
-  </li>
-  <li>
-    While in Gmail, they receive a notification from Calendar for an upcoming meeting
-  </li>
-  <li>
-    So they choose that notification, which takes them to a
-    dedicated Calendar activity that displays brief details of the
-    upcoming meeting
-  </li>
-  <li>
-    The user chooses this short notice to view further details
-  </li>
-  <li>
-    When done viewing the event, the user presses the BACK
-    key. They should be taken to Gmail, which is where they were
-    when they took the notification
-  </li>
-</ol>
-
-<p>
-This behavior doesn't necessarily happen by default.
-</p>
-
-<p>
-Notifications generally happen primarily in one of two ways:
-</p>
-
-  <ul>
-    <li>
-      <b>The chosen activity is dedicated for notification only</b> -
-      For example, when the user receives a
-      Calendar notification, choosing that
-      notification starts a special activity that displays a list
-      of upcoming calendar events &mdash; this view is available only
-      from the notification, not through the Calendar's own user
-      interface. After viewing this upcoming event, to ensure that
-      the user pressing the BACK key will return to the activity
-      the user was in when they picked the notification, you would
-      make sure this dedicated activity does not have the same
-      task affinity as the Calendar or any other activity. (You do
-      this by setting task affinity to the empty string, which
-      means it has no affinity to anything.) The explanation for
-      this follows.
-
-      <p>
-      Because of the way tasks work, if the taskAffinity of the
-      dedicated activity is kept as its default, then pressing the
-      BACK key (in step 6, above) would go to Calendar, rather
-      than Gmail. The reason is that, by default, all activities
-      in a given application have the same task
-      affinity. Therefore, the task affinity of the dedicated
-      activity matches the Calendar task, which is already running
-      in step 1. This means in step 4, choosing the notification
-      brings the existing Calendar event (in step 1) forward and
-      starts the dedicated activity on top of it.  This is not
-      what you want to have happen. Setting the dedicated
-      activity's taskAffinity to empty string fixes this.
-      </p>
-    </li>
-
-    <li>
-      <b>The chosen activity is not dedicated, but always comes to
-      the foreground in its initial state</b> - For example, in
-      response to a notification, when the Gmail application comes
-      to the foreground, it always presents the list of conversations.
-      You can ensure this happens by setting a "clear top" flag in the
-      intent that the notification triggers.  This ensures that when the
-      activity is launched, it displays its initial activity, preventing
-      Gmail from coming to the foreground in whatever state the user last
-      happened to be viewing it. (To do this, you put {@link
-      android.content.Intent#FLAG_ACTIVITY_CLEAR_TOP
-      FLAG_ACTIVITY_CLEAR_TOP} in the intent you pass to startActivity()). 
-    </li>
-  </ul>
-
-<p>
-  There are other ways to handle notifications, such as bringing the
-  activity to the foreground, set to display specific data, such as
-  displaying the text message thread for the person who just sent a
-  new text message.
+  The
+  <a href="{@docRoot}guide/topics/ui/notifiers/notifications.html#HandlingNotifications">Handling
+  Notifications</a> section of the developer guide's
+  <a href="{@docRoot}guide/topics/ui/notifiers/notifications.html">Status Bar Notifications</a>
+  documentation provides an overview of how to write code to correctly handle
+  notification.  This dicussion applies equally to handling interactions with
+  app widgets.
 </p>
 
 <p>
diff --git a/docs/html/guide/topics/graphics/hardware-accel.jd b/docs/html/guide/topics/graphics/hardware-accel.jd
index c8703a5..e3ff215 100644
--- a/docs/html/guide/topics/graphics/hardware-accel.jd
+++ b/docs/html/guide/topics/graphics/hardware-accel.jd
@@ -283,8 +283,6 @@
 
         <li>{@link android.graphics.Canvas#drawPicture drawPicture()}</li>
 
-        <li>{@link android.graphics.Canvas#drawPosText drawPosText()}</li>
-
         <li>{@link android.graphics.Canvas#drawTextOnPath drawTextOnPath()}</li>
 
         <li>{@link android.graphics.Canvas#drawVertices drawVertices()}</li>
@@ -318,9 +316,6 @@
         <li>{@link android.graphics.Canvas#drawBitmapMesh drawBitmapMesh()}: colors array is
         ignored</li>
 
-        <li>{@link android.graphics.Canvas#drawLines drawLines()}: anti-aliasing is not
-        supported</li>
-
         <li>{@link android.graphics.Canvas#setDrawFilter setDrawFilter()}: can be set, but is
         ignored</li>
       </ul>
diff --git a/docs/html/guide/topics/renderscript/reference.jd b/docs/html/guide/topics/renderscript/reference.jd
new file mode 100644
index 0000000..a0a9df2
--- /dev/null
+++ b/docs/html/guide/topics/renderscript/reference.jd
@@ -0,0 +1,18 @@
+page.title=Runtime API Reference
+@jd:body
+
+<script language="JavaScript">
+
+function autoResize(element){
+    var newheight;
+    var newwidth;
+
+    newheight = element.contentWindow.document.body.scrollHeight + 20;
+    newwidth = element.contentWindow.document.body.scrollWidth;
+    element.height = (newheight) + "px";
+    element.width = (newwidth) + "px";
+}
+</script>
+
+
+<iframe SRC="{@docRoot}reference/renderscript/index.html" width="100%"  id="iframe" marginheight="0" frameborder="0" onLoad="autoResize(this);"></iframe>
diff --git a/docs/html/guide/topics/resources/providing-resources.jd b/docs/html/guide/topics/resources/providing-resources.jd
index 3a176e6..380791a 100644
--- a/docs/html/guide/topics/resources/providing-resources.jd
+++ b/docs/html/guide/topics/resources/providing-resources.jd
@@ -231,6 +231,9 @@
     </ul>
     <p>You can append more than one <em>{@code &lt;qualifier&gt;}</em>. Separate each
 one with a dash.</p>
+    <p class="caution"><strong>Caution:</strong> When appending multiple qualifiers, you must
+place them in the same order in which they are listed in table 2. If the qualifiers are ordered
+wrong, the resources are ignored.</p>
   </li>
   <li>Save the respective alternative resources in this new directory. The resource files must be
 named exactly the same as the default resource files.</li>
@@ -254,20 +257,14 @@
 the same. This way, the resource ID that you use to reference the {@code icon.png} or {@code
 background.png} image is always the same, but Android selects the
 version of each resource that best matches the current device, by comparing the device
-configuration information with the qualifiers in the alternative resource directory name.</p>
+configuration information with the qualifiers in the resource directory name.</p>
 
 <p>Android supports several configuration qualifiers and you can
 add multiple qualifiers to one directory name, by separating each qualifier with a dash. Table 2
 lists the valid configuration qualifiers, in order of precedence&mdash;if you use multiple
-qualifiers for one resource directory, they must be added to the directory name in the order they
+qualifiers for a resource directory, you must add them to the directory name in the order they
 are listed in the table.</p>
 
-<p class="note"><strong>Note:</strong> Some configuration qualifiers were added after Android 1.0,
-so not
-all versions of Android support all the qualifiers listed in table 2. New qualifiers
-indicate the version in which they were added. To avoid any issues, always include a set of default
-resources for resources that your application uses. For more information, see the section about <a
-href="#Compatibility">Providing the Best Device Compatibility with Resources</a>.</p>
 
 <p class="table-caption" id="table2"><strong>Table 2.</strong> Configuration qualifier
 names.</p>
@@ -752,6 +749,17 @@
 </table>
 
 
+<p class="note"><strong>Note:</strong> Some configuration qualifiers have been added since Android
+1.0, so not all versions of Android support all the qualifiers. Using a new qualifier implicitly
+adds the platform version qualifier so that older devices are sure to ignore it. For example, using
+a <code>w600dp</code> qualifier will automatically include the <code>v13</code> qualifier, because
+the available-width qualifier was new in API level 13. To avoid any issues, always include a set of
+default resources (a set of resources with <em>no qualifiers</em>). For more information, see the
+section about <a href="#Compatibility">Providing the Best Device Compatibility with
+Resources</a>.</p>
+
+
+
 <h3 id="QualifierRules">Qualifier name rules</h3>
 
 <p>Here are some rules about using configuration qualifier names:</p>
diff --git a/docs/html/guide/topics/ui/notifiers/notifications.jd b/docs/html/guide/topics/ui/notifiers/notifications.jd
index 71aa2fe..33b0fec 100644
--- a/docs/html/guide/topics/ui/notifiers/notifications.jd
+++ b/docs/html/guide/topics/ui/notifiers/notifications.jd
@@ -16,6 +16,7 @@
     <h2>In this document</h2>
     <ol>
       <li><a href="#Basics">The Basics</a></li>
+      <li><a href="#HandlingNotifications">Responding to Notifications</a></li>
       <li><a href="#ManageYourNotifications">Managing your Notifications</a></li>
       <li><a href="#CreateANotification">Creating a Notification</a>
         <ol>
@@ -137,6 +138,138 @@
 </ol>
 
 
+<h2 id="HandlingNotifications">Responding to Notifications</h2>
+
+<p>A central part of the user's experience with a notification revolves around
+how it interacts with the application's UI flow.  You must implement
+this correctly to provide a consistent user experience within your app.</p>
+
+<p>Two typical examples of notifications are provided by Calendar, which can send out
+notifications of upcoming events, and Email, which can send out notifications
+when new messages arrive.  These represent the two recommended patterns for handling
+notifications: either launching into an activity that is separate from the
+main application, or launching an entirely new instance of the application
+showing the appropriate point for the notification.</p>
+
+<p>The following scenario shows how the activity stack should work
+in these two typical notification flows, first handling a Calendar notification:
+</p>
+
+<ol>
+  <li>User is creating a new event in Calendar. They realize they
+    need to copy part of an email message into this event.
+  </li>
+  <li>
+    The user chooses Home &gt; Email.
+  </li>
+  <li>
+    While in Email, they receive a notification from Calendar for an upcoming
+    meeting.
+  </li>
+  <li>
+    So they choose that notification, which takes them to a
+    dedicated Calendar activity that displays brief details of the
+    upcoming meeting.
+  </li>
+  <li>
+    The user has seen enough to know they have a meeting coming up,
+    so they press the BACK button.  They are now returned to Email, which
+    is where they were when they took the notification.
+  </li>
+</ol>
+
+<p>Handling an Email notification:</p>
+
+<ol>
+  <li>
+    The user is currently in Email composing a message, and needs to
+    check a date in their calendar.
+  </li>
+  <li>
+    The user chooses Home &gt; Calendar.
+  </li>
+  <li>
+    While in Calendar, they receive a notification from Email about a new
+    message.
+  </li>
+  <li>
+    They select the notification, which brings them to Email with the message
+    details displayed.  This has replaced what they were previously doing
+    (writing an e-mail), but that message is still saved in their drafts.
+  </li>
+  <li>
+    The user presses BACK once to go to the message list (the typical flow in the
+    Email app), and press BACK again to return to Calendar as they left it.
+  </li>
+</ol>
+
+<p>In an Email style of notification, the UI launched by the notification
+shows the main application in a state representing that notification.
+For example, when the Email application comes to the foreground from its
+notification, it displays either the conversion list or a specific
+conversation depending on whether there are multiple or only one new
+email.  To achieve this, we want to completely replace whatever current
+state the application is in with a new activity stack representing the
+new notification state.</p>
+
+<p>The following code illustrates how to show this kind of notification.  Of
+most interest is the <code>makeMessageIntentStack()</code> method, which constructs
+an array of intents representing the app's new activity stack for this state.
+(If you are using fragments, you may need to initialize your fragment and
+app state so that pressing BACK will switch the UI back to its parent state.)
+The core of this is the {@link android.content.Intent#makeRestartActivityTask
+Intent.makeRestartActivityTask()} method, which constructs the root activity
+of the stack with the appropriate flags, such as
+{@link android.content.Intent#FLAG_ACTIVITY_CLEAR_TASK Intent.FLAG_ACTIVITY_CLEAR_TASK}.</p>
+
+{@sample development/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessage.java
+  app_notification}
+
+<p>In a Calendar style of notification, the UI launched by the notification
+is a dedicated activity that is not part of the normal application flow.
+For example, when the user receives a Calendar notification, choosing that
+notification starts a special activity that displays a list
+of upcoming calendar events &mdash; this view is available only
+from the notification, not through the Calendar's normal user
+interface.</p>
+
+<p>The code for posting this type of notification is very straight-forward; it
+is like the above, but the {@link android.app.PendingIntent} is for just a single
+activity, our dedicated notification activity.</p>
+
+{@sample development/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessage.java
+  interstitial_notification}
+
+<p>This is not enough, however.  Normally Android considers all activities within
+an application to be part of that application's UI flow, so simply launching the
+activity like this can cause it to be mixed with your normal application back stack
+in undesired ways.  To make it behave correctly, in the manifest declaration
+for the activity the attributes 
+<code>android:launchMode="singleInstance"</code> and
+<code>android:excludeFromRecents="true"</code>
+must be set.  The full activity declaration for this sample is:</p>
+
+{@sample development/samples/ApiDemos/AndroidManifest.xml interstitial_affinity}
+
+<p>Because of the use of <code>singleInstance</code>, you must be careful about launching
+any other activities from this one.  These activities will be launched
+in their own task, and care must be taken to make sure this interacts
+well with the current state of your application's task.  This is essentially
+the same as switching to the main application as described for the Email style
+notification shown before.  Given the <code>makeMessageIntentStack()</code>
+method previously shown, handling a click here would look something like this:</p>
+
+{@sample development/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessageInterstitial.java
+  app_launch}
+
+<p>If you don't want to use the <code>singleInstance</code> launch mode for
+this activity, an alternative approach is to use <code>android:taskAffinity=""</code>.
+This tells Android that the activity should not be treated as part of the
+main application flow, so it will not get mixed together with that.  All of the
+other issues discussed here do still apply, though this would allow you to start
+additional activities that are part of this notification task instead of switching
+to and replacing the main application task.</p>
+
 <h2 id="ManageYourNotifications">Managing your Notifications</h2>
 
 <p>The {@link android.app.NotificationManager} is a system service that manages all
diff --git a/docs/html/guide/topics/usb/adk.jd b/docs/html/guide/topics/usb/adk.jd
index 99c5f92..4d5fbfa 100644
--- a/docs/html/guide/topics/usb/adk.jd
+++ b/docs/html/guide/topics/usb/adk.jd
@@ -281,16 +281,17 @@
       <p>On Mac:</p>
 
       <ol type="a">
-        <li>Right-click on the Arduino application in Finder and select <strong>Show Package
-        Contents</strong>.</li>
+        <li>Create, if it does not already exist, an <code>Arduino</code>
+        directory inside your user account's <code>Documents</code> directory, and within
+        that, a <code>libraries</code> directory.</li>
 
         <li>Copy the <code>firmware/arduino_libs/AndroidAccessory</code> and
-        <code>firmware/arduino_libs/USB_Host_Shield</code> directories (the complete directories,
-        not just the files within) to the <code>Contents/Resources/Java/libraries</code> directory
-        inside the Arduino application.</li>
+        <code>firmware/arduino_libs/USB_Host_Shield</code> directories (the
+        complete directories, not just the files within) to your
+        <code>Documents/Arduino/libraries/</code> directory.</li>
 
-        <li>Create a <code>CapSense</code> directory in the
-        <code>Contents/Resources/Java/libraries</code> directory.</li>
+        <li>Create a <code>CapSense</code> directory in your
+        <code>Documents/Arduino/libraries/</code> directory.</li>
 
         <li>Copy <code>CapSense.cpp</code> and <code>CapSense.h</code> from the unzipped CapSense
         download to the <code>CapSense</code> directory.</li>
diff --git a/docs/html/reference/renderscript/annotated.html b/docs/html/reference/renderscript/annotated.html
new file mode 100644
index 0000000..0425db2
--- /dev/null
+++ b/docs/html/reference/renderscript/annotated.html
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Data Structures</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">Data Structures</div>  </div>
+</div>
+<div class="contents">
+<div class="textblock"> </div><table>
+  <tr><td class="indexkey"><a class="el" href="structrs__allocation.html">rs_allocation</a></td><td class="indexvalue">Opaque handle to a Renderscript allocation </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__element.html">rs_element</a></td><td class="indexvalue">Opaque handle to a Renderscript element </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__font.html">rs_font</a></td><td class="indexvalue">Opaque handle to a Renderscript font object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a></td><td class="indexvalue">2x2 float matrix </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a></td><td class="indexvalue">3x3 float matrix </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a></td><td class="indexvalue">4x4 float matrix </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__mesh.html">rs_mesh</a></td><td class="indexvalue">Opaque handle to a Renderscript mesh object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a></td><td class="indexvalue">Opaque handle to a Renderscript ProgramFragment object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__program__raster.html">rs_program_raster</a></td><td class="indexvalue">Opaque handle to a Renderscript ProgramRaster object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__program__store.html">rs_program_store</a></td><td class="indexvalue">Opaque handle to a Renderscript ProgramStore object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a></td><td class="indexvalue">Opaque handle to a Renderscript ProgramVertex object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__sampler.html">rs_sampler</a></td><td class="indexvalue">Opaque handle to a Renderscript sampler object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__script.html">rs_script</a></td><td class="indexvalue">Opaque handle to a Renderscript script object </td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__script__call.html">rs_script_call</a></td><td class="indexvalue"></td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__tm.html">rs_tm</a></td><td class="indexvalue"></td></tr>
+  <tr><td class="indexkey"><a class="el" href="structrs__type.html">rs_type</a></td><td class="indexvalue">Opaque handle to a Renderscript type </td></tr>
+</table>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/doxygen.css b/docs/html/reference/renderscript/doxygen.css
new file mode 100644
index 0000000..22c7b5c
--- /dev/null
+++ b/docs/html/reference/renderscript/doxygen.css
@@ -0,0 +1,946 @@
+/* The standard CSS for doxygen */
+
+body, table, div, p, dl {
+	font-family: Lucida Grande, Verdana, Geneva, Arial, sans-serif;
+	font-size: 12px;
+}
+
+/* @group Heading Levels */
+
+h1 {
+	font-size: 150%;
+}
+
+.title {
+	font-size: 150%;
+	font-weight: bold;
+	margin: 10px 2px;
+}
+
+h2 {
+	font-size: 120%;
+}
+
+h3 {
+	font-size: 100%;
+}
+
+dt {
+	font-weight: bold;
+}
+
+div.multicol {
+	-moz-column-gap: 1em;
+	-webkit-column-gap: 1em;
+	-moz-column-count: 3;
+	-webkit-column-count: 3;
+}
+
+p.startli, p.startdd, p.starttd {
+	margin-top: 2px;
+}
+
+p.endli {
+	margin-bottom: 0px;
+}
+
+p.enddd {
+	margin-bottom: 4px;
+}
+
+p.endtd {
+	margin-bottom: 2px;
+}
+
+/* @end */
+
+caption {
+	font-weight: bold;
+}
+
+span.legend {
+        font-size: 70%;
+        text-align: center;
+}
+
+h3.version {
+        font-size: 90%;
+        text-align: center;
+}
+
+div.qindex, div.navtab{
+	background-color: #EBEFF6;
+	border: 1px solid #A3B4D7;
+	text-align: center;
+}
+
+div.qindex, div.navpath {
+	width: 100%;
+	line-height: 140%;
+}
+
+div.navtab {
+	margin-right: 15px;
+}
+
+/* @group Link Styling */
+
+a {
+	color: #3D578C;
+	font-weight: normal;
+	text-decoration: none;
+}
+
+.contents a:visited {
+	color: #4665A2;
+}
+
+a:hover {
+	text-decoration: underline;
+}
+
+a.qindex {
+	font-weight: bold;
+}
+
+a.qindexHL {
+	font-weight: bold;
+	background-color: #9CAFD4;
+	color: #ffffff;
+	border: 1px double #869DCA;
+}
+
+.contents a.qindexHL:visited {
+        color: #ffffff;
+}
+
+a.el {
+	font-weight: bold;
+}
+
+a.elRef {
+}
+
+a.code {
+	color: #4665A2;
+}
+
+a.codeRef {
+	color: #4665A2;
+}
+
+/* @end */
+
+dl.el {
+	margin-left: -1cm;
+}
+
+.fragment {
+	font-family: monospace, fixed;
+	font-size: 105%;
+}
+
+pre.fragment {
+	border: 1px solid #C4CFE5;
+	background-color: #FBFCFD;
+	padding: 4px 6px;
+	margin: 4px 8px 4px 2px;
+	overflow: auto;
+	word-wrap: break-word;
+	font-size:  9pt;
+	line-height: 125%;
+}
+
+div.ah {
+	background-color: black;
+	font-weight: bold;
+	color: #ffffff;
+	margin-bottom: 3px;
+	margin-top: 3px;
+	padding: 0.2em;
+	border: solid thin #333;
+	border-radius: 0.5em;
+	-webkit-border-radius: .5em;
+	-moz-border-radius: .5em;
+	box-shadow: 2px 2px 3px #999;
+	-webkit-box-shadow: 2px 2px 3px #999;
+	-moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px;
+	background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444));
+	background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000);
+}
+
+div.groupHeader {
+	margin-left: 16px;
+	margin-top: 12px;
+	font-weight: bold;
+}
+
+div.groupText {
+	margin-left: 16px;
+	font-style: italic;
+}
+
+body {
+	background-color: white;
+	color: black;
+        margin: 0;
+}
+
+div.contents {
+	margin-top: 10px;
+	margin-left: 8px;
+	margin-right: 8px;
+}
+
+td.indexkey {
+	background-color: #EBEFF6;
+	font-weight: bold;
+	border: 1px solid #C4CFE5;
+	margin: 2px 0px 2px 0;
+	padding: 2px 10px;
+}
+
+td.indexvalue {
+	background-color: #EBEFF6;
+	border: 1px solid #C4CFE5;
+	padding: 2px 10px;
+	margin: 2px 0px;
+}
+
+tr.memlist {
+	background-color: #EEF1F7;
+}
+
+p.formulaDsp {
+	text-align: center;
+}
+
+img.formulaDsp {
+	
+}
+
+img.formulaInl {
+	vertical-align: middle;
+}
+
+div.center {
+	text-align: center;
+        margin-top: 0px;
+        margin-bottom: 0px;
+        padding: 0px;
+}
+
+div.center img {
+	border: 0px;
+}
+
+address.footer {
+	text-align: right;
+	padding-right: 12px;
+}
+
+img.footer {
+	border: 0px;
+	vertical-align: middle;
+}
+
+/* @group Code Colorization */
+
+span.keyword {
+	color: #008000
+}
+
+span.keywordtype {
+	color: #604020
+}
+
+span.keywordflow {
+	color: #e08000
+}
+
+span.comment {
+	color: #800000
+}
+
+span.preprocessor {
+	color: #806020
+}
+
+span.stringliteral {
+	color: #002080
+}
+
+span.charliteral {
+	color: #008080
+}
+
+span.vhdldigit { 
+	color: #ff00ff 
+}
+
+span.vhdlchar { 
+	color: #000000 
+}
+
+span.vhdlkeyword { 
+	color: #700070 
+}
+
+span.vhdllogic { 
+	color: #ff0000 
+}
+
+/* @end */
+
+/*
+.search {
+	color: #003399;
+	font-weight: bold;
+}
+
+form.search {
+	margin-bottom: 0px;
+	margin-top: 0px;
+}
+
+input.search {
+	font-size: 75%;
+	color: #000080;
+	font-weight: normal;
+	background-color: #e8eef2;
+}
+*/
+
+td.tiny {
+	font-size: 75%;
+}
+
+.dirtab {
+	padding: 4px;
+	border-collapse: collapse;
+	border: 1px solid #A3B4D7;
+}
+
+th.dirtab {
+	background: #EBEFF6;
+	font-weight: bold;
+}
+
+hr {
+	height: 0px;
+	border: none;
+	border-top: 1px solid #4A6AAA;
+}
+
+hr.footer {
+	height: 1px;
+}
+
+/* @group Member Descriptions */
+
+table.memberdecls {
+	border-spacing: 0px;
+	padding: 0px;
+}
+
+.mdescLeft, .mdescRight,
+.memItemLeft, .memItemRight,
+.memTemplItemLeft, .memTemplItemRight, .memTemplParams {
+	background-color: #F9FAFC;
+	border: none;
+	margin: 4px;
+	padding: 1px 0 0 8px;
+}
+
+.mdescLeft, .mdescRight {
+	padding: 0px 8px 4px 8px;
+	color: #555;
+}
+
+.memItemLeft, .memItemRight, .memTemplParams {
+	border-top: 1px solid #C4CFE5;
+}
+
+.memItemLeft, .memTemplItemLeft {
+        white-space: nowrap;
+}
+
+.memItemRight {
+	width: 100%;
+}
+
+.memTemplParams {
+	color: #4665A2;
+        white-space: nowrap;
+}
+
+/* @end */
+
+/* @group Member Details */
+
+/* Styles for detailed member documentation */
+
+.memtemplate {
+	font-size: 80%;
+	color: #4665A2;
+	font-weight: normal;
+	margin-left: 9px;
+}
+
+.memnav {
+	background-color: #EBEFF6;
+	border: 1px solid #A3B4D7;
+	text-align: center;
+	margin: 2px;
+	margin-right: 15px;
+	padding: 2px;
+}
+
+.mempage {
+	width: 100%;
+}
+
+.memitem {
+	padding: 0;
+	margin-bottom: 10px;
+	margin-right: 5px;
+}
+
+.memname {
+        white-space: nowrap;
+        font-weight: bold;
+        margin-left: 6px;
+}
+
+.memproto, dl.reflist dt {
+        border-top: 1px solid #A8B8D9;
+        border-left: 1px solid #A8B8D9;
+        border-right: 1px solid #A8B8D9;
+        padding: 6px 0px 6px 0px;
+        color: #253555;
+        font-weight: bold;
+        text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9);
+        /* opera specific markup */
+        box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
+        border-top-right-radius: 8px;
+        border-top-left-radius: 8px;
+        /* firefox specific markup */
+        -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;
+        -moz-border-radius-topright: 8px;
+        -moz-border-radius-topleft: 8px;
+        /* webkit specific markup */
+        -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
+        -webkit-border-top-right-radius: 8px;
+        -webkit-border-top-left-radius: 8px;
+        background-image:url('nav_f.png');
+        background-repeat:repeat-x;
+        background-color: #E2E8F2;
+
+}
+
+.memdoc, dl.reflist dd {
+        border-bottom: 1px solid #A8B8D9;      
+        border-left: 1px solid #A8B8D9;      
+        border-right: 1px solid #A8B8D9; 
+        padding: 2px 5px;
+        background-color: #FBFCFD;
+        border-top-width: 0;
+        /* opera specific markup */
+        border-bottom-left-radius: 8px;
+        border-bottom-right-radius: 8px;
+        box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
+        /* firefox specific markup */
+        -moz-border-radius-bottomleft: 8px;
+        -moz-border-radius-bottomright: 8px;
+        -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px;
+        background-image: -moz-linear-gradient(center top, #FFFFFF 0%, #FFFFFF 60%, #F7F8FB 95%, #EEF1F7);
+        /* webkit specific markup */
+        -webkit-border-bottom-left-radius: 8px;
+        -webkit-border-bottom-right-radius: 8px;
+        -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
+        background-image: -webkit-gradient(linear,center top,center bottom,from(#FFFFFF), color-stop(0.6,#FFFFFF), color-stop(0.60,#FFFFFF), color-stop(0.95,#F7F8FB), to(#EEF1F7));
+}
+
+dl.reflist dt {
+        padding: 5px;
+}
+
+dl.reflist dd {
+        margin: 0px 0px 10px 0px;
+        padding: 5px;
+}
+
+.paramkey {
+	text-align: right;
+}
+
+.paramtype {
+	white-space: nowrap;
+}
+
+.paramname {
+	color: #602020;
+	white-space: nowrap;
+}
+.paramname em {
+	font-style: normal;
+}
+
+.params, .retval, .exception, .tparams {
+        border-spacing: 6px 2px;
+}       
+
+.params .paramname, .retval .paramname {
+        font-weight: bold;
+        vertical-align: top;
+}
+        
+.params .paramtype {
+        font-style: italic;
+        vertical-align: top;
+}       
+        
+.params .paramdir {
+        font-family: "courier new",courier,monospace;
+        vertical-align: top;
+}
+
+
+
+
+/* @end */
+
+/* @group Directory (tree) */
+
+/* for the tree view */
+
+.ftvtree {
+	font-family: sans-serif;
+	margin: 0px;
+}
+
+/* these are for tree view when used as main index */
+
+.directory {
+	font-size: 9pt;
+	font-weight: bold;
+	margin: 5px;
+}
+
+.directory h3 {
+	margin: 0px;
+	margin-top: 1em;
+	font-size: 11pt;
+}
+
+/*
+The following two styles can be used to replace the root node title
+with an image of your choice.  Simply uncomment the next two styles,
+specify the name of your image and be sure to set 'height' to the
+proper pixel height of your image.
+*/
+
+/*
+.directory h3.swap {
+	height: 61px;
+	background-repeat: no-repeat;
+	background-image: url("yourimage.gif");
+}
+.directory h3.swap span {
+	display: none;
+}
+*/
+
+.directory > h3 {
+	margin-top: 0;
+}
+
+.directory p {
+	margin: 0px;
+	white-space: nowrap;
+}
+
+.directory div {
+	display: none;
+	margin: 0px;
+}
+
+.directory img {
+	vertical-align: -30%;
+}
+
+/* these are for tree view when not used as main index */
+
+.directory-alt {
+	font-size: 100%;
+	font-weight: bold;
+}
+
+.directory-alt h3 {
+	margin: 0px;
+	margin-top: 1em;
+	font-size: 11pt;
+}
+
+.directory-alt > h3 {
+	margin-top: 0;
+}
+
+.directory-alt p {
+	margin: 0px;
+	white-space: nowrap;
+}
+
+.directory-alt div {
+	display: none;
+	margin: 0px;
+}
+
+.directory-alt img {
+	vertical-align: -30%;
+}
+
+/* @end */
+
+div.dynheader {
+        margin-top: 8px;
+}
+
+address {
+	font-style: normal;
+	color: #2A3D61;
+}
+
+table.doxtable {
+	border-collapse:collapse;
+}
+
+table.doxtable td, table.doxtable th {
+	border: 1px solid #2D4068;
+	padding: 3px 7px 2px;
+}
+
+table.doxtable th {
+	background-color: #374F7F;
+	color: #FFFFFF;
+	font-size: 110%;
+	padding-bottom: 4px;
+	padding-top: 5px;
+	text-align:left;
+}
+
+table.fieldtable {
+        width: 100%;
+        margin-bottom: 10px;
+        border: 1px solid #A8B8D9;
+        border-spacing: 0px;
+        -moz-border-radius: 4px;
+        -webkit-border-radius: 4px;
+        border-radius: 4px;
+        -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px;
+        -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15);
+        box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15);
+}
+
+.fieldtable td, .fieldtable th {
+        padding: 3px 7px 2px;
+}
+
+.fieldtable td.fieldtype, .fieldtable td.fieldname {
+        white-space: nowrap;
+        border-right: 1px solid #A8B8D9;
+        border-bottom: 1px solid #A8B8D9;
+        vertical-align: top;
+}
+
+.fieldtable td.fielddoc {
+        border-bottom: 1px solid #A8B8D9;
+        width: 100%;
+}
+
+.fieldtable tr:last-child td {
+        border-bottom: none;
+}
+
+.fieldtable th {
+        background-image:url('nav_f.png');
+        background-repeat:repeat-x;
+        background-color: #E2E8F2;
+        font-size: 90%;
+        color: #253555;
+        padding-bottom: 4px;
+        padding-top: 5px;
+        text-align:left;
+        -moz-border-radius-topleft: 4px;
+        -moz-border-radius-topright: 4px;
+        -webkit-border-top-left-radius: 4px;
+        -webkit-border-top-right-radius: 4px;
+        border-top-left-radius: 4px;
+        border-top-right-radius: 4px;
+        border-bottom: 1px solid #A8B8D9;
+}
+
+
+.tabsearch {
+	top: 0px;
+	left: 10px;
+	height: 36px;
+	background-image: url('tab_b.png');
+	z-index: 101;
+	overflow: hidden;
+	font-size: 13px;
+}
+
+.navpath ul
+{
+	font-size: 11px;
+	background-image:url('tab_b.png');
+	background-repeat:repeat-x;
+	height:30px;
+	line-height:30px;
+	color:#8AA0CC;
+	border:solid 1px #C2CDE4;
+	overflow:hidden;
+	margin:0px;
+	padding:0px;
+}
+
+.navpath li
+{
+	list-style-type:none;
+	float:left;
+	padding-left:10px;
+	padding-right:15px;
+	background-image:url('bc_s.png');
+	background-repeat:no-repeat;
+	background-position:right;
+	color:#364D7C;
+}
+
+.navpath li.navelem a
+{
+	height:32px;
+	display:block;
+	text-decoration: none;
+	outline: none;
+}
+
+.navpath li.navelem a:hover
+{
+	color:#6884BD;
+}
+
+.navpath li.footer
+{
+        list-style-type:none;
+        float:right;
+        padding-left:10px;
+        padding-right:15px;
+        background-image:none;
+        background-repeat:no-repeat;
+        background-position:right;
+        color:#364D7C;
+        font-size: 8pt;
+}
+
+
+div.summary
+{
+	float: right;
+	font-size: 8pt;
+	padding-right: 5px;
+	width: 50%;
+	text-align: right;
+}       
+
+div.summary a
+{
+	white-space: nowrap;
+}
+
+div.ingroups
+{
+	margin-left: 5px;
+	font-size: 8pt;
+	padding-left: 5px;
+	width: 50%;
+	text-align: left;
+}
+
+div.ingroups a
+{
+	white-space: nowrap;
+}
+
+div.header
+{
+        background-image:url('nav_h.png');
+        background-repeat:repeat-x;
+	background-color: #F9FAFC;
+	margin:  0px;
+	border-bottom: 1px solid #C4CFE5;
+}
+
+div.headertitle
+{
+	padding: 5px 5px 5px 7px;
+}
+
+dl
+{
+        padding: 0 0 0 10px;
+}
+
+dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug
+{
+        border-left:4px solid;
+        padding: 0 0 0 6px;
+}
+
+dl.note
+{
+        border-color: #D0C000;
+}
+
+dl.warning, dl.attention
+{
+        border-color: #FF0000;
+}
+
+dl.pre, dl.post, dl.invariant
+{
+        border-color: #00D000;
+}
+
+dl.deprecated
+{
+        border-color: #505050;
+}
+
+dl.todo
+{
+        border-color: #00C0E0;
+}
+
+dl.test
+{
+        border-color: #3030E0;
+}
+
+dl.bug
+{
+        border-color: #C08050;
+}
+
+#projectlogo
+{
+	text-align: center;
+	vertical-align: bottom;
+	border-collapse: separate;
+}
+ 
+#projectlogo img
+{ 
+	border: 0px none;
+}
+ 
+#projectname
+{
+	font: 300% Tahoma, Arial,sans-serif;
+	margin: 0px;
+	padding: 2px 0px;
+}
+    
+#projectbrief
+{
+	font: 120% Tahoma, Arial,sans-serif;
+	margin: 0px;
+	padding: 0px;
+}
+
+#projectnumber
+{
+	font: 50% Tahoma, Arial,sans-serif;
+	margin: 0px;
+	padding: 0px;
+}
+
+#titlearea
+{
+	padding: 0px;
+	margin: 0px;
+	width: 100%;
+	border-bottom: 1px solid #5373B4;
+}
+
+.image
+{
+        text-align: center;
+}
+
+.dotgraph
+{
+        text-align: center;
+}
+
+.mscgraph
+{
+        text-align: center;
+}
+
+.caption
+{
+	font-weight: bold;
+}
+
+div.zoom
+{
+	border: 1px solid #90A5CE;
+}
+
+dl.citelist {
+        margin-bottom:50px;
+}
+
+dl.citelist dt {
+        color:#334975;
+        float:left;
+        font-weight:bold;
+        margin-right:10px;
+        padding:5px;
+}
+
+dl.citelist dd {
+        margin:2px 0;
+        padding:5px 0;
+}
+
+@media print
+{
+  #top { display: none; }
+  #side-nav { display: none; }
+  #nav-path { display: none; }
+  body { overflow:visible; }
+  h1, h2, h3, h4, h5, h6 { page-break-after: avoid; }
+  .summary { display: none; }
+  .memitem { page-break-inside: avoid; }
+  #doc-content
+  {
+    margin-left:0 !important;
+    height:auto !important;
+    width:auto !important;
+    overflow:inherit;
+    display:inline;
+  }
+  pre.fragment
+  {
+    overflow: visible;
+    text-wrap: unrestricted;
+    white-space: -moz-pre-wrap; /* Moz */
+    white-space: -pre-wrap; /* Opera 4-6 */
+    white-space: -o-pre-wrap; /* Opera 7 */
+    white-space: pre-wrap; /* CSS3  */
+    word-wrap: break-word; /* IE 5.5+ */
+  }
+}
+
diff --git a/docs/html/reference/renderscript/globals.html b/docs/html/reference/renderscript/globals.html
new file mode 100644
index 0000000..f6fa413
--- /dev/null
+++ b/docs/html/reference/renderscript/globals.html
@@ -0,0 +1,720 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Members</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow3" class="tabs2">
+    <ul class="tablist">
+      <li class="current"><a href="globals.html"><span>All</span></a></li>
+      <li><a href="globals_func.html"><span>Functions</span></a></li>
+      <li><a href="globals_type.html"><span>Typedefs</span></a></li>
+      <li><a href="globals_enum.html"><span>Enumerations</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow4" class="tabs3">
+    <ul class="tablist">
+      <li><a href="#index_a"><span>a</span></a></li>
+      <li><a href="#index_c"><span>c</span></a></li>
+      <li><a href="#index_d"><span>d</span></a></li>
+      <li><a href="#index_e"><span>e</span></a></li>
+      <li><a href="#index_f"><span>f</span></a></li>
+      <li><a href="#index_h"><span>h</span></a></li>
+      <li><a href="#index_i"><span>i</span></a></li>
+      <li><a href="#index_l"><span>l</span></a></li>
+      <li><a href="#index_m"><span>m</span></a></li>
+      <li><a href="#index_n"><span>n</span></a></li>
+      <li><a href="#index_p"><span>p</span></a></li>
+      <li><a href="#index_r"><span>r</span></a></li>
+      <li><a href="#index_s"><span>s</span></a></li>
+      <li><a href="#index_t"><span>t</span></a></li>
+      <li><a href="#index_u"><span>u</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="contents">
+<div class="textblock"> </div>
+
+<h3><a class="anchor" id="index_a"></a>- a -</h3><ul>
+<li>acos()
+: <a class="el" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">rs_cl.rsh</a>
+</li>
+<li>acosh()
+: <a class="el" href="rs__cl_8rsh.html#a6575106413ec72448439ef67f1309424">rs_cl.rsh</a>
+</li>
+<li>acospi()
+: <a class="el" href="rs__cl_8rsh.html#a2c0c7c00815bd480fcda80d1144ac20d">rs_cl.rsh</a>
+</li>
+<li>asin()
+: <a class="el" href="rs__cl_8rsh.html#a78b9d0583bd0699e2eac30d2a136817a">rs_cl.rsh</a>
+</li>
+<li>asinh()
+: <a class="el" href="rs__cl_8rsh.html#a4e3fe465ed5541af53192c59c80af1a0">rs_cl.rsh</a>
+</li>
+<li>asinpi()
+: <a class="el" href="rs__cl_8rsh.html#a679b63e86358fc962cb343eb6263496b">rs_cl.rsh</a>
+</li>
+<li>atan()
+: <a class="el" href="rs__cl_8rsh.html#ab790c3a7df8fcbeab77f6c0e3b4dcada">rs_cl.rsh</a>
+</li>
+<li>atan2()
+: <a class="el" href="rs__cl_8rsh.html#aaf4b636b09041878e1542054c73d81e9">rs_cl.rsh</a>
+</li>
+<li>atan2pi()
+: <a class="el" href="rs__cl_8rsh.html#a9aed0a1613c86acf5e4c5ad3290a4745">rs_cl.rsh</a>
+</li>
+<li>atanh()
+: <a class="el" href="rs__cl_8rsh.html#a83bdf415cc561ff6237a124273d9fb0d">rs_cl.rsh</a>
+</li>
+<li>atanpi()
+: <a class="el" href="rs__cl_8rsh.html#a420d4aaea0e53d7172845a21a1e648ea">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_c"></a>- c -</h3><ul>
+<li>cbrt()
+: <a class="el" href="rs__cl_8rsh.html#ae9d1787b55c2587478a24d96573225df">rs_cl.rsh</a>
+</li>
+<li>ceil()
+: <a class="el" href="rs__cl_8rsh.html#aa8fc6daff743a1b635ccbf9af83fe4e4">rs_cl.rsh</a>
+</li>
+<li>char2
+: <a class="el" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">rs_types.rsh</a>
+</li>
+<li>char3
+: <a class="el" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">rs_types.rsh</a>
+</li>
+<li>char4
+: <a class="el" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">rs_types.rsh</a>
+</li>
+<li>clamp()
+: <a class="el" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">rs_cl.rsh</a>
+</li>
+<li>copysign()
+: <a class="el" href="rs__cl_8rsh.html#a29f2602d95aa7b3950e2b77b3e268f7e">rs_cl.rsh</a>
+</li>
+<li>cos()
+: <a class="el" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">rs_cl.rsh</a>
+</li>
+<li>cosh()
+: <a class="el" href="rs__cl_8rsh.html#ac8d88d83182afd591401eaed101d9670">rs_cl.rsh</a>
+</li>
+<li>cospi()
+: <a class="el" href="rs__cl_8rsh.html#a07b12188bd53c6b584274892f6abf425">rs_cl.rsh</a>
+</li>
+<li>cross()
+: <a class="el" href="rs__cl_8rsh.html#a0f7beb26bb4aa30535babd14492a7e90">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_d"></a>- d -</h3><ul>
+<li>degrees()
+: <a class="el" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">rs_cl.rsh</a>
+</li>
+<li>distance()
+: <a class="el" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">rs_cl.rsh</a>
+</li>
+<li>dot()
+: <a class="el" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">rs_cl.rsh</a>
+</li>
+<li>double2
+: <a class="el" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">rs_types.rsh</a>
+</li>
+<li>double3
+: <a class="el" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">rs_types.rsh</a>
+</li>
+<li>double4
+: <a class="el" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_e"></a>- e -</h3><ul>
+<li>erf()
+: <a class="el" href="rs__cl_8rsh.html#a139f102df651c25c26dd35d549173f57">rs_cl.rsh</a>
+</li>
+<li>erfc()
+: <a class="el" href="rs__cl_8rsh.html#a2e24dc8594e758b64c340153f67a533c">rs_cl.rsh</a>
+</li>
+<li>exp()
+: <a class="el" href="rs__cl_8rsh.html#a6d9aac64c2686961ca8f30e3c34fef36">rs_cl.rsh</a>
+</li>
+<li>exp10()
+: <a class="el" href="rs__cl_8rsh.html#a4b51589157c9ce600ea6156be51d8d18">rs_cl.rsh</a>
+</li>
+<li>exp2()
+: <a class="el" href="rs__cl_8rsh.html#a39bca19ee2b1aa95144e58eb4a1e4f88">rs_cl.rsh</a>
+</li>
+<li>expm1()
+: <a class="el" href="rs__cl_8rsh.html#a7996044b67be921a5e58e2fe76af66e2">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_f"></a>- f -</h3><ul>
+<li>fabs()
+: <a class="el" href="rs__cl_8rsh.html#ad6e897f1acae252ec0901e3b122992ea">rs_cl.rsh</a>
+</li>
+<li>fdim()
+: <a class="el" href="rs__cl_8rsh.html#ae7a7bac0f4e244594078f87b42c8716a">rs_cl.rsh</a>
+</li>
+<li>float2
+: <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">rs_types.rsh</a>
+</li>
+<li>float3
+: <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">rs_types.rsh</a>
+</li>
+<li>float4
+: <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">rs_types.rsh</a>
+</li>
+<li>floor()
+: <a class="el" href="rs__cl_8rsh.html#aae2da38a7246378dff8014ec407a30c3">rs_cl.rsh</a>
+</li>
+<li>fma()
+: <a class="el" href="rs__cl_8rsh.html#ac42909daec463fe449743e70baf8360d">rs_cl.rsh</a>
+</li>
+<li>fmax()
+: <a class="el" href="rs__cl_8rsh.html#a60f2072d8a746e7fe05cd46dea0fefcc">rs_cl.rsh</a>
+</li>
+<li>fmin()
+: <a class="el" href="rs__cl_8rsh.html#a1fd9d57c6c992866bf5161be2cf4c447">rs_cl.rsh</a>
+</li>
+<li>fmod()
+: <a class="el" href="rs__cl_8rsh.html#a31d5e179730ae44e1dbc74c1535f392e">rs_cl.rsh</a>
+</li>
+<li>fract()
+: <a class="el" href="rs__cl_8rsh.html#ac5277212e0df309a0a7c908424f7b14b">rs_cl.rsh</a>
+</li>
+<li>frexp()
+: <a class="el" href="rs__cl_8rsh.html#a778635fffed3cee8ab0800482ba53a30">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_h"></a>- h -</h3><ul>
+<li>hypot()
+: <a class="el" href="rs__cl_8rsh.html#a147f38d6e41f45de9b5e7c6f3dcac010">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_i"></a>- i -</h3><ul>
+<li>ilogb()
+: <a class="el" href="rs__cl_8rsh.html#aad9a8beba52acb77b1efeba432e6cc2c">rs_cl.rsh</a>
+</li>
+<li>int16_t
+: <a class="el" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">rs_types.rsh</a>
+</li>
+<li>int2
+: <a class="el" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">rs_types.rsh</a>
+</li>
+<li>int3
+: <a class="el" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">rs_types.rsh</a>
+</li>
+<li>int32_t
+: <a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">rs_types.rsh</a>
+</li>
+<li>int4
+: <a class="el" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">rs_types.rsh</a>
+</li>
+<li>int64_t
+: <a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">rs_types.rsh</a>
+</li>
+<li>int8_t
+: <a class="el" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_l"></a>- l -</h3><ul>
+<li>ldexp()
+: <a class="el" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">rs_cl.rsh</a>
+</li>
+<li>length()
+: <a class="el" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">rs_cl.rsh</a>
+</li>
+<li>lgamma()
+: <a class="el" href="rs__cl_8rsh.html#a735f4e14e33c50348ef41220f9210bcc">rs_cl.rsh</a>
+</li>
+<li>log()
+: <a class="el" href="rs__cl_8rsh.html#a3ff85f5f4b206ecf9ec9d128d7d18a08">rs_cl.rsh</a>
+</li>
+<li>log10()
+: <a class="el" href="rs__cl_8rsh.html#af5c1bdba2a13aa2e2b0722287f6a919f">rs_cl.rsh</a>
+</li>
+<li>log1p()
+: <a class="el" href="rs__cl_8rsh.html#ae10541ede49062ef7f977712c4878c1f">rs_cl.rsh</a>
+</li>
+<li>log2()
+: <a class="el" href="rs__cl_8rsh.html#a2fb571ae932f671ff3e9e97f2d3fabb7">rs_cl.rsh</a>
+</li>
+<li>logb()
+: <a class="el" href="rs__cl_8rsh.html#a28742d6ce2f20a61f16ecc08ed499871">rs_cl.rsh</a>
+</li>
+<li>long2
+: <a class="el" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">rs_types.rsh</a>
+</li>
+<li>long3
+: <a class="el" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">rs_types.rsh</a>
+</li>
+<li>long4
+: <a class="el" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_m"></a>- m -</h3><ul>
+<li>mad()
+: <a class="el" href="rs__cl_8rsh.html#a4f9086698f1eb466ba2dccf7e331cdc3">rs_cl.rsh</a>
+</li>
+<li>mix()
+: <a class="el" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">rs_cl.rsh</a>
+</li>
+<li>modf()
+: <a class="el" href="rs__cl_8rsh.html#a841633bcdcaeb6a514d9c6460f0adf2d">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_n"></a>- n -</h3><ul>
+<li>nextafter()
+: <a class="el" href="rs__cl_8rsh.html#adb11df05fb9985595af0a7bd882bdeac">rs_cl.rsh</a>
+</li>
+<li>normalize()
+: <a class="el" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_p"></a>- p -</h3><ul>
+<li>pow()
+: <a class="el" href="rs__cl_8rsh.html#a9243de1d67fcc847a89f95748d664b19">rs_cl.rsh</a>
+</li>
+<li>pown()
+: <a class="el" href="rs__cl_8rsh.html#afd46205452017b741abb2e17fc28557d">rs_cl.rsh</a>
+</li>
+<li>powr()
+: <a class="el" href="rs__cl_8rsh.html#a3ff65421721ec8e6ce8d875a563d005f">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_r"></a>- r -</h3><ul>
+<li>radians()
+: <a class="el" href="rs__cl_8rsh.html#aaef2526c4d190ba6f7301b4e810917a7">rs_cl.rsh</a>
+</li>
+<li>remainder()
+: <a class="el" href="rs__cl_8rsh.html#a5188ac0e3af95b0956c6abeafb74fda9">rs_cl.rsh</a>
+</li>
+<li>rint()
+: <a class="el" href="rs__cl_8rsh.html#adb0ffe344ae56ca7fc9083c1f2943e55">rs_cl.rsh</a>
+</li>
+<li>rootn()
+: <a class="el" href="rs__cl_8rsh.html#af169e7e1c575b7c24c1834569223077f">rs_cl.rsh</a>
+</li>
+<li>round()
+: <a class="el" href="rs__cl_8rsh.html#aff4846ab5b947550814d5414a2c3626f">rs_cl.rsh</a>
+</li>
+<li>rs_for_each_strategy
+: <a class="el" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_core.rsh</a>
+</li>
+<li>rs_quaternion
+: <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_types.rsh</a>
+</li>
+<li>rs_script_call_t
+: <a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_core.rsh</a>
+</li>
+<li>rs_time_t
+: <a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time.rsh</a>
+</li>
+<li>rsAllocationGetDimFaces()
+: <a class="el" href="rs__allocation_8rsh.html#ac85f7ed88f38b35482c6d63b56d470fe">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimLOD()
+: <a class="el" href="rs__allocation_8rsh.html#ac42a07c079d6b3c6bb21975170d4e11c">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimX()
+: <a class="el" href="rs__allocation_8rsh.html#a3ca7f505a97d5b7f477bc65b9e77dafb">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimY()
+: <a class="el" href="rs__allocation_8rsh.html#ac889b866b465580eb313e5d2a9fcac3d">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimZ()
+: <a class="el" href="rs__allocation_8rsh.html#acd6f1a2b2443e6ea39e6154577645d2c">rs_allocation.rsh</a>
+</li>
+<li>rsClamp()
+: <a class="el" href="rs__math_8rsh.html#ad36abebbb36ffc5312fb2ed8baf98d39">rs_math.rsh</a>
+</li>
+<li>rsClearObject()
+: <a class="el" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rs_object.rsh</a>
+</li>
+<li>rsDebug()
+: <a class="el" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rs_debug.rsh</a>
+</li>
+<li>rsExtractFrustumPlanes()
+: <a class="el" href="rs__math_8rsh.html#a191f9c687c56322c18b7d71491602122">rs_math.rsh</a>
+</li>
+<li>rsForEach()
+: <a class="el" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rs_core.rsh</a>
+</li>
+<li>rsFrac()
+: <a class="el" href="rs__math_8rsh.html#ac4f127e78da0849321c7f6db14f9e989">rs_math.rsh</a>
+</li>
+<li>rsgAllocationSyncAll()
+: <a class="el" href="rs__graphics_8rsh.html#a647228d8e15da6ad67a97701d920dcac">rs_graphics.rsh</a>
+</li>
+<li>rsgBindFont()
+: <a class="el" href="rs__graphics_8rsh.html#ae89effef281e92e2940055883ea366d4">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramFragment()
+: <a class="el" href="rs__graphics_8rsh.html#a9f8deb600729a83c39c5bcaba2152b9c">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramRaster()
+: <a class="el" href="rs__graphics_8rsh.html#a391eb5535544f6312c724b910da6ec35">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramStore()
+: <a class="el" href="rs__graphics_8rsh.html#a34dfa6eddd7454fc1865222c5a022315">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramVertex()
+: <a class="el" href="rs__graphics_8rsh.html#a894e26d0d05d3ef99be65ddf98dd901c">rs_graphics.rsh</a>
+</li>
+<li>rsgBindSampler()
+: <a class="el" href="rs__graphics_8rsh.html#a4ade6c5acbf6acaa1c29a1aecc6e87d3">rs_graphics.rsh</a>
+</li>
+<li>rsgBindTexture()
+: <a class="el" href="rs__graphics_8rsh.html#a1694eb5489bd3a444da921dbf16aeeb5">rs_graphics.rsh</a>
+</li>
+<li>rsgClearColor()
+: <a class="el" href="rs__graphics_8rsh.html#a147674fed92745fbb5c64a6300ca3c49">rs_graphics.rsh</a>
+</li>
+<li>rsgClearDepth()
+: <a class="el" href="rs__graphics_8rsh.html#a4bedb06e8facd587e3eacd746fe3e727">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawMesh()
+: <a class="el" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawQuad()
+: <a class="el" href="rs__graphics_8rsh.html#ad6953da0349e58547b08b8ce174ed3fc">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawQuadTexCoords()
+: <a class="el" href="rs__graphics_8rsh.html#afb98a59bb9f878f0a09459567c269e64">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawRect()
+: <a class="el" href="rs__graphics_8rsh.html#a80c51849bf12ec6c699c23c3fa3e6208">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawSpriteScreenspace()
+: <a class="el" href="rs__graphics_8rsh.html#a07d15127330fa1dff6c99b0d7d14e65e">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawText()
+: <a class="el" href="rs__graphics_8rsh.html#afaec82492762e62cad1ff53ada479b14">rs_graphics.rsh</a>
+</li>
+<li>rsGetAllocation()
+: <a class="el" href="rs__allocation_8rsh.html#aadad7654929c451be299df125061c9ba">rs_allocation.rsh</a>
+</li>
+<li>rsGetDt()
+: <a class="el" href="rs__time_8rsh.html#adea2682186fd903752431ad848bd8bf4">rs_time.rsh</a>
+</li>
+<li>rsGetElementAt()
+: <a class="el" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rs_allocation.rsh</a>
+</li>
+<li>rsgFontColor()
+: <a class="el" href="rs__graphics_8rsh.html#abda8c344092ed6310c7a8f353a6df876">rs_graphics.rsh</a>
+</li>
+<li>rsgGetHeight()
+: <a class="el" href="rs__graphics_8rsh.html#a7e6565cd5d5e44f442a8bf8ba68f4681">rs_graphics.rsh</a>
+</li>
+<li>rsgGetWidth()
+: <a class="el" href="rs__graphics_8rsh.html#a67f4ed1ca4bba27d5c952ada89cd0717">rs_graphics.rsh</a>
+</li>
+<li>rsgMeasureText()
+: <a class="el" href="rs__graphics_8rsh.html#a5c599f4ea989f3d0616cbf8e983688c4">rs_graphics.rsh</a>
+</li>
+<li>rsgMeshComputeBoundingBox()
+: <a class="el" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramFragmentConstantColor()
+: <a class="el" href="rs__graphics_8rsh.html#a35ac8c3759e25047e6a458c15520c887">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexGetProjectionMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a2b767d209b36ffcd2e0fc0cf6f4c5706">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadModelMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a976b8594cccb4b94d7ce520b44d884e3">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadProjectionMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a83a87d8efa3f26ed3f8fb25e49f29059">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadTextureMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a377b7b394c4bf0881532b1241d4be168">rs_graphics.rsh</a>
+</li>
+<li>rsIsObject()
+: <a class="el" href="rs__object_8rsh.html#ac1d6da920f12974b3633d25ed078da2d">rs_object.rsh</a>
+</li>
+<li>rsIsSphereInFrustum()
+: <a class="el" href="rs__math_8rsh.html#a7bbeaf44838e08e68d5cf3e3d7b0818c">rs_math.rsh</a>
+</li>
+<li>rsLocaltime()
+: <a class="el" href="rs__time_8rsh.html#a08a8fcadae964f7416aef487da624110">rs_time.rsh</a>
+</li>
+<li>rsMatrixGet()
+: <a class="el" href="rs__matrix_8rsh.html#af1fb87eb02f166bb85ef10a92333bb49">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixInverse()
+: <a class="el" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixInverseTranspose()
+: <a class="el" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoad()
+: <a class="el" href="rs__matrix_8rsh.html#a06176acb38405937cb94c835a712a3b3">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadFrustum()
+: <a class="el" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadIdentity()
+: <a class="el" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadMultiply()
+: <a class="el" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadOrtho()
+: <a class="el" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadPerspective()
+: <a class="el" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadRotate()
+: <a class="el" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadScale()
+: <a class="el" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadTranslate()
+: <a class="el" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixMultiply()
+: <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixRotate()
+: <a class="el" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixScale()
+: <a class="el" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixSet()
+: <a class="el" href="rs__matrix_8rsh.html#a68e320f7fa2cc5a5b4759e3ab679ee10">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixTranslate()
+: <a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixTranspose()
+: <a class="el" href="rs__matrix_8rsh.html#ac52acb31a705f6c68af8bddea0e79969">rs_matrix.rsh</a>
+</li>
+<li>rsPackColorTo8888()
+: <a class="el" href="rs__math_8rsh.html#a22e0be7e18b317a7453ebad4300934f6">rs_math.rsh</a>
+</li>
+<li>rsqrt()
+: <a class="el" href="rs__cl_8rsh.html#a5db00fde9e6bff693a38f3a37e7a1f70">rs_cl.rsh</a>
+</li>
+<li>rsQuaternionAdd()
+: <a class="el" href="rs__quaternion_8rsh.html#a5e6e493b9917336b0d9118fdd4e91444">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionConjugate()
+: <a class="el" href="rs__quaternion_8rsh.html#acd670264e49743d35f38028b8e2a8800">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionDot()
+: <a class="el" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionGetMatrixUnit()
+: <a class="el" href="rs__quaternion_8rsh.html#a7726c524868c49892976fec53ea0693b">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionLoadRotate()
+: <a class="el" href="rs__quaternion_8rsh.html#adf4423c521e34f3cf29d5dd5b5a93de0">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionLoadRotateUnit()
+: <a class="el" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionMultiply()
+: <a class="el" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionNormalize()
+: <a class="el" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionSet()
+: <a class="el" href="rs__quaternion_8rsh.html#a249782133e54f13a8096d1fbe295714d">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionSlerp()
+: <a class="el" href="rs__quaternion_8rsh.html#a7da94a30e287cbb8148771a5cd768dbd">rs_quaternion.rsh</a>
+</li>
+<li>rsRand()
+: <a class="el" href="rs__math_8rsh.html#a03e898d810ac44158e7461b2b2b1c356">rs_math.rsh</a>
+</li>
+<li>rsSendToClient()
+: <a class="el" href="rs__core_8rsh.html#a508003cadad2d37d41e2de7e9226f859">rs_core.rsh</a>
+</li>
+<li>rsSendToClientBlocking()
+: <a class="el" href="rs__core_8rsh.html#afc93b00be08f58512a6ab6a87feb9515">rs_core.rsh</a>
+</li>
+<li>rsSetObject()
+: <a class="el" href="rs__object_8rsh.html#a5132f90b4aaf8d2e35e6ad021fb08175">rs_object.rsh</a>
+</li>
+<li>rsTime()
+: <a class="el" href="rs__time_8rsh.html#a555f9324acb8c3d0c6f09a1d05478ce2">rs_time.rsh</a>
+</li>
+<li>rsUnpackColor8888()
+: <a class="el" href="rs__math_8rsh.html#a26525a4f5093bd0f13191efe06127f4b">rs_math.rsh</a>
+</li>
+<li>rsUptimeMillis()
+: <a class="el" href="rs__time_8rsh.html#a3c406e51a769718dd1c760518b9cad44">rs_time.rsh</a>
+</li>
+<li>rsUptimeNanos()
+: <a class="el" href="rs__time_8rsh.html#a24e2cc12acf1e7fdd857d1a48981395d">rs_time.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_s"></a>- s -</h3><ul>
+<li>short2
+: <a class="el" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">rs_types.rsh</a>
+</li>
+<li>short3
+: <a class="el" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">rs_types.rsh</a>
+</li>
+<li>short4
+: <a class="el" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">rs_types.rsh</a>
+</li>
+<li>sign()
+: <a class="el" href="rs__cl_8rsh.html#a3e6d477a06dec7070f073eec9d8f420c">rs_cl.rsh</a>
+</li>
+<li>sin()
+: <a class="el" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">rs_cl.rsh</a>
+</li>
+<li>sincos()
+: <a class="el" href="rs__cl_8rsh.html#a240f7c7c20b432a30dc660b5dd4cd320">rs_cl.rsh</a>
+</li>
+<li>sinh()
+: <a class="el" href="rs__cl_8rsh.html#ae686e0cc567f7ee2b0a84706aa486e4a">rs_cl.rsh</a>
+</li>
+<li>sinpi()
+: <a class="el" href="rs__cl_8rsh.html#a4fe4fef049786e888526d6f37b912b0a">rs_cl.rsh</a>
+</li>
+<li>size_t
+: <a class="el" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">rs_types.rsh</a>
+</li>
+<li>sqrt()
+: <a class="el" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">rs_cl.rsh</a>
+</li>
+<li>ssize_t
+: <a class="el" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">rs_types.rsh</a>
+</li>
+<li>step()
+: <a class="el" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_t"></a>- t -</h3><ul>
+<li>tan()
+: <a class="el" href="rs__cl_8rsh.html#af12e245af8ff9bb72b5000e7c26cd8fe">rs_cl.rsh</a>
+</li>
+<li>tanh()
+: <a class="el" href="rs__cl_8rsh.html#abc36e89ddb87ea78451d1c5921ddbd8d">rs_cl.rsh</a>
+</li>
+<li>tanpi()
+: <a class="el" href="rs__cl_8rsh.html#ad8bfb083dd3979a305e594a0d6e581c4">rs_cl.rsh</a>
+</li>
+<li>tgamma()
+: <a class="el" href="rs__cl_8rsh.html#ab9f4cbfd2470420ee302f28cf3de6dd0">rs_cl.rsh</a>
+</li>
+<li>trunc()
+: <a class="el" href="rs__cl_8rsh.html#ad1a7c65693231219db1babeae1c41f15">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_u"></a>- u -</h3><ul>
+<li>uchar
+: <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">rs_types.rsh</a>
+</li>
+<li>uchar2
+: <a class="el" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">rs_types.rsh</a>
+</li>
+<li>uchar3
+: <a class="el" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">rs_types.rsh</a>
+</li>
+<li>uchar4
+: <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">rs_types.rsh</a>
+</li>
+<li>uint
+: <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">rs_types.rsh</a>
+</li>
+<li>uint16_t
+: <a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">rs_types.rsh</a>
+</li>
+<li>uint2
+: <a class="el" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">rs_types.rsh</a>
+</li>
+<li>uint3
+: <a class="el" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">rs_types.rsh</a>
+</li>
+<li>uint32_t
+: <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">rs_types.rsh</a>
+</li>
+<li>uint4
+: <a class="el" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">rs_types.rsh</a>
+</li>
+<li>uint64_t
+: <a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">rs_types.rsh</a>
+</li>
+<li>uint8_t
+: <a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">rs_types.rsh</a>
+</li>
+<li>ulong
+: <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">rs_types.rsh</a>
+</li>
+<li>ulong2
+: <a class="el" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">rs_types.rsh</a>
+</li>
+<li>ulong3
+: <a class="el" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">rs_types.rsh</a>
+</li>
+<li>ulong4
+: <a class="el" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">rs_types.rsh</a>
+</li>
+<li>ushort
+: <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">rs_types.rsh</a>
+</li>
+<li>ushort2
+: <a class="el" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">rs_types.rsh</a>
+</li>
+<li>ushort3
+: <a class="el" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">rs_types.rsh</a>
+</li>
+<li>ushort4
+: <a class="el" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">rs_types.rsh</a>
+</li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/globals_enum.html b/docs/html/reference/renderscript/globals_enum.html
new file mode 100644
index 0000000..7301432
--- /dev/null
+++ b/docs/html/reference/renderscript/globals_enum.html
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Members</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow3" class="tabs2">
+    <ul class="tablist">
+      <li><a href="globals.html"><span>All</span></a></li>
+      <li><a href="globals_func.html"><span>Functions</span></a></li>
+      <li><a href="globals_type.html"><span>Typedefs</span></a></li>
+      <li class="current"><a href="globals_enum.html"><span>Enumerations</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="contents">
+&#160;<ul>
+<li>rs_for_each_strategy
+: <a class="el" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_core.rsh</a>
+</li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/globals_func.html b/docs/html/reference/renderscript/globals_func.html
new file mode 100644
index 0000000..5886454
--- /dev/null
+++ b/docs/html/reference/renderscript/globals_func.html
@@ -0,0 +1,571 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Members</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow3" class="tabs2">
+    <ul class="tablist">
+      <li><a href="globals.html"><span>All</span></a></li>
+      <li class="current"><a href="globals_func.html"><span>Functions</span></a></li>
+      <li><a href="globals_type.html"><span>Typedefs</span></a></li>
+      <li><a href="globals_enum.html"><span>Enumerations</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow4" class="tabs3">
+    <ul class="tablist">
+      <li><a href="#index_a"><span>a</span></a></li>
+      <li><a href="#index_c"><span>c</span></a></li>
+      <li><a href="#index_d"><span>d</span></a></li>
+      <li><a href="#index_e"><span>e</span></a></li>
+      <li><a href="#index_f"><span>f</span></a></li>
+      <li><a href="#index_h"><span>h</span></a></li>
+      <li><a href="#index_i"><span>i</span></a></li>
+      <li><a href="#index_l"><span>l</span></a></li>
+      <li><a href="#index_m"><span>m</span></a></li>
+      <li><a href="#index_n"><span>n</span></a></li>
+      <li><a href="#index_p"><span>p</span></a></li>
+      <li><a href="#index_r"><span>r</span></a></li>
+      <li><a href="#index_s"><span>s</span></a></li>
+      <li><a href="#index_t"><span>t</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="contents">
+&#160;
+
+<h3><a class="anchor" id="index_a"></a>- a -</h3><ul>
+<li>acos()
+: <a class="el" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">rs_cl.rsh</a>
+</li>
+<li>acosh()
+: <a class="el" href="rs__cl_8rsh.html#a6575106413ec72448439ef67f1309424">rs_cl.rsh</a>
+</li>
+<li>acospi()
+: <a class="el" href="rs__cl_8rsh.html#a2c0c7c00815bd480fcda80d1144ac20d">rs_cl.rsh</a>
+</li>
+<li>asin()
+: <a class="el" href="rs__cl_8rsh.html#a78b9d0583bd0699e2eac30d2a136817a">rs_cl.rsh</a>
+</li>
+<li>asinh()
+: <a class="el" href="rs__cl_8rsh.html#a4e3fe465ed5541af53192c59c80af1a0">rs_cl.rsh</a>
+</li>
+<li>asinpi()
+: <a class="el" href="rs__cl_8rsh.html#a679b63e86358fc962cb343eb6263496b">rs_cl.rsh</a>
+</li>
+<li>atan()
+: <a class="el" href="rs__cl_8rsh.html#ab790c3a7df8fcbeab77f6c0e3b4dcada">rs_cl.rsh</a>
+</li>
+<li>atan2()
+: <a class="el" href="rs__cl_8rsh.html#aaf4b636b09041878e1542054c73d81e9">rs_cl.rsh</a>
+</li>
+<li>atan2pi()
+: <a class="el" href="rs__cl_8rsh.html#a9aed0a1613c86acf5e4c5ad3290a4745">rs_cl.rsh</a>
+</li>
+<li>atanh()
+: <a class="el" href="rs__cl_8rsh.html#a83bdf415cc561ff6237a124273d9fb0d">rs_cl.rsh</a>
+</li>
+<li>atanpi()
+: <a class="el" href="rs__cl_8rsh.html#a420d4aaea0e53d7172845a21a1e648ea">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_c"></a>- c -</h3><ul>
+<li>cbrt()
+: <a class="el" href="rs__cl_8rsh.html#ae9d1787b55c2587478a24d96573225df">rs_cl.rsh</a>
+</li>
+<li>ceil()
+: <a class="el" href="rs__cl_8rsh.html#aa8fc6daff743a1b635ccbf9af83fe4e4">rs_cl.rsh</a>
+</li>
+<li>clamp()
+: <a class="el" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">rs_cl.rsh</a>
+</li>
+<li>copysign()
+: <a class="el" href="rs__cl_8rsh.html#a29f2602d95aa7b3950e2b77b3e268f7e">rs_cl.rsh</a>
+</li>
+<li>cos()
+: <a class="el" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">rs_cl.rsh</a>
+</li>
+<li>cosh()
+: <a class="el" href="rs__cl_8rsh.html#ac8d88d83182afd591401eaed101d9670">rs_cl.rsh</a>
+</li>
+<li>cospi()
+: <a class="el" href="rs__cl_8rsh.html#a07b12188bd53c6b584274892f6abf425">rs_cl.rsh</a>
+</li>
+<li>cross()
+: <a class="el" href="rs__cl_8rsh.html#a0f7beb26bb4aa30535babd14492a7e90">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_d"></a>- d -</h3><ul>
+<li>degrees()
+: <a class="el" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">rs_cl.rsh</a>
+</li>
+<li>distance()
+: <a class="el" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">rs_cl.rsh</a>
+</li>
+<li>dot()
+: <a class="el" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_e"></a>- e -</h3><ul>
+<li>erf()
+: <a class="el" href="rs__cl_8rsh.html#a139f102df651c25c26dd35d549173f57">rs_cl.rsh</a>
+</li>
+<li>erfc()
+: <a class="el" href="rs__cl_8rsh.html#a2e24dc8594e758b64c340153f67a533c">rs_cl.rsh</a>
+</li>
+<li>exp()
+: <a class="el" href="rs__cl_8rsh.html#a6d9aac64c2686961ca8f30e3c34fef36">rs_cl.rsh</a>
+</li>
+<li>exp10()
+: <a class="el" href="rs__cl_8rsh.html#a4b51589157c9ce600ea6156be51d8d18">rs_cl.rsh</a>
+</li>
+<li>exp2()
+: <a class="el" href="rs__cl_8rsh.html#a39bca19ee2b1aa95144e58eb4a1e4f88">rs_cl.rsh</a>
+</li>
+<li>expm1()
+: <a class="el" href="rs__cl_8rsh.html#a7996044b67be921a5e58e2fe76af66e2">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_f"></a>- f -</h3><ul>
+<li>fabs()
+: <a class="el" href="rs__cl_8rsh.html#ad6e897f1acae252ec0901e3b122992ea">rs_cl.rsh</a>
+</li>
+<li>fdim()
+: <a class="el" href="rs__cl_8rsh.html#ae7a7bac0f4e244594078f87b42c8716a">rs_cl.rsh</a>
+</li>
+<li>floor()
+: <a class="el" href="rs__cl_8rsh.html#aae2da38a7246378dff8014ec407a30c3">rs_cl.rsh</a>
+</li>
+<li>fma()
+: <a class="el" href="rs__cl_8rsh.html#ac42909daec463fe449743e70baf8360d">rs_cl.rsh</a>
+</li>
+<li>fmax()
+: <a class="el" href="rs__cl_8rsh.html#a60f2072d8a746e7fe05cd46dea0fefcc">rs_cl.rsh</a>
+</li>
+<li>fmin()
+: <a class="el" href="rs__cl_8rsh.html#a1fd9d57c6c992866bf5161be2cf4c447">rs_cl.rsh</a>
+</li>
+<li>fmod()
+: <a class="el" href="rs__cl_8rsh.html#a31d5e179730ae44e1dbc74c1535f392e">rs_cl.rsh</a>
+</li>
+<li>fract()
+: <a class="el" href="rs__cl_8rsh.html#ac5277212e0df309a0a7c908424f7b14b">rs_cl.rsh</a>
+</li>
+<li>frexp()
+: <a class="el" href="rs__cl_8rsh.html#a778635fffed3cee8ab0800482ba53a30">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_h"></a>- h -</h3><ul>
+<li>hypot()
+: <a class="el" href="rs__cl_8rsh.html#a147f38d6e41f45de9b5e7c6f3dcac010">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_i"></a>- i -</h3><ul>
+<li>ilogb()
+: <a class="el" href="rs__cl_8rsh.html#aad9a8beba52acb77b1efeba432e6cc2c">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_l"></a>- l -</h3><ul>
+<li>ldexp()
+: <a class="el" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">rs_cl.rsh</a>
+</li>
+<li>length()
+: <a class="el" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">rs_cl.rsh</a>
+</li>
+<li>lgamma()
+: <a class="el" href="rs__cl_8rsh.html#a735f4e14e33c50348ef41220f9210bcc">rs_cl.rsh</a>
+</li>
+<li>log()
+: <a class="el" href="rs__cl_8rsh.html#a3ff85f5f4b206ecf9ec9d128d7d18a08">rs_cl.rsh</a>
+</li>
+<li>log10()
+: <a class="el" href="rs__cl_8rsh.html#af5c1bdba2a13aa2e2b0722287f6a919f">rs_cl.rsh</a>
+</li>
+<li>log1p()
+: <a class="el" href="rs__cl_8rsh.html#ae10541ede49062ef7f977712c4878c1f">rs_cl.rsh</a>
+</li>
+<li>log2()
+: <a class="el" href="rs__cl_8rsh.html#a2fb571ae932f671ff3e9e97f2d3fabb7">rs_cl.rsh</a>
+</li>
+<li>logb()
+: <a class="el" href="rs__cl_8rsh.html#a28742d6ce2f20a61f16ecc08ed499871">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_m"></a>- m -</h3><ul>
+<li>mad()
+: <a class="el" href="rs__cl_8rsh.html#a4f9086698f1eb466ba2dccf7e331cdc3">rs_cl.rsh</a>
+</li>
+<li>mix()
+: <a class="el" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">rs_cl.rsh</a>
+</li>
+<li>modf()
+: <a class="el" href="rs__cl_8rsh.html#a841633bcdcaeb6a514d9c6460f0adf2d">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_n"></a>- n -</h3><ul>
+<li>nextafter()
+: <a class="el" href="rs__cl_8rsh.html#adb11df05fb9985595af0a7bd882bdeac">rs_cl.rsh</a>
+</li>
+<li>normalize()
+: <a class="el" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_p"></a>- p -</h3><ul>
+<li>pow()
+: <a class="el" href="rs__cl_8rsh.html#a9243de1d67fcc847a89f95748d664b19">rs_cl.rsh</a>
+</li>
+<li>pown()
+: <a class="el" href="rs__cl_8rsh.html#afd46205452017b741abb2e17fc28557d">rs_cl.rsh</a>
+</li>
+<li>powr()
+: <a class="el" href="rs__cl_8rsh.html#a3ff65421721ec8e6ce8d875a563d005f">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_r"></a>- r -</h3><ul>
+<li>radians()
+: <a class="el" href="rs__cl_8rsh.html#aaef2526c4d190ba6f7301b4e810917a7">rs_cl.rsh</a>
+</li>
+<li>remainder()
+: <a class="el" href="rs__cl_8rsh.html#a5188ac0e3af95b0956c6abeafb74fda9">rs_cl.rsh</a>
+</li>
+<li>rint()
+: <a class="el" href="rs__cl_8rsh.html#adb0ffe344ae56ca7fc9083c1f2943e55">rs_cl.rsh</a>
+</li>
+<li>rootn()
+: <a class="el" href="rs__cl_8rsh.html#af169e7e1c575b7c24c1834569223077f">rs_cl.rsh</a>
+</li>
+<li>round()
+: <a class="el" href="rs__cl_8rsh.html#aff4846ab5b947550814d5414a2c3626f">rs_cl.rsh</a>
+</li>
+<li>rsAllocationGetDimFaces()
+: <a class="el" href="rs__allocation_8rsh.html#ac85f7ed88f38b35482c6d63b56d470fe">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimLOD()
+: <a class="el" href="rs__allocation_8rsh.html#ac42a07c079d6b3c6bb21975170d4e11c">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimX()
+: <a class="el" href="rs__allocation_8rsh.html#a3ca7f505a97d5b7f477bc65b9e77dafb">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimY()
+: <a class="el" href="rs__allocation_8rsh.html#ac889b866b465580eb313e5d2a9fcac3d">rs_allocation.rsh</a>
+</li>
+<li>rsAllocationGetDimZ()
+: <a class="el" href="rs__allocation_8rsh.html#acd6f1a2b2443e6ea39e6154577645d2c">rs_allocation.rsh</a>
+</li>
+<li>rsClamp()
+: <a class="el" href="rs__math_8rsh.html#ae31137028793c4aaf4df839535135837">rs_math.rsh</a>
+</li>
+<li>rsClearObject()
+: <a class="el" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rs_object.rsh</a>
+</li>
+<li>rsDebug()
+: <a class="el" href="rs__debug_8rsh.html#a0a59285be7204bde7b199c77578b6a42">rs_debug.rsh</a>
+</li>
+<li>rsExtractFrustumPlanes()
+: <a class="el" href="rs__math_8rsh.html#a191f9c687c56322c18b7d71491602122">rs_math.rsh</a>
+</li>
+<li>rsForEach()
+: <a class="el" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rs_core.rsh</a>
+</li>
+<li>rsFrac()
+: <a class="el" href="rs__math_8rsh.html#ac4f127e78da0849321c7f6db14f9e989">rs_math.rsh</a>
+</li>
+<li>rsgAllocationSyncAll()
+: <a class="el" href="rs__graphics_8rsh.html#a647228d8e15da6ad67a97701d920dcac">rs_graphics.rsh</a>
+</li>
+<li>rsgBindFont()
+: <a class="el" href="rs__graphics_8rsh.html#ae89effef281e92e2940055883ea366d4">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramFragment()
+: <a class="el" href="rs__graphics_8rsh.html#a9f8deb600729a83c39c5bcaba2152b9c">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramRaster()
+: <a class="el" href="rs__graphics_8rsh.html#a391eb5535544f6312c724b910da6ec35">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramStore()
+: <a class="el" href="rs__graphics_8rsh.html#a34dfa6eddd7454fc1865222c5a022315">rs_graphics.rsh</a>
+</li>
+<li>rsgBindProgramVertex()
+: <a class="el" href="rs__graphics_8rsh.html#a894e26d0d05d3ef99be65ddf98dd901c">rs_graphics.rsh</a>
+</li>
+<li>rsgBindSampler()
+: <a class="el" href="rs__graphics_8rsh.html#a4ade6c5acbf6acaa1c29a1aecc6e87d3">rs_graphics.rsh</a>
+</li>
+<li>rsgBindTexture()
+: <a class="el" href="rs__graphics_8rsh.html#a1694eb5489bd3a444da921dbf16aeeb5">rs_graphics.rsh</a>
+</li>
+<li>rsgClearColor()
+: <a class="el" href="rs__graphics_8rsh.html#a147674fed92745fbb5c64a6300ca3c49">rs_graphics.rsh</a>
+</li>
+<li>rsgClearDepth()
+: <a class="el" href="rs__graphics_8rsh.html#a4bedb06e8facd587e3eacd746fe3e727">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawMesh()
+: <a class="el" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawQuad()
+: <a class="el" href="rs__graphics_8rsh.html#ad6953da0349e58547b08b8ce174ed3fc">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawQuadTexCoords()
+: <a class="el" href="rs__graphics_8rsh.html#afb98a59bb9f878f0a09459567c269e64">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawRect()
+: <a class="el" href="rs__graphics_8rsh.html#a80c51849bf12ec6c699c23c3fa3e6208">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawSpriteScreenspace()
+: <a class="el" href="rs__graphics_8rsh.html#a07d15127330fa1dff6c99b0d7d14e65e">rs_graphics.rsh</a>
+</li>
+<li>rsgDrawText()
+: <a class="el" href="rs__graphics_8rsh.html#afaec82492762e62cad1ff53ada479b14">rs_graphics.rsh</a>
+</li>
+<li>rsGetAllocation()
+: <a class="el" href="rs__allocation_8rsh.html#aadad7654929c451be299df125061c9ba">rs_allocation.rsh</a>
+</li>
+<li>rsGetDt()
+: <a class="el" href="rs__time_8rsh.html#adea2682186fd903752431ad848bd8bf4">rs_time.rsh</a>
+</li>
+<li>rsGetElementAt()
+: <a class="el" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rs_allocation.rsh</a>
+</li>
+<li>rsgFontColor()
+: <a class="el" href="rs__graphics_8rsh.html#abda8c344092ed6310c7a8f353a6df876">rs_graphics.rsh</a>
+</li>
+<li>rsgGetHeight()
+: <a class="el" href="rs__graphics_8rsh.html#a7e6565cd5d5e44f442a8bf8ba68f4681">rs_graphics.rsh</a>
+</li>
+<li>rsgGetWidth()
+: <a class="el" href="rs__graphics_8rsh.html#a67f4ed1ca4bba27d5c952ada89cd0717">rs_graphics.rsh</a>
+</li>
+<li>rsgMeasureText()
+: <a class="el" href="rs__graphics_8rsh.html#a5c599f4ea989f3d0616cbf8e983688c4">rs_graphics.rsh</a>
+</li>
+<li>rsgMeshComputeBoundingBox()
+: <a class="el" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramFragmentConstantColor()
+: <a class="el" href="rs__graphics_8rsh.html#a35ac8c3759e25047e6a458c15520c887">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexGetProjectionMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a2b767d209b36ffcd2e0fc0cf6f4c5706">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadModelMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a976b8594cccb4b94d7ce520b44d884e3">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadProjectionMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a83a87d8efa3f26ed3f8fb25e49f29059">rs_graphics.rsh</a>
+</li>
+<li>rsgProgramVertexLoadTextureMatrix()
+: <a class="el" href="rs__graphics_8rsh.html#a377b7b394c4bf0881532b1241d4be168">rs_graphics.rsh</a>
+</li>
+<li>rsIsObject()
+: <a class="el" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rs_object.rsh</a>
+</li>
+<li>rsIsSphereInFrustum()
+: <a class="el" href="rs__math_8rsh.html#a7bbeaf44838e08e68d5cf3e3d7b0818c">rs_math.rsh</a>
+</li>
+<li>rsLocaltime()
+: <a class="el" href="rs__time_8rsh.html#a08a8fcadae964f7416aef487da624110">rs_time.rsh</a>
+</li>
+<li>rsMatrixGet()
+: <a class="el" href="rs__matrix_8rsh.html#a90b0548da8dbe1f643bcbac8466e5b72">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixInverse()
+: <a class="el" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixInverseTranspose()
+: <a class="el" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoad()
+: <a class="el" href="rs__matrix_8rsh.html#a06176acb38405937cb94c835a712a3b3">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadFrustum()
+: <a class="el" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadIdentity()
+: <a class="el" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadMultiply()
+: <a class="el" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadOrtho()
+: <a class="el" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadPerspective()
+: <a class="el" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadRotate()
+: <a class="el" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadScale()
+: <a class="el" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixLoadTranslate()
+: <a class="el" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixMultiply()
+: <a class="el" href="rs__matrix_8rsh.html#a716bc2d29b80eb25388aba3ba8845aef">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixRotate()
+: <a class="el" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixScale()
+: <a class="el" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixSet()
+: <a class="el" href="rs__matrix_8rsh.html#ada106cb8f08e4b23930d7ba1a0ce5609">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixTranslate()
+: <a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rs_matrix.rsh</a>
+</li>
+<li>rsMatrixTranspose()
+: <a class="el" href="rs__matrix_8rsh.html#a49164dd4d4e85b212196028b1fd89dc1">rs_matrix.rsh</a>
+</li>
+<li>rsPackColorTo8888()
+: <a class="el" href="rs__math_8rsh.html#a22e0be7e18b317a7453ebad4300934f6">rs_math.rsh</a>
+</li>
+<li>rsqrt()
+: <a class="el" href="rs__cl_8rsh.html#a5db00fde9e6bff693a38f3a37e7a1f70">rs_cl.rsh</a>
+</li>
+<li>rsQuaternionAdd()
+: <a class="el" href="rs__quaternion_8rsh.html#a5e6e493b9917336b0d9118fdd4e91444">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionConjugate()
+: <a class="el" href="rs__quaternion_8rsh.html#acd670264e49743d35f38028b8e2a8800">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionDot()
+: <a class="el" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionGetMatrixUnit()
+: <a class="el" href="rs__quaternion_8rsh.html#a7726c524868c49892976fec53ea0693b">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionLoadRotate()
+: <a class="el" href="rs__quaternion_8rsh.html#adf4423c521e34f3cf29d5dd5b5a93de0">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionLoadRotateUnit()
+: <a class="el" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionMultiply()
+: <a class="el" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionNormalize()
+: <a class="el" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionSet()
+: <a class="el" href="rs__quaternion_8rsh.html#a249782133e54f13a8096d1fbe295714d">rs_quaternion.rsh</a>
+</li>
+<li>rsQuaternionSlerp()
+: <a class="el" href="rs__quaternion_8rsh.html#a7da94a30e287cbb8148771a5cd768dbd">rs_quaternion.rsh</a>
+</li>
+<li>rsRand()
+: <a class="el" href="rs__math_8rsh.html#a84b2e7468314873b3aa02969e310d9e4">rs_math.rsh</a>
+</li>
+<li>rsSendToClient()
+: <a class="el" href="rs__core_8rsh.html#a508003cadad2d37d41e2de7e9226f859">rs_core.rsh</a>
+</li>
+<li>rsSendToClientBlocking()
+: <a class="el" href="rs__core_8rsh.html#a6e4ff6388e8c6978ed17447214f2a2e2">rs_core.rsh</a>
+</li>
+<li>rsSetObject()
+: <a class="el" href="rs__object_8rsh.html#a8135bceeb7b3ec8bf9a49d04e39bd565">rs_object.rsh</a>
+</li>
+<li>rsTime()
+: <a class="el" href="rs__time_8rsh.html#a555f9324acb8c3d0c6f09a1d05478ce2">rs_time.rsh</a>
+</li>
+<li>rsUnpackColor8888()
+: <a class="el" href="rs__math_8rsh.html#a26525a4f5093bd0f13191efe06127f4b">rs_math.rsh</a>
+</li>
+<li>rsUptimeMillis()
+: <a class="el" href="rs__time_8rsh.html#a3c406e51a769718dd1c760518b9cad44">rs_time.rsh</a>
+</li>
+<li>rsUptimeNanos()
+: <a class="el" href="rs__time_8rsh.html#a24e2cc12acf1e7fdd857d1a48981395d">rs_time.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_s"></a>- s -</h3><ul>
+<li>sign()
+: <a class="el" href="rs__cl_8rsh.html#a3e6d477a06dec7070f073eec9d8f420c">rs_cl.rsh</a>
+</li>
+<li>sin()
+: <a class="el" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">rs_cl.rsh</a>
+</li>
+<li>sincos()
+: <a class="el" href="rs__cl_8rsh.html#a240f7c7c20b432a30dc660b5dd4cd320">rs_cl.rsh</a>
+</li>
+<li>sinh()
+: <a class="el" href="rs__cl_8rsh.html#ae686e0cc567f7ee2b0a84706aa486e4a">rs_cl.rsh</a>
+</li>
+<li>sinpi()
+: <a class="el" href="rs__cl_8rsh.html#a4fe4fef049786e888526d6f37b912b0a">rs_cl.rsh</a>
+</li>
+<li>sqrt()
+: <a class="el" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">rs_cl.rsh</a>
+</li>
+<li>step()
+: <a class="el" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">rs_cl.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_t"></a>- t -</h3><ul>
+<li>tan()
+: <a class="el" href="rs__cl_8rsh.html#af12e245af8ff9bb72b5000e7c26cd8fe">rs_cl.rsh</a>
+</li>
+<li>tanh()
+: <a class="el" href="rs__cl_8rsh.html#abc36e89ddb87ea78451d1c5921ddbd8d">rs_cl.rsh</a>
+</li>
+<li>tanpi()
+: <a class="el" href="rs__cl_8rsh.html#ad8bfb083dd3979a305e594a0d6e581c4">rs_cl.rsh</a>
+</li>
+<li>tgamma()
+: <a class="el" href="rs__cl_8rsh.html#ab9f4cbfd2470420ee302f28cf3de6dd0">rs_cl.rsh</a>
+</li>
+<li>trunc()
+: <a class="el" href="rs__cl_8rsh.html#ad1a7c65693231219db1babeae1c41f15">rs_cl.rsh</a>
+</li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/globals_type.html b/docs/html/reference/renderscript/globals_type.html
new file mode 100644
index 0000000..238a6c4
--- /dev/null
+++ b/docs/html/reference/renderscript/globals_type.html
@@ -0,0 +1,223 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Members</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow3" class="tabs2">
+    <ul class="tablist">
+      <li><a href="globals.html"><span>All</span></a></li>
+      <li><a href="globals_func.html"><span>Functions</span></a></li>
+      <li class="current"><a href="globals_type.html"><span>Typedefs</span></a></li>
+      <li><a href="globals_enum.html"><span>Enumerations</span></a></li>
+    </ul>
+  </div>
+  <div id="navrow4" class="tabs3">
+    <ul class="tablist">
+      <li><a href="#index_c"><span>c</span></a></li>
+      <li><a href="#index_d"><span>d</span></a></li>
+      <li><a href="#index_f"><span>f</span></a></li>
+      <li><a href="#index_i"><span>i</span></a></li>
+      <li><a href="#index_l"><span>l</span></a></li>
+      <li><a href="#index_r"><span>r</span></a></li>
+      <li><a href="#index_s"><span>s</span></a></li>
+      <li><a href="#index_u"><span>u</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="contents">
+&#160;
+
+<h3><a class="anchor" id="index_c"></a>- c -</h3><ul>
+<li>char2
+: <a class="el" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">rs_types.rsh</a>
+</li>
+<li>char3
+: <a class="el" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">rs_types.rsh</a>
+</li>
+<li>char4
+: <a class="el" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_d"></a>- d -</h3><ul>
+<li>double2
+: <a class="el" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">rs_types.rsh</a>
+</li>
+<li>double3
+: <a class="el" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">rs_types.rsh</a>
+</li>
+<li>double4
+: <a class="el" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_f"></a>- f -</h3><ul>
+<li>float2
+: <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">rs_types.rsh</a>
+</li>
+<li>float3
+: <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">rs_types.rsh</a>
+</li>
+<li>float4
+: <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_i"></a>- i -</h3><ul>
+<li>int16_t
+: <a class="el" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">rs_types.rsh</a>
+</li>
+<li>int2
+: <a class="el" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">rs_types.rsh</a>
+</li>
+<li>int3
+: <a class="el" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">rs_types.rsh</a>
+</li>
+<li>int32_t
+: <a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">rs_types.rsh</a>
+</li>
+<li>int4
+: <a class="el" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">rs_types.rsh</a>
+</li>
+<li>int64_t
+: <a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">rs_types.rsh</a>
+</li>
+<li>int8_t
+: <a class="el" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_l"></a>- l -</h3><ul>
+<li>long2
+: <a class="el" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">rs_types.rsh</a>
+</li>
+<li>long3
+: <a class="el" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">rs_types.rsh</a>
+</li>
+<li>long4
+: <a class="el" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_r"></a>- r -</h3><ul>
+<li>rs_quaternion
+: <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_types.rsh</a>
+</li>
+<li>rs_script_call_t
+: <a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_core.rsh</a>
+</li>
+<li>rs_time_t
+: <a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_s"></a>- s -</h3><ul>
+<li>short2
+: <a class="el" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">rs_types.rsh</a>
+</li>
+<li>short3
+: <a class="el" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">rs_types.rsh</a>
+</li>
+<li>short4
+: <a class="el" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">rs_types.rsh</a>
+</li>
+<li>size_t
+: <a class="el" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">rs_types.rsh</a>
+</li>
+<li>ssize_t
+: <a class="el" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">rs_types.rsh</a>
+</li>
+</ul>
+
+
+<h3><a class="anchor" id="index_u"></a>- u -</h3><ul>
+<li>uchar
+: <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">rs_types.rsh</a>
+</li>
+<li>uchar2
+: <a class="el" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">rs_types.rsh</a>
+</li>
+<li>uchar3
+: <a class="el" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">rs_types.rsh</a>
+</li>
+<li>uchar4
+: <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">rs_types.rsh</a>
+</li>
+<li>uint
+: <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">rs_types.rsh</a>
+</li>
+<li>uint16_t
+: <a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">rs_types.rsh</a>
+</li>
+<li>uint2
+: <a class="el" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">rs_types.rsh</a>
+</li>
+<li>uint3
+: <a class="el" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">rs_types.rsh</a>
+</li>
+<li>uint32_t
+: <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">rs_types.rsh</a>
+</li>
+<li>uint4
+: <a class="el" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">rs_types.rsh</a>
+</li>
+<li>uint64_t
+: <a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">rs_types.rsh</a>
+</li>
+<li>uint8_t
+: <a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">rs_types.rsh</a>
+</li>
+<li>ulong
+: <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">rs_types.rsh</a>
+</li>
+<li>ulong2
+: <a class="el" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">rs_types.rsh</a>
+</li>
+<li>ulong3
+: <a class="el" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">rs_types.rsh</a>
+</li>
+<li>ulong4
+: <a class="el" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">rs_types.rsh</a>
+</li>
+<li>ushort
+: <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">rs_types.rsh</a>
+</li>
+<li>ushort2
+: <a class="el" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">rs_types.rsh</a>
+</li>
+<li>ushort3
+: <a class="el" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">rs_types.rsh</a>
+</li>
+<li>ushort4
+: <a class="el" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">rs_types.rsh</a>
+</li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/index.html b/docs/html/reference/renderscript/index.html
new file mode 100644
index 0000000..c4c057e
--- /dev/null
+++ b/docs/html/reference/renderscript/index.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>Main Page</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li class="current"><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="contents">
+<div class="textblock"><p>Renderscript is a high-performance runtime that provides graphics rendering and compute operations at the native level. Renderscript code is compiled on devices at runtime to allow platform-independence as well. This reference documentation describes the Renderscript runtime APIs, which you can utilize to write Renderscript code in C99. The Renderscript header files are automatically included for you, except for the <a class="el" href="rs__graphics_8rsh.html" title="Renderscript graphics API.">rs_graphics.rsh</a> header. If you are doing graphics rendering, include the graphics header file like this:</p>
+<p><code>#include "rs_graphics.rsh"</code></p>
+<p>To use Renderscript, you need to utilize the Renderscript runtime APIs documented here as well as the Android framework APIs for Renderscript. For documentation on the Android framework APIs, see the <a target="_parent" href="http://developer.android.com/reference/android/renderscript/package-summary.html">android.renderscript</a> package reference. For more information on how to develop with Renderscript and how the runtime and Android framework APIs interact, see the <a target="_parent" href="http://developer.android.com/guide/topics/renderscript/index.html">Renderscript developer guide</a> and the <a target="_parent" href="http://developer.android.com/resources/samples/RenderScript/index.html">Renderscript samples</a>. </p>
+</div></div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__allocation_8rsh.html b/docs/html/reference/renderscript/rs__allocation_8rsh.html
new file mode 100644
index 0000000..ca2663b
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__allocation_8rsh.html
@@ -0,0 +1,269 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_allocation.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_allocation.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#aadad7654929c451be299df125061c9ba">rsGetAllocation</a> (const void *)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#a3ca7f505a97d5b7f477bc65b9e77dafb">rsAllocationGetDimX</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#ac889b866b465580eb313e5d2a9fcac3d">rsAllocationGetDimY</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#acd6f1a2b2443e6ea39e6154577645d2c">rsAllocationGetDimZ</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#ac42a07c079d6b3c6bb21975170d4e11c">rsAllocationGetDimLOD</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#ac85f7ed88f38b35482c6d63b56d470fe">rsAllocationGetDimFaces</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">const void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rsGetElementAt</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">const void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#a7e0a1753a930557f6dc87f25ed3fd23b">rsGetElementAt</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">const void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__allocation_8rsh.html#a049ba2f6e6e18d47f2267474b2092822">rsGetElementAt</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> y, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> z)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Allocation routines. </p>
+
+<p>Definition in file <a class="el" href="rs__allocation_8rsh_source.html">rs_allocation.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="ac85f7ed88f38b35482c6d63b56d470fe"></a><!-- doxytag: member="rs_allocation.rsh::rsAllocationGetDimFaces" ref="ac85f7ed88f38b35482c6d63b56d470fe" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> rsAllocationGetDimFaces </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Query an allocation for the presence of more than one face.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint32_t Returns 1 if more than one face is present, 0 otherwise. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="ac42a07c079d6b3c6bb21975170d4e11c"></a><!-- doxytag: member="rs_allocation.rsh::rsAllocationGetDimLOD" ref="ac42a07c079d6b3c6bb21975170d4e11c" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> rsAllocationGetDimLOD </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Query an allocation for the presence of more than one LOD.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint32_t Returns 1 if more than one LOD is present, 0 otherwise. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a3ca7f505a97d5b7f477bc65b9e77dafb"></a><!-- doxytag: member="rs_allocation.rsh::rsAllocationGetDimX" ref="a3ca7f505a97d5b7f477bc65b9e77dafb" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> rsAllocationGetDimX </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Query the dimension of an allocation.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint32_t The X dimension of the allocation. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="ac889b866b465580eb313e5d2a9fcac3d"></a><!-- doxytag: member="rs_allocation.rsh::rsAllocationGetDimY" ref="ac889b866b465580eb313e5d2a9fcac3d" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> rsAllocationGetDimY </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Query the dimension of an allocation.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint32_t The Y dimension of the allocation. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="acd6f1a2b2443e6ea39e6154577645d2c"></a><!-- doxytag: member="rs_allocation.rsh::rsAllocationGetDimZ" ref="acd6f1a2b2443e6ea39e6154577645d2c" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> rsAllocationGetDimZ </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Query the dimension of an allocation.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint32_t The Z dimension of the allocation. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="aadad7654929c451be299df125061c9ba"></a><!-- doxytag: member="rs_allocation.rsh::rsGetAllocation" ref="aadad7654929c451be299df125061c9ba" args="(const void *)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="structrs__allocation.html">rs_allocation</a> rsGetAllocation </td>
+          <td>(</td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the Allocation for a given pointer. The pointer should point within a valid allocation. The results are undefined if the pointer is not from a valid allocation. </p>
+
+</div>
+</div>
+<a class="anchor" id="a3fd30b4388748601e025bb3566ce0cbc"></a><!-- doxytag: member="rs_allocation.rsh::rsGetElementAt" ref="a3fd30b4388748601e025bb3566ce0cbc" args="(rs_allocation, uint32_t x)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">const void* rsGetElementAt </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>x</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Extract a single element from an allocation. </p>
+
+</div>
+</div>
+<a class="anchor" id="a7e0a1753a930557f6dc87f25ed3fd23b"></a><!-- doxytag: member="rs_allocation.rsh::rsGetElementAt" ref="a7e0a1753a930557f6dc87f25ed3fd23b" args="(rs_allocation, uint32_t x, uint32_t y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">const void* rsGetElementAt </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a049ba2f6e6e18d47f2267474b2092822"></a><!-- doxytag: member="rs_allocation.rsh::rsGetElementAt" ref="a049ba2f6e6e18d47f2267474b2092822" args="(rs_allocation, uint32_t x, uint32_t y, uint32_t z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">const void* rsGetElementAt </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__allocation_8rsh_source.html b/docs/html/reference/renderscript/rs__allocation_8rsh_source.html
new file mode 100644
index 0000000..0d1c167
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__allocation_8rsh_source.html
@@ -0,0 +1,102 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_allocation.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_allocation.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__allocation_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_ALLOCATION_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_ALLOCATION_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00031"></a>00031 <span class="keyword">extern</span> <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> __attribute__((overloadable))
+<a name="l00032"></a>00032     <a class="code" href="rs__allocation_8rsh.html#aadad7654929c451be299df125061c9ba">rsGetAllocation</a>(const <span class="keywordtype">void</span> *);
+<a name="l00033"></a>00033 
+<a name="l00039"></a>00039 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00040"></a>00040     <a class="code" href="rs__allocation_8rsh.html#a3ca7f505a97d5b7f477bc65b9e77dafb">rsAllocationGetDimX</a>(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a>);
+<a name="l00041"></a>00041 
+<a name="l00047"></a>00047 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00048"></a>00048     <a class="code" href="rs__allocation_8rsh.html#ac889b866b465580eb313e5d2a9fcac3d">rsAllocationGetDimY</a>(rs_allocation);
+<a name="l00049"></a>00049 
+<a name="l00055"></a>00055 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00056"></a>00056     <a class="code" href="rs__allocation_8rsh.html#acd6f1a2b2443e6ea39e6154577645d2c">rsAllocationGetDimZ</a>(rs_allocation);
+<a name="l00057"></a>00057 
+<a name="l00063"></a>00063 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00064"></a>00064     <a class="code" href="rs__allocation_8rsh.html#ac42a07c079d6b3c6bb21975170d4e11c">rsAllocationGetDimLOD</a>(rs_allocation);
+<a name="l00065"></a>00065 
+<a name="l00071"></a>00071 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00072"></a>00072     <a class="code" href="rs__allocation_8rsh.html#ac85f7ed88f38b35482c6d63b56d470fe">rsAllocationGetDimFaces</a>(rs_allocation);
+<a name="l00073"></a>00073 
+<a name="l00074"></a>00074 <span class="preprocessor">#if (defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14))</span>
+<a name="l00075"></a>00075 <span class="preprocessor"></span>
+<a name="l00089"></a>00089 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00090"></a>00090     rsAllocationCopy1DRange(rs_allocation dstAlloc,
+<a name="l00091"></a>00091                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> dstOff, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> dstMip,
+<a name="l00092"></a>00092                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> count,
+<a name="l00093"></a>00093                             rs_allocation srcAlloc,
+<a name="l00094"></a>00094                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> srcOff, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> srcMip);
+<a name="l00095"></a>00095 
+<a name="l00117"></a>00117 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00118"></a>00118     rsAllocationCopy2DRange(rs_allocation dstAlloc,
+<a name="l00119"></a>00119                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> dstXoff, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> dstYoff,
+<a name="l00120"></a>00120                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> dstMip,
+<a name="l00121"></a>00121                             rs_allocation_cubemap_face dstFace,
+<a name="l00122"></a>00122                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> width, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> height,
+<a name="l00123"></a>00123                             rs_allocation srcAlloc,
+<a name="l00124"></a>00124                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> srcXoff, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> srcYoff,
+<a name="l00125"></a>00125                             <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> srcMip,
+<a name="l00126"></a>00126                             rs_allocation_cubemap_face srcFace);
+<a name="l00127"></a>00127 
+<a name="l00128"></a>00128 <span class="preprocessor">#endif //defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14)</span>
+<a name="l00129"></a>00129 <span class="preprocessor"></span>
+<a name="l00133"></a>00133 <span class="keyword">extern</span> <span class="keyword">const</span> <span class="keywordtype">void</span> * __attribute__((overloadable))
+<a name="l00134"></a>00134     <a class="code" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rsGetElementAt</a>(rs_allocation, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x);
+<a name="l00138"></a>00138 extern const <span class="keywordtype">void</span> * __attribute__((overloadable))
+<a name="l00139"></a>00139     <a class="code" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rsGetElementAt</a>(rs_allocation, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> y);
+<a name="l00143"></a>00143 extern const <span class="keywordtype">void</span> * __attribute__((overloadable))
+<a name="l00144"></a>00144     <a class="code" href="rs__allocation_8rsh.html#a3fd30b4388748601e025bb3566ce0cbc">rsGetElementAt</a>(rs_allocation, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> x, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> y, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> z);
+<a name="l00145"></a>00145 
+<a name="l00146"></a>00146 <span class="preprocessor">#endif</span>
+<a name="l00147"></a>00147 <span class="preprocessor"></span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__atomic_8rsh.html b/docs/html/reference/renderscript/rs__atomic_8rsh.html
new file mode 100644
index 0000000..3d0e97e
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__atomic_8rsh.html
@@ -0,0 +1,38 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_atomic.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_atomic.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Atomic routines. </p>
+
+<p>Definition in file <a class="el" href="rs__atomic_8rsh_source.html">rs_atomic.rsh</a>.</p>
+</div></div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__atomic_8rsh_source.html b/docs/html/reference/renderscript/rs__atomic_8rsh_source.html
new file mode 100644
index 0000000..a1400bd
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__atomic_8rsh_source.html
@@ -0,0 +1,110 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_atomic.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_atomic.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__atomic_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_ATOMIC_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_ATOMIC_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00026"></a>00026 <span class="preprocessor">#if (defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14))</span>
+<a name="l00027"></a>00027 <span class="preprocessor"></span>
+<a name="l00036"></a>00036 <span class="keyword">extern</span> <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00037"></a>00037     rsAtomicInc(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr);
+<a name="l00046"></a>00046 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00047"></a>00047     rsAtomicInc(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr);
+<a name="l00048"></a>00048 
+<a name="l00056"></a>00056 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00057"></a>00057     rsAtomicDec(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr);
+<a name="l00065"></a>00065 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00066"></a>00066     rsAtomicDec(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr);
+<a name="l00067"></a>00067 
+<a name="l00076"></a>00076 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00077"></a>00077     rsAtomicAdd(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00086"></a>00086 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00087"></a>00087     rsAtomicAdd(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00088"></a>00088 
+<a name="l00097"></a>00097 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00098"></a>00098     rsAtomicSub(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00107"></a>00107 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00108"></a>00108     rsAtomicSub(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00109"></a>00109 
+<a name="l00118"></a>00118 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00119"></a>00119     rsAtomicAnd(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00128"></a>00128 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00129"></a>00129     rsAtomicAnd(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00130"></a>00130 
+<a name="l00139"></a>00139 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00140"></a>00140     rsAtomicOr(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00149"></a>00149 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00150"></a>00150     rsAtomicOr(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00151"></a>00151 
+<a name="l00160"></a>00160 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00161"></a>00161     rsAtomicXor(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00170"></a>00170 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00171"></a>00171     rsAtomicXor(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00172"></a>00172 
+<a name="l00182"></a>00182 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00183"></a>00183     rsAtomicMin(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00193"></a>00193 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00194"></a>00194     rsAtomicMin(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00195"></a>00195 
+<a name="l00205"></a>00205 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00206"></a>00206     rsAtomicMax(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> value);
+<a name="l00216"></a>00216 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00217"></a>00217     rsAtomicMax(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> value);
+<a name="l00218"></a>00218 
+<a name="l00230"></a>00230 extern <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> __attribute__((overloadable))
+<a name="l00231"></a>00231     rsAtomicCas(volatile <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> compareValue, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> newValue);
+<a name="l00232"></a>00232 
+<a name="l00244"></a>00244 extern <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> __attribute__((overloadable))
+<a name="l00245"></a>00245     rsAtomicCas(volatile <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>* addr, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> compareValue, <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> newValue);
+<a name="l00246"></a>00246 
+<a name="l00247"></a>00247 <span class="preprocessor">#endif //defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14)</span>
+<a name="l00248"></a>00248 <span class="preprocessor"></span>
+<a name="l00249"></a>00249 <span class="preprocessor">#endif</span>
+<a name="l00250"></a>00250 <span class="preprocessor"></span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__cl_8rsh.html b/docs/html/reference/renderscript/rs__cl_8rsh.html
new file mode 100644
index 0000000..5c499e6
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__cl_8rsh.html
@@ -0,0 +1,1938 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_cl.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_cl.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">acos</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a6575106413ec72448439ef67f1309424">acosh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a2c0c7c00815bd480fcda80d1144ac20d">acospi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a78b9d0583bd0699e2eac30d2a136817a">asin</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4e3fe465ed5541af53192c59c80af1a0">asinh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a679b63e86358fc962cb343eb6263496b">asinpi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ab790c3a7df8fcbeab77f6c0e3b4dcada">atan</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aaf4b636b09041878e1542054c73d81e9">atan2</a> (float y, float x)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a83bdf415cc561ff6237a124273d9fb0d">atanh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a420d4aaea0e53d7172845a21a1e648ea">atanpi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a9aed0a1613c86acf5e4c5ad3290a4745">atan2pi</a> (float y, float x)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ae9d1787b55c2587478a24d96573225df">cbrt</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aa8fc6daff743a1b635ccbf9af83fe4e4">ceil</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a29f2602d95aa7b3950e2b77b3e268f7e">copysign</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">cos</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ac8d88d83182afd591401eaed101d9670">cosh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a07b12188bd53c6b584274892f6abf425">cospi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a2e24dc8594e758b64c340153f67a533c">erfc</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a139f102df651c25c26dd35d549173f57">erf</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a6d9aac64c2686961ca8f30e3c34fef36">exp</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a39bca19ee2b1aa95144e58eb4a1e4f88">exp2</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a9243de1d67fcc847a89f95748d664b19">pow</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4b51589157c9ce600ea6156be51d8d18">exp10</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a7996044b67be921a5e58e2fe76af66e2">expm1</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ad6e897f1acae252ec0901e3b122992ea">fabs</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ae7a7bac0f4e244594078f87b42c8716a">fdim</a> (float, float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aae2da38a7246378dff8014ec407a30c3">floor</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ac42909daec463fe449743e70baf8360d">fma</a> (float a, float b, float c)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a60f2072d8a746e7fe05cd46dea0fefcc">fmax</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a1fd9d57c6c992866bf5161be2cf4c447">fmin</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a31d5e179730ae44e1dbc74c1535f392e">fmod</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ac5277212e0df309a0a7c908424f7b14b">fract</a> (float v, float *iptr)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a778635fffed3cee8ab0800482ba53a30">frexp</a> (float v, int *iptr)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a147f38d6e41f45de9b5e7c6f3dcac010">hypot</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aad9a8beba52acb77b1efeba432e6cc2c">ilogb</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">ldexp</a> (float x, int y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a3ff36f9b21927d6b4b58616e48fddcb4">lgamma</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a735f4e14e33c50348ef41220f9210bcc">lgamma</a> (float x, int *y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a3ff85f5f4b206ecf9ec9d128d7d18a08">log</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#af5c1bdba2a13aa2e2b0722287f6a919f">log10</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a2fb571ae932f671ff3e9e97f2d3fabb7">log2</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ae10541ede49062ef7f977712c4878c1f">log1p</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a28742d6ce2f20a61f16ecc08ed499871">logb</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4f9086698f1eb466ba2dccf7e331cdc3">mad</a> (float a, float b, float c)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a841633bcdcaeb6a514d9c6460f0adf2d">modf</a> (float x, float *iret)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#adb11df05fb9985595af0a7bd882bdeac">nextafter</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#afd46205452017b741abb2e17fc28557d">pown</a> (float v, int p)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a3ff65421721ec8e6ce8d875a563d005f">powr</a> (float v, float p)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a5188ac0e3af95b0956c6abeafb74fda9">remainder</a> (float x, float y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#adb0ffe344ae56ca7fc9083c1f2943e55">rint</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#af169e7e1c575b7c24c1834569223077f">rootn</a> (float v, int n)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aff4846ab5b947550814d5414a2c3626f">round</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">sqrt</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a5db00fde9e6bff693a38f3a37e7a1f70">rsqrt</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a240f7c7c20b432a30dc660b5dd4cd320">sincos</a> (float v, float *cosptr)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ae686e0cc567f7ee2b0a84706aa486e4a">sinh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4fe4fef049786e888526d6f37b912b0a">sinpi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#af12e245af8ff9bb72b5000e7c26cd8fe">tan</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#abc36e89ddb87ea78451d1c5921ddbd8d">tanh</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ad8bfb083dd3979a305e594a0d6e581c4">tanpi</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ab9f4cbfd2470420ee302f28cf3de6dd0">tgamma</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ad1a7c65693231219db1babeae1c41f15">trunc</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a> (float amount, float low, float high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">degrees</a> (float radians)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a> (float start, float stop, float amount)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#aaef2526c4d190ba6f7301b4e810917a7">radians</a> (float degrees)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a> (float edge, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a3e6d477a06dec7070f073eec9d8f420c">sign</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a0f7beb26bb4aa30535babd14492a7e90">cross</a> (<a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> lhs, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a> (float lhs, float rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a> (float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">distance</a> (float lhs, float rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">normalize</a> (float v)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Basic math functions. </p>
+
+<p>Definition in file <a class="el" href="rs__cl_8rsh_source.html">rs_cl.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="a07648648c7f857cfd1479821d4389751"></a><!-- doxytag: member="rs_cl.rsh::acos" ref="a07648648c7f857cfd1479821d4389751" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float acos </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse cosine.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a6575106413ec72448439ef67f1309424"></a><!-- doxytag: member="rs_cl.rsh::acosh" ref="a6575106413ec72448439ef67f1309424" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float acosh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse hyperbolic cosine.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a2c0c7c00815bd480fcda80d1144ac20d"></a><!-- doxytag: member="rs_cl.rsh::acospi" ref="a2c0c7c00815bd480fcda80d1144ac20d" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float acospi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse cosine divided by PI.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a78b9d0583bd0699e2eac30d2a136817a"></a><!-- doxytag: member="rs_cl.rsh::asin" ref="a78b9d0583bd0699e2eac30d2a136817a" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float asin </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse sine.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a4e3fe465ed5541af53192c59c80af1a0"></a><!-- doxytag: member="rs_cl.rsh::asinh" ref="a4e3fe465ed5541af53192c59c80af1a0" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float asinh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse hyperbolic sine.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a679b63e86358fc962cb343eb6263496b"></a><!-- doxytag: member="rs_cl.rsh::asinpi" ref="a679b63e86358fc962cb343eb6263496b" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float asinpi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse sine divided by PI.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="ab790c3a7df8fcbeab77f6c0e3b4dcada"></a><!-- doxytag: member="rs_cl.rsh::atan" ref="ab790c3a7df8fcbeab77f6c0e3b4dcada" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float atan </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse tangent.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="aaf4b636b09041878e1542054c73d81e9"></a><!-- doxytag: member="rs_cl.rsh::atan2" ref="aaf4b636b09041878e1542054c73d81e9" args="(float y, float x)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float atan2 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse tangent of y / x.</p>
+<p>Supports float, float2, float3, float4. Both arguments must be of the same type.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a9aed0a1613c86acf5e4c5ad3290a4745"></a><!-- doxytag: member="rs_cl.rsh::atan2pi" ref="a9aed0a1613c86acf5e4c5ad3290a4745" args="(float y, float x)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float atan2pi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse tangent of y / x, divided by PI.</p>
+<p>Supports float, float2, float3, float4. Both arguments must be of the same type.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a83bdf415cc561ff6237a124273d9fb0d"></a><!-- doxytag: member="rs_cl.rsh::atanh" ref="a83bdf415cc561ff6237a124273d9fb0d" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float atanh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse hyperbolic tangent.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="a420d4aaea0e53d7172845a21a1e648ea"></a><!-- doxytag: member="rs_cl.rsh::atanpi" ref="a420d4aaea0e53d7172845a21a1e648ea" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float atanpi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the inverse tangent divided by PI.</p>
+<p>Supports float, float2, float3, float4 </p>
+
+</div>
+</div>
+<a class="anchor" id="ae9d1787b55c2587478a24d96573225df"></a><!-- doxytag: member="rs_cl.rsh::cbrt" ref="ae9d1787b55c2587478a24d96573225df" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float cbrt </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the cube root.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa8fc6daff743a1b635ccbf9af83fe4e4"></a><!-- doxytag: member="rs_cl.rsh::ceil" ref="aa8fc6daff743a1b635ccbf9af83fe4e4" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float ceil </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the smallest integer not less than a value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad4dab580aba6cf15539b407b9163dfde"></a><!-- doxytag: member="rs_cl.rsh::clamp" ref="ad4dab580aba6cf15539b407b9163dfde" args="(float amount, float low, float high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> clamp </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the minimum of two values.</p>
+<p>Supports 1,2,3,4 components of uchar, char, ushort, short, uint, int, float. Return the maximum of two values.</p>
+<p>Supports 1,2,3,4 components of uchar, char, ushort, short, uint, int, float. Clamp a value to a specified high and low bound.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">amount</td><td>value to be clamped. Supports 1,2,3,4 components </td></tr>
+    <tr><td class="paramname">low</td><td>Lower bound, must be scalar or matching vector. </td></tr>
+    <tr><td class="paramname">high</td><td>High bound, must match type of low </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a29f2602d95aa7b3950e2b77b3e268f7e"></a><!-- doxytag: member="rs_cl.rsh::copysign" ref="a29f2602d95aa7b3950e2b77b3e268f7e" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float copysign </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Copy the sign bit from y to x.</p>
+<p>Supports float, float2, float3, float4. Both arguments must be of the same type.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a8eec7aeb4b0c46b06cbcd1a3ac3e6f05"></a><!-- doxytag: member="rs_cl.rsh::cos" ref="a8eec7aeb4b0c46b06cbcd1a3ac3e6f05" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float cos </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the cosine.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ac8d88d83182afd591401eaed101d9670"></a><!-- doxytag: member="rs_cl.rsh::cosh" ref="ac8d88d83182afd591401eaed101d9670" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float cosh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the hypebolic cosine.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a07b12188bd53c6b584274892f6abf425"></a><!-- doxytag: member="rs_cl.rsh::cospi" ref="a07b12188bd53c6b584274892f6abf425" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float cospi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the cosine of the value * PI.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a0f7beb26bb4aa30535babd14492a7e90"></a><!-- doxytag: member="rs_cl.rsh::cross" ref="a0f7beb26bb4aa30535babd14492a7e90" args="(float3 lhs, float3 rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> cross </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the cross product of two vectors.</p>
+<p>Supports 3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="adc1b551193e66d8037daa1721df4d29c"></a><!-- doxytag: member="rs_cl.rsh::degrees" ref="adc1b551193e66d8037daa1721df4d29c" args="(float radians)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float degrees </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>radians</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Convert from radians to degrees.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a4488863373be92e113e9d24aa3d21e76"></a><!-- doxytag: member="rs_cl.rsh::distance" ref="a4488863373be92e113e9d24aa3d21e76" args="(float lhs, float rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float distance </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the distance between two points.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a70544acaca578035a849eef67d62c449"></a><!-- doxytag: member="rs_cl.rsh::dot" ref="a70544acaca578035a849eef67d62c449" args="(float lhs, float rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float dot </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the dot product of two vectors.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a139f102df651c25c26dd35d549173f57"></a><!-- doxytag: member="rs_cl.rsh::erf" ref="a139f102df651c25c26dd35d549173f57" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float erf </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the error function.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a2e24dc8594e758b64c340153f67a533c"></a><!-- doxytag: member="rs_cl.rsh::erfc" ref="a2e24dc8594e758b64c340153f67a533c" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float erfc </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the complementary error function.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6d9aac64c2686961ca8f30e3c34fef36"></a><!-- doxytag: member="rs_cl.rsh::exp" ref="a6d9aac64c2686961ca8f30e3c34fef36" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float exp </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return e ^ value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4b51589157c9ce600ea6156be51d8d18"></a><!-- doxytag: member="rs_cl.rsh::exp10" ref="a4b51589157c9ce600ea6156be51d8d18" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float exp10 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return 10 ^ value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a39bca19ee2b1aa95144e58eb4a1e4f88"></a><!-- doxytag: member="rs_cl.rsh::exp2" ref="a39bca19ee2b1aa95144e58eb4a1e4f88" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float exp2 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return 2 ^ value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a7996044b67be921a5e58e2fe76af66e2"></a><!-- doxytag: member="rs_cl.rsh::expm1" ref="a7996044b67be921a5e58e2fe76af66e2" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float expm1 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (e ^ value) - 1.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad6e897f1acae252ec0901e3b122992ea"></a><!-- doxytag: member="rs_cl.rsh::fabs" ref="ad6e897f1acae252ec0901e3b122992ea" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fabs </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the absolute value of a value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ae7a7bac0f4e244594078f87b42c8716a"></a><!-- doxytag: member="rs_cl.rsh::fdim" ref="ae7a7bac0f4e244594078f87b42c8716a" args="(float, float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fdim </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the positive difference between two values.</p>
+<p>Supports float, float2, float3, float4. Both arguments must be of the same type. </p>
+
+</div>
+</div>
+<a class="anchor" id="aae2da38a7246378dff8014ec407a30c3"></a><!-- doxytag: member="rs_cl.rsh::floor" ref="aae2da38a7246378dff8014ec407a30c3" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float floor </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the smallest integer not greater than a value.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ac42909daec463fe449743e70baf8360d"></a><!-- doxytag: member="rs_cl.rsh::fma" ref="ac42909daec463fe449743e70baf8360d" args="(float a, float b, float c)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fma </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>c</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return a*b + c.</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="a60f2072d8a746e7fe05cd46dea0fefcc"></a><!-- doxytag: member="rs_cl.rsh::fmax" ref="a60f2072d8a746e7fe05cd46dea0fefcc" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fmax </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (x &lt; y ? y : x)</p>
+<p>Supports float, float2, float3, float4. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x,:</td><td>may be float, float2, float3, float4 </td></tr>
+    <tr><td class="paramname">y,:</td><td>may be float or vector. If vector must match type of x. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a1fd9d57c6c992866bf5161be2cf4c447"></a><!-- doxytag: member="rs_cl.rsh::fmin" ref="a1fd9d57c6c992866bf5161be2cf4c447" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fmin </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (x &gt; y ? y : x)</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x,:</td><td>may be float, float2, float3, float4 </td></tr>
+    <tr><td class="paramname">y,:</td><td>may be float or vector. If vector must match type of x. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a31d5e179730ae44e1dbc74c1535f392e"></a><!-- doxytag: member="rs_cl.rsh::fmod" ref="a31d5e179730ae44e1dbc74c1535f392e" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float fmod </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the remainder from x / y</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="ac5277212e0df309a0a7c908424f7b14b"></a><!-- doxytag: member="rs_cl.rsh::fract" ref="ac5277212e0df309a0a7c908424f7b14b" args="(float v, float *iptr)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float fract </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>iptr</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return fractional part of v</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">iptr</td><td>iptr[0] will be set to the floor of the input value. Supports float, float2, float3, float4. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a778635fffed3cee8ab0800482ba53a30"></a><!-- doxytag: member="rs_cl.rsh::frexp" ref="a778635fffed3cee8ab0800482ba53a30" args="(float v, int *iptr)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float frexp </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>iptr</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the mantissa and place the exponent into iptr[0]</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>Supports float, float2, float3, float4. </td></tr>
+    <tr><td class="paramname">iptr</td><td>Must have the same vector size as v. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a147f38d6e41f45de9b5e7c6f3dcac010"></a><!-- doxytag: member="rs_cl.rsh::hypot" ref="a147f38d6e41f45de9b5e7c6f3dcac010" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float hypot </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return sqrt(x*x + y*y)</p>
+<p>Supports float, float2, float3, float4. </p>
+
+</div>
+</div>
+<a class="anchor" id="aad9a8beba52acb77b1efeba432e6cc2c"></a><!-- doxytag: member="rs_cl.rsh::ilogb" ref="aad9a8beba52acb77b1efeba432e6cc2c" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">int ilogb </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the integer exponent of a value</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a013bc1dcda984cbc608e123ed38491e6"></a><!-- doxytag: member="rs_cl.rsh::ldexp" ref="a013bc1dcda984cbc608e123ed38491e6" args="(float x, int y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float ldexp </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (x * 2^y)</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x</td><td>Supports 1,2,3,4 components </td></tr>
+    <tr><td class="paramname">y</td><td>Supports single component or matching vector. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a1a222b7879342279e1e0070d6afd9e18"></a><!-- doxytag: member="rs_cl.rsh::length" ref="a1a222b7879342279e1e0070d6afd9e18" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float length </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the length of a vector.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a3ff36f9b21927d6b4b58616e48fddcb4"></a><!-- doxytag: member="rs_cl.rsh::lgamma" ref="a3ff36f9b21927d6b4b58616e48fddcb4" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float lgamma </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the log gamma</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a735f4e14e33c50348ef41220f9210bcc"></a><!-- doxytag: member="rs_cl.rsh::lgamma" ref="a735f4e14e33c50348ef41220f9210bcc" args="(float x, int *y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float lgamma </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the log gamma and sign</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x</td><td>Supports 1,2,3,4 components </td></tr>
+    <tr><td class="paramname">y</td><td>Supports matching vector. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a3ff85f5f4b206ecf9ec9d128d7d18a08"></a><!-- doxytag: member="rs_cl.rsh::log" ref="a3ff85f5f4b206ecf9ec9d128d7d18a08" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float log </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the natural logarithm</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="af5c1bdba2a13aa2e2b0722287f6a919f"></a><!-- doxytag: member="rs_cl.rsh::log10" ref="af5c1bdba2a13aa2e2b0722287f6a919f" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float log10 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the base 10 logarithm</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="ae10541ede49062ef7f977712c4878c1f"></a><!-- doxytag: member="rs_cl.rsh::log1p" ref="ae10541ede49062ef7f977712c4878c1f" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float log1p </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the natural logarithm of (v + 1.0f)</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a2fb571ae932f671ff3e9e97f2d3fabb7"></a><!-- doxytag: member="rs_cl.rsh::log2" ref="a2fb571ae932f671ff3e9e97f2d3fabb7" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float log2 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the base 2 logarithm</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a28742d6ce2f20a61f16ecc08ed499871"></a><!-- doxytag: member="rs_cl.rsh::logb" ref="a28742d6ce2f20a61f16ecc08ed499871" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float logb </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the exponent of the value.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a4f9086698f1eb466ba2dccf7e331cdc3"></a><!-- doxytag: member="rs_cl.rsh::mad" ref="a4f9086698f1eb466ba2dccf7e331cdc3" args="(float a, float b, float c)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float mad </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>c</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute (a * b) + c</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="af4c76d51368c8e330cb59ea5a0a2310e"></a><!-- doxytag: member="rs_cl.rsh::mix" ref="af4c76d51368c8e330cb59ea5a0a2310e" args="(float start, float stop, float amount)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> mix </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>start</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>stop</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>amount</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>return start + ((stop - start) * amount);</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a841633bcdcaeb6a514d9c6460f0adf2d"></a><!-- doxytag: member="rs_cl.rsh::modf" ref="a841633bcdcaeb6a514d9c6460f0adf2d" args="(float x, float *iret)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float modf </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>iret</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the integral and fractional components of a number Supports 1,2,3,4 components</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x</td><td>Source value </td></tr>
+    <tr><td class="paramname">iret</td><td>iret[0] will be set to the integral portion of the number. </td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>The floating point portion of the value. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="adb11df05fb9985595af0a7bd882bdeac"></a><!-- doxytag: member="rs_cl.rsh::nextafter" ref="adb11df05fb9985595af0a7bd882bdeac" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float nextafter </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the next floating point number from x towards y.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a373e03e92a1b7f3fdea5ca4ca159d2a8"></a><!-- doxytag: member="rs_cl.rsh::normalize" ref="a373e03e92a1b7f3fdea5ca4ca159d2a8" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> normalize </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Normalize a vector.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a9243de1d67fcc847a89f95748d664b19"></a><!-- doxytag: member="rs_cl.rsh::pow" ref="a9243de1d67fcc847a89f95748d664b19" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float pow </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return x ^ y.</p>
+<p>Supports float, float2, float3, float4. Both arguments must be of the same type. </p>
+
+</div>
+</div>
+<a class="anchor" id="afd46205452017b741abb2e17fc28557d"></a><!-- doxytag: member="rs_cl.rsh::pown" ref="afd46205452017b741abb2e17fc28557d" args="(float v, int p)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float pown </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>p</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (v ^ p).</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a3ff65421721ec8e6ce8d875a563d005f"></a><!-- doxytag: member="rs_cl.rsh::powr" ref="a3ff65421721ec8e6ce8d875a563d005f" args="(float v, float p)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float powr </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>p</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (v ^ p). </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>must be greater than 0.</td></tr>
+  </table>
+  </dd>
+</dl>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="aaef2526c4d190ba6f7301b4e810917a7"></a><!-- doxytag: member="rs_cl.rsh::radians" ref="aaef2526c4d190ba6f7301b4e810917a7" args="(float degrees)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float radians </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>degrees</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Convert from degrees to radians.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a5188ac0e3af95b0956c6abeafb74fda9"></a><!-- doxytag: member="rs_cl.rsh::remainder" ref="a5188ac0e3af95b0956c6abeafb74fda9" args="(float x, float y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float remainder </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return round x/y to the nearest integer then compute the remander.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="adb0ffe344ae56ca7fc9083c1f2943e55"></a><!-- doxytag: member="rs_cl.rsh::rint" ref="adb0ffe344ae56ca7fc9083c1f2943e55" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float rint </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Round to the nearest integral value.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="af169e7e1c575b7c24c1834569223077f"></a><!-- doxytag: member="rs_cl.rsh::rootn" ref="af169e7e1c575b7c24c1834569223077f" args="(float v, int n)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float rootn </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>n</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the Nth root of a value.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="aff4846ab5b947550814d5414a2c3626f"></a><!-- doxytag: member="rs_cl.rsh::round" ref="aff4846ab5b947550814d5414a2c3626f" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float round </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Round to the nearest integral value. Half values are rounded away from zero.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a5db00fde9e6bff693a38f3a37e7a1f70"></a><!-- doxytag: member="rs_cl.rsh::rsqrt" ref="a5db00fde9e6bff693a38f3a37e7a1f70" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float rsqrt </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return (1 / sqrt(value)).</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>The incoming value in radians Supports 1,2,3,4 components </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a3e6d477a06dec7070f073eec9d8f420c"></a><!-- doxytag: member="rs_cl.rsh::sign" ref="a3e6d477a06dec7070f073eec9d8f420c" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float sign </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>if (v &lt; 0) return -1.f; else if (v &gt; 0) return 1.f; else return 0.f;</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a8c8cd526b44eb55aede77cf659f24306"></a><!-- doxytag: member="rs_cl.rsh::sin" ref="a8c8cd526b44eb55aede77cf659f24306" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float sin </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the sine of a value specified in radians.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>The incoming value in radians Supports 1,2,3,4 components </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a240f7c7c20b432a30dc660b5dd4cd320"></a><!-- doxytag: member="rs_cl.rsh::sincos" ref="a240f7c7c20b432a30dc660b5dd4cd320" args="(float v, float *cosptr)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float sincos </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>cosptr</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the sine and cosine of a value.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>sine </dd></dl>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>The incoming value in radians </td></tr>
+    <tr><td class="paramname">*cosptr</td><td>cosptr[0] will be set to the cosine value.</td></tr>
+  </table>
+  </dd>
+</dl>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="ae686e0cc567f7ee2b0a84706aa486e4a"></a><!-- doxytag: member="rs_cl.rsh::sinh" ref="ae686e0cc567f7ee2b0a84706aa486e4a" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float sinh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the hyperbolic sine of a value specified in radians.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a4fe4fef049786e888526d6f37b912b0a"></a><!-- doxytag: member="rs_cl.rsh::sinpi" ref="a4fe4fef049786e888526d6f37b912b0a" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float sinpi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the sin(v * PI).</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a92da0faef80c4d8f66e954c8c169a729"></a><!-- doxytag: member="rs_cl.rsh::sqrt" ref="a92da0faef80c4d8f66e954c8c169a729" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float sqrt </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the square root of a value.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="a4f7ba6882099d16853d0415982121900"></a><!-- doxytag: member="rs_cl.rsh::step" ref="a4f7ba6882099d16853d0415982121900" args="(float edge, float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> step </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>edge</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>if (v &lt; edge) return 0.f; else return 1.f;</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="af12e245af8ff9bb72b5000e7c26cd8fe"></a><!-- doxytag: member="rs_cl.rsh::tan" ref="af12e245af8ff9bb72b5000e7c26cd8fe" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float tan </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the tangent of a value.</p>
+<p>Supports 1,2,3,4 components </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>The incoming value in radians </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="abc36e89ddb87ea78451d1c5921ddbd8d"></a><!-- doxytag: member="rs_cl.rsh::tanh" ref="abc36e89ddb87ea78451d1c5921ddbd8d" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float tanh </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return the hyperbolic tangent of a value.</p>
+<p>Supports 1,2,3,4 components </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">v</td><td>The incoming value in radians </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ad8bfb083dd3979a305e594a0d6e581c4"></a><!-- doxytag: member="rs_cl.rsh::tanpi" ref="ad8bfb083dd3979a305e594a0d6e581c4" args="(float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float tanpi </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return tan(v * PI)</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="ab9f4cbfd2470420ee302f28cf3de6dd0"></a><!-- doxytag: member="rs_cl.rsh::tgamma" ref="ab9f4cbfd2470420ee302f28cf3de6dd0" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float tgamma </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Compute the gamma function of a value.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+<a class="anchor" id="ad1a7c65693231219db1babeae1c41f15"></a><!-- doxytag: member="rs_cl.rsh::trunc" ref="ad1a7c65693231219db1babeae1c41f15" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float trunc </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Round to integral using truncation.</p>
+<p>Supports 1,2,3,4 components </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__cl_8rsh_source.html b/docs/html/reference/renderscript/rs__cl_8rsh_source.html
new file mode 100644
index 0000000..73ecdc6
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__cl_8rsh_source.html
@@ -0,0 +1,475 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_cl.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_cl.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__cl_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_CL_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_CL_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00026"></a>00026 <span class="comment">// Conversions</span>
+<a name="l00027"></a>00027 <span class="preprocessor">#define CVT_FUNC_2(typeout, typein)                             \</span>
+<a name="l00028"></a>00028 <span class="preprocessor">_RS_RUNTIME typeout##2 __attribute__((overloadable))             \</span>
+<a name="l00029"></a>00029 <span class="preprocessor">        convert_##typeout##2(typein##2 v);                      \</span>
+<a name="l00030"></a>00030 <span class="preprocessor">_RS_RUNTIME typeout##3 __attribute__((overloadable))             \</span>
+<a name="l00031"></a>00031 <span class="preprocessor">        convert_##typeout##3(typein##3 v);                      \</span>
+<a name="l00032"></a>00032 <span class="preprocessor">_RS_RUNTIME typeout##4 __attribute__((overloadable))             \</span>
+<a name="l00033"></a>00033 <span class="preprocessor">        convert_##typeout##4(typein##4 v);</span>
+<a name="l00034"></a>00034 <span class="preprocessor"></span>
+<a name="l00035"></a>00035 
+<a name="l00036"></a>00036 <span class="preprocessor">#define CVT_FUNC(type)  CVT_FUNC_2(type, uchar)     \</span>
+<a name="l00037"></a>00037 <span class="preprocessor">                        CVT_FUNC_2(type, char)      \</span>
+<a name="l00038"></a>00038 <span class="preprocessor">                        CVT_FUNC_2(type, ushort)    \</span>
+<a name="l00039"></a>00039 <span class="preprocessor">                        CVT_FUNC_2(type, short)     \</span>
+<a name="l00040"></a>00040 <span class="preprocessor">                        CVT_FUNC_2(type, uint)      \</span>
+<a name="l00041"></a>00041 <span class="preprocessor">                        CVT_FUNC_2(type, int)       \</span>
+<a name="l00042"></a>00042 <span class="preprocessor">                        CVT_FUNC_2(type, float)</span>
+<a name="l00043"></a>00043 <span class="preprocessor"></span>
+<a name="l00044"></a>00044 CVT_FUNC(<span class="keywordtype">char</span>)
+<a name="l00045"></a>00045 CVT_FUNC(<a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>)
+<a name="l00046"></a>00046 CVT_FUNC(<span class="keywordtype">short</span>)
+<a name="l00047"></a>00047 CVT_FUNC(<a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>)
+<a name="l00048"></a>00048 CVT_FUNC(<span class="keywordtype">int</span>)
+<a name="l00049"></a>00049 CVT_FUNC(<a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>)
+<a name="l00050"></a>00050 CVT_FUNC(<span class="keywordtype">float</span>)
+<a name="l00051"></a>00051 
+<a name="l00052"></a>00052 <span class="comment">// Float ops, 6.11.2</span>
+<a name="l00053"></a>00053 
+<a name="l00054"></a>00054 <span class="preprocessor">#define FN_FUNC_FN(fnc)                                         \</span>
+<a name="l00055"></a>00055 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v);  \</span>
+<a name="l00056"></a>00056 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v);  \</span>
+<a name="l00057"></a>00057 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v);</span>
+<a name="l00058"></a>00058 <span class="preprocessor"></span>
+<a name="l00059"></a>00059 <span class="preprocessor">#define IN_FUNC_FN(fnc)                                         \</span>
+<a name="l00060"></a>00060 <span class="preprocessor">_RS_RUNTIME int2 __attribute__((overloadable)) fnc(float2 v);    \</span>
+<a name="l00061"></a>00061 <span class="preprocessor">_RS_RUNTIME int3 __attribute__((overloadable)) fnc(float3 v);    \</span>
+<a name="l00062"></a>00062 <span class="preprocessor">_RS_RUNTIME int4 __attribute__((overloadable)) fnc(float4 v);</span>
+<a name="l00063"></a>00063 <span class="preprocessor"></span>
+<a name="l00064"></a>00064 <span class="preprocessor">#define FN_FUNC_FN_FN(fnc)                                                  \</span>
+<a name="l00065"></a>00065 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v1, float2 v2);  \</span>
+<a name="l00066"></a>00066 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v1, float3 v2);  \</span>
+<a name="l00067"></a>00067 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v1, float4 v2);</span>
+<a name="l00068"></a>00068 <span class="preprocessor"></span>
+<a name="l00069"></a>00069 <span class="preprocessor">#define FN_FUNC_FN_F(fnc)                                                   \</span>
+<a name="l00070"></a>00070 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v1, float v2);   \</span>
+<a name="l00071"></a>00071 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v1, float v2);   \</span>
+<a name="l00072"></a>00072 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v1, float v2);</span>
+<a name="l00073"></a>00073 <span class="preprocessor"></span>
+<a name="l00074"></a>00074 <span class="preprocessor">#define FN_FUNC_FN_IN(fnc)                                                  \</span>
+<a name="l00075"></a>00075 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v1, int2 v2);    \</span>
+<a name="l00076"></a>00076 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v1, int3 v2);    \</span>
+<a name="l00077"></a>00077 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v1, int4 v2);    \</span>
+<a name="l00078"></a>00078 <span class="preprocessor"></span>
+<a name="l00079"></a>00079 <span class="preprocessor"></span><span class="preprocessor">#define FN_FUNC_FN_I(fnc)                                                   \</span>
+<a name="l00080"></a>00080 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v1, int v2);     \</span>
+<a name="l00081"></a>00081 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v1, int v2);     \</span>
+<a name="l00082"></a>00082 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v1, int v2);</span>
+<a name="l00083"></a>00083 <span class="preprocessor"></span>
+<a name="l00084"></a>00084 <span class="preprocessor">#define FN_FUNC_FN_PFN(fnc)                     \</span>
+<a name="l00085"></a>00085 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) \</span>
+<a name="l00086"></a>00086 <span class="preprocessor">        fnc(float2 v1, float2 *v2);             \</span>
+<a name="l00087"></a>00087 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) \</span>
+<a name="l00088"></a>00088 <span class="preprocessor">        fnc(float3 v1, float3 *v2);             \</span>
+<a name="l00089"></a>00089 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) \</span>
+<a name="l00090"></a>00090 <span class="preprocessor">        fnc(float4 v1, float4 *v2);</span>
+<a name="l00091"></a>00091 <span class="preprocessor"></span>
+<a name="l00092"></a>00092 <span class="preprocessor">#define FN_FUNC_FN_PIN(fnc)                                                 \</span>
+<a name="l00093"></a>00093 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) fnc(float2 v1, int2 *v2);   \</span>
+<a name="l00094"></a>00094 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) fnc(float3 v1, int3 *v2);   \</span>
+<a name="l00095"></a>00095 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) fnc(float4 v1, int4 *v2);</span>
+<a name="l00096"></a>00096 <span class="preprocessor"></span>
+<a name="l00097"></a>00097 <span class="preprocessor">#define FN_FUNC_FN_FN_FN(fnc)                   \</span>
+<a name="l00098"></a>00098 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) \</span>
+<a name="l00099"></a>00099 <span class="preprocessor">        fnc(float2 v1, float2 v2, float2 v3);   \</span>
+<a name="l00100"></a>00100 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) \</span>
+<a name="l00101"></a>00101 <span class="preprocessor">        fnc(float3 v1, float3 v2, float3 v3);   \</span>
+<a name="l00102"></a>00102 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) \</span>
+<a name="l00103"></a>00103 <span class="preprocessor">        fnc(float4 v1, float4 v2, float4 v3);</span>
+<a name="l00104"></a>00104 <span class="preprocessor"></span>
+<a name="l00105"></a>00105 <span class="preprocessor">#define FN_FUNC_FN_FN_PIN(fnc)                  \</span>
+<a name="l00106"></a>00106 <span class="preprocessor">_RS_RUNTIME float2 __attribute__((overloadable)) \</span>
+<a name="l00107"></a>00107 <span class="preprocessor">        fnc(float2 v1, float2 v2, int2 *v3);    \</span>
+<a name="l00108"></a>00108 <span class="preprocessor">_RS_RUNTIME float3 __attribute__((overloadable)) \</span>
+<a name="l00109"></a>00109 <span class="preprocessor">        fnc(float3 v1, float3 v2, int3 *v3);    \</span>
+<a name="l00110"></a>00110 <span class="preprocessor">_RS_RUNTIME float4 __attribute__((overloadable)) \</span>
+<a name="l00111"></a>00111 <span class="preprocessor">        fnc(float4 v1, float4 v2, int4 *v3);</span>
+<a name="l00112"></a>00112 <span class="preprocessor"></span>
+<a name="l00113"></a>00113 
+<a name="l00119"></a>00119 <span class="keyword">extern</span> <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">acos</a>(<span class="keywordtype">float</span>);
+<a name="l00120"></a>00120 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">acos</a>)
+<a name="l00121"></a>00121 
+<a name="l00127"></a>00127 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a6575106413ec72448439ef67f1309424">acosh</a>(<span class="keywordtype">float</span>);
+<a name="l00128"></a>00128 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a6575106413ec72448439ef67f1309424">acosh</a>)
+<a name="l00129"></a>00129 
+<a name="l00135"></a>00135 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a2c0c7c00815bd480fcda80d1144ac20d">acospi</a>(<span class="keywordtype">float</span> v);
+<a name="l00136"></a>00136 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a2c0c7c00815bd480fcda80d1144ac20d">acospi</a>)
+<a name="l00137"></a>00137 
+<a name="l00143"></a>00143 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a78b9d0583bd0699e2eac30d2a136817a">asin</a>(<span class="keywordtype">float</span>);
+<a name="l00144"></a>00144 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a78b9d0583bd0699e2eac30d2a136817a">asin</a>)
+<a name="l00145"></a>00145 
+<a name="l00151"></a>00151 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4e3fe465ed5541af53192c59c80af1a0">asinh</a>(<span class="keywordtype">float</span>);
+<a name="l00152"></a>00152 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a4e3fe465ed5541af53192c59c80af1a0">asinh</a>)
+<a name="l00153"></a>00153 
+<a name="l00154"></a>00154 
+<a name="l00160"></a>00160 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a679b63e86358fc962cb343eb6263496b">asinpi</a>(<span class="keywordtype">float</span> v);
+<a name="l00161"></a>00161 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a679b63e86358fc962cb343eb6263496b">asinpi</a>)
+<a name="l00162"></a>00162 
+<a name="l00168"></a>00168 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ab790c3a7df8fcbeab77f6c0e3b4dcada">atan</a>(<span class="keywordtype">float</span>);
+<a name="l00169"></a>00169 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ab790c3a7df8fcbeab77f6c0e3b4dcada">atan</a>)
+<a name="l00170"></a>00170 
+<a name="l00180"></a>00180 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#aaf4b636b09041878e1542054c73d81e9">atan2</a>(<span class="keywordtype">float</span> y, <span class="keywordtype">float</span> x);
+<a name="l00181"></a>00181 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#aaf4b636b09041878e1542054c73d81e9">atan2</a>)
+<a name="l00182"></a>00182 
+<a name="l00188"></a>00188 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a83bdf415cc561ff6237a124273d9fb0d">atanh</a>(<span class="keywordtype">float</span>);
+<a name="l00189"></a>00189 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a83bdf415cc561ff6237a124273d9fb0d">atanh</a>)
+<a name="l00190"></a>00190 
+<a name="l00196"></a>00196 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a420d4aaea0e53d7172845a21a1e648ea">atanpi</a>(<span class="keywordtype">float</span> v);
+<a name="l00197"></a>00197 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a420d4aaea0e53d7172845a21a1e648ea">atanpi</a>)
+<a name="l00198"></a>00198 
+<a name="l00208"></a>00208 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a9aed0a1613c86acf5e4c5ad3290a4745">atan2pi</a>(<span class="keywordtype">float</span> y, <span class="keywordtype">float</span> x);
+<a name="l00209"></a>00209 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a9aed0a1613c86acf5e4c5ad3290a4745">atan2pi</a>)
+<a name="l00210"></a>00210 
+<a name="l00211"></a>00211 
+<a name="l00217"></a>00217 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ae9d1787b55c2587478a24d96573225df">cbrt</a>(<span class="keywordtype">float</span>);
+<a name="l00218"></a>00218 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ae9d1787b55c2587478a24d96573225df">cbrt</a>)
+<a name="l00219"></a>00219 
+<a name="l00225"></a>00225 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#aa8fc6daff743a1b635ccbf9af83fe4e4">ceil</a>(<span class="keywordtype">float</span>);
+<a name="l00226"></a>00226 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#aa8fc6daff743a1b635ccbf9af83fe4e4">ceil</a>)
+<a name="l00227"></a>00227 
+<a name="l00237"></a>00237 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a29f2602d95aa7b3950e2b77b3e268f7e">copysign</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00238"></a>00238 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a29f2602d95aa7b3950e2b77b3e268f7e">copysign</a>)
+<a name="l00239"></a>00239 
+<a name="l00245"></a>00245 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">cos</a>(<span class="keywordtype">float</span>);
+<a name="l00246"></a>00246 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">cos</a>)
+<a name="l00247"></a>00247 
+<a name="l00253"></a>00253 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ac8d88d83182afd591401eaed101d9670">cosh</a>(<span class="keywordtype">float</span>);
+<a name="l00254"></a>00254 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ac8d88d83182afd591401eaed101d9670">cosh</a>)
+<a name="l00255"></a>00255 
+<a name="l00261"></a>00261 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a07b12188bd53c6b584274892f6abf425">cospi</a>(<span class="keywordtype">float</span> v);
+<a name="l00262"></a>00262 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a07b12188bd53c6b584274892f6abf425">cospi</a>)
+<a name="l00263"></a>00263 
+<a name="l00269"></a>00269 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a2e24dc8594e758b64c340153f67a533c">erfc</a>(<span class="keywordtype">float</span>);
+<a name="l00270"></a>00270 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a2e24dc8594e758b64c340153f67a533c">erfc</a>)
+<a name="l00271"></a>00271 
+<a name="l00277"></a>00277 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a139f102df651c25c26dd35d549173f57">erf</a>(<span class="keywordtype">float</span>);
+<a name="l00278"></a>00278 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a139f102df651c25c26dd35d549173f57">erf</a>)
+<a name="l00279"></a>00279 
+<a name="l00285"></a>00285 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a6d9aac64c2686961ca8f30e3c34fef36">exp</a>(<span class="keywordtype">float</span>);
+<a name="l00286"></a>00286 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a6d9aac64c2686961ca8f30e3c34fef36">exp</a>)
+<a name="l00287"></a>00287 
+<a name="l00293"></a>00293 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a39bca19ee2b1aa95144e58eb4a1e4f88">exp2</a>(<span class="keywordtype">float</span>);
+<a name="l00294"></a>00294 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a39bca19ee2b1aa95144e58eb4a1e4f88">exp2</a>)
+<a name="l00295"></a>00295 
+<a name="l00302"></a>00302 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a9243de1d67fcc847a89f95748d664b19">pow</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00303"></a>00303 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a9243de1d67fcc847a89f95748d664b19">pow</a>)
+<a name="l00304"></a>00304 
+<a name="l00310"></a>00310 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4b51589157c9ce600ea6156be51d8d18">exp10</a>(<span class="keywordtype">float</span> v);
+<a name="l00311"></a>00311 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a4b51589157c9ce600ea6156be51d8d18">exp10</a>)
+<a name="l00312"></a>00312 
+<a name="l00318"></a>00318 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a7996044b67be921a5e58e2fe76af66e2">expm1</a>(<span class="keywordtype">float</span>);
+<a name="l00319"></a>00319 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a7996044b67be921a5e58e2fe76af66e2">expm1</a>)
+<a name="l00320"></a>00320 
+<a name="l00326"></a>00326 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad6e897f1acae252ec0901e3b122992ea">fabs</a>(<span class="keywordtype">float</span>);
+<a name="l00327"></a>00327 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ad6e897f1acae252ec0901e3b122992ea">fabs</a>)
+<a name="l00328"></a>00328 
+<a name="l00335"></a>00335 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ae7a7bac0f4e244594078f87b42c8716a">fdim</a>(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>);
+<a name="l00336"></a>00336 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#ae7a7bac0f4e244594078f87b42c8716a">fdim</a>)
+<a name="l00337"></a>00337 
+<a name="l00343"></a>00343 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#aae2da38a7246378dff8014ec407a30c3">floor</a>(<span class="keywordtype">float</span>);
+<a name="l00344"></a>00344 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#aae2da38a7246378dff8014ec407a30c3">floor</a>)
+<a name="l00345"></a>00345 
+<a name="l00351"></a>00351 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ac42909daec463fe449743e70baf8360d">fma</a>(<span class="keywordtype">float</span> a, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> c);
+<a name="l00352"></a>00352 FN_FUNC_FN_FN_FN(<a class="code" href="rs__cl_8rsh.html#ac42909daec463fe449743e70baf8360d">fma</a>)
+<a name="l00353"></a>00353 
+<a name="l00361"></a>00361 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a60f2072d8a746e7fe05cd46dea0fefcc">fmax</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00362"></a>00362 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a60f2072d8a746e7fe05cd46dea0fefcc">fmax</a>);
+<a name="l00363"></a>00363 FN_FUNC_FN_F(fmax);
+<a name="l00364"></a>00364 
+<a name="l00371"></a>00371 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a1fd9d57c6c992866bf5161be2cf4c447">fmin</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00372"></a>00372 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a1fd9d57c6c992866bf5161be2cf4c447">fmin</a>);
+<a name="l00373"></a>00373 FN_FUNC_FN_F(fmin);
+<a name="l00374"></a>00374 
+<a name="l00380"></a>00380 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a31d5e179730ae44e1dbc74c1535f392e">fmod</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00381"></a>00381 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a31d5e179730ae44e1dbc74c1535f392e">fmod</a>)
+<a name="l00382"></a>00382 
+<a name="l00383"></a>00383 
+<a name="l00390"></a>00390 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ac5277212e0df309a0a7c908424f7b14b">fract</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">float</span> *iptr);
+<a name="l00391"></a>00391 FN_FUNC_FN_PFN(<a class="code" href="rs__cl_8rsh.html#ac5277212e0df309a0a7c908424f7b14b">fract</a>)
+<a name="l00392"></a>00392 
+<a name="l00399"></a>00399 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a778635fffed3cee8ab0800482ba53a30">frexp</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">int</span> *iptr);
+<a name="l00400"></a>00400 FN_FUNC_FN_PIN(<a class="code" href="rs__cl_8rsh.html#a778635fffed3cee8ab0800482ba53a30">frexp</a>)
+<a name="l00401"></a>00401 
+<a name="l00407"></a>00407 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a147f38d6e41f45de9b5e7c6f3dcac010">hypot</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00408"></a>00408 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a147f38d6e41f45de9b5e7c6f3dcac010">hypot</a>)
+<a name="l00409"></a>00409 
+<a name="l00415"></a>00415 extern <span class="keywordtype">int</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#aad9a8beba52acb77b1efeba432e6cc2c">ilogb</a>(<span class="keywordtype">float</span>);
+<a name="l00416"></a>00416 IN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#aad9a8beba52acb77b1efeba432e6cc2c">ilogb</a>)
+<a name="l00417"></a>00417 
+<a name="l00424"></a>00424 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">ldexp</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">int</span> y);
+<a name="l00425"></a>00425 FN_FUNC_FN_IN(<a class="code" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">ldexp</a>)
+<a name="l00426"></a>00426 FN_FUNC_FN_I(<a class="code" href="rs__cl_8rsh.html#a013bc1dcda984cbc608e123ed38491e6">ldexp</a>)
+<a name="l00427"></a>00427 
+<a name="l00433"></a>00433 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a3ff36f9b21927d6b4b58616e48fddcb4">lgamma</a>(<span class="keywordtype">float</span>);
+<a name="l00434"></a>00434 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a3ff36f9b21927d6b4b58616e48fddcb4">lgamma</a>)
+<a name="l00435"></a>00435 
+<a name="l00442"></a>00442 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a3ff36f9b21927d6b4b58616e48fddcb4">lgamma</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">int</span>* y);
+<a name="l00443"></a>00443 FN_FUNC_FN_PIN(<a class="code" href="rs__cl_8rsh.html#a3ff36f9b21927d6b4b58616e48fddcb4">lgamma</a>)
+<a name="l00444"></a>00444 
+<a name="l00450"></a>00450 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a3ff85f5f4b206ecf9ec9d128d7d18a08">log</a>(<span class="keywordtype">float</span>);
+<a name="l00451"></a>00451 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a3ff85f5f4b206ecf9ec9d128d7d18a08">log</a>)
+<a name="l00452"></a>00452 
+<a name="l00458"></a>00458 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af5c1bdba2a13aa2e2b0722287f6a919f">log10</a>(<span class="keywordtype">float</span>);
+<a name="l00459"></a>00459 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#af5c1bdba2a13aa2e2b0722287f6a919f">log10</a>)
+<a name="l00460"></a>00460 
+<a name="l00466"></a>00466 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a2fb571ae932f671ff3e9e97f2d3fabb7">log2</a>(<span class="keywordtype">float</span> v);
+<a name="l00467"></a>00467 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a2fb571ae932f671ff3e9e97f2d3fabb7">log2</a>)
+<a name="l00468"></a>00468 
+<a name="l00474"></a>00474 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ae10541ede49062ef7f977712c4878c1f">log1p</a>(<span class="keywordtype">float</span> v);
+<a name="l00475"></a>00475 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ae10541ede49062ef7f977712c4878c1f">log1p</a>)
+<a name="l00476"></a>00476 
+<a name="l00482"></a>00482 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a28742d6ce2f20a61f16ecc08ed499871">logb</a>(<span class="keywordtype">float</span>);
+<a name="l00483"></a>00483 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a28742d6ce2f20a61f16ecc08ed499871">logb</a>)
+<a name="l00484"></a>00484 
+<a name="l00490"></a>00490 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f9086698f1eb466ba2dccf7e331cdc3">mad</a>(<span class="keywordtype">float</span> a, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> c);
+<a name="l00491"></a>00491 FN_FUNC_FN_FN_FN(<a class="code" href="rs__cl_8rsh.html#a4f9086698f1eb466ba2dccf7e331cdc3">mad</a>)
+<a name="l00492"></a>00492 
+<a name="l00501"></a>00501 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a841633bcdcaeb6a514d9c6460f0adf2d">modf</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> *iret);
+<a name="l00502"></a>00502 FN_FUNC_FN_PFN(<a class="code" href="rs__cl_8rsh.html#a841633bcdcaeb6a514d9c6460f0adf2d">modf</a>);
+<a name="l00503"></a>00503 
+<a name="l00504"></a>00504 <span class="comment">//extern float __attribute__((overloadable)) nan(uint);</span>
+<a name="l00505"></a>00505 
+<a name="l00511"></a>00511 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#adb11df05fb9985595af0a7bd882bdeac">nextafter</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00512"></a>00512 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#adb11df05fb9985595af0a7bd882bdeac">nextafter</a>)
+<a name="l00513"></a>00513 
+<a name="l00519"></a>00519 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#afd46205452017b741abb2e17fc28557d">pown</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">int</span> p);
+<a name="l00520"></a>00520 FN_FUNC_FN_IN(<a class="code" href="rs__cl_8rsh.html#afd46205452017b741abb2e17fc28557d">pown</a>)
+<a name="l00521"></a>00521 
+<a name="l00528"></a>00528 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a3ff65421721ec8e6ce8d875a563d005f">powr</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">float</span> p);
+<a name="l00529"></a>00529 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a3ff65421721ec8e6ce8d875a563d005f">powr</a>)
+<a name="l00530"></a>00530 
+<a name="l00536"></a>00536 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a5188ac0e3af95b0956c6abeafb74fda9">remainder</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y);
+<a name="l00537"></a>00537 FN_FUNC_FN_FN(<a class="code" href="rs__cl_8rsh.html#a5188ac0e3af95b0956c6abeafb74fda9">remainder</a>)
+<a name="l00538"></a>00538 
+<a name="l00539"></a>00539 <span class="comment">// document once we know the precision of bionic</span>
+<a name="l00540"></a>00540 extern <span class="keywordtype">float</span> __attribute__((overloadable)) remquo(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>, <span class="keywordtype">int</span> *);
+<a name="l00541"></a>00541 FN_FUNC_FN_FN_PIN(remquo)
+<a name="l00542"></a>00542 
+<a name="l00548"></a>00548 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#adb0ffe344ae56ca7fc9083c1f2943e55">rint</a>(<span class="keywordtype">float</span>);
+<a name="l00549"></a>00549 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#adb0ffe344ae56ca7fc9083c1f2943e55">rint</a>)
+<a name="l00550"></a>00550 
+<a name="l00556"></a>00556 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af169e7e1c575b7c24c1834569223077f">rootn</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">int</span> n);
+<a name="l00557"></a>00557 FN_FUNC_FN_IN(<a class="code" href="rs__cl_8rsh.html#af169e7e1c575b7c24c1834569223077f">rootn</a>)
+<a name="l00558"></a>00558 
+<a name="l00564"></a>00564 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#aff4846ab5b947550814d5414a2c3626f">round</a>(<span class="keywordtype">float</span>);
+<a name="l00565"></a>00565 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#aff4846ab5b947550814d5414a2c3626f">round</a>)
+<a name="l00566"></a>00566 
+<a name="l00572"></a>00572 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">sqrt</a>(<span class="keywordtype">float</span>);
+<a name="l00573"></a>00573 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">sqrt</a>)
+<a name="l00574"></a>00574 
+<a name="l00581"></a>00581 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a5db00fde9e6bff693a38f3a37e7a1f70">rsqrt</a>(<span class="keywordtype">float</span> v);
+<a name="l00582"></a>00582 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a5db00fde9e6bff693a38f3a37e7a1f70">rsqrt</a>)
+<a name="l00583"></a>00583 
+<a name="l00590"></a>00590 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(<span class="keywordtype">float</span> v);
+<a name="l00591"></a>00591 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>)
+<a name="l00592"></a>00592 
+<a name="l00602"></a>00602 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a240f7c7c20b432a30dc660b5dd4cd320">sincos</a>(<span class="keywordtype">float</span> v, <span class="keywordtype">float</span> *cosptr);
+<a name="l00603"></a>00603 FN_FUNC_FN_PFN(<a class="code" href="rs__cl_8rsh.html#a240f7c7c20b432a30dc660b5dd4cd320">sincos</a>);
+<a name="l00604"></a>00604 
+<a name="l00610"></a>00610 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ae686e0cc567f7ee2b0a84706aa486e4a">sinh</a>(<span class="keywordtype">float</span>);
+<a name="l00611"></a>00611 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ae686e0cc567f7ee2b0a84706aa486e4a">sinh</a>)
+<a name="l00612"></a>00612 
+<a name="l00618"></a>00618 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4fe4fef049786e888526d6f37b912b0a">sinpi</a>(<span class="keywordtype">float</span> v);
+<a name="l00619"></a>00619 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a4fe4fef049786e888526d6f37b912b0a">sinpi</a>)
+<a name="l00620"></a>00620 
+<a name="l00627"></a>00627 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af12e245af8ff9bb72b5000e7c26cd8fe">tan</a>(<span class="keywordtype">float</span> v);
+<a name="l00628"></a>00628 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#af12e245af8ff9bb72b5000e7c26cd8fe">tan</a>)
+<a name="l00629"></a>00629 
+<a name="l00636"></a>00636 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#abc36e89ddb87ea78451d1c5921ddbd8d">tanh</a>(<span class="keywordtype">float</span>);
+<a name="l00637"></a>00637 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#abc36e89ddb87ea78451d1c5921ddbd8d">tanh</a>)
+<a name="l00638"></a>00638 
+<a name="l00644"></a>00644 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad8bfb083dd3979a305e594a0d6e581c4">tanpi</a>(<span class="keywordtype">float</span> v);
+<a name="l00645"></a>00645 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ad8bfb083dd3979a305e594a0d6e581c4">tanpi</a>)
+<a name="l00646"></a>00646 
+<a name="l00652"></a>00652 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ab9f4cbfd2470420ee302f28cf3de6dd0">tgamma</a>(<span class="keywordtype">float</span>);
+<a name="l00653"></a>00653 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ab9f4cbfd2470420ee302f28cf3de6dd0">tgamma</a>)
+<a name="l00654"></a>00654 
+<a name="l00660"></a>00660 extern <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad1a7c65693231219db1babeae1c41f15">trunc</a>(<span class="keywordtype">float</span>);
+<a name="l00661"></a>00661 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#ad1a7c65693231219db1babeae1c41f15">trunc</a>)
+<a name="l00662"></a>00662 
+<a name="l00663"></a>00663 
+<a name="l00664"></a>00664 <span class="preprocessor">#define XN_FUNC_YN(typeout, fnc, typein)                                \</span>
+<a name="l00665"></a>00665 <span class="preprocessor">extern typeout __attribute__((overloadable)) fnc(typein);               \</span>
+<a name="l00666"></a>00666 <span class="preprocessor">_RS_RUNTIME typeout##2 __attribute__((overloadable)) fnc(typein##2 v);   \</span>
+<a name="l00667"></a>00667 <span class="preprocessor">_RS_RUNTIME typeout##3 __attribute__((overloadable)) fnc(typein##3 v);   \</span>
+<a name="l00668"></a>00668 <span class="preprocessor">_RS_RUNTIME typeout##4 __attribute__((overloadable)) fnc(typein##4 v);</span>
+<a name="l00669"></a>00669 <span class="preprocessor"></span>
+<a name="l00670"></a>00670 <span class="preprocessor">#define UIN_FUNC_IN(fnc)          \</span>
+<a name="l00671"></a>00671 <span class="preprocessor">XN_FUNC_YN(uchar, fnc, char)      \</span>
+<a name="l00672"></a>00672 <span class="preprocessor">XN_FUNC_YN(ushort, fnc, short)    \</span>
+<a name="l00673"></a>00673 <span class="preprocessor">XN_FUNC_YN(uint, fnc, int)</span>
+<a name="l00674"></a>00674 <span class="preprocessor"></span>
+<a name="l00675"></a>00675 <span class="preprocessor">#define IN_FUNC_IN(fnc)           \</span>
+<a name="l00676"></a>00676 <span class="preprocessor">XN_FUNC_YN(uchar, fnc, uchar)     \</span>
+<a name="l00677"></a>00677 <span class="preprocessor">XN_FUNC_YN(char, fnc, char)       \</span>
+<a name="l00678"></a>00678 <span class="preprocessor">XN_FUNC_YN(ushort, fnc, ushort)   \</span>
+<a name="l00679"></a>00679 <span class="preprocessor">XN_FUNC_YN(short, fnc, short)     \</span>
+<a name="l00680"></a>00680 <span class="preprocessor">XN_FUNC_YN(uint, fnc, uint)       \</span>
+<a name="l00681"></a>00681 <span class="preprocessor">XN_FUNC_YN(int, fnc, int)</span>
+<a name="l00682"></a>00682 <span class="preprocessor"></span>
+<a name="l00683"></a>00683 
+<a name="l00684"></a>00684 <span class="preprocessor">#define XN_FUNC_XN_XN_BODY(type, fnc, body)         \</span>
+<a name="l00685"></a>00685 <span class="preprocessor">_RS_RUNTIME type __attribute__((overloadable))       \</span>
+<a name="l00686"></a>00686 <span class="preprocessor">        fnc(type v1, type v2);                      \</span>
+<a name="l00687"></a>00687 <span class="preprocessor">_RS_RUNTIME type##2 __attribute__((overloadable))    \</span>
+<a name="l00688"></a>00688 <span class="preprocessor">        fnc(type##2 v1, type##2 v2);                \</span>
+<a name="l00689"></a>00689 <span class="preprocessor">_RS_RUNTIME type##3 __attribute__((overloadable))    \</span>
+<a name="l00690"></a>00690 <span class="preprocessor">        fnc(type##3 v1, type##3 v2);                \</span>
+<a name="l00691"></a>00691 <span class="preprocessor">_RS_RUNTIME type##4 __attribute__((overloadable))    \</span>
+<a name="l00692"></a>00692 <span class="preprocessor">        fnc(type##4 v1, type##4 v2);</span>
+<a name="l00693"></a>00693 <span class="preprocessor"></span>
+<a name="l00694"></a>00694 <span class="preprocessor">#define IN_FUNC_IN_IN_BODY(fnc, body) \</span>
+<a name="l00695"></a>00695 <span class="preprocessor">XN_FUNC_XN_XN_BODY(uchar, fnc, body)  \</span>
+<a name="l00696"></a>00696 <span class="preprocessor">XN_FUNC_XN_XN_BODY(char, fnc, body)   \</span>
+<a name="l00697"></a>00697 <span class="preprocessor">XN_FUNC_XN_XN_BODY(ushort, fnc, body) \</span>
+<a name="l00698"></a>00698 <span class="preprocessor">XN_FUNC_XN_XN_BODY(short, fnc, body)  \</span>
+<a name="l00699"></a>00699 <span class="preprocessor">XN_FUNC_XN_XN_BODY(uint, fnc, body)   \</span>
+<a name="l00700"></a>00700 <span class="preprocessor">XN_FUNC_XN_XN_BODY(int, fnc, body)    \</span>
+<a name="l00701"></a>00701 <span class="preprocessor">XN_FUNC_XN_XN_BODY(float, fnc, body)</span>
+<a name="l00702"></a>00702 <span class="preprocessor"></span>
+<a name="l00703"></a>00703 UIN_FUNC_IN(abs)
+<a name="l00704"></a>00704 IN_FUNC_IN(clz)
+<a name="l00705"></a>00705 
+<a name="l00711"></a>00711 IN_FUNC_IN_IN_BODY(min, (v1 &lt; v2 ? v1 : v2))
+<a name="l00712"></a>00712 FN_FUNC_FN_F(min)
+<a name="l00713"></a>00713 
+<a name="l00719"></a>00719 IN_FUNC_IN_IN_BODY(max, (v1 &gt; v2 ? v1 : v2))
+<a name="l00720"></a>00720 FN_FUNC_FN_F(max)
+<a name="l00721"></a>00721 
+<a name="l00729"></a>00729 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<span class="keywordtype">float</span> amount, <span class="keywordtype">float</span> low, <span class="keywordtype">float</span> high);
+<a name="l00730"></a>00730 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> amount, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> low, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> high);
+<a name="l00731"></a>00731 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> amount, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> low, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> high);
+<a name="l00732"></a>00732 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> amount, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> low, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> high);
+<a name="l00733"></a>00733 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> amount, <span class="keywordtype">float</span> low, <span class="keywordtype">float</span> high);
+<a name="l00734"></a>00734 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> amount, <span class="keywordtype">float</span> low, <span class="keywordtype">float</span> high);
+<a name="l00735"></a>00735 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#ad4dab580aba6cf15539b407b9163dfde">clamp</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> amount, <span class="keywordtype">float</span> low, <span class="keywordtype">float</span> high);
+<a name="l00736"></a>00736 
+<a name="l00742"></a>00742 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">degrees</a>(<span class="keywordtype">float</span> <a class="code" href="rs__cl_8rsh.html#aaef2526c4d190ba6f7301b4e810917a7">radians</a>);
+<a name="l00743"></a>00743 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">degrees</a>)
+<a name="l00744"></a>00744 
+<a name="l00750"></a>00750 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<span class="keywordtype">float</span> start, <span class="keywordtype">float</span> stop, <span class="keywordtype">float</span> amount);
+<a name="l00751"></a>00751 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> start, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> stop, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> amount);
+<a name="l00752"></a>00752 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> start, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> stop, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> amount);
+<a name="l00753"></a>00753 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> start, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> stop, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> amount);
+<a name="l00754"></a>00754 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> start, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> stop, <span class="keywordtype">float</span> amount);
+<a name="l00755"></a>00755 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> start, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> stop, <span class="keywordtype">float</span> amount);
+<a name="l00756"></a>00756 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#af4c76d51368c8e330cb59ea5a0a2310e">mix</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> start, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> stop, <span class="keywordtype">float</span> amount);
+<a name="l00757"></a>00757 
+<a name="l00763"></a>00763 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) radians(<span class="keywordtype">float</span> <a class="code" href="rs__cl_8rsh.html#adc1b551193e66d8037daa1721df4d29c">degrees</a>);
+<a name="l00764"></a>00764 FN_FUNC_FN(radians)
+<a name="l00765"></a>00765 
+<a name="l00774"></a>00774 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<span class="keywordtype">float</span> edge, <span class="keywordtype">float</span> v);
+<a name="l00775"></a>00775 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> edge, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> v);
+<a name="l00776"></a>00776 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> edge, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> v);
+<a name="l00777"></a>00777 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> edge, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> v);
+<a name="l00778"></a>00778 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> edge, <span class="keywordtype">float</span> v);
+<a name="l00779"></a>00779 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> edge, <span class="keywordtype">float</span> v);
+<a name="l00780"></a>00780 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4f7ba6882099d16853d0415982121900">step</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> edge, <span class="keywordtype">float</span> v);
+<a name="l00781"></a>00781 
+<a name="l00782"></a>00782 <span class="comment">// not implemented</span>
+<a name="l00783"></a>00783 extern <span class="keywordtype">float</span> __attribute__((overloadable)) smoothstep(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>);
+<a name="l00784"></a>00784 extern <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable)) smoothstep(<a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a>, float2, float2);
+<a name="l00785"></a>00785 extern <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable)) smoothstep(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>, float3, float3);
+<a name="l00786"></a>00786 extern <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable)) smoothstep(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>, float4, float4);
+<a name="l00787"></a>00787 extern float2 __attribute__((overloadable)) smoothstep(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>, float2);
+<a name="l00788"></a>00788 extern float3 __attribute__((overloadable)) smoothstep(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>, float3);
+<a name="l00789"></a>00789 extern float4 __attribute__((overloadable)) smoothstep(<span class="keywordtype">float</span>, <span class="keywordtype">float</span>, float4);
+<a name="l00790"></a>00790 
+<a name="l00798"></a>00798 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a3e6d477a06dec7070f073eec9d8f420c">sign</a>(<span class="keywordtype">float</span> v);
+<a name="l00799"></a>00799 FN_FUNC_FN(<a class="code" href="rs__cl_8rsh.html#a3e6d477a06dec7070f073eec9d8f420c">sign</a>)
+<a name="l00800"></a>00800 
+<a name="l00806"></a>00806 _RS_RUNTIME float3 __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a0f7beb26bb4aa30535babd14492a7e90">cross</a>(float3 lhs, float3 rhs);
+<a name="l00807"></a>00807 _RS_RUNTIME float4 __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a0f7beb26bb4aa30535babd14492a7e90">cross</a>(float4 lhs, float4 rhs);
+<a name="l00808"></a>00808 
+<a name="l00814"></a>00814 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(<span class="keywordtype">float</span> lhs, <span class="keywordtype">float</span> rhs);
+<a name="l00815"></a>00815 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(float2 lhs, float2 rhs);
+<a name="l00816"></a>00816 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(float3 lhs, float3 rhs);
+<a name="l00817"></a>00817 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(float4 lhs, float4 rhs);
+<a name="l00818"></a>00818 
+<a name="l00824"></a>00824 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(<span class="keywordtype">float</span> v);
+<a name="l00825"></a>00825 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(float2 v);
+<a name="l00826"></a>00826 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(float3 v);
+<a name="l00827"></a>00827 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(float4 v);
+<a name="l00828"></a>00828 
+<a name="l00834"></a>00834 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">distance</a>(<span class="keywordtype">float</span> lhs, <span class="keywordtype">float</span> rhs);
+<a name="l00835"></a>00835 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">distance</a>(float2 lhs, float2 rhs);
+<a name="l00836"></a>00836 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">distance</a>(float3 lhs, float3 rhs);
+<a name="l00837"></a>00837 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a4488863373be92e113e9d24aa3d21e76">distance</a>(float4 lhs, float4 rhs);
+<a name="l00838"></a>00838 
+<a name="l00844"></a>00844 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">normalize</a>(<span class="keywordtype">float</span> v);
+<a name="l00845"></a>00845 _RS_RUNTIME float2 __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">normalize</a>(float2 v);
+<a name="l00846"></a>00846 _RS_RUNTIME float3 __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">normalize</a>(float3 v);
+<a name="l00847"></a>00847 _RS_RUNTIME float4 __attribute__((overloadable)) <a class="code" href="rs__cl_8rsh.html#a373e03e92a1b7f3fdea5ca4ca159d2a8">normalize</a>(float4 v);
+<a name="l00848"></a>00848 
+<a name="l00849"></a>00849 <span class="preprocessor">#undef CVT_FUNC</span>
+<a name="l00850"></a>00850 <span class="preprocessor"></span><span class="preprocessor">#undef CVT_FUNC_2</span>
+<a name="l00851"></a>00851 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN</span>
+<a name="l00852"></a>00852 <span class="preprocessor"></span><span class="preprocessor">#undef IN_FUNC_FN</span>
+<a name="l00853"></a>00853 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_FN</span>
+<a name="l00854"></a>00854 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_F</span>
+<a name="l00855"></a>00855 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_IN</span>
+<a name="l00856"></a>00856 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_I</span>
+<a name="l00857"></a>00857 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_PFN</span>
+<a name="l00858"></a>00858 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_PIN</span>
+<a name="l00859"></a>00859 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_FN_FN</span>
+<a name="l00860"></a>00860 <span class="preprocessor"></span><span class="preprocessor">#undef FN_FUNC_FN_FN_PIN</span>
+<a name="l00861"></a>00861 <span class="preprocessor"></span><span class="preprocessor">#undef XN_FUNC_YN</span>
+<a name="l00862"></a>00862 <span class="preprocessor"></span><span class="preprocessor">#undef UIN_FUNC_IN</span>
+<a name="l00863"></a>00863 <span class="preprocessor"></span><span class="preprocessor">#undef IN_FUNC_IN</span>
+<a name="l00864"></a>00864 <span class="preprocessor"></span><span class="preprocessor">#undef XN_FUNC_XN_XN_BODY</span>
+<a name="l00865"></a>00865 <span class="preprocessor"></span><span class="preprocessor">#undef IN_FUNC_IN_IN_BODY</span>
+<a name="l00866"></a>00866 <span class="preprocessor"></span>
+<a name="l00867"></a>00867 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__core_8rsh.html b/docs/html/reference/renderscript/rs__core_8rsh.html
new file mode 100644
index 0000000..5a32e19
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__core_8rsh.html
@@ -0,0 +1,306 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_core.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#nested-classes">Data Structures</a> &#124;
+<a href="#typedef-members">Typedefs</a> &#124;
+<a href="#enum-members">Enumerations</a> &#124;
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_core.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<div class="textblock"><code>#include &quot;<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__allocation_8rsh_source.html">rs_allocation.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__atomic_8rsh_source.html">rs_atomic.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__cl_8rsh_source.html">rs_cl.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__debug_8rsh_source.html">rs_debug.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__math_8rsh_source.html">rs_math.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__matrix_8rsh_source.html">rs_matrix.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__object_8rsh_source.html">rs_object.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>&quot;</code><br/>
+<code>#include &quot;<a class="el" href="rs__time_8rsh_source.html">rs_time.rsh</a>&quot;</code><br/>
+</div><table class="memberdecls">
+<tr><td colspan="2"><h2><a name="nested-classes"></a>
+Data Structures</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__script__call.html">rs_script_call</a></td></tr>
+<tr><td colspan="2"><h2><a name="typedef-members"></a>
+Typedefs</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="structrs__script__call.html">rs_script_call</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_script_call_t</a></td></tr>
+<tr><td colspan="2"><h2><a name="enum-members"></a>
+Enumerations</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_for_each_strategy</a> </td></tr>
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#a91cfbca99f87ef144bea2cdf1e8473ca">rsSendToClient</a> (int cmdID)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#a508003cadad2d37d41e2de7e9226f859">rsSendToClient</a> (int cmdID, const void *data, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#a6e4ff6388e8c6978ed17447214f2a2e2">rsSendToClientBlocking</a> (int cmdID)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#afc93b00be08f58512a6ab6a87feb9515">rsSendToClientBlocking</a> (int cmdID, const void *data, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a> (<a class="el" href="structrs__script.html">rs_script</a> script, <a class="el" href="structrs__allocation.html">rs_allocation</a> input, <a class="el" href="structrs__allocation.html">rs_allocation</a> output, const void *usrData, const <a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_script_call_t</a> *sc)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__core_8rsh.html#ae62dc9d507e0e62c064217c71cc94101">rsForEach</a> (<a class="el" href="structrs__script.html">rs_script</a> script, <a class="el" href="structrs__allocation.html">rs_allocation</a> input, <a class="el" href="structrs__allocation.html">rs_allocation</a> output, const void *usrData)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>todo-jsams </p>
+
+<p>Definition in file <a class="el" href="rs__core_8rsh_source.html">rs_core.rsh</a>.</p>
+</div><hr/><h2>Typedef Documentation</h2>
+<a class="anchor" id="ae8756b32e23445f287960b9d0ffb449c"></a><!-- doxytag: member="rs_core.rsh::rs_script_call_t" ref="ae8756b32e23445f287960b9d0ffb449c" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef struct <a class="el" href="structrs__script__call.html">rs_script_call</a>  <a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_script_call_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Structure to provide extra information to a rsForEach call. Primarly used to restrict the call to a subset of cells in the allocation. </p>
+
+</div>
+</div>
+<hr/><h2>Enumeration Type Documentation</h2>
+<a class="anchor" id="ae1755c901e8acb42510ad10b4e104746"></a><!-- doxytag: member="rs_core.rsh::rs_for_each_strategy" ref="ae1755c901e8acb42510ad10b4e104746" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">enum <a class="el" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_for_each_strategy</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Launch order hint for rsForEach calls. This provides a hint to the system to determine in which order the root function of the target is called with each cell of the allocation.</p>
+<p>This is a hint and implementations may not obey the order. </p>
+
+<p>Definition at line <a class="el" href="rs__core_8rsh_source.html#l00074">74</a> of file <a class="el" href="rs__core_8rsh_source.html">rs_core.rsh</a>.</p>
+
+</div>
+</div>
+<hr/><h2>Function Documentation</h2>
+<a class="anchor" id="a95ebbf7a8923193df144649c066daae6"></a><!-- doxytag: member="rs_core.rsh::rsForEach" ref="a95ebbf7a8923193df144649c066daae6" args="(rs_script script, rs_allocation input, rs_allocation output, const void *usrData, const rs_script_call_t *sc)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsForEach </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a>&#160;</td>
+          <td class="paramname"><em>script</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>input</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>output</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname"><em>usrData</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_script_call_t</a> *&#160;</td>
+          <td class="paramname"><em>sc</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Make a script to script call to launch work. One of the input or output is required to be a valid object. The input and output must be of the same dimensions. API 10-13</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">script</td><td>The target script to call </td></tr>
+    <tr><td class="paramname">input</td><td>The allocation to source data from </td></tr>
+    <tr><td class="paramname">output</td><td>the allocation to write date into </td></tr>
+    <tr><td class="paramname">usrData</td><td>The user definied params to pass to the root script. May be NULL. </td></tr>
+    <tr><td class="paramname">sc</td><td>Extra control infomation used to select a sub-region of the allocation to be processed or suggest a walking strategy. May be NULL. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ae62dc9d507e0e62c064217c71cc94101"></a><!-- doxytag: member="rs_core.rsh::rsForEach" ref="ae62dc9d507e0e62c064217c71cc94101" args="(rs_script script, rs_allocation input, rs_allocation output, const void *usrData)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsForEach </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a>&#160;</td>
+          <td class="paramname"><em>script</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>input</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>output</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname"><em>usrData</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a91cfbca99f87ef144bea2cdf1e8473ca"></a><!-- doxytag: member="rs_core.rsh::rsSendToClient" ref="a91cfbca99f87ef144bea2cdf1e8473ca" args="(int cmdID)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsSendToClient </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>cmdID</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Send a message back to the client. Will not block and returns true if the message was sendable and false if the fifo was full. A message ID is required. Data payload is optional. </p>
+
+</div>
+</div>
+<a class="anchor" id="a508003cadad2d37d41e2de7e9226f859"></a><!-- doxytag: member="rs_core.rsh::rsSendToClient" ref="a508003cadad2d37d41e2de7e9226f859" args="(int cmdID, const void *data, uint len)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsSendToClient </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>cmdID</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname"><em>data</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>len</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6e4ff6388e8c6978ed17447214f2a2e2"></a><!-- doxytag: member="rs_core.rsh::rsSendToClientBlocking" ref="a6e4ff6388e8c6978ed17447214f2a2e2" args="(int cmdID)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSendToClientBlocking </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>cmdID</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Send a message back to the client, blocking until the message is queued. A message ID is required. Data payload is optional. </p>
+
+</div>
+</div>
+<a class="anchor" id="afc93b00be08f58512a6ab6a87feb9515"></a><!-- doxytag: member="rs_core.rsh::rsSendToClientBlocking" ref="afc93b00be08f58512a6ab6a87feb9515" args="(int cmdID, const void *data, uint len)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSendToClientBlocking </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>cmdID</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname"><em>data</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>len</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__core_8rsh_source.html b/docs/html/reference/renderscript/rs__core_8rsh_source.html
new file mode 100644
index 0000000..fac83e0
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__core_8rsh_source.html
@@ -0,0 +1,125 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_core.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_core.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__core_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00024"></a>00024 <span class="preprocessor">#ifndef __RS_CORE_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="preprocessor">#define __RS_CORE_RSH__</span>
+<a name="l00026"></a>00026 <span class="preprocessor"></span>
+<a name="l00027"></a>00027 <span class="preprocessor">#define _RS_RUNTIME extern</span>
+<a name="l00028"></a>00028 <span class="preprocessor"></span>
+<a name="l00029"></a>00029 <span class="preprocessor">#include &quot;<a class="code" href="rs__types_8rsh.html">rs_types.rsh</a>&quot;</span>
+<a name="l00030"></a>00030 <span class="preprocessor">#include &quot;<a class="code" href="rs__allocation_8rsh.html" title="Allocation routines.">rs_allocation.rsh</a>&quot;</span>
+<a name="l00031"></a>00031 <span class="preprocessor">#include &quot;<a class="code" href="rs__atomic_8rsh.html" title="Atomic routines.">rs_atomic.rsh</a>&quot;</span>
+<a name="l00032"></a>00032 <span class="preprocessor">#include &quot;<a class="code" href="rs__cl_8rsh.html" title="Basic math functions.">rs_cl.rsh</a>&quot;</span>
+<a name="l00033"></a>00033 <span class="preprocessor">#include &quot;<a class="code" href="rs__debug_8rsh.html" title="Utility debugging routines.">rs_debug.rsh</a>&quot;</span>
+<a name="l00034"></a>00034 <span class="preprocessor">#include &quot;<a class="code" href="rs__math_8rsh.html">rs_math.rsh</a>&quot;</span>
+<a name="l00035"></a>00035 <span class="preprocessor">#include &quot;<a class="code" href="rs__matrix_8rsh.html" title="Matrix routines.">rs_matrix.rsh</a>&quot;</span>
+<a name="l00036"></a>00036 <span class="preprocessor">#include &quot;<a class="code" href="rs__object_8rsh.html" title="Object routines.">rs_object.rsh</a>&quot;</span>
+<a name="l00037"></a>00037 <span class="preprocessor">#include &quot;<a class="code" href="rs__quaternion_8rsh.html" title="Quaternion routines.">rs_quaternion.rsh</a>&quot;</span>
+<a name="l00038"></a>00038 <span class="preprocessor">#include &quot;<a class="code" href="rs__time_8rsh.html" title="Renderscript time routines.">rs_time.rsh</a>&quot;</span>
+<a name="l00039"></a>00039 
+<a name="l00040"></a>00040 
+<a name="l00041"></a>00041 
+<a name="l00047"></a>00047 <span class="keyword">extern</span> <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00048"></a>00048     <a class="code" href="rs__core_8rsh.html#a91cfbca99f87ef144bea2cdf1e8473ca">rsSendToClient</a>(<span class="keywordtype">int</span> cmdID);
+<a name="l00052"></a>00052 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00053"></a>00053     <a class="code" href="rs__core_8rsh.html#a91cfbca99f87ef144bea2cdf1e8473ca">rsSendToClient</a>(<span class="keywordtype">int</span> cmdID, const <span class="keywordtype">void</span> *data, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len);
+<a name="l00058"></a>00058 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00059"></a>00059     <a class="code" href="rs__core_8rsh.html#a6e4ff6388e8c6978ed17447214f2a2e2">rsSendToClientBlocking</a>(<span class="keywordtype">int</span> cmdID);
+<a name="l00063"></a>00063 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00064"></a>00064     <a class="code" href="rs__core_8rsh.html#a6e4ff6388e8c6978ed17447214f2a2e2">rsSendToClientBlocking</a>(<span class="keywordtype">int</span> cmdID, const <span class="keywordtype">void</span> *data, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len);
+<a name="l00065"></a>00065 
+<a name="l00066"></a>00066 
+<a name="l00074"></a><a class="code" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">00074</a> enum <a class="code" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_for_each_strategy</a> {
+<a name="l00075"></a>00075     RS_FOR_EACH_STRATEGY_SERIAL,
+<a name="l00076"></a>00076     RS_FOR_EACH_STRATEGY_DONT_CARE,
+<a name="l00077"></a>00077     RS_FOR_EACH_STRATEGY_DST_LINEAR,
+<a name="l00078"></a>00078     RS_FOR_EACH_STRATEGY_TILE_SMALL,
+<a name="l00079"></a>00079     RS_FOR_EACH_STRATEGY_TILE_MEDIUM,
+<a name="l00080"></a>00080     RS_FOR_EACH_STRATEGY_TILE_LARGE
+<a name="l00081"></a>00081 };
+<a name="l00082"></a>00082 
+<a name="l00083"></a>00083 
+<a name="l00088"></a><a class="code" href="structrs__script__call.html">00088</a> <span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structrs__script__call.html">rs_script_call</a> {
+<a name="l00089"></a>00089     <span class="keyword">enum</span> <a class="code" href="rs__core_8rsh.html#ae1755c901e8acb42510ad10b4e104746">rs_for_each_strategy</a> strategy;
+<a name="l00090"></a>00090     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> xStart;
+<a name="l00091"></a>00091     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> xEnd;
+<a name="l00092"></a>00092     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> yStart;
+<a name="l00093"></a>00093     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> yEnd;
+<a name="l00094"></a>00094     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> zStart;
+<a name="l00095"></a>00095     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> zEnd;
+<a name="l00096"></a>00096     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> arrayStart;
+<a name="l00097"></a>00097     <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> arrayEnd;
+<a name="l00098"></a>00098 } <a class="code" href="rs__core_8rsh.html#ae8756b32e23445f287960b9d0ffb449c">rs_script_call_t</a>;
+<a name="l00099"></a>00099 
+<a name="l00116"></a>00116 <span class="preprocessor">#if !defined(RS_VERSION) || (RS_VERSION &lt; 14)</span>
+<a name="l00117"></a>00117 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00118"></a>00118     <a class="code" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> script, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> input,
+<a name="l00119"></a>00119               <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> output, const <span class="keywordtype">void</span> * usrData,
+<a name="l00120"></a>00120               const <a class="code" href="structrs__script__call.html">rs_script_call_t</a> *sc);
+<a name="l00124"></a>00124 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00125"></a>00125     <a class="code" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> script, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> input,
+<a name="l00126"></a>00126               <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> output, const <span class="keywordtype">void</span> * usrData);
+<a name="l00127"></a>00127 <span class="preprocessor">#else</span>
+<a name="l00128"></a>00128 <span class="preprocessor"></span>
+<a name="l00147"></a>00147 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00148"></a>00148     <a class="code" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> script, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> input, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> output,
+<a name="l00149"></a>00149               const <span class="keywordtype">void</span> * usrData, <span class="keywordtype">size_t</span> usrDataLen, const <a class="code" href="structrs__script__call.html">rs_script_call_t</a> *);
+<a name="l00153"></a>00153 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00154"></a>00154     <a class="code" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> script, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> input, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> output,
+<a name="l00155"></a>00155               const <span class="keywordtype">void</span> * usrData, <span class="keywordtype">size_t</span> usrDataLen);
+<a name="l00159"></a>00159 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00160"></a>00160     <a class="code" href="rs__core_8rsh.html#a95ebbf7a8923193df144649c066daae6">rsForEach</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> script, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> input, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> output);
+<a name="l00161"></a>00161 <span class="preprocessor">#endif</span>
+<a name="l00162"></a>00162 <span class="preprocessor"></span>
+<a name="l00163"></a>00163 
+<a name="l00164"></a>00164 
+<a name="l00165"></a>00165 <span class="preprocessor">#undef _RS_RUNTIME</span>
+<a name="l00166"></a>00166 <span class="preprocessor"></span>
+<a name="l00167"></a>00167 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__debug_8rsh.html b/docs/html/reference/renderscript/rs__debug_8rsh.html
new file mode 100644
index 0000000..75ce9db
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__debug_8rsh.html
@@ -0,0 +1,459 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_debug.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_debug.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a> (const char *, float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#aebd4d3e687a397db1a817ca6d46aed29">rsDebug</a> (const char *, float, float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#ab1731408774f01186aff59b89c47fe32">rsDebug</a> (const char *, float, float, float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#a6bb20c16c9fcc613158ca8c6f0dd81bd">rsDebug</a> (const char *, float, float, float, float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#a0a59285be7204bde7b199c77578b6a42">rsDebug</a> (const char *, double)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#a47b07360e1df6885b3f2eb207408db2c">rsDebug</a> (const char *, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#aee885d367bb22f5c437dec486eafb75c">rsDebug</a> (const char *, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#ac611c53b945b0ced90fde98e3846be79">rsDebug</a> (const char *, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#ad8f8901db11563ddd7d655fed025047f">rsDebug</a> (const char *, int)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#a490b0f6af3cc2e0280e97f2d2c2da228">rsDebug</a> (const char *, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#aa75aa9faf7646ceeafeb19279416e9e8">rsDebug</a> (const char *, long)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#aa371f42b8d323a1a20d56461011fc664">rsDebug</a> (const char *, unsigned long)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__debug_8rsh.html#ab5a58069a9d914e413f52b0f9bd62a00">rsDebug</a> (const char *, const void *)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Utility debugging routines. </p>
+<p>Routines intended to be used during application developement. These should not be used in shipping applications. All print a string and value pair to the standard log. </p>
+
+<p>Definition in file <a class="el" href="rs__debug_8rsh_source.html">rs_debug.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="a9a86fd617111dee78b3179a293afb66c"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="a9a86fd617111dee78b3179a293afb66c" args="(const char *, float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="aebd4d3e687a397db1a817ca6d46aed29"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="aebd4d3e687a397db1a817ca6d46aed29" args="(const char *, float, float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="ab1731408774f01186aff59b89c47fe32"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="ab1731408774f01186aff59b89c47fe32" args="(const char *, float, float, float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6bb20c16c9fcc613158ca8c6f0dd81bd"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="a6bb20c16c9fcc613158ca8c6f0dd81bd" args="(const char *, float, float, float, float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="a0a59285be7204bde7b199c77578b6a42"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="a0a59285be7204bde7b199c77578b6a42" args="(const char *, double)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">double&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="a47b07360e1df6885b3f2eb207408db2c"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="a47b07360e1df6885b3f2eb207408db2c" args="(const char *, const rs_matrix4x4 *)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="aee885d367bb22f5c437dec486eafb75c"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="aee885d367bb22f5c437dec486eafb75c" args="(const char *, const rs_matrix3x3 *)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="ac611c53b945b0ced90fde98e3846be79"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="ac611c53b945b0ced90fde98e3846be79" args="(const char *, const rs_matrix2x2 *)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad8f8901db11563ddd7d655fed025047f"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="ad8f8901db11563ddd7d655fed025047f" args="(const char *, int)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="a490b0f6af3cc2e0280e97f2d2c2da228"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="a490b0f6af3cc2e0280e97f2d2c2da228" args="(const char *, uint)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa75aa9faf7646ceeafeb19279416e9e8"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="aa75aa9faf7646ceeafeb19279416e9e8" args="(const char *, long)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">long&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa371f42b8d323a1a20d56461011fc664"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="aa371f42b8d323a1a20d56461011fc664" args="(const char *, unsigned long)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">unsigned&#160;</td>
+          <td class="paramname"><em>long</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+<a class="anchor" id="ab5a58069a9d914e413f52b0f9bd62a00"></a><!-- doxytag: member="rs_debug.rsh::rsDebug" ref="ab5a58069a9d914e413f52b0f9bd62a00" args="(const char *, const void *)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsDebug </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const void *&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Debug function. Prints a string and value to the log. </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__debug_8rsh_source.html b/docs/html/reference/renderscript/rs__debug_8rsh_source.html
new file mode 100644
index 0000000..b06e99c
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__debug_8rsh_source.html
@@ -0,0 +1,94 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_debug.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_debug.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__debug_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00026"></a>00026 <span class="preprocessor">#ifndef __RS_DEBUG_RSH__</span>
+<a name="l00027"></a>00027 <span class="preprocessor"></span><span class="preprocessor">#define __RS_DEBUG_RSH__</span>
+<a name="l00028"></a>00028 <span class="preprocessor"></span>
+<a name="l00029"></a>00029 
+<a name="l00030"></a>00030 
+<a name="l00034"></a>00034 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00035"></a>00035     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">float</span>);
+<a name="l00039"></a>00039 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00040"></a>00040     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>);
+<a name="l00044"></a>00044 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00045"></a>00045     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>);
+<a name="l00049"></a>00049 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00050"></a>00050     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>, <span class="keywordtype">float</span>);
+<a name="l00054"></a>00054 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00055"></a>00055     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">double</span>);
+<a name="l00059"></a>00059 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00060"></a>00060     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *);
+<a name="l00064"></a>00064 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00065"></a>00065     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *);
+<a name="l00069"></a>00069 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00070"></a>00070     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *);
+<a name="l00074"></a>00074 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00075"></a>00075     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">int</span>);
+<a name="l00079"></a>00079 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00080"></a>00080     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>);
+<a name="l00084"></a>00084 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00085"></a>00085     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">long</span>);
+<a name="l00089"></a>00089 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00090"></a>00090     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>);
+<a name="l00094"></a>00094 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00095"></a>00095     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">long</span> <span class="keywordtype">long</span>);
+<a name="l00099"></a>00099 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00100"></a>00100     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <span class="keywordtype">long</span>);
+<a name="l00104"></a>00104 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00105"></a>00105     <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *, const <span class="keywordtype">void</span> *);
+<a name="l00106"></a>00106 <span class="preprocessor">#define RS_DEBUG(a) rsDebug(#a, a)</span>
+<a name="l00107"></a>00107 <span class="preprocessor"></span><span class="preprocessor">#define RS_DEBUG_MARKER rsDebug(__FILE__, __LINE__)</span>
+<a name="l00108"></a>00108 <span class="preprocessor"></span>
+<a name="l00109"></a>00109 
+<a name="l00113"></a>00113 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *s, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> v);
+<a name="l00117"></a>00117 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *s, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> v);
+<a name="l00121"></a>00121 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__debug_8rsh.html#a9a86fd617111dee78b3179a293afb66c">rsDebug</a>(const <span class="keywordtype">char</span> *s, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> v);
+<a name="l00122"></a>00122 
+<a name="l00123"></a>00123 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__graphics_8rsh.html b/docs/html/reference/renderscript/rs__graphics_8rsh.html
new file mode 100644
index 0000000..8a17b30
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__graphics_8rsh.html
@@ -0,0 +1,1347 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_graphics.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_graphics.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a9f8deb600729a83c39c5bcaba2152b9c">rsgBindProgramFragment</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> pf)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a34dfa6eddd7454fc1865222c5a022315">rsgBindProgramStore</a> (<a class="el" href="structrs__program__store.html">rs_program_store</a> ps)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a894e26d0d05d3ef99be65ddf98dd901c">rsgBindProgramVertex</a> (<a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> pv)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a391eb5535544f6312c724b910da6ec35">rsgBindProgramRaster</a> (<a class="el" href="structrs__program__raster.html">rs_program_raster</a> pr)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a4ade6c5acbf6acaa1c29a1aecc6e87d3">rsgBindSampler</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot, <a class="el" href="structrs__sampler.html">rs_sampler</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a1694eb5489bd3a444da921dbf16aeeb5">rsgBindTexture</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot, <a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a83a87d8efa3f26ed3f8fb25e49f29059">rsgProgramVertexLoadProjectionMatrix</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *proj)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a976b8594cccb4b94d7ce520b44d884e3">rsgProgramVertexLoadModelMatrix</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *model)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a377b7b394c4bf0881532b1241d4be168">rsgProgramVertexLoadTextureMatrix</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *tex)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a2b767d209b36ffcd2e0fc0cf6f4c5706">rsgProgramVertexGetProjectionMatrix</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *proj)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a35ac8c3759e25047e6a458c15520c887">rsgProgramFragmentConstantColor</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> pf, float r, float g, float b, float a)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a67f4ed1ca4bba27d5c952ada89cd0717">rsgGetWidth</a> (void)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a7e6565cd5d5e44f442a8bf8ba68f4681">rsgGetHeight</a> (void)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a647228d8e15da6ad67a97701d920dcac">rsgAllocationSyncAll</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a> alloc)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a80c51849bf12ec6c699c23c3fa3e6208">rsgDrawRect</a> (float x1, float y1, float x2, float y2, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#ad6953da0349e58547b08b8ce174ed3fc">rsgDrawQuad</a> (float x1, float y1, float z1, float x2, float y2, float z2, float x3, float y3, float z3, float x4, float y4, float z4)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#afb98a59bb9f878f0a09459567c269e64">rsgDrawQuadTexCoords</a> (float x1, float y1, float z1, float u1, float v1, float x2, float y2, float z2, float u2, float v2, float x3, float y3, float z3, float u3, float v3, float x4, float y4, float z4, float u4, float v4)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a07d15127330fa1dff6c99b0d7d14e65e">rsgDrawSpriteScreenspace</a> (float x, float y, float z, float w, float h)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rsgDrawMesh</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> ism)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a621abfc693fed028b5dc74826453142d">rsgDrawMesh</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> ism, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> primitiveIndex)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#ab2704a6d16e3d7983524d0a8413c1b8a">rsgDrawMesh</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> ism, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> primitiveIndex, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> start, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a147674fed92745fbb5c64a6300ca3c49">rsgClearColor</a> (float r, float g, float b, float a)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a4bedb06e8facd587e3eacd746fe3e727">rsgClearDepth</a> (float value)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#afaec82492762e62cad1ff53ada479b14">rsgDrawText</a> (const char *, int x, int y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#ac5e84fd253b4b1d2b0e11a7a0a7df945">rsgDrawText</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>, int x, int y)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#ae89effef281e92e2940055883ea366d4">rsgBindFont</a> (<a class="el" href="structrs__font.html">rs_font</a> font)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#abda8c344092ed6310c7a8f353a6df876">rsgFontColor</a> (float r, float g, float b, float a)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a5c599f4ea989f3d0616cbf8e983688c4">rsgMeasureText</a> (const char *, int *left, int *right, int *top, int *bottom)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a2abb920283b1dafa9059de488143a870">rsgMeasureText</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>, int *left, int *right, int *top, int *bottom)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rsgMeshComputeBoundingBox</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> mesh, float *minX, float *minY, float *minZ, float *maxX, float *maxY, float *maxZ)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static __inline__ void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__graphics_8rsh.html#a6058b6b6c8b94f96f03dc8bca6a2090b">rsgMeshComputeBoundingBox</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> mesh, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *bBoxMin, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *bBoxMax)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Renderscript graphics API. </p>
+<p>A set of graphics functions used by Renderscript. </p>
+
+<p>Definition in file <a class="el" href="rs__graphics_8rsh_source.html">rs_graphics.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="a647228d8e15da6ad67a97701d920dcac"></a><!-- doxytag: member="rs_graphics.rsh::rsgAllocationSyncAll" ref="a647228d8e15da6ad67a97701d920dcac" args="(rs_allocation alloc)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgAllocationSyncAll </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>alloc</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Sync the contents of an allocation from its SCRIPT memory space to its HW memory spaces.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">alloc</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ae89effef281e92e2940055883ea366d4"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindFont" ref="ae89effef281e92e2940055883ea366d4" args="(rs_font font)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindFont </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__font.html">rs_font</a>&#160;</td>
+          <td class="paramname"><em>font</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Binds the font object to be used for all subsequent font rendering calls </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">font</td><td>object to bind </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a9f8deb600729a83c39c5bcaba2152b9c"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindProgramFragment" ref="a9f8deb600729a83c39c5bcaba2152b9c" args="(rs_program_fragment pf)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindProgramFragment </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname"><em>pf</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Bind a new ProgramFragment to the rendering context.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">pf</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a391eb5535544f6312c724b910da6ec35"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindProgramRaster" ref="a391eb5535544f6312c724b910da6ec35" args="(rs_program_raster pr)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindProgramRaster </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__raster.html">rs_program_raster</a>&#160;</td>
+          <td class="paramname"><em>pr</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Bind a new ProgramRaster to the rendering context.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">pr</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a34dfa6eddd7454fc1865222c5a022315"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindProgramStore" ref="a34dfa6eddd7454fc1865222c5a022315" args="(rs_program_store ps)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindProgramStore </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__store.html">rs_program_store</a>&#160;</td>
+          <td class="paramname"><em>ps</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Bind a new ProgramStore to the rendering context.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">ps</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a894e26d0d05d3ef99be65ddf98dd901c"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindProgramVertex" ref="a894e26d0d05d3ef99be65ddf98dd901c" args="(rs_program_vertex pv)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindProgramVertex </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a>&#160;</td>
+          <td class="paramname"><em>pv</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Bind a new ProgramVertex to the rendering context.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">pv</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a4ade6c5acbf6acaa1c29a1aecc6e87d3"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindSampler" ref="a4ade6c5acbf6acaa1c29a1aecc6e87d3" args="(rs_program_fragment, uint slot, rs_sampler)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindSampler </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>slot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__sampler.html">rs_sampler</a>&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Bind a new Sampler object to a ProgramFragment. The sampler will operate on the texture bound at the matching slot.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">slot</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a1694eb5489bd3a444da921dbf16aeeb5"></a><!-- doxytag: member="rs_graphics.rsh::rsgBindTexture" ref="a1694eb5489bd3a444da921dbf16aeeb5" args="(rs_program_fragment, uint slot, rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgBindTexture </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>slot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>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 matching slot.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">slot</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a147674fed92745fbb5c64a6300ca3c49"></a><!-- doxytag: member="rs_graphics.rsh::rsgClearColor" ref="a147674fed92745fbb5c64a6300ca3c49" args="(float r, float g, float b, float a)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgClearColor </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>r</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>g</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Clears the rendering surface to the specified color.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">r</td><td></td></tr>
+    <tr><td class="paramname">g</td><td></td></tr>
+    <tr><td class="paramname">b</td><td></td></tr>
+    <tr><td class="paramname">a</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a4bedb06e8facd587e3eacd746fe3e727"></a><!-- doxytag: member="rs_graphics.rsh::rsgClearDepth" ref="a4bedb06e8facd587e3eacd746fe3e727" args="(float value)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgClearDepth </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>value</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Clears the depth suface to the specified value. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6f8b87c994810908fbe5e01f8f63f9af"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawMesh" ref="a6f8b87c994810908fbe5e01f8f63f9af" args="(rs_mesh ism)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawMesh </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>ism</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Draw a mesh using the current context state. The whole mesh is rendered.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">ism</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a621abfc693fed028b5dc74826453142d"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawMesh" ref="a621abfc693fed028b5dc74826453142d" args="(rs_mesh ism, uint primitiveIndex)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawMesh </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>ism</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>primitiveIndex</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Draw part of a mesh using the current context state. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">ism</td><td>mesh object to render </td></tr>
+    <tr><td class="paramname">primitiveIndex</td><td>for meshes that contain multiple primitive groups this parameter specifies the index of the group to draw. </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ab2704a6d16e3d7983524d0a8413c1b8a"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawMesh" ref="ab2704a6d16e3d7983524d0a8413c1b8a" args="(rs_mesh ism, uint primitiveIndex, uint start, uint len)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawMesh </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>ism</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>primitiveIndex</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>start</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>len</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Draw specified index range of part of a mesh using the current context state. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">ism</td><td>mesh object to render </td></tr>
+    <tr><td class="paramname">primitiveIndex</td><td>for meshes that contain multiple primitive groups this parameter specifies the index of the group to draw. </td></tr>
+    <tr><td class="paramname">start</td><td>starting index in the range </td></tr>
+    <tr><td class="paramname">len</td><td>number of indices to draw </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ad6953da0349e58547b08b8ce174ed3fc"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawQuad" ref="ad6953da0349e58547b08b8ce174ed3fc" args="(float x1, float y1, float z1, float x2, float y2, float z2, float x3, float y3, float z3, float x4, float y4, float z4)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawQuad </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z4</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Low performance utility function for drawing a simple quad. Not intended for drawing large quantities of geometry.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x1</td><td></td></tr>
+    <tr><td class="paramname">y1</td><td></td></tr>
+    <tr><td class="paramname">z1</td><td></td></tr>
+    <tr><td class="paramname">x2</td><td></td></tr>
+    <tr><td class="paramname">y2</td><td></td></tr>
+    <tr><td class="paramname">z2</td><td></td></tr>
+    <tr><td class="paramname">x3</td><td></td></tr>
+    <tr><td class="paramname">y3</td><td></td></tr>
+    <tr><td class="paramname">z3</td><td></td></tr>
+    <tr><td class="paramname">x4</td><td></td></tr>
+    <tr><td class="paramname">y4</td><td></td></tr>
+    <tr><td class="paramname">z4</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="afb98a59bb9f878f0a09459567c269e64"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawQuadTexCoords" ref="afb98a59bb9f878f0a09459567c269e64" args="(float x1, float y1, float z1, float u1, float v1, float x2, float y2, float z2, float u2, float v2, float x3, float y3, float z3, float u3, float v3, float x4, float y4, float z4, float u4, float v4)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawQuadTexCoords </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>u1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>u2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>u3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v3</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>u4</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v4</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Low performance utility function for drawing a textured quad. Not intended for drawing large quantities of geometry.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x1</td><td></td></tr>
+    <tr><td class="paramname">y1</td><td></td></tr>
+    <tr><td class="paramname">z1</td><td></td></tr>
+    <tr><td class="paramname">u1</td><td></td></tr>
+    <tr><td class="paramname">v1</td><td></td></tr>
+    <tr><td class="paramname">x2</td><td></td></tr>
+    <tr><td class="paramname">y2</td><td></td></tr>
+    <tr><td class="paramname">z2</td><td></td></tr>
+    <tr><td class="paramname">u2</td><td></td></tr>
+    <tr><td class="paramname">v2</td><td></td></tr>
+    <tr><td class="paramname">x3</td><td></td></tr>
+    <tr><td class="paramname">y3</td><td></td></tr>
+    <tr><td class="paramname">z3</td><td></td></tr>
+    <tr><td class="paramname">u3</td><td></td></tr>
+    <tr><td class="paramname">v3</td><td></td></tr>
+    <tr><td class="paramname">x4</td><td></td></tr>
+    <tr><td class="paramname">y4</td><td></td></tr>
+    <tr><td class="paramname">z4</td><td></td></tr>
+    <tr><td class="paramname">u4</td><td></td></tr>
+    <tr><td class="paramname">v4</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a80c51849bf12ec6c699c23c3fa3e6208"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawRect" ref="a80c51849bf12ec6c699c23c3fa3e6208" args="(float x1, float y1, float x2, float y2, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawRect </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y2</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Low performance utility function for drawing a simple rectangle. Not intended for drawing large quantities of geometry.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x1</td><td></td></tr>
+    <tr><td class="paramname">y1</td><td></td></tr>
+    <tr><td class="paramname">x2</td><td></td></tr>
+    <tr><td class="paramname">y2</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a07d15127330fa1dff6c99b0d7d14e65e"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawSpriteScreenspace" ref="a07d15127330fa1dff6c99b0d7d14e65e" args="(float x, float y, float z, float w, float h)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawSpriteScreenspace </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>w</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>h</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Low performance function for drawing rectangles in screenspace. This function uses the default passthough ProgramVertex. Any bound ProgramVertex is ignored. This function has considerable overhead and should not be used for drawing in shipping applications.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">w</td><td></td></tr>
+    <tr><td class="paramname">h</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="afaec82492762e62cad1ff53ada479b14"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawText" ref="afaec82492762e62cad1ff53ada479b14" args="(const char *, int x, int y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawText </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Draws text given a string and location </p>
+
+</div>
+</div>
+<a class="anchor" id="ac5e84fd253b4b1d2b0e11a7a0a7df945"></a><!-- doxytag: member="rs_graphics.rsh::rsgDrawText" ref="ac5e84fd253b4b1d2b0e11a7a0a7df945" args="(rs_allocation, int x, int y)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgDrawText </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>y</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="abda8c344092ed6310c7a8f353a6df876"></a><!-- doxytag: member="rs_graphics.rsh::rsgFontColor" ref="abda8c344092ed6310c7a8f353a6df876" args="(float r, float g, float b, float a)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgFontColor </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>r</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>g</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Sets the font color for all subsequent rendering calls </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">r</td><td>red component </td></tr>
+    <tr><td class="paramname">g</td><td>green component </td></tr>
+    <tr><td class="paramname">b</td><td>blue component </td></tr>
+    <tr><td class="paramname">a</td><td>alpha component </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a7e6565cd5d5e44f442a8bf8ba68f4681"></a><!-- doxytag: member="rs_graphics.rsh::rsgGetHeight" ref="a7e6565cd5d5e44f442a8bf8ba68f4681" args="(void)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> rsgGetHeight </td>
+          <td>(</td>
+          <td class="paramtype">void&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Get the height of the current rendering surface.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a67f4ed1ca4bba27d5c952ada89cd0717"></a><!-- doxytag: member="rs_graphics.rsh::rsgGetWidth" ref="a67f4ed1ca4bba27d5c952ada89cd0717" args="(void)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> rsgGetWidth </td>
+          <td>(</td>
+          <td class="paramtype">void&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Get the width of the current rendering surface.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uint </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a5c599f4ea989f3d0616cbf8e983688c4"></a><!-- doxytag: member="rs_graphics.rsh::rsgMeasureText" ref="a5c599f4ea989f3d0616cbf8e983688c4" args="(const char *, int *left, int *right, int *top, int *bottom)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgMeasureText </td>
+          <td>(</td>
+          <td class="paramtype">const char *&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>bottom</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the bounding box of the text relative to (0, 0) Any of left, right, top, bottom could be NULL </p>
+
+</div>
+</div>
+<a class="anchor" id="a2abb920283b1dafa9059de488143a870"></a><!-- doxytag: member="rs_graphics.rsh::rsgMeasureText" ref="a2abb920283b1dafa9059de488143a870" args="(rs_allocation, int *left, int *right, int *top, int *bottom)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgMeasureText </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname">, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int *&#160;</td>
+          <td class="paramname"><em>bottom</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a0978c54902dd1d60180f8dbb0b781105"></a><!-- doxytag: member="rs_graphics.rsh::rsgMeshComputeBoundingBox" ref="a0978c54902dd1d60180f8dbb0b781105" args="(rs_mesh mesh, float *minX, float *minY, float *minZ, float *maxX, float *maxY, float *maxZ)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgMeshComputeBoundingBox </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>mesh</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>minX</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>minY</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>minZ</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>maxX</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>maxY</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float *&#160;</td>
+          <td class="paramname"><em>maxZ</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Computes an axis aligned bounding box of a mesh object </p>
+
+</div>
+</div>
+<a class="anchor" id="a6058b6b6c8b94f96f03dc8bca6a2090b"></a><!-- doxytag: member="rs_graphics.rsh::rsgMeshComputeBoundingBox" ref="a6058b6b6c8b94f96f03dc8bca6a2090b" args="(rs_mesh mesh, float3 *bBoxMin, float3 *bBoxMax)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static __inline__ void rsgMeshComputeBoundingBox </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>mesh</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *&#160;</td>
+          <td class="paramname"><em>bBoxMin</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *&#160;</td>
+          <td class="paramname"><em>bBoxMax</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+<p>Definition at line <a class="el" href="rs__graphics_8rsh_source.html#l00380">380</a> of file <a class="el" href="rs__graphics_8rsh_source.html">rs_graphics.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a35ac8c3759e25047e6a458c15520c887"></a><!-- doxytag: member="rs_graphics.rsh::rsgProgramFragmentConstantColor" ref="a35ac8c3759e25047e6a458c15520c887" args="(rs_program_fragment pf, float r, float g, float b, float a)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgProgramFragmentConstantColor </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname"><em>pf</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>r</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>g</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the constant color for a fixed function emulation program.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">pf</td><td></td></tr>
+    <tr><td class="paramname">r</td><td></td></tr>
+    <tr><td class="paramname">g</td><td></td></tr>
+    <tr><td class="paramname">b</td><td></td></tr>
+    <tr><td class="paramname">a</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a2b767d209b36ffcd2e0fc0cf6f4c5706"></a><!-- doxytag: member="rs_graphics.rsh::rsgProgramVertexGetProjectionMatrix" ref="a2b767d209b36ffcd2e0fc0cf6f4c5706" args="(rs_matrix4x4 *proj)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgProgramVertexGetProjectionMatrix </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>proj</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Get the projection matrix for a currently bound fixed function vertex program. Calling this function with a custom vertex shader would result in an error. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">proj</td><td>matrix to store the current projection matrix into </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a976b8594cccb4b94d7ce520b44d884e3"></a><!-- doxytag: member="rs_graphics.rsh::rsgProgramVertexLoadModelMatrix" ref="a976b8594cccb4b94d7ce520b44d884e3" args="(const rs_matrix4x4 *model)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgProgramVertexLoadModelMatrix </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>model</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load the model matrix for a currently bound fixed function vertex program. Calling this function with a custom vertex shader would result in an error. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">model</td><td>model matrix </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a83a87d8efa3f26ed3f8fb25e49f29059"></a><!-- doxytag: member="rs_graphics.rsh::rsgProgramVertexLoadProjectionMatrix" ref="a83a87d8efa3f26ed3f8fb25e49f29059" args="(const rs_matrix4x4 *proj)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgProgramVertexLoadProjectionMatrix </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>proj</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load the projection matrix for a currently bound fixed function vertex program. Calling this function with a custom vertex shader would result in an error. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">proj</td><td>projection matrix </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a377b7b394c4bf0881532b1241d4be168"></a><!-- doxytag: member="rs_graphics.rsh::rsgProgramVertexLoadTextureMatrix" ref="a377b7b394c4bf0881532b1241d4be168" args="(const rs_matrix4x4 *tex)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsgProgramVertexLoadTextureMatrix </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>tex</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load the texture matrix for a currently bound fixed function vertex program. Calling this function with a custom vertex shader would result in an error. </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">tex</td><td>texture matrix </td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__graphics_8rsh_source.html b/docs/html/reference/renderscript/rs__graphics_8rsh_source.html
new file mode 100644
index 0000000..b9ce0b7
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__graphics_8rsh_source.html
@@ -0,0 +1,183 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_graphics.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_graphics.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__graphics_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_GRAPHICS_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_GRAPHICS_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="preprocessor">#if (defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14))</span>
+<a name="l00026"></a>00026 <span class="preprocessor"></span>
+<a name="l00031"></a>00031 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00032"></a>00032     rsgBindColorTarget(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> colorTarget, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot);
+<a name="l00033"></a>00033 
+<a name="l00038"></a>00038 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00039"></a>00039     rsgClearColorTarget(<a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot);
+<a name="l00040"></a>00040 
+<a name="l00045"></a>00045 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00046"></a>00046     rsgBindDepthTarget(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> depthTarget);
+<a name="l00047"></a>00047 
+<a name="l00051"></a>00051 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00052"></a>00052     rsgClearDepthTarget(<span class="keywordtype">void</span>);
+<a name="l00053"></a>00053 
+<a name="l00058"></a>00058 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00059"></a>00059     rsgClearAllRenderTargets(<span class="keywordtype">void</span>);
+<a name="l00060"></a>00060 
+<a name="l00064"></a>00064 extern <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> __attribute__((overloadable))
+<a name="l00065"></a>00065     rsgFinish(<span class="keywordtype">void</span>);
+<a name="l00066"></a>00066 
+<a name="l00067"></a>00067 <span class="preprocessor">#endif //defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14)</span>
+<a name="l00068"></a>00068 <span class="preprocessor"></span>
+<a name="l00074"></a>00074 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00075"></a>00075     <a class="code" href="rs__graphics_8rsh.html#a9f8deb600729a83c39c5bcaba2152b9c">rsgBindProgramFragment</a>(<a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a> pf);
+<a name="l00076"></a>00076 
+<a name="l00082"></a>00082 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00083"></a>00083     <a class="code" href="rs__graphics_8rsh.html#a34dfa6eddd7454fc1865222c5a022315">rsgBindProgramStore</a>(<a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a> ps);
+<a name="l00084"></a>00084 
+<a name="l00090"></a>00090 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00091"></a>00091     <a class="code" href="rs__graphics_8rsh.html#a894e26d0d05d3ef99be65ddf98dd901c">rsgBindProgramVertex</a>(<a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a> pv);
+<a name="l00092"></a>00092 
+<a name="l00098"></a>00098 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00099"></a>00099     <a class="code" href="rs__graphics_8rsh.html#a391eb5535544f6312c724b910da6ec35">rsgBindProgramRaster</a>(<a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a> pr);
+<a name="l00100"></a>00100 
+<a name="l00107"></a>00107 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00108"></a>00108     <a class="code" href="rs__graphics_8rsh.html#a4ade6c5acbf6acaa1c29a1aecc6e87d3">rsgBindSampler</a>(<a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a>, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot, <a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a>);
+<a name="l00109"></a>00109 
+<a name="l00118"></a>00118 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00119"></a>00119     <a class="code" href="rs__graphics_8rsh.html#a1694eb5489bd3a444da921dbf16aeeb5">rsgBindTexture</a>(rs_program_fragment, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> slot, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a>);
+<a name="l00120"></a>00120 
+<a name="l00127"></a>00127 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00128"></a>00128     <a class="code" href="rs__graphics_8rsh.html#a83a87d8efa3f26ed3f8fb25e49f29059">rsgProgramVertexLoadProjectionMatrix</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *proj);
+<a name="l00135"></a>00135 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00136"></a>00136     <a class="code" href="rs__graphics_8rsh.html#a976b8594cccb4b94d7ce520b44d884e3">rsgProgramVertexLoadModelMatrix</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *model);
+<a name="l00143"></a>00143 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00144"></a>00144     <a class="code" href="rs__graphics_8rsh.html#a377b7b394c4bf0881532b1241d4be168">rsgProgramVertexLoadTextureMatrix</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *tex);
+<a name="l00151"></a>00151 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00152"></a>00152     <a class="code" href="rs__graphics_8rsh.html#a2b767d209b36ffcd2e0fc0cf6f4c5706">rsgProgramVertexGetProjectionMatrix</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *proj);
+<a name="l00153"></a>00153 
+<a name="l00163"></a>00163 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00164"></a>00164     <a class="code" href="rs__graphics_8rsh.html#a35ac8c3759e25047e6a458c15520c887">rsgProgramFragmentConstantColor</a>(rs_program_fragment pf, <span class="keywordtype">float</span> r, <span class="keywordtype">float</span> g, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> a);
+<a name="l00165"></a>00165 
+<a name="l00171"></a>00171 extern <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> __attribute__((overloadable))
+<a name="l00172"></a>00172     <a class="code" href="rs__graphics_8rsh.html#a67f4ed1ca4bba27d5c952ada89cd0717">rsgGetWidth</a>(<span class="keywordtype">void</span>);
+<a name="l00173"></a>00173 
+<a name="l00179"></a>00179 extern <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> __attribute__((overloadable))
+<a name="l00180"></a>00180     <a class="code" href="rs__graphics_8rsh.html#a7e6565cd5d5e44f442a8bf8ba68f4681">rsgGetHeight</a>(<span class="keywordtype">void</span>);
+<a name="l00181"></a>00181 
+<a name="l00182"></a>00182 
+<a name="l00189"></a>00189 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00190"></a>00190     <a class="code" href="rs__graphics_8rsh.html#a647228d8e15da6ad67a97701d920dcac">rsgAllocationSyncAll</a>(rs_allocation alloc);
+<a name="l00191"></a>00191 
+<a name="l00192"></a>00192 <span class="preprocessor">#if (defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14))</span>
+<a name="l00193"></a>00193 <span class="preprocessor"></span>
+<a name="l00201"></a>00201 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00202"></a>00202     <a class="code" href="rs__graphics_8rsh.html#a647228d8e15da6ad67a97701d920dcac">rsgAllocationSyncAll</a>(rs_allocation alloc,
+<a name="l00203"></a>00203                          rs_allocation_usage_type source);
+<a name="l00204"></a>00204 
+<a name="l00205"></a>00205 <span class="preprocessor">#endif //defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14)</span>
+<a name="l00206"></a>00206 <span class="preprocessor"></span>
+<a name="l00217"></a>00217 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00218"></a>00218     <a class="code" href="rs__graphics_8rsh.html#a80c51849bf12ec6c699c23c3fa3e6208">rsgDrawRect</a>(<span class="keywordtype">float</span> x1, <span class="keywordtype">float</span> y1, <span class="keywordtype">float</span> x2, <span class="keywordtype">float</span> y2, <span class="keywordtype">float</span> z);
+<a name="l00219"></a>00219 
+<a name="l00237"></a>00237 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00238"></a>00238     <a class="code" href="rs__graphics_8rsh.html#ad6953da0349e58547b08b8ce174ed3fc">rsgDrawQuad</a>(<span class="keywordtype">float</span> x1, <span class="keywordtype">float</span> y1, <span class="keywordtype">float</span> z1,
+<a name="l00239"></a>00239                 <span class="keywordtype">float</span> x2, <span class="keywordtype">float</span> y2, <span class="keywordtype">float</span> z2,
+<a name="l00240"></a>00240                 <span class="keywordtype">float</span> x3, <span class="keywordtype">float</span> y3, <span class="keywordtype">float</span> z3,
+<a name="l00241"></a>00241                 <span class="keywordtype">float</span> x4, <span class="keywordtype">float</span> y4, <span class="keywordtype">float</span> z4);
+<a name="l00242"></a>00242 
+<a name="l00243"></a>00243 
+<a name="l00269"></a>00269 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00270"></a>00270     <a class="code" href="rs__graphics_8rsh.html#afb98a59bb9f878f0a09459567c269e64">rsgDrawQuadTexCoords</a>(<span class="keywordtype">float</span> x1, <span class="keywordtype">float</span> y1, <span class="keywordtype">float</span> z1, <span class="keywordtype">float</span> u1, <span class="keywordtype">float</span> v1,
+<a name="l00271"></a>00271                          <span class="keywordtype">float</span> x2, <span class="keywordtype">float</span> y2, <span class="keywordtype">float</span> z2, <span class="keywordtype">float</span> u2, <span class="keywordtype">float</span> v2,
+<a name="l00272"></a>00272                          <span class="keywordtype">float</span> x3, <span class="keywordtype">float</span> y3, <span class="keywordtype">float</span> z3, <span class="keywordtype">float</span> u3, <span class="keywordtype">float</span> v3,
+<a name="l00273"></a>00273                          <span class="keywordtype">float</span> x4, <span class="keywordtype">float</span> y4, <span class="keywordtype">float</span> z4, <span class="keywordtype">float</span> u4, <span class="keywordtype">float</span> v4);
+<a name="l00274"></a>00274 
+<a name="l00275"></a>00275 
+<a name="l00288"></a>00288 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00289"></a>00289     <a class="code" href="rs__graphics_8rsh.html#a07d15127330fa1dff6c99b0d7d14e65e">rsgDrawSpriteScreenspace</a>(<span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z, <span class="keywordtype">float</span> w, <span class="keywordtype">float</span> h);
+<a name="l00290"></a>00290 
+<a name="l00297"></a>00297 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00298"></a>00298     <a class="code" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rsgDrawMesh</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> ism);
+<a name="l00305"></a>00305 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00306"></a>00306     <a class="code" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rsgDrawMesh</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> ism, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> primitiveIndex);
+<a name="l00315"></a>00315 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00316"></a>00316     <a class="code" href="rs__graphics_8rsh.html#a6f8b87c994810908fbe5e01f8f63f9af">rsgDrawMesh</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> ism, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> primitiveIndex, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> start, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> len);
+<a name="l00317"></a>00317 
+<a name="l00326"></a>00326 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00327"></a>00327     <a class="code" href="rs__graphics_8rsh.html#a147674fed92745fbb5c64a6300ca3c49">rsgClearColor</a>(<span class="keywordtype">float</span> r, <span class="keywordtype">float</span> g, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> a);
+<a name="l00328"></a>00328 
+<a name="l00332"></a>00332 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00333"></a>00333     <a class="code" href="rs__graphics_8rsh.html#a4bedb06e8facd587e3eacd746fe3e727">rsgClearDepth</a>(<span class="keywordtype">float</span> value);
+<a name="l00337"></a>00337 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00338"></a>00338     <a class="code" href="rs__graphics_8rsh.html#afaec82492762e62cad1ff53ada479b14">rsgDrawText</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y);
+<a name="l00342"></a>00342 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00343"></a>00343     <a class="code" href="rs__graphics_8rsh.html#afaec82492762e62cad1ff53ada479b14">rsgDrawText</a>(rs_allocation, <span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y);
+<a name="l00348"></a>00348 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00349"></a>00349     <a class="code" href="rs__graphics_8rsh.html#ae89effef281e92e2940055883ea366d4">rsgBindFont</a>(<a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a> font);
+<a name="l00357"></a>00357 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00358"></a>00358     <a class="code" href="rs__graphics_8rsh.html#abda8c344092ed6310c7a8f353a6df876">rsgFontColor</a>(<span class="keywordtype">float</span> r, <span class="keywordtype">float</span> g, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> a);
+<a name="l00363"></a>00363 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00364"></a>00364     <a class="code" href="rs__graphics_8rsh.html#a5c599f4ea989f3d0616cbf8e983688c4">rsgMeasureText</a>(const <span class="keywordtype">char</span> *, <span class="keywordtype">int</span> *left, <span class="keywordtype">int</span> *right, <span class="keywordtype">int</span> *top, <span class="keywordtype">int</span> *bottom);
+<a name="l00368"></a>00368 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00369"></a>00369     <a class="code" href="rs__graphics_8rsh.html#a5c599f4ea989f3d0616cbf8e983688c4">rsgMeasureText</a>(rs_allocation, <span class="keywordtype">int</span> *left, <span class="keywordtype">int</span> *right, <span class="keywordtype">int</span> *top, <span class="keywordtype">int</span> *bottom);
+<a name="l00373"></a>00373 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00374"></a>00374     <a class="code" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rsgMeshComputeBoundingBox</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> mesh, <span class="keywordtype">float</span> *minX, <span class="keywordtype">float</span> *minY, <span class="keywordtype">float</span> *minZ,
+<a name="l00375"></a>00375                                                 <span class="keywordtype">float</span> *maxX, <span class="keywordtype">float</span> *maxY, <span class="keywordtype">float</span> *maxZ);
+<a name="l00379"></a>00379 __inline__ static <span class="keywordtype">void</span> __attribute__((overloadable, always_inline))
+<a name="l00380"></a><a class="code" href="rs__graphics_8rsh.html#a6058b6b6c8b94f96f03dc8bca6a2090b">00380</a> <a class="code" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rsgMeshComputeBoundingBox</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> mesh, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *bBoxMin, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> *bBoxMax) {
+<a name="l00381"></a>00381     <span class="keywordtype">float</span> x1, y1, z1, x2, y2, z2;
+<a name="l00382"></a>00382     <a class="code" href="rs__graphics_8rsh.html#a0978c54902dd1d60180f8dbb0b781105">rsgMeshComputeBoundingBox</a>(mesh, &amp;x1, &amp;y1, &amp;z1, &amp;x2, &amp;y2, &amp;z2);
+<a name="l00383"></a>00383     bBoxMin-&gt;x = x1;
+<a name="l00384"></a>00384     bBoxMin-&gt;y = y1;
+<a name="l00385"></a>00385     bBoxMin-&gt;z = z1;
+<a name="l00386"></a>00386     bBoxMax-&gt;x = x2;
+<a name="l00387"></a>00387     bBoxMax-&gt;y = y2;
+<a name="l00388"></a>00388     bBoxMax-&gt;z = z2;
+<a name="l00389"></a>00389 }
+<a name="l00390"></a>00390 
+<a name="l00391"></a>00391 <span class="preprocessor">#endif</span>
+<a name="l00392"></a>00392 <span class="preprocessor"></span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__math_8rsh.html b/docs/html/reference/renderscript/rs__math_8rsh.html
new file mode 100644
index 0000000..9415c3a
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__math_8rsh.html
@@ -0,0 +1,679 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_math.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_math.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#ad9106e5aae5b1248870f21061f36a1c9">rsRand</a> (int max_value)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a01edf1cf3cdaecb1629761b69148e189">rsRand</a> (int min_value, int max_value)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a03e898d810ac44158e7461b2b2b1c356">rsRand</a> (float max_value)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a84b2e7468314873b3aa02969e310d9e4">rsRand</a> (float min_value, float max_value)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#ac4f127e78da0849321c7f6db14f9e989">rsFrac</a> (float)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a> (<a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> amount, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> low, <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#ad36abebbb36ffc5312fb2ed8baf98d39">rsClamp</a> (int amount, int low, int high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a1f9e5f628fc42e8215e9dcf89ebc6897">rsClamp</a> (<a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> amount, <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> low, <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a7b8cb9e970171f866b75d333abf68d89">rsClamp</a> (short amount, short low, short high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a08fe0a967cc59f2ad831115557c86c50">rsClamp</a> (<a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> amount, <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> low, <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#ae31137028793c4aaf4df839535135837">rsClamp</a> (char amount, char low, char high)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static __inline__ void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a191f9c687c56322c18b7d71491602122">rsExtractFrustumPlanes</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *viewProj, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *left, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *right, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *top, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *bottom, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *near, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *far)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static __inline__ bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a7bbeaf44838e08e68d5cf3e3d7b0818c">rsIsSphereInFrustum</a> (<a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *sphere, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *left, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *right, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *top, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *bottom, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *near, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *far)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a628c8d13e3fe41fc860ad937184e4dcd">rsPackColorTo8888</a> (float r, float g, float b)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a84d08e07ec8421c51ee8bd57d5b8b33e">rsPackColorTo8888</a> (float r, float g, float b, float a)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a22e0be7e18b317a7453ebad4300934f6">rsPackColorTo8888</a> (<a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> color)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__math_8rsh.html#a26525a4f5093bd0f13191efe06127f4b">rsUnpackColor8888</a> (<a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> c)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>todo-jsams </p>
+
+<p>Definition in file <a class="el" href="rs__math_8rsh_source.html">rs_math.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="ad40f2fb8f416e2ab7d2879de3b3d885e"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="ad40f2fb8f416e2ab7d2879de3b3d885e" args="(uint amount, uint low, uint high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> rsClamp </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Clamp the value amount between low and high.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">amount</td><td>The value to clamp </td></tr>
+    <tr><td class="paramname">low</td><td></td></tr>
+    <tr><td class="paramname">high</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ad36abebbb36ffc5312fb2ed8baf98d39"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="ad36abebbb36ffc5312fb2ed8baf98d39" args="(int amount, int low, int high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME int rsClamp </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a1f9e5f628fc42e8215e9dcf89ebc6897"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="a1f9e5f628fc42e8215e9dcf89ebc6897" args="(ushort amount, ushort low, ushort high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> rsClamp </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a7b8cb9e970171f866b75d333abf68d89"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="a7b8cb9e970171f866b75d333abf68d89" args="(short amount, short low, short high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME short rsClamp </td>
+          <td>(</td>
+          <td class="paramtype">short&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">short&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">short&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a08fe0a967cc59f2ad831115557c86c50"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="a08fe0a967cc59f2ad831115557c86c50" args="(uchar amount, uchar low, uchar high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> rsClamp </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ae31137028793c4aaf4df839535135837"></a><!-- doxytag: member="rs_math.rsh::rsClamp" ref="ae31137028793c4aaf4df839535135837" args="(char amount, char low, char high)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME char rsClamp </td>
+          <td>(</td>
+          <td class="paramtype">char&#160;</td>
+          <td class="paramname"><em>amount</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">char&#160;</td>
+          <td class="paramname"><em>low</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">char&#160;</td>
+          <td class="paramname"><em>high</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a191f9c687c56322c18b7d71491602122"></a><!-- doxytag: member="rs_math.rsh::rsExtractFrustumPlanes" ref="a191f9c687c56322c18b7d71491602122" args="(const rs_matrix4x4 *viewProj, float4 *left, float4 *right, float4 *top, float4 *bottom, float4 *near, float4 *far)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static __inline__ void rsExtractFrustumPlanes </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>viewProj</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>bottom</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>near</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>far</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Computes 6 frustum planes from the view projection matrix </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">viewProj</td><td>matrix to extract planes from </td></tr>
+    <tr><td class="paramname">left</td><td>plane </td></tr>
+    <tr><td class="paramname">right</td><td>plane </td></tr>
+    <tr><td class="paramname">top</td><td>plane </td></tr>
+    <tr><td class="paramname">bottom</td><td>plane </td></tr>
+    <tr><td class="paramname">near</td><td>plane </td></tr>
+    <tr><td class="paramname">far</td><td>plane </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__math_8rsh_source.html#l00102">102</a> of file <a class="el" href="rs__math_8rsh_source.html">rs_math.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ac4f127e78da0849321c7f6db14f9e989"></a><!-- doxytag: member="rs_math.rsh::rsFrac" ref="ac4f127e78da0849321c7f6db14f9e989" args="(float)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float rsFrac </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the fractional part of a float </p>
+
+</div>
+</div>
+<a class="anchor" id="a7bbeaf44838e08e68d5cf3e3d7b0818c"></a><!-- doxytag: member="rs_math.rsh::rsIsSphereInFrustum" ref="a7bbeaf44838e08e68d5cf3e3d7b0818c" args="(float4 *sphere, float4 *left, float4 *right, float4 *top, float4 *bottom, float4 *near, float4 *far)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static __inline__ bool rsIsSphereInFrustum </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>sphere</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>bottom</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>near</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *&#160;</td>
+          <td class="paramname"><em>far</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Checks if a sphere is withing the 6 frustum planes </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">sphere</td><td>float4 representing the sphere </td></tr>
+    <tr><td class="paramname">left</td><td>plane </td></tr>
+    <tr><td class="paramname">right</td><td>plane </td></tr>
+    <tr><td class="paramname">top</td><td>plane </td></tr>
+    <tr><td class="paramname">bottom</td><td>plane </td></tr>
+    <tr><td class="paramname">near</td><td>plane </td></tr>
+    <tr><td class="paramname">far</td><td>plane </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__math_8rsh_source.html#l00162">162</a> of file <a class="el" href="rs__math_8rsh_source.html">rs_math.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a628c8d13e3fe41fc860ad937184e4dcd"></a><!-- doxytag: member="rs_math.rsh::rsPackColorTo8888" ref="a628c8d13e3fe41fc860ad937184e4dcd" args="(float r, float g, float b)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> rsPackColorTo8888 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>r</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>g</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Pack floating point (0-1) RGB values into a uchar4. The alpha component is set to 255 (1.0).</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">r</td><td></td></tr>
+    <tr><td class="paramname">g</td><td></td></tr>
+    <tr><td class="paramname">b</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uchar4 </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a84d08e07ec8421c51ee8bd57d5b8b33e"></a><!-- doxytag: member="rs_math.rsh::rsPackColorTo8888" ref="a84d08e07ec8421c51ee8bd57d5b8b33e" args="(float r, float g, float b, float a)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> rsPackColorTo8888 </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>r</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>g</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>b</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>a</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Pack floating point (0-1) RGBA values into a uchar4.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">r</td><td></td></tr>
+    <tr><td class="paramname">g</td><td></td></tr>
+    <tr><td class="paramname">b</td><td></td></tr>
+    <tr><td class="paramname">a</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uchar4 </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a22e0be7e18b317a7453ebad4300934f6"></a><!-- doxytag: member="rs_math.rsh::rsPackColorTo8888" ref="a22e0be7e18b317a7453ebad4300934f6" args="(float3 color)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> rsPackColorTo8888 </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td>
+          <td class="paramname"><em>color</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Pack floating point (0-1) RGB values into a uchar4. The alpha component is set to 255 (1.0).</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">color</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uchar4</dd></dl>
+<p>Pack floating point (0-1) RGBA values into a uchar4.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">color</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>uchar4 </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="ad9106e5aae5b1248870f21061f36a1c9"></a><!-- doxytag: member="rs_math.rsh::rsRand" ref="ad9106e5aae5b1248870f21061f36a1c9" args="(int max_value)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">int rsRand </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>max_value</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Return a random value between 0 (or min_value) and max_malue. </p>
+
+</div>
+</div>
+<a class="anchor" id="a01edf1cf3cdaecb1629761b69148e189"></a><!-- doxytag: member="rs_math.rsh::rsRand" ref="a01edf1cf3cdaecb1629761b69148e189" args="(int min_value, int max_value)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">int rsRand </td>
+          <td>(</td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>min_value</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">int&#160;</td>
+          <td class="paramname"><em>max_value</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a03e898d810ac44158e7461b2b2b1c356"></a><!-- doxytag: member="rs_math.rsh::rsRand" ref="a03e898d810ac44158e7461b2b2b1c356" args="(float max_value)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float rsRand </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>max_value</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a84b2e7468314873b3aa02969e310d9e4"></a><!-- doxytag: member="rs_math.rsh::rsRand" ref="a84b2e7468314873b3aa02969e310d9e4" args="(float min_value, float max_value)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float rsRand </td>
+          <td>(</td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>min_value</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>max_value</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a26525a4f5093bd0f13191efe06127f4b"></a><!-- doxytag: member="rs_math.rsh::rsUnpackColor8888" ref="a26525a4f5093bd0f13191efe06127f4b" args="(uchar4 c)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> rsUnpackColor8888 </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a>&#160;</td>
+          <td class="paramname"><em>c</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Unpack a uchar4 color to float4. The resulting float range will be (0-1).</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">c</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>float4 </dd></dl>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__math_8rsh_source.html b/docs/html/reference/renderscript/rs__math_8rsh_source.html
new file mode 100644
index 0000000..c056994
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__math_8rsh_source.html
@@ -0,0 +1,174 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_math.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_math.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__math_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00024"></a>00024 <span class="preprocessor">#ifndef __RS_MATH_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="preprocessor">#define __RS_MATH_RSH__</span>
+<a name="l00026"></a>00026 <span class="preprocessor"></span>
+<a name="l00027"></a>00027 
+<a name="l00031"></a>00031 <span class="keyword">extern</span> <span class="keywordtype">int</span> __attribute__((overloadable))
+<a name="l00032"></a>00032     <a class="code" href="rs__math_8rsh.html#ad9106e5aae5b1248870f21061f36a1c9">rsRand</a>(<span class="keywordtype">int</span> max_value);
+<a name="l00036"></a>00036 extern <span class="keywordtype">int</span> __attribute__((overloadable))
+<a name="l00037"></a>00037     <a class="code" href="rs__math_8rsh.html#ad9106e5aae5b1248870f21061f36a1c9">rsRand</a>(<span class="keywordtype">int</span> min_value, <span class="keywordtype">int</span> max_value);
+<a name="l00041"></a>00041 extern <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00042"></a>00042     <a class="code" href="rs__math_8rsh.html#ad9106e5aae5b1248870f21061f36a1c9">rsRand</a>(<span class="keywordtype">float</span> max_value);
+<a name="l00046"></a>00046 extern <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00047"></a>00047     <a class="code" href="rs__math_8rsh.html#ad9106e5aae5b1248870f21061f36a1c9">rsRand</a>(<span class="keywordtype">float</span> min_value, <span class="keywordtype">float</span> max_value);
+<a name="l00048"></a>00048 
+<a name="l00052"></a>00052 extern <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00053"></a>00053     <a class="code" href="rs__math_8rsh.html#ac4f127e78da0849321c7f6db14f9e989">rsFrac</a>(<span class="keywordtype">float</span>);
+<a name="l00054"></a>00054 
+<a name="l00055"></a>00055 
+<a name="l00057"></a>00057 <span class="comment">// int ops</span>
+<a name="l00059"></a>00059 <span class="comment"></span>
+<a name="l00067"></a>00067 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> amount, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> low, <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> high);
+<a name="l00068"></a>00068 
+<a name="l00072"></a>00072 _RS_RUNTIME <span class="keywordtype">int</span> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<span class="keywordtype">int</span> amount, <span class="keywordtype">int</span> low, <span class="keywordtype">int</span> high);
+<a name="l00076"></a>00076 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> amount, <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> low, <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> high);
+<a name="l00080"></a>00080 _RS_RUNTIME <span class="keywordtype">short</span> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<span class="keywordtype">short</span> amount, <span class="keywordtype">short</span> low, <span class="keywordtype">short</span> high);
+<a name="l00084"></a>00084 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> amount, <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> low, <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> high);
+<a name="l00088"></a>00088 _RS_RUNTIME <span class="keywordtype">char</span> __attribute__((overloadable, always_inline)) <a class="code" href="rs__math_8rsh.html#ad40f2fb8f416e2ab7d2879de3b3d885e">rsClamp</a>(<span class="keywordtype">char</span> amount, <span class="keywordtype">char</span> low, <span class="keywordtype">char</span> high);
+<a name="l00089"></a>00089 
+<a name="l00090"></a>00090 
+<a name="l00101"></a>00101 __inline__ static <span class="keywordtype">void</span> __attribute__((overloadable, always_inline))
+<a name="l00102"></a><a class="code" href="rs__math_8rsh.html#a191f9c687c56322c18b7d71491602122">00102</a> <a class="code" href="rs__math_8rsh.html#a191f9c687c56322c18b7d71491602122">rsExtractFrustumPlanes</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *viewProj,
+<a name="l00103"></a>00103                          <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *left, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *right,
+<a name="l00104"></a>00104                          <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *top, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *bottom,
+<a name="l00105"></a>00105                          <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *near, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *far) {
+<a name="l00106"></a>00106     <span class="comment">// x y z w = a b c d in the plane equation</span>
+<a name="l00107"></a>00107     left-&gt;x = viewProj-&gt;m[3] + viewProj-&gt;m[0];
+<a name="l00108"></a>00108     left-&gt;y = viewProj-&gt;m[7] + viewProj-&gt;m[4];
+<a name="l00109"></a>00109     left-&gt;z = viewProj-&gt;m[11] + viewProj-&gt;m[8];
+<a name="l00110"></a>00110     left-&gt;w = viewProj-&gt;m[15] + viewProj-&gt;m[12];
+<a name="l00111"></a>00111 
+<a name="l00112"></a>00112     right-&gt;x = viewProj-&gt;m[3] - viewProj-&gt;m[0];
+<a name="l00113"></a>00113     right-&gt;y = viewProj-&gt;m[7] - viewProj-&gt;m[4];
+<a name="l00114"></a>00114     right-&gt;z = viewProj-&gt;m[11] - viewProj-&gt;m[8];
+<a name="l00115"></a>00115     right-&gt;w = viewProj-&gt;m[15] - viewProj-&gt;m[12];
+<a name="l00116"></a>00116 
+<a name="l00117"></a>00117     top-&gt;x = viewProj-&gt;m[3] - viewProj-&gt;m[1];
+<a name="l00118"></a>00118     top-&gt;y = viewProj-&gt;m[7] - viewProj-&gt;m[5];
+<a name="l00119"></a>00119     top-&gt;z = viewProj-&gt;m[11] - viewProj-&gt;m[9];
+<a name="l00120"></a>00120     top-&gt;w = viewProj-&gt;m[15] - viewProj-&gt;m[13];
+<a name="l00121"></a>00121 
+<a name="l00122"></a>00122     bottom-&gt;x = viewProj-&gt;m[3] + viewProj-&gt;m[1];
+<a name="l00123"></a>00123     bottom-&gt;y = viewProj-&gt;m[7] + viewProj-&gt;m[5];
+<a name="l00124"></a>00124     bottom-&gt;z = viewProj-&gt;m[11] + viewProj-&gt;m[9];
+<a name="l00125"></a>00125     bottom-&gt;w = viewProj-&gt;m[15] + viewProj-&gt;m[13];
+<a name="l00126"></a>00126 
+<a name="l00127"></a>00127     near-&gt;x = viewProj-&gt;m[3] + viewProj-&gt;m[2];
+<a name="l00128"></a>00128     near-&gt;y = viewProj-&gt;m[7] + viewProj-&gt;m[6];
+<a name="l00129"></a>00129     near-&gt;z = viewProj-&gt;m[11] + viewProj-&gt;m[10];
+<a name="l00130"></a>00130     near-&gt;w = viewProj-&gt;m[15] + viewProj-&gt;m[14];
+<a name="l00131"></a>00131 
+<a name="l00132"></a>00132     far-&gt;x = viewProj-&gt;m[3] - viewProj-&gt;m[2];
+<a name="l00133"></a>00133     far-&gt;y = viewProj-&gt;m[7] - viewProj-&gt;m[6];
+<a name="l00134"></a>00134     far-&gt;z = viewProj-&gt;m[11] - viewProj-&gt;m[10];
+<a name="l00135"></a>00135     far-&gt;w = viewProj-&gt;m[15] - viewProj-&gt;m[14];
+<a name="l00136"></a>00136 
+<a name="l00137"></a>00137     <span class="keywordtype">float</span> len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(left-&gt;xyz);
+<a name="l00138"></a>00138     *left /= len;
+<a name="l00139"></a>00139     len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(right-&gt;xyz);
+<a name="l00140"></a>00140     *right /= len;
+<a name="l00141"></a>00141     len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(top-&gt;xyz);
+<a name="l00142"></a>00142     *top /= len;
+<a name="l00143"></a>00143     len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(bottom-&gt;xyz);
+<a name="l00144"></a>00144     *bottom /= len;
+<a name="l00145"></a>00145     len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(near-&gt;xyz);
+<a name="l00146"></a>00146     *near /= len;
+<a name="l00147"></a>00147     len = <a class="code" href="rs__cl_8rsh.html#a1a222b7879342279e1e0070d6afd9e18">length</a>(far-&gt;xyz);
+<a name="l00148"></a>00148     *far /= len;
+<a name="l00149"></a>00149 }
+<a name="l00150"></a>00150 
+<a name="l00161"></a>00161 __inline__ <span class="keyword">static</span> <span class="keywordtype">bool</span> __attribute__((overloadable, always_inline))
+<a name="l00162"></a><a class="code" href="rs__math_8rsh.html#a7bbeaf44838e08e68d5cf3e3d7b0818c">00162</a> <a class="code" href="rs__math_8rsh.html#a7bbeaf44838e08e68d5cf3e3d7b0818c">rsIsSphereInFrustum</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *sphere,
+<a name="l00163"></a>00163                       <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *left, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *right,
+<a name="l00164"></a>00164                       <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *top, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *bottom,
+<a name="l00165"></a>00165                       <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *near, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> *far) {
+<a name="l00166"></a>00166 
+<a name="l00167"></a>00167     <span class="keywordtype">float</span> distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(left-&gt;xyz, sphere-&gt;xyz) + left-&gt;w;
+<a name="l00168"></a>00168     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00169"></a>00169         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00170"></a>00170     }
+<a name="l00171"></a>00171     distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(right-&gt;xyz, sphere-&gt;xyz) + right-&gt;w;
+<a name="l00172"></a>00172     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00173"></a>00173         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00174"></a>00174     }
+<a name="l00175"></a>00175     distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(top-&gt;xyz, sphere-&gt;xyz) + top-&gt;w;
+<a name="l00176"></a>00176     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00177"></a>00177         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00178"></a>00178     }
+<a name="l00179"></a>00179     distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(bottom-&gt;xyz, sphere-&gt;xyz) + bottom-&gt;w;
+<a name="l00180"></a>00180     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00181"></a>00181         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00182"></a>00182     }
+<a name="l00183"></a>00183     distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(near-&gt;xyz, sphere-&gt;xyz) + near-&gt;w;
+<a name="l00184"></a>00184     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00185"></a>00185         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00186"></a>00186     }
+<a name="l00187"></a>00187     distToCenter = <a class="code" href="rs__cl_8rsh.html#a70544acaca578035a849eef67d62c449">dot</a>(far-&gt;xyz, sphere-&gt;xyz) + far-&gt;w;
+<a name="l00188"></a>00188     <span class="keywordflow">if</span> (distToCenter &lt; -sphere-&gt;w) {
+<a name="l00189"></a>00189         <span class="keywordflow">return</span> <span class="keyword">false</span>;
+<a name="l00190"></a>00190     }
+<a name="l00191"></a>00191     <span class="keywordflow">return</span> <span class="keyword">true</span>;
+<a name="l00192"></a>00192 }
+<a name="l00193"></a>00193 
+<a name="l00194"></a>00194 
+<a name="l00205"></a>00205 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> __attribute__((overloadable)) <a class="code" href="rs__math_8rsh.html#a628c8d13e3fe41fc860ad937184e4dcd">rsPackColorTo8888</a>(<span class="keywordtype">float</span> r, <span class="keywordtype">float</span> g, <span class="keywordtype">float</span> b);
+<a name="l00206"></a>00206 
+<a name="l00217"></a>00217 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> __attribute__((overloadable)) <a class="code" href="rs__math_8rsh.html#a628c8d13e3fe41fc860ad937184e4dcd">rsPackColorTo8888</a>(<span class="keywordtype">float</span> r, <span class="keywordtype">float</span> g, <span class="keywordtype">float</span> b, <span class="keywordtype">float</span> a);
+<a name="l00218"></a>00218 
+<a name="l00227"></a>00227 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> __attribute__((overloadable)) <a class="code" href="rs__math_8rsh.html#a628c8d13e3fe41fc860ad937184e4dcd">rsPackColorTo8888</a>(<a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> color);
+<a name="l00228"></a>00228 
+<a name="l00236"></a>00236 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> __attribute__((overloadable)) <a class="code" href="rs__math_8rsh.html#a628c8d13e3fe41fc860ad937184e4dcd">rsPackColorTo8888</a>(<a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> color);
+<a name="l00237"></a>00237 
+<a name="l00245"></a>00245 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> <a class="code" href="rs__math_8rsh.html#a26525a4f5093bd0f13191efe06127f4b">rsUnpackColor8888</a>(<a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> c);
+<a name="l00246"></a>00246 
+<a name="l00247"></a>00247 
+<a name="l00248"></a>00248 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__matrix_8rsh.html b/docs/html/reference/renderscript/rs__matrix_8rsh.html
new file mode 100644
index 0000000..b956301
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__matrix_8rsh.html
@@ -0,0 +1,1520 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_matrix.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_matrix.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a68e320f7fa2cc5a5b4759e3ab679ee10">rsMatrixSet</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ada106cb8f08e4b23930d7ba1a0ce5609">rsMatrixSet</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a086c4f1cd21500f8e332226af4f62001">rsMatrixSet</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#af1fb87eb02f166bb85ef10a92333bb49">rsMatrixGet</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a90b0548da8dbe1f643bcbac8466e5b72">rsMatrixGet</a> (const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a22a46174a3c72452c9f6c33403aeae19">rsMatrixGet</a> (const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5b31e83553efa947db2198674d5db043">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad2954a5ac11d2370227296be89e92471">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const float *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aef942535c5d56072125dcf5244970ea2">rsMatrixLoad</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const float *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aa327089f7ad9161d7372094163147005">rsMatrixLoad</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const float *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5239a3f5f2becd20507d0aa56638ba03">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a06176acb38405937cb94c835a712a3b3">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a3a3d0f0053720fb4afb3a3eb32e42a82">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a654e5abe095770979d740f7b55382bd0">rsMatrixLoad</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5f3697805c794c9c9f2f8cfdde4b9a44">rsMatrixLoad</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rsMatrixLoadRotate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float rot, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rsMatrixLoadScale</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rsMatrixLoadTranslate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *lhs, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a78872343ea6a5c1a846160ccdc4add52">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *lhs, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ae0dd4755c28fc896626ebf5dc784130f">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *lhs, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ae0b03aeec17ec8b9c5e75f8efb1bdc53">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ab1973ad3efa0ab2d53f466dd9fb190bb">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rsMatrixRotate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float rot, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rsMatrixScale</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float fovy, float aspect, float near, float far)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a47b6abbf32ffaf77bb13d96c3f05779f">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a716bc2d29b80eb25388aba3ba8845aef">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac52acb31a705f6c68af8bddea0e79969">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a49164dd4d4e85b212196028b1fd89dc1">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Matrix routines. </p>
+
+<p>Definition in file <a class="el" href="rs__matrix_8rsh_source.html">rs_matrix.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="af1fb87eb02f166bb85ef10a92333bb49"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="af1fb87eb02f166bb85ef10a92333bb49" args="(const rs_matrix4x4 *m, uint32_t row, uint32_t col)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Get one element of a matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td>The matrix to read from </td></tr>
+    <tr><td class="paramname">row</td><td></td></tr>
+    <tr><td class="paramname">col</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>float </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a90b0548da8dbe1f643bcbac8466e5b72"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="a90b0548da8dbe1f643bcbac8466e5b72" args="(const rs_matrix3x3 *m, uint32_t row, uint32_t col)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a22a46174a3c72452c9f6c33403aeae19"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="a22a46174a3c72452c9f6c33403aeae19" args="(const rs_matrix2x2 *m, uint32_t row, uint32_t col)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a00b6a334ba5ac94d84850f22ec9f4de5"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixInverse" ref="a00b6a334ba5ac94d84850f22ec9f4de5" args="(rs_matrix4x4 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsMatrixInverse </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns true if the matrix was successfully inversed</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ac05080d52da2d99a759ef34fa0655e82"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixInverseTranspose" ref="ac05080d52da2d99a759ef34fa0655e82" args="(rs_matrix4x4 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsMatrixInverseTranspose </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns true if the matrix was successfully inversed and transposed.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ac380c4117e047da494a74f0dad20fab3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="ac380c4117e047da494a74f0dad20fab3" args="(rs_matrix4x4 *m, const float *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const float *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the elements of a matrix from an array of floats.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="aef942535c5d56072125dcf5244970ea2"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="aef942535c5d56072125dcf5244970ea2" args="(rs_matrix3x3 *m, const float *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const float *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa327089f7ad9161d7372094163147005"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="aa327089f7ad9161d7372094163147005" args="(rs_matrix2x2 *m, const float *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const float *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a5239a3f5f2becd20507d0aa56638ba03"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a5239a3f5f2becd20507d0aa56638ba03" args="(rs_matrix4x4 *m, const rs_matrix4x4 *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a06176acb38405937cb94c835a712a3b3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a06176acb38405937cb94c835a712a3b3" args="(rs_matrix4x4 *m, const rs_matrix3x3 *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a3a3d0f0053720fb4afb3a3eb32e42a82"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a3a3d0f0053720fb4afb3a3eb32e42a82" args="(rs_matrix4x4 *m, const rs_matrix2x2 *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the elements of a matrix from another matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a654e5abe095770979d740f7b55382bd0"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a654e5abe095770979d740f7b55382bd0" args="(rs_matrix3x3 *m, const rs_matrix3x3 *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a5f3697805c794c9c9f2f8cfdde4b9a44"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a5f3697805c794c9c9f2f8cfdde4b9a44" args="(rs_matrix2x2 *m, const rs_matrix2x2 *v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoad </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad25760aaf01e95d0055237afab41bbb3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadFrustum" ref="ad25760aaf01e95d0055237afab41bbb3" args="(rs_matrix4x4 *m, float left, float right, float bottom, float top, float near, float far)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadFrustum </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>bottom</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>near</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>far</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load an Frustum projection matrix constructed from the 6 planes</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">left</td><td></td></tr>
+    <tr><td class="paramname">right</td><td></td></tr>
+    <tr><td class="paramname">bottom</td><td></td></tr>
+    <tr><td class="paramname">top</td><td></td></tr>
+    <tr><td class="paramname">near</td><td></td></tr>
+    <tr><td class="paramname">far</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a0ffd9de971cf10d0a663ff565be8d3cc"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="a0ffd9de971cf10d0a663ff565be8d3cc" args="(rs_matrix4x4 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadIdentity </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the elements of a matrix to the identity matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a5b31e83553efa947db2198674d5db043"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="a5b31e83553efa947db2198674d5db043" args="(rs_matrix3x3 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadIdentity </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad2954a5ac11d2370227296be89e92471"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="ad2954a5ac11d2370227296be89e92471" args="(rs_matrix2x2 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadIdentity </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a79f14c4c0f5ecc1bbd0bf54da8b653ef"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="a79f14c4c0f5ecc1bbd0bf54da8b653ef" args="(rs_matrix4x4 *m, const rs_matrix4x4 *lhs, const rs_matrix4x4 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiply two matrix (lhs, rhs) and place the result in m.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">lhs</td><td></td></tr>
+    <tr><td class="paramname">rhs</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a78872343ea6a5c1a846160ccdc4add52"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="a78872343ea6a5c1a846160ccdc4add52" args="(rs_matrix3x3 *m, const rs_matrix3x3 *lhs, const rs_matrix3x3 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ae0dd4755c28fc896626ebf5dc784130f"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="ae0dd4755c28fc896626ebf5dc784130f" args="(rs_matrix2x2 *m, const rs_matrix2x2 *lhs, const rs_matrix2x2 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>lhs</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4c59884a0e534dbbcdc5655842732d43"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadOrtho" ref="a4c59884a0e534dbbcdc5655842732d43" args="(rs_matrix4x4 *m, float left, float right, float bottom, float top, float near, float far)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadOrtho </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>left</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>right</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>bottom</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>top</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>near</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>far</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load an Ortho projection matrix constructed from the 6 planes</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">left</td><td></td></tr>
+    <tr><td class="paramname">right</td><td></td></tr>
+    <tr><td class="paramname">bottom</td><td></td></tr>
+    <tr><td class="paramname">top</td><td></td></tr>
+    <tr><td class="paramname">near</td><td></td></tr>
+    <tr><td class="paramname">far</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="aa404c34d7478f2921f7415d2da95d02b"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadPerspective" ref="aa404c34d7478f2921f7415d2da95d02b" args="(rs_matrix4x4 *m, float fovy, float aspect, float near, float far)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadPerspective </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>fovy</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>aspect</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>near</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>far</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load an perspective projection matrix constructed from the 6 planes</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">fovy</td><td>Field of view, in degrees along the Y axis. </td></tr>
+    <tr><td class="paramname">aspect</td><td>Ratio of x / y. </td></tr>
+    <tr><td class="paramname">near</td><td></td></tr>
+    <tr><td class="paramname">far</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a268032f3ac6d766b1d7fe72a6cb50464"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadRotate" ref="a268032f3ac6d766b1d7fe72a6cb50464" args="(rs_matrix4x4 *m, float rot, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadRotate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load a rotation matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">rot</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="acaf51d1f9ad5041ce01fbf8b7c5923fd"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadScale" ref="acaf51d1f9ad5041ce01fbf8b7c5923fd" args="(rs_matrix4x4 *m, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadScale </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load a scale matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a1b521c8a3d1260fa732cbf0a71af0e74"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadTranslate" ref="a1b521c8a3d1260fa732cbf0a71af0e74" args="(rs_matrix4x4 *m, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixLoadTranslate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Load a translation matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a97953ab2606900a839e5816c619abe66"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a97953ab2606900a839e5816c619abe66" args="(rs_matrix4x4 *m, const rs_matrix4x4 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiply the matrix m by rhs and place the result back into m.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td>(lhs) </td></tr>
+    <tr><td class="paramname">rhs</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ae0b03aeec17ec8b9c5e75f8efb1bdc53"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="ae0b03aeec17ec8b9c5e75f8efb1bdc53" args="(rs_matrix3x3 *m, const rs_matrix3x3 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ab1973ad3efa0ab2d53f466dd9fb190bb"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="ab1973ad3efa0ab2d53f466dd9fb190bb" args="(rs_matrix2x2 *m, const rs_matrix2x2 *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a47b6abbf32ffaf77bb13d96c3f05779f"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a47b6abbf32ffaf77bb13d96c3f05779f" args="(rs_matrix4x4 *m, float4 in)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td>
+          <td class="paramname"><em>in</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiply a vector by a matrix and return the result vector. API version 10-13</p>
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a716bc2d29b80eb25388aba3ba8845aef"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a716bc2d29b80eb25388aba3ba8845aef" args="(rs_matrix3x3 *m, float3 in)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td>
+          <td class="paramname"><em>in</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4d9a8bb7c3f5d67b14fa349bdd531d13"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a4d9a8bb7c3f5d67b14fa349bdd531d13" args="(rs_matrix2x2 *m, float2 in)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> rsMatrixMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a>&#160;</td>
+          <td class="paramname"><em>in</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad5ed05ca4880397fb29615e3c6798de1"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixRotate" ref="ad5ed05ca4880397fb29615e3c6798de1" args="(rs_matrix4x4 *m, float rot, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixRotate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiple matrix m with a rotation matrix</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">rot</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a94cc6b22bd1a6c07a9a1c1d21afb392c"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixScale" ref="a94cc6b22bd1a6c07a9a1c1d21afb392c" args="(rs_matrix4x4 *m, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixScale </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiple matrix m with a scale matrix</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a68e320f7fa2cc5a5b4759e3ab679ee10"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="a68e320f7fa2cc5a5b4759e3ab679ee10" args="(rs_matrix4x4 *m, uint32_t row, uint32_t col, float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set one element of a matrix.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td>The matrix to be set </td></tr>
+    <tr><td class="paramname">row</td><td></td></tr>
+    <tr><td class="paramname">col</td><td></td></tr>
+    <tr><td class="paramname">v</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>void </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="ada106cb8f08e4b23930d7ba1a0ce5609"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="ada106cb8f08e4b23930d7ba1a0ce5609" args="(rs_matrix3x3 *m, uint32_t row, uint32_t col, float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a086c4f1cd21500f8e332226af4f62001"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="a086c4f1cd21500f8e332226af4f62001" args="(rs_matrix2x2 *m, uint32_t row, uint32_t col, float v)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>row</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
+          <td class="paramname"><em>col</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>v</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4df5f9b5bb6044f3c3426f2f58b94405"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranslate" ref="a4df5f9b5bb6044f3c3426f2f58b94405" args="(rs_matrix4x4 *m, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixTranslate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiple matrix m with a translation matrix</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">x</td><td></td></tr>
+    <tr><td class="paramname">y</td><td></td></tr>
+    <tr><td class="paramname">z</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="a88095c70f1550c760844b3e32e41a31a"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="a88095c70f1550c760844b3e32e41a31a" args="(rs_matrix4x4 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixTranspose </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Transpose the matrix m.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ac52acb31a705f6c68af8bddea0e79969"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="ac52acb31a705f6c68af8bddea0e79969" args="(rs_matrix3x3 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixTranspose </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a49164dd4d4e85b212196028b1fd89dc1"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="a49164dd4d4e85b212196028b1fd89dc1" args="(rs_matrix2x2 *m)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsMatrixTranspose </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramname"><em>m</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__matrix_8rsh_source.html b/docs/html/reference/renderscript/rs__matrix_8rsh_source.html
new file mode 100644
index 0000000..531a3e3
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__matrix_8rsh_source.html
@@ -0,0 +1,173 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_matrix.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_matrix.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__matrix_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_MATRIX_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_MATRIX_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00036"></a>00036 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00037"></a>00037 <a class="code" href="rs__matrix_8rsh.html#a68e320f7fa2cc5a5b4759e3ab679ee10">rsMatrixSet</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
+<a name="l00041"></a>00041 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00042"></a>00042 <a class="code" href="rs__matrix_8rsh.html#a68e320f7fa2cc5a5b4759e3ab679ee10">rsMatrixSet</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
+<a name="l00046"></a>00046 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00047"></a>00047 <a class="code" href="rs__matrix_8rsh.html#a68e320f7fa2cc5a5b4759e3ab679ee10">rsMatrixSet</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
+<a name="l00048"></a>00048 
+<a name="l00058"></a>00058 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00059"></a>00059 <a class="code" href="rs__matrix_8rsh.html#af1fb87eb02f166bb85ef10a92333bb49">rsMatrixGet</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
+<a name="l00063"></a>00063 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00064"></a>00064 <a class="code" href="rs__matrix_8rsh.html#af1fb87eb02f166bb85ef10a92333bb49">rsMatrixGet</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
+<a name="l00068"></a>00068 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00069"></a>00069 <a class="code" href="rs__matrix_8rsh.html#af1fb87eb02f166bb85ef10a92333bb49">rsMatrixGet</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
+<a name="l00070"></a>00070 
+<a name="l00076"></a>00076 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00080"></a>00080 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
+<a name="l00084"></a>00084 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
+<a name="l00085"></a>00085 
+<a name="l00091"></a>00091 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00095"></a>00095 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00099"></a>00099 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00103"></a>00103 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *v);
+<a name="l00107"></a>00107 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
+<a name="l00108"></a>00108 
+<a name="l00114"></a>00114 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
+<a name="l00118"></a>00118 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
+<a name="l00122"></a>00122 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
+<a name="l00123"></a>00123 
+<a name="l00133"></a>00133 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00134"></a>00134 <a class="code" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rsMatrixLoadRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00135"></a>00135 
+<a name="l00144"></a>00144 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00145"></a>00145 <a class="code" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rsMatrixLoadScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00146"></a>00146 
+<a name="l00155"></a>00155 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00156"></a>00156 <a class="code" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rsMatrixLoadTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00157"></a>00157 
+<a name="l00165"></a>00165 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00166"></a>00166 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *lhs, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
+<a name="l00170"></a>00170 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00171"></a>00171 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *lhs, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
+<a name="l00175"></a>00175 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00176"></a>00176 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *lhs, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
+<a name="l00177"></a>00177 
+<a name="l00184"></a>00184 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00185"></a>00185 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
+<a name="l00189"></a>00189 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00190"></a>00190 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
+<a name="l00194"></a>00194 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00195"></a>00195 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
+<a name="l00196"></a>00196 
+<a name="l00206"></a>00206 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00207"></a>00207 <a class="code" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rsMatrixRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00208"></a>00208 
+<a name="l00217"></a>00217 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00218"></a>00218 <a class="code" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rsMatrixScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00219"></a>00219 
+<a name="l00228"></a>00228 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00229"></a>00229 <a class="code" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00230"></a>00230 
+<a name="l00242"></a>00242 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00243"></a>00243 <a class="code" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00244"></a>00244 
+<a name="l00256"></a>00256 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00257"></a>00257 <a class="code" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00258"></a>00258 
+<a name="l00268"></a>00268 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00269"></a>00269 <a class="code" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a>* m, <span class="keywordtype">float</span> fovy, <span class="keywordtype">float</span> aspect, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00270"></a>00270 
+<a name="l00271"></a>00271 <span class="preprocessor">#if !defined(RS_VERSION) || (RS_VERSION &lt; 14)</span>
+<a name="l00272"></a>00272 <span class="preprocessor"></span>
+<a name="l00276"></a>00276 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00277"></a>00277 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
+<a name="l00278"></a>00278 
+<a name="l00282"></a>00282 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00283"></a>00283 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00284"></a>00284 
+<a name="l00288"></a>00288 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00289"></a>00289 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00290"></a>00290 
+<a name="l00294"></a>00294 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00295"></a>00295 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00296"></a>00296 
+<a name="l00300"></a>00300 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00301"></a>00301 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00302"></a>00302 
+<a name="l00306"></a>00306 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
+<a name="l00307"></a>00307 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00308"></a>00308 <span class="preprocessor">#else</span>
+<a name="l00309"></a>00309 <span class="preprocessor"></span>
+<a name="l00313"></a>00313 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00314"></a>00314 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
+<a name="l00315"></a>00315 
+<a name="l00319"></a>00319 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00320"></a>00320 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00321"></a>00321 
+<a name="l00325"></a>00325 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00326"></a>00326 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00327"></a>00327 
+<a name="l00331"></a>00331 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00332"></a>00332 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00333"></a>00333 
+<a name="l00337"></a>00337 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00338"></a>00338 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00339"></a>00339 
+<a name="l00343"></a>00343 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
+<a name="l00344"></a>00344 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00345"></a>00345 <span class="preprocessor">#endif</span>
+<a name="l00346"></a>00346 <span class="preprocessor"></span>
+<a name="l00347"></a>00347 
+<a name="l00353"></a>00353 <span class="keyword">extern</span> <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00354"></a>00354 
+<a name="l00360"></a>00360 extern <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00361"></a>00361 
+<a name="l00367"></a>00367 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00371"></a>00371 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
+<a name="l00375"></a>00375 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
+<a name="l00376"></a>00376 
+<a name="l00377"></a>00377 
+<a name="l00378"></a>00378 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__object_8rsh.html b/docs/html/reference/renderscript/rs__object_8rsh.html
new file mode 100644
index 0000000..464e7e5
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__object_8rsh.html
@@ -0,0 +1,791 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_object.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_object.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a> (<a class="el" href="structrs__element.html">rs_element</a> *dst, <a class="el" href="structrs__element.html">rs_element</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#ab1c6d0672b6b88add70a98e627eeb7ae">rsSetObject</a> (<a class="el" href="structrs__type.html">rs_type</a> *dst, <a class="el" href="structrs__type.html">rs_type</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#af3446b1b9c2e4b600cdc8d828f3dbb59">rsSetObject</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a> *dst, <a class="el" href="structrs__allocation.html">rs_allocation</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a5132f90b4aaf8d2e35e6ad021fb08175">rsSetObject</a> (<a class="el" href="structrs__sampler.html">rs_sampler</a> *dst, <a class="el" href="structrs__sampler.html">rs_sampler</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a9dfc520ed267ac9733760bc628a93cae">rsSetObject</a> (<a class="el" href="structrs__script.html">rs_script</a> *dst, <a class="el" href="structrs__script.html">rs_script</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a4d6368cf71d6fd2e55efbe23af6cfd7c">rsSetObject</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> *dst, <a class="el" href="structrs__mesh.html">rs_mesh</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a8135bceeb7b3ec8bf9a49d04e39bd565">rsSetObject</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> *dst, <a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a5512c023d40e416bea709f8d8caf9674">rsSetObject</a> (<a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> *dst, <a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a42c0d25d78051a1de58a7a1c4dcfdada">rsSetObject</a> (<a class="el" href="structrs__program__raster.html">rs_program_raster</a> *dst, <a class="el" href="structrs__program__raster.html">rs_program_raster</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a4babadff570c9f57edbb3fb98c80a113">rsSetObject</a> (<a class="el" href="structrs__program__store.html">rs_program_store</a> *dst, <a class="el" href="structrs__program__store.html">rs_program_store</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#ad1af9aed63d9f925a8e6288c0607d55b">rsSetObject</a> (<a class="el" href="structrs__font.html">rs_font</a> *dst, <a class="el" href="structrs__font.html">rs_font</a> src)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a> (<a class="el" href="structrs__element.html">rs_element</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#ae9c24592eb550e72c9ff480dfbb9fe07">rsClearObject</a> (<a class="el" href="structrs__type.html">rs_type</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a5b944e2762ce1a44f7e63abd41851bcd">rsClearObject</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a51fe2098cc5c2ff73ceff8cc46b6dd89">rsClearObject</a> (<a class="el" href="structrs__sampler.html">rs_sampler</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a0034d7e67f80a9ce2e1139f1cb54b9a4">rsClearObject</a> (<a class="el" href="structrs__script.html">rs_script</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a6f26564cf4fa1bcd46db51a478bf91b9">rsClearObject</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#afc6aca3a903d5e2021d9eeab4836fd26">rsClearObject</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a712fcc988eedf21845495477cec54029">rsClearObject</a> (<a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a06b6d56105e192e121a5a4a555dc7b70">rsClearObject</a> (<a class="el" href="structrs__program__raster.html">rs_program_raster</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a691d3c2564dd2c08d965ccb1c73a9b29">rsClearObject</a> (<a class="el" href="structrs__program__store.html">rs_program_store</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#aa246aa3c8162ef03e43bc0062671ae29">rsClearObject</a> (<a class="el" href="structrs__font.html">rs_font</a> *dst)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a> (<a class="el" href="structrs__element.html">rs_element</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a445c32d5bc085369f1ffa1a8ba13a381">rsIsObject</a> (<a class="el" href="structrs__type.html">rs_type</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#afd33063fc6e45cb23f9a6f68dc2976ba">rsIsObject</a> (<a class="el" href="structrs__allocation.html">rs_allocation</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a509c7f0eacf1f07a3e7afaa029168f11">rsIsObject</a> (<a class="el" href="structrs__sampler.html">rs_sampler</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a6dc9db5fb60856b04c0b495a85affcbc">rsIsObject</a> (<a class="el" href="structrs__script.html">rs_script</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#aa1860f7322da25f4c4a1727571b01e2b">rsIsObject</a> (<a class="el" href="structrs__mesh.html">rs_mesh</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#afa57d9148778b03b270facbdbcb88816">rsIsObject</a> (<a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#acaa5da532eab1803a72fc4af2e7c6573">rsIsObject</a> (<a class="el" href="structrs__program__vertex.html">rs_program_vertex</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a2358cf1fd6b2e0b1d6f1bde8664d9c41">rsIsObject</a> (<a class="el" href="structrs__program__raster.html">rs_program_raster</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#a547cd0a8071d895139893f1e10f5c3fd">rsIsObject</a> (<a class="el" href="structrs__program__store.html">rs_program_store</a>)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__object_8rsh.html#ac1d6da920f12974b3633d25ed078da2d">rsIsObject</a> (<a class="el" href="structrs__font.html">rs_font</a>)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Object routines. </p>
+
+<p>Definition in file <a class="el" href="rs__object_8rsh_source.html">rs_object.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="aab5f47dc11b9044b3d02c4ed818fe6e7"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="aab5f47dc11b9044b3d02c4ed818fe6e7" args="(rs_element *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__element.html">rs_element</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Sets the object to NULL.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>bool </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="ae9c24592eb550e72c9ff480dfbb9fe07"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="ae9c24592eb550e72c9ff480dfbb9fe07" args="(rs_type *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__type.html">rs_type</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a5b944e2762ce1a44f7e63abd41851bcd"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a5b944e2762ce1a44f7e63abd41851bcd" args="(rs_allocation *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a51fe2098cc5c2ff73ceff8cc46b6dd89"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a51fe2098cc5c2ff73ceff8cc46b6dd89" args="(rs_sampler *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__sampler.html">rs_sampler</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a0034d7e67f80a9ce2e1139f1cb54b9a4"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a0034d7e67f80a9ce2e1139f1cb54b9a4" args="(rs_script *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6f26564cf4fa1bcd46db51a478bf91b9"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a6f26564cf4fa1bcd46db51a478bf91b9" args="(rs_mesh *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="afc6aca3a903d5e2021d9eeab4836fd26"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="afc6aca3a903d5e2021d9eeab4836fd26" args="(rs_program_fragment *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a712fcc988eedf21845495477cec54029"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a712fcc988eedf21845495477cec54029" args="(rs_program_vertex *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a06b6d56105e192e121a5a4a555dc7b70"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a06b6d56105e192e121a5a4a555dc7b70" args="(rs_program_raster *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__raster.html">rs_program_raster</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a691d3c2564dd2c08d965ccb1c73a9b29"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="a691d3c2564dd2c08d965ccb1c73a9b29" args="(rs_program_store *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__store.html">rs_program_store</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa246aa3c8162ef03e43bc0062671ae29"></a><!-- doxytag: member="rs_object.rsh::rsClearObject" ref="aa246aa3c8162ef03e43bc0062671ae29" args="(rs_font *dst)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsClearObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__font.html">rs_font</a> *&#160;</td>
+          <td class="paramname"><em>dst</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a81f862730b961bd93ac132c24cbc0f82"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a81f862730b961bd93ac132c24cbc0f82" args="(rs_element)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__element.html">rs_element</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Tests if the object is valid. Returns true if the object is valid, false if it is NULL.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>bool </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a445c32d5bc085369f1ffa1a8ba13a381"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a445c32d5bc085369f1ffa1a8ba13a381" args="(rs_type)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__type.html">rs_type</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="afd33063fc6e45cb23f9a6f68dc2976ba"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="afd33063fc6e45cb23f9a6f68dc2976ba" args="(rs_allocation)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a509c7f0eacf1f07a3e7afaa029168f11"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a509c7f0eacf1f07a3e7afaa029168f11" args="(rs_sampler)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__sampler.html">rs_sampler</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a6dc9db5fb60856b04c0b495a85affcbc"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a6dc9db5fb60856b04c0b495a85affcbc" args="(rs_script)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="aa1860f7322da25f4c4a1727571b01e2b"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="aa1860f7322da25f4c4a1727571b01e2b" args="(rs_mesh)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="afa57d9148778b03b270facbdbcb88816"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="afa57d9148778b03b270facbdbcb88816" args="(rs_program_fragment)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="acaa5da532eab1803a72fc4af2e7c6573"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="acaa5da532eab1803a72fc4af2e7c6573" args="(rs_program_vertex)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a2358cf1fd6b2e0b1d6f1bde8664d9c41"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a2358cf1fd6b2e0b1d6f1bde8664d9c41" args="(rs_program_raster)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__raster.html">rs_program_raster</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a547cd0a8071d895139893f1e10f5c3fd"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="a547cd0a8071d895139893f1e10f5c3fd" args="(rs_program_store)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__store.html">rs_program_store</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ac1d6da920f12974b3633d25ed078da2d"></a><!-- doxytag: member="rs_object.rsh::rsIsObject" ref="ac1d6da920f12974b3633d25ed078da2d" args="(rs_font)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">bool rsIsObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__font.html">rs_font</a>&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="af6983a1578621ce283acc07f876cda62"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="af6983a1578621ce283acc07f876cda62" args="(rs_element *dst, rs_element src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__element.html">rs_element</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__element.html">rs_element</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Copy reference to the specified object.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">dst</td><td></td></tr>
+    <tr><td class="paramname">src</td><td></td></tr>
+  </table>
+  </dd>
+</dl>
+
+</div>
+</div>
+<a class="anchor" id="ab1c6d0672b6b88add70a98e627eeb7ae"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="ab1c6d0672b6b88add70a98e627eeb7ae" args="(rs_type *dst, rs_type src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__type.html">rs_type</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__type.html">rs_type</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="af3446b1b9c2e4b600cdc8d828f3dbb59"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="af3446b1b9c2e4b600cdc8d828f3dbb59" args="(rs_allocation *dst, rs_allocation src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__allocation.html">rs_allocation</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a5132f90b4aaf8d2e35e6ad021fb08175"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a5132f90b4aaf8d2e35e6ad021fb08175" args="(rs_sampler *dst, rs_sampler src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__sampler.html">rs_sampler</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__sampler.html">rs_sampler</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a9dfc520ed267ac9733760bc628a93cae"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a9dfc520ed267ac9733760bc628a93cae" args="(rs_script *dst, rs_script src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__script.html">rs_script</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4d6368cf71d6fd2e55efbe23af6cfd7c"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a4d6368cf71d6fd2e55efbe23af6cfd7c" args="(rs_mesh *dst, rs_mesh src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__mesh.html">rs_mesh</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a8135bceeb7b3ec8bf9a49d04e39bd565"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a8135bceeb7b3ec8bf9a49d04e39bd565" args="(rs_program_fragment *dst, rs_program_fragment src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a5512c023d40e416bea709f8d8caf9674"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a5512c023d40e416bea709f8d8caf9674" args="(rs_program_vertex *dst, rs_program_vertex src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a42c0d25d78051a1de58a7a1c4dcfdada"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a42c0d25d78051a1de58a7a1c4dcfdada" args="(rs_program_raster *dst, rs_program_raster src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__raster.html">rs_program_raster</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__program__raster.html">rs_program_raster</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="a4babadff570c9f57edbb3fb98c80a113"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="a4babadff570c9f57edbb3fb98c80a113" args="(rs_program_store *dst, rs_program_store src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__program__store.html">rs_program_store</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__program__store.html">rs_program_store</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+<a class="anchor" id="ad1af9aed63d9f925a8e6288c0607d55b"></a><!-- doxytag: member="rs_object.rsh::rsSetObject" ref="ad1af9aed63d9f925a8e6288c0607d55b" args="(rs_font *dst, rs_font src)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">void rsSetObject </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__font.html">rs_font</a> *&#160;</td>
+          <td class="paramname"><em>dst</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype"><a class="el" href="structrs__font.html">rs_font</a>&#160;</td>
+          <td class="paramname"><em>src</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__object_8rsh_source.html b/docs/html/reference/renderscript/rs__object_8rsh_source.html
new file mode 100644
index 0000000..0f9b488
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__object_8rsh_source.html
@@ -0,0 +1,126 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_object.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_object.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__object_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_OBJECT_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_OBJECT_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00026"></a>00026 
+<a name="l00033"></a>00033 <span class="keyword">extern</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00034"></a>00034     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__element.html" title="Opaque handle to a Renderscript element.">rs_element</a> *dst, <a class="code" href="structrs__element.html" title="Opaque handle to a Renderscript element.">rs_element</a> src);
+<a name="l00038"></a>00038 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00039"></a>00039     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__type.html" title="Opaque handle to a Renderscript type.">rs_type</a> *dst, <a class="code" href="structrs__type.html" title="Opaque handle to a Renderscript type.">rs_type</a> src);
+<a name="l00043"></a>00043 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00044"></a>00044     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> *dst, <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> src);
+<a name="l00048"></a>00048 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00049"></a>00049     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a> *dst, <a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a> src);
+<a name="l00053"></a>00053 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00054"></a>00054     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> *dst, <a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> src);
+<a name="l00058"></a>00058 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00059"></a>00059     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> *dst, <a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> src);
+<a name="l00063"></a>00063 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00064"></a>00064     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a> *dst, <a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a> src);
+<a name="l00068"></a>00068 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00069"></a>00069     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a> *dst, <a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a> src);
+<a name="l00073"></a>00073 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00074"></a>00074     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a> *dst, <a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a> src);
+<a name="l00078"></a>00078 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00079"></a>00079     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a> *dst, <a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a> src);
+<a name="l00083"></a>00083 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00084"></a>00084     <a class="code" href="rs__object_8rsh.html#af6983a1578621ce283acc07f876cda62">rsSetObject</a>(<a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a> *dst, <a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a> src);
+<a name="l00085"></a>00085 
+<a name="l00091"></a>00091 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00092"></a>00092     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__element.html" title="Opaque handle to a Renderscript element.">rs_element</a> *dst);
+<a name="l00096"></a>00096 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00097"></a>00097     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__type.html" title="Opaque handle to a Renderscript type.">rs_type</a> *dst);
+<a name="l00101"></a>00101 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00102"></a>00102     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a> *dst);
+<a name="l00106"></a>00106 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00107"></a>00107     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a> *dst);
+<a name="l00111"></a>00111 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00112"></a>00112     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a> *dst);
+<a name="l00116"></a>00116 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00117"></a>00117     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a> *dst);
+<a name="l00121"></a>00121 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00122"></a>00122     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a> *dst);
+<a name="l00126"></a>00126 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00127"></a>00127     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a> *dst);
+<a name="l00131"></a>00131 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00132"></a>00132     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a> *dst);
+<a name="l00136"></a>00136 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00137"></a>00137     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a> *dst);
+<a name="l00141"></a>00141 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00142"></a>00142     <a class="code" href="rs__object_8rsh.html#aab5f47dc11b9044b3d02c4ed818fe6e7">rsClearObject</a>(<a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a> *dst);
+<a name="l00143"></a>00143 
+<a name="l00144"></a>00144 
+<a name="l00145"></a>00145 
+<a name="l00152"></a>00152 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00153"></a>00153     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__element.html" title="Opaque handle to a Renderscript element.">rs_element</a>);
+<a name="l00157"></a>00157 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00158"></a>00158     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__type.html" title="Opaque handle to a Renderscript type.">rs_type</a>);
+<a name="l00162"></a>00162 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00163"></a>00163     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a>);
+<a name="l00167"></a>00167 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00168"></a>00168     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a>);
+<a name="l00172"></a>00172 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00173"></a>00173     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a>);
+<a name="l00177"></a>00177 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00178"></a>00178     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a>);
+<a name="l00182"></a>00182 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00183"></a>00183     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a>);
+<a name="l00187"></a>00187 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00188"></a>00188     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a>);
+<a name="l00192"></a>00192 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00193"></a>00193     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a>);
+<a name="l00197"></a>00197 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00198"></a>00198     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a>);
+<a name="l00202"></a>00202 extern <span class="keywordtype">bool</span> __attribute__((overloadable))
+<a name="l00203"></a>00203     <a class="code" href="rs__object_8rsh.html#a81f862730b961bd93ac132c24cbc0f82">rsIsObject</a>(<a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a>);
+<a name="l00204"></a>00204 
+<a name="l00205"></a>00205 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__quaternion_8rsh.html b/docs/html/reference/renderscript/rs__quaternion_8rsh.html
new file mode 100644
index 0000000..bd6979c
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__quaternion_8rsh.html
@@ -0,0 +1,556 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_quaternion.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_quaternion.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, float w, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a249782133e54f13a8096d1fbe295714d">rsQuaternionSet</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rsQuaternionMultiply</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, float s)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a5e6e493b9917336b0d9118fdd4e91444">rsQuaternionAdd</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">rsQuaternionLoadRotateUnit</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, float rot, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#adf4423c521e34f3cf29d5dd5b5a93de0">rsQuaternionLoadRotate</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, float rot, float x, float y, float z)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#acd670264e49743d35f38028b8e2a8800">rsQuaternionConjugate</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rsQuaternionDot</a> (const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q0, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q1)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">rsQuaternionNormalize</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a8bbbb286a2e2cb71b416c053f44844c3">rsQuaternionMultiply</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a7da94a30e287cbb8148771a5cd768dbd">rsQuaternionSlerp</a> (<a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q0, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q1, float t)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__quaternion_8rsh.html#a7726c524868c49892976fec53ea0693b">rsQuaternionGetMatrixUnit</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Quaternion routines. </p>
+
+<p>Definition in file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+</div><hr/><h2>Function Documentation</h2>
+<a class="anchor" id="a5e6e493b9917336b0d9118fdd4e91444"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionAdd" ref="a5e6e493b9917336b0d9118fdd4e91444" args="(rs_quaternion *q, const rs_quaternion *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionAdd </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Add two quaternions </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>destination quaternion to add to </td></tr>
+    <tr><td class="paramname">rsh</td><td>right hand side quaternion to add </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00074">74</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="acd670264e49743d35f38028b8e2a8800"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionConjugate" ref="acd670264e49743d35f38028b8e2a8800" args="(rs_quaternion *q)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionConjugate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em></td><td>)</td>
+          <td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Conjugates the quaternion </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>quaternion to conjugate </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00127">127</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aa810f8857439564e7b3be771f47b40ca"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionDot" ref="aa810f8857439564e7b3be771f47b40ca" args="(const rs_quaternion *q0, const rs_quaternion *q1)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static float rsQuaternionDot </td>
+          <td>(</td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q0</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q1</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Dot product of two quaternions </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q0</td><td>first quaternion </td></tr>
+    <tr><td class="paramname">q1</td><td>second quaternion </td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>dot product between q0 and q1 </dd></dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00140">140</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a7726c524868c49892976fec53ea0693b"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionGetMatrixUnit" ref="a7726c524868c49892976fec53ea0693b" args="(rs_matrix4x4 *m, const rs_quaternion *q)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionGetMatrixUnit </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramname"><em>m</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Computes rotation matrix from the normalized quaternion </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td>resulting matrix </td></tr>
+    <tr><td class="paramname">p</td><td>normalized quaternion </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00228">228</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="adf4423c521e34f3cf29d5dd5b5a93de0"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionLoadRotate" ref="adf4423c521e34f3cf29d5dd5b5a93de0" args="(rs_quaternion *q, float rot, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionLoadRotate </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Loads a quaternion that represents a rotation about an arbitrary vector (doesn't have to be unit) </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>quaternion to set </td></tr>
+    <tr><td class="paramname">rot</td><td>angle to rotate by </td></tr>
+    <tr><td class="paramname">x</td><td>component of a vector </td></tr>
+    <tr><td class="paramname">y</td><td>component of a vector </td></tr>
+    <tr><td class="paramname">x</td><td>component of a vector </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00111">111</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aa72a43cf3d7b5924de1ddfaa5766db09"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionLoadRotateUnit" ref="aa72a43cf3d7b5924de1ddfaa5766db09" args="(rs_quaternion *q, float rot, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionLoadRotateUnit </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>rot</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Loads a quaternion that represents a rotation about an arbitrary unit vector </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>quaternion to set </td></tr>
+    <tr><td class="paramname">rot</td><td>angle to rotate by </td></tr>
+    <tr><td class="paramname">x</td><td>component of a vector </td></tr>
+    <tr><td class="paramname">y</td><td>component of a vector </td></tr>
+    <tr><td class="paramname">x</td><td>component of a vector </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00090">90</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a4f3d214912facf72f6a6d57e95aa3c3b"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionMultiply" ref="a4f3d214912facf72f6a6d57e95aa3c3b" args="(rs_quaternion *q, float s)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>s</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiply quaternion by a scalar </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>quaternion to multiply </td></tr>
+    <tr><td class="paramname">s</td><td>scalar </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00061">61</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a8bbbb286a2e2cb71b416c053f44844c3"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionMultiply" ref="a8bbbb286a2e2cb71b416c053f44844c3" args="(rs_quaternion *q, const rs_quaternion *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionMultiply </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Multiply quaternion by another quaternion </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>destination quaternion </td></tr>
+    <tr><td class="paramname">rhs</td><td>right hand side quaternion to multiply by </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00163">163</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="abb31aad2416044ad5bbf44ee7c838e2a"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionNormalize" ref="abb31aad2416044ad5bbf44ee7c838e2a" args="(rs_quaternion *q)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionNormalize </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em></td><td>)</td>
+          <td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Normalizes the quaternion </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>quaternion to normalize </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00149">149</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a5ff868dbc33e710a666a102fdcc6670a"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionSet" ref="a5ff868dbc33e710a666a102fdcc6670a" args="(rs_quaternion *q, float w, float x, float y, float z)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionSet </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>w</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>x</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>y</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>z</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the quaternion components </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">w</td><td>component </td></tr>
+    <tr><td class="paramname">x</td><td>component </td></tr>
+    <tr><td class="paramname">y</td><td>component </td></tr>
+    <tr><td class="paramname">z</td><td>component </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00035">35</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a249782133e54f13a8096d1fbe295714d"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionSet" ref="a249782133e54f13a8096d1fbe295714d" args="(rs_quaternion *q, const rs_quaternion *rhs)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionSet </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>rhs</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Set the quaternion from another quaternion </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>destination quaternion </td></tr>
+    <tr><td class="paramname">rhs</td><td>source quaternion </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00048">48</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a7da94a30e287cbb8148771a5cd768dbd"></a><!-- doxytag: member="rs_quaternion.rsh::rsQuaternionSlerp" ref="a7da94a30e287cbb8148771a5cd768dbd" args="(rs_quaternion *q, const rs_quaternion *q0, const rs_quaternion *q1, float t)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">static void rsQuaternionSlerp </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q0</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *&#160;</td>
+          <td class="paramname"><em>q1</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">float&#160;</td>
+          <td class="paramname"><em>t</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td><code> [static]</code></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Performs spherical linear interpolation between two quaternions </p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">q</td><td>result quaternion from interpolation </td></tr>
+    <tr><td class="paramname">q0</td><td>first param </td></tr>
+    <tr><td class="paramname">q1</td><td>second param </td></tr>
+    <tr><td class="paramname">t</td><td>how much to interpolate by </td></tr>
+  </table>
+  </dd>
+</dl>
+
+<p>Definition at line <a class="el" href="rs__quaternion_8rsh_source.html#l00182">182</a> of file <a class="el" href="rs__quaternion_8rsh_source.html">rs_quaternion.rsh</a>.</p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__quaternion_8rsh_source.html b/docs/html/reference/renderscript/rs__quaternion_8rsh_source.html
new file mode 100644
index 0000000..c08565a
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__quaternion_8rsh_source.html
@@ -0,0 +1,211 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_quaternion.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_quaternion.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__quaternion_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_QUATERNION_RSH__</span>
+<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_QUATERNION_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span>
+<a name="l00026"></a>00026 
+<a name="l00034"></a>00034 <span class="keyword">static</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00035"></a><a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">00035</a> <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keywordtype">float</span> w, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z) {
+<a name="l00036"></a>00036     q-&gt;w = w;
+<a name="l00037"></a>00037     q-&gt;x = x;
+<a name="l00038"></a>00038     q-&gt;y = y;
+<a name="l00039"></a>00039     q-&gt;z = z;
+<a name="l00040"></a>00040 }
+<a name="l00041"></a>00041 
+<a name="l00047"></a>00047 <span class="keyword">static</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00048"></a><a class="code" href="rs__quaternion_8rsh.html#a249782133e54f13a8096d1fbe295714d">00048</a> <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs) {
+<a name="l00049"></a>00049     q-&gt;w = rhs-&gt;w;
+<a name="l00050"></a>00050     q-&gt;x = rhs-&gt;x;
+<a name="l00051"></a>00051     q-&gt;y = rhs-&gt;y;
+<a name="l00052"></a>00052     q-&gt;z = rhs-&gt;z;
+<a name="l00053"></a>00053 }
+<a name="l00054"></a>00054 
+<a name="l00060"></a>00060 <span class="keyword">static</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00061"></a><a class="code" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">00061</a> <a class="code" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rsQuaternionMultiply</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keywordtype">float</span> s) {
+<a name="l00062"></a>00062     q-&gt;w *= s;
+<a name="l00063"></a>00063     q-&gt;x *= s;
+<a name="l00064"></a>00064     q-&gt;y *= s;
+<a name="l00065"></a>00065     q-&gt;z *= s;
+<a name="l00066"></a>00066 }
+<a name="l00067"></a>00067 
+<a name="l00073"></a>00073 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00074"></a><a class="code" href="rs__quaternion_8rsh.html#a5e6e493b9917336b0d9118fdd4e91444">00074</a> <a class="code" href="rs__quaternion_8rsh.html#a5e6e493b9917336b0d9118fdd4e91444">rsQuaternionAdd</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs) {
+<a name="l00075"></a>00075     q-&gt;w *= rhs-&gt;w;
+<a name="l00076"></a>00076     q-&gt;x *= rhs-&gt;x;
+<a name="l00077"></a>00077     q-&gt;y *= rhs-&gt;y;
+<a name="l00078"></a>00078     q-&gt;z *= rhs-&gt;z;
+<a name="l00079"></a>00079 }
+<a name="l00080"></a>00080 
+<a name="l00089"></a>00089 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00090"></a><a class="code" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">00090</a> <a class="code" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">rsQuaternionLoadRotateUnit</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z) {
+<a name="l00091"></a>00091     rot *= (float)(M_PI / 180.0f) * 0.5f;
+<a name="l00092"></a>00092     <span class="keywordtype">float</span> c = <a class="code" href="rs__cl_8rsh.html#a8eec7aeb4b0c46b06cbcd1a3ac3e6f05">cos</a>(rot);
+<a name="l00093"></a>00093     <span class="keywordtype">float</span> s = <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(rot);
+<a name="l00094"></a>00094 
+<a name="l00095"></a>00095     q-&gt;w = c;
+<a name="l00096"></a>00096     q-&gt;x = x * s;
+<a name="l00097"></a>00097     q-&gt;y = y * s;
+<a name="l00098"></a>00098     q-&gt;z = z * s;
+<a name="l00099"></a>00099 }
+<a name="l00100"></a>00100 
+<a name="l00110"></a>00110 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00111"></a><a class="code" href="rs__quaternion_8rsh.html#adf4423c521e34f3cf29d5dd5b5a93de0">00111</a> <a class="code" href="rs__quaternion_8rsh.html#adf4423c521e34f3cf29d5dd5b5a93de0">rsQuaternionLoadRotate</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z) {
+<a name="l00112"></a>00112     <span class="keyword">const</span> <span class="keywordtype">float</span> len = x*x + y*y + z*z;
+<a name="l00113"></a>00113     <span class="keywordflow">if</span> (len != 1) {
+<a name="l00114"></a>00114         <span class="keyword">const</span> <span class="keywordtype">float</span> recipLen = 1.f / <a class="code" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">sqrt</a>(len);
+<a name="l00115"></a>00115         x *= recipLen;
+<a name="l00116"></a>00116         y *= recipLen;
+<a name="l00117"></a>00117         z *= recipLen;
+<a name="l00118"></a>00118     }
+<a name="l00119"></a>00119     <a class="code" href="rs__quaternion_8rsh.html#aa72a43cf3d7b5924de1ddfaa5766db09">rsQuaternionLoadRotateUnit</a>(q, rot, x, y, z);
+<a name="l00120"></a>00120 }
+<a name="l00121"></a>00121 
+<a name="l00126"></a>00126 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00127"></a><a class="code" href="rs__quaternion_8rsh.html#acd670264e49743d35f38028b8e2a8800">00127</a> <a class="code" href="rs__quaternion_8rsh.html#acd670264e49743d35f38028b8e2a8800">rsQuaternionConjugate</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q) {
+<a name="l00128"></a>00128     q-&gt;x = -q-&gt;x;
+<a name="l00129"></a>00129     q-&gt;y = -q-&gt;y;
+<a name="l00130"></a>00130     q-&gt;z = -q-&gt;z;
+<a name="l00131"></a>00131 }
+<a name="l00132"></a>00132 
+<a name="l00139"></a>00139 <span class="keyword">static</span> <span class="keywordtype">float</span>
+<a name="l00140"></a><a class="code" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">00140</a> <a class="code" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rsQuaternionDot</a>(<span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q0, <span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q1) {
+<a name="l00141"></a>00141     <span class="keywordflow">return</span> q0-&gt;w*q1-&gt;w + q0-&gt;x*q1-&gt;x + q0-&gt;y*q1-&gt;y + q0-&gt;z*q1-&gt;z;
+<a name="l00142"></a>00142 }
+<a name="l00143"></a>00143 
+<a name="l00148"></a>00148 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00149"></a><a class="code" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">00149</a> <a class="code" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">rsQuaternionNormalize</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q) {
+<a name="l00150"></a>00150     <span class="keyword">const</span> <span class="keywordtype">float</span> len = <a class="code" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rsQuaternionDot</a>(q, q);
+<a name="l00151"></a>00151     <span class="keywordflow">if</span> (len != 1) {
+<a name="l00152"></a>00152         <span class="keyword">const</span> <span class="keywordtype">float</span> recipLen = 1.f / <a class="code" href="rs__cl_8rsh.html#a92da0faef80c4d8f66e954c8c169a729">sqrt</a>(len);
+<a name="l00153"></a>00153         <a class="code" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rsQuaternionMultiply</a>(q, recipLen);
+<a name="l00154"></a>00154     }
+<a name="l00155"></a>00155 }
+<a name="l00156"></a>00156 
+<a name="l00162"></a>00162 <span class="keyword">static</span> <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00163"></a><a class="code" href="rs__quaternion_8rsh.html#a8bbbb286a2e2cb71b416c053f44844c3">00163</a> <a class="code" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rsQuaternionMultiply</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, const <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *rhs) {
+<a name="l00164"></a>00164     <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> qtmp;
+<a name="l00165"></a>00165     <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(&amp;qtmp, q);
+<a name="l00166"></a>00166 
+<a name="l00167"></a>00167     q-&gt;w = qtmp.w*rhs-&gt;w - qtmp.x*rhs-&gt;x - qtmp.y*rhs-&gt;y - qtmp.z*rhs-&gt;z;
+<a name="l00168"></a>00168     q-&gt;x = qtmp.w*rhs-&gt;x + qtmp.x*rhs-&gt;w + qtmp.y*rhs-&gt;z - qtmp.z*rhs-&gt;y;
+<a name="l00169"></a>00169     q-&gt;y = qtmp.w*rhs-&gt;y + qtmp.y*rhs-&gt;w + qtmp.z*rhs-&gt;x - qtmp.x*rhs-&gt;z;
+<a name="l00170"></a>00170     q-&gt;z = qtmp.w*rhs-&gt;z + qtmp.z*rhs-&gt;w + qtmp.x*rhs-&gt;y - qtmp.y*rhs-&gt;x;
+<a name="l00171"></a>00171     <a class="code" href="rs__quaternion_8rsh.html#abb31aad2416044ad5bbf44ee7c838e2a">rsQuaternionNormalize</a>(q);
+<a name="l00172"></a>00172 }
+<a name="l00173"></a>00173 
+<a name="l00181"></a>00181 <span class="keyword">static</span> <span class="keywordtype">void</span>
+<a name="l00182"></a><a class="code" href="rs__quaternion_8rsh.html#a7da94a30e287cbb8148771a5cd768dbd">00182</a> <a class="code" href="rs__quaternion_8rsh.html#a7da94a30e287cbb8148771a5cd768dbd">rsQuaternionSlerp</a>(<a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q, <span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q0, <span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q1, <span class="keywordtype">float</span> t) {
+<a name="l00183"></a>00183     <span class="keywordflow">if</span> (t &lt;= 0.0f) {
+<a name="l00184"></a>00184         <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(q, q0);
+<a name="l00185"></a>00185         <span class="keywordflow">return</span>;
+<a name="l00186"></a>00186     }
+<a name="l00187"></a>00187     <span class="keywordflow">if</span> (t &gt;= 1.0f) {
+<a name="l00188"></a>00188         <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(q, q1);
+<a name="l00189"></a>00189         <span class="keywordflow">return</span>;
+<a name="l00190"></a>00190     }
+<a name="l00191"></a>00191 
+<a name="l00192"></a>00192     <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> tempq0, tempq1;
+<a name="l00193"></a>00193     <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(&amp;tempq0, q0);
+<a name="l00194"></a>00194     <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(&amp;tempq1, q1);
+<a name="l00195"></a>00195 
+<a name="l00196"></a>00196     <span class="keywordtype">float</span> angle = <a class="code" href="rs__quaternion_8rsh.html#aa810f8857439564e7b3be771f47b40ca">rsQuaternionDot</a>(q0, q1);
+<a name="l00197"></a>00197     <span class="keywordflow">if</span> (angle &lt; 0) {
+<a name="l00198"></a>00198         <a class="code" href="rs__quaternion_8rsh.html#a4f3d214912facf72f6a6d57e95aa3c3b">rsQuaternionMultiply</a>(&amp;tempq0, -1.0f);
+<a name="l00199"></a>00199         angle *= -1.0f;
+<a name="l00200"></a>00200     }
+<a name="l00201"></a>00201 
+<a name="l00202"></a>00202     <span class="keywordtype">float</span> scale, invScale;
+<a name="l00203"></a>00203     <span class="keywordflow">if</span> (angle + 1.0f &gt; 0.05f) {
+<a name="l00204"></a>00204         <span class="keywordflow">if</span> (1.0f - angle &gt;= 0.05f) {
+<a name="l00205"></a>00205             <span class="keywordtype">float</span> theta = <a class="code" href="rs__cl_8rsh.html#a07648648c7f857cfd1479821d4389751">acos</a>(angle);
+<a name="l00206"></a>00206             <span class="keywordtype">float</span> invSinTheta = 1.0f / <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(theta);
+<a name="l00207"></a>00207             scale = <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(theta * (1.0f - t)) * invSinTheta;
+<a name="l00208"></a>00208             invScale = <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(theta * t) * invSinTheta;
+<a name="l00209"></a>00209         } <span class="keywordflow">else</span> {
+<a name="l00210"></a>00210             scale = 1.0f - t;
+<a name="l00211"></a>00211             invScale = t;
+<a name="l00212"></a>00212         }
+<a name="l00213"></a>00213     } <span class="keywordflow">else</span> {
+<a name="l00214"></a>00214         <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(&amp;tempq1, tempq0.z, -tempq0.y, tempq0.x, -tempq0.w);
+<a name="l00215"></a>00215         scale = <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(M_PI * (0.5f - t));
+<a name="l00216"></a>00216         invScale = <a class="code" href="rs__cl_8rsh.html#a8c8cd526b44eb55aede77cf659f24306">sin</a>(M_PI * t);
+<a name="l00217"></a>00217     }
+<a name="l00218"></a>00218 
+<a name="l00219"></a>00219     <a class="code" href="rs__quaternion_8rsh.html#a5ff868dbc33e710a666a102fdcc6670a">rsQuaternionSet</a>(q, tempq0.w*scale + tempq1.w*invScale, tempq0.x*scale + tempq1.x*invScale,
+<a name="l00220"></a>00220                         tempq0.y*scale + tempq1.y*invScale, tempq0.z*scale + tempq1.z*invScale);
+<a name="l00221"></a>00221 }
+<a name="l00222"></a>00222 
+<a name="l00228"></a><a class="code" href="rs__quaternion_8rsh.html#a7726c524868c49892976fec53ea0693b">00228</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="rs__quaternion_8rsh.html#a7726c524868c49892976fec53ea0693b">rsQuaternionGetMatrixUnit</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keyword">const</span> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a> *q) {
+<a name="l00229"></a>00229     <span class="keywordtype">float</span> xx = q-&gt;x * q-&gt;x;
+<a name="l00230"></a>00230     <span class="keywordtype">float</span> xy = q-&gt;x * q-&gt;y;
+<a name="l00231"></a>00231     <span class="keywordtype">float</span> xz = q-&gt;x * q-&gt;z;
+<a name="l00232"></a>00232     <span class="keywordtype">float</span> xw = q-&gt;x * q-&gt;w;
+<a name="l00233"></a>00233     <span class="keywordtype">float</span> yy = q-&gt;y * q-&gt;y;
+<a name="l00234"></a>00234     <span class="keywordtype">float</span> yz = q-&gt;y * q-&gt;z;
+<a name="l00235"></a>00235     <span class="keywordtype">float</span> yw = q-&gt;y * q-&gt;w;
+<a name="l00236"></a>00236     <span class="keywordtype">float</span> zz = q-&gt;z * q-&gt;z;
+<a name="l00237"></a>00237     <span class="keywordtype">float</span> zw = q-&gt;z * q-&gt;w;
+<a name="l00238"></a>00238 
+<a name="l00239"></a>00239     m-&gt;m[0]  = 1.0f - 2.0f * ( yy + zz );
+<a name="l00240"></a>00240     m-&gt;m[4]  =        2.0f * ( xy - zw );
+<a name="l00241"></a>00241     m-&gt;m[8]  =        2.0f * ( xz + yw );
+<a name="l00242"></a>00242     m-&gt;m[1]  =        2.0f * ( xy + zw );
+<a name="l00243"></a>00243     m-&gt;m[5]  = 1.0f - 2.0f * ( xx + zz );
+<a name="l00244"></a>00244     m-&gt;m[9]  =        2.0f * ( yz - xw );
+<a name="l00245"></a>00245     m-&gt;m[2]  =        2.0f * ( xz - yw );
+<a name="l00246"></a>00246     m-&gt;m[6]  =        2.0f * ( yz + xw );
+<a name="l00247"></a>00247     m-&gt;m[10] = 1.0f - 2.0f * ( xx + yy );
+<a name="l00248"></a>00248     m-&gt;m[3]  = m-&gt;m[7] = m-&gt;m[11] = m-&gt;m[12] = m-&gt;m[13] = m-&gt;m[14] = 0.0f;
+<a name="l00249"></a>00249     m-&gt;m[15] = 1.0f;
+<a name="l00250"></a>00250 }
+<a name="l00251"></a>00251 
+<a name="l00252"></a>00252 <span class="preprocessor">#endif</span>
+<a name="l00253"></a>00253 <span class="preprocessor"></span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__time_8rsh.html b/docs/html/reference/renderscript/rs__time_8rsh.html
new file mode 100644
index 0000000..34ac9cd
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__time_8rsh.html
@@ -0,0 +1,194 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_time.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#nested-classes">Data Structures</a> &#124;
+<a href="#typedef-members">Typedefs</a> &#124;
+<a href="#func-members">Functions</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_time.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<table class="memberdecls">
+<tr><td colspan="2"><h2><a name="nested-classes"></a>
+Data Structures</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html">rs_tm</a></td></tr>
+<tr><td colspan="2"><h2><a name="typedef-members"></a>
+Typedefs</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a></td></tr>
+<tr><td colspan="2"><h2><a name="func-members"></a>
+Functions</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#a555f9324acb8c3d0c6f09a1d05478ce2">rsTime</a> (<a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *timer)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="structrs__tm.html">rs_tm</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#a08a8fcadae964f7416aef487da624110">rsLocaltime</a> (<a class="el" href="structrs__tm.html">rs_tm</a> *local, const <a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *timer)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#a3c406e51a769718dd1c760518b9cad44">rsUptimeMillis</a> (void)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#a24e2cc12acf1e7fdd857d1a48981395d">rsUptimeNanos</a> (void)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__time_8rsh.html#adea2682186fd903752431ad848bd8bf4">rsGetDt</a> (void)</td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Renderscript time routines. </p>
+<p>This file contains Renderscript functions relating to time and date manipulation. </p>
+
+<p>Definition in file <a class="el" href="rs__time_8rsh_source.html">rs_time.rsh</a>.</p>
+</div><hr/><h2>Typedef Documentation</h2>
+<a class="anchor" id="ad2b4759a0a6a98bd79b7ad82a4b057d6"></a><!-- doxytag: member="rs_time.rsh::rs_time_t" ref="ad2b4759a0a6a98bd79b7ad82a4b057d6" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef int <a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Calendar time interpreted as seconds elapsed since the Epoch (00:00:00 on January 1, 1970, Coordinated Universal Time (UTC)). </p>
+
+<p>Definition at line <a class="el" href="rs__time_8rsh_source.html#l00031">31</a> of file <a class="el" href="rs__time_8rsh_source.html">rs_time.rsh</a>.</p>
+
+</div>
+</div>
+<hr/><h2>Function Documentation</h2>
+<a class="anchor" id="adea2682186fd903752431ad848bd8bf4"></a><!-- doxytag: member="rs_time.rsh::rsGetDt" ref="adea2682186fd903752431ad848bd8bf4" args="(void)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">float rsGetDt </td>
+          <td>(</td>
+          <td class="paramtype">void&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the time in seconds since this function was last called in this script.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>Time in seconds. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a08a8fcadae964f7416aef487da624110"></a><!-- doxytag: member="rs_time.rsh::rsLocaltime" ref="a08a8fcadae964f7416aef487da624110" args="(rs_tm *local, const rs_time_t *timer)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="structrs__tm.html">rs_tm</a>* rsLocaltime </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="structrs__tm.html">rs_tm</a> *&#160;</td>
+          <td class="paramname"><em>local</em>, </td>
+        </tr>
+        <tr>
+          <td class="paramkey"></td>
+          <td></td>
+          <td class="paramtype">const <a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *&#160;</td>
+          <td class="paramname"><em>timer</em>&#160;</td>
+        </tr>
+        <tr>
+          <td></td>
+          <td>)</td>
+          <td></td><td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Converts the time specified by <code>timer</code> into broken-down time and stores it in <code>local</code>. This function also returns a pointer to <code>local</code>. If <code>local</code> is NULL, this function does nothing and returns NULL.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">local</td><td>Broken-down time. </td></tr>
+    <tr><td class="paramname">timer</td><td>Input time as calendar time.</td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>Pointer to broken-down time (same as input <code>local</code>). </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a555f9324acb8c3d0c6f09a1d05478ce2"></a><!-- doxytag: member="rs_time.rsh::rsTime" ref="a555f9324acb8c3d0c6f09a1d05478ce2" args="(rs_time_t *timer)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> rsTime </td>
+          <td>(</td>
+          <td class="paramtype"><a class="el" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *&#160;</td>
+          <td class="paramname"><em>timer</em></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the number of seconds since the Epoch (00:00:00 UTC, January 1, 1970). If <code>timer</code> is non-NULL, the result is also stored in the memory pointed to by this variable. If an error occurs, a value of -1 is returned.</p>
+<dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">timer</td><td>Location to also store the returned calendar time.</td></tr>
+  </table>
+  </dd>
+</dl>
+<dl class="return"><dt><b>Returns:</b></dt><dd>Seconds since the Epoch. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a3c406e51a769718dd1c760518b9cad44"></a><!-- doxytag: member="rs_time.rsh::rsUptimeMillis" ref="a3c406e51a769718dd1c760518b9cad44" args="(void)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a> rsUptimeMillis </td>
+          <td>(</td>
+          <td class="paramtype">void&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the current system clock (uptime) in milliseconds.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>Uptime in milliseconds. </dd></dl>
+
+</div>
+</div>
+<a class="anchor" id="a24e2cc12acf1e7fdd857d1a48981395d"></a><!-- doxytag: member="rs_time.rsh::rsUptimeNanos" ref="a24e2cc12acf1e7fdd857d1a48981395d" args="(void)" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname"><a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a> rsUptimeNanos </td>
+          <td>(</td>
+          <td class="paramtype">void&#160;</td>
+          <td class="paramname"></td><td>)</td>
+          <td></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Returns the current system clock (uptime) in nanoseconds.</p>
+<dl class="return"><dt><b>Returns:</b></dt><dd>Uptime in nanoseconds. </dd></dl>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__time_8rsh_source.html b/docs/html/reference/renderscript/rs__time_8rsh_source.html
new file mode 100644
index 0000000..1c5c74b
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__time_8rsh_source.html
@@ -0,0 +1,83 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_time.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_time.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__time_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00024"></a>00024 <span class="preprocessor">#ifndef __RS_TIME_RSH__</span>
+<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="preprocessor">#define __RS_TIME_RSH__</span>
+<a name="l00026"></a>00026 <span class="preprocessor"></span>
+<a name="l00031"></a><a class="code" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">00031</a> <span class="keyword">typedef</span> <span class="keywordtype">int</span> <a class="code" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a>;
+<a name="l00032"></a>00032 
+<a name="l00049"></a><a class="code" href="structrs__tm.html">00049</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
+<a name="l00050"></a><a class="code" href="structrs__tm.html#ae1590aa8850370a4712da801edb8da9e">00050</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#ae1590aa8850370a4712da801edb8da9e" title="seconds">tm_sec</a>;     
+<a name="l00051"></a><a class="code" href="structrs__tm.html#abd4bd6ccf0d1f20859ecaecf850ce85b">00051</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#abd4bd6ccf0d1f20859ecaecf850ce85b" title="minutes">tm_min</a>;     
+<a name="l00052"></a><a class="code" href="structrs__tm.html#afb46962bc20f8724567981adc3711b5a">00052</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#afb46962bc20f8724567981adc3711b5a" title="hours">tm_hour</a>;    
+<a name="l00053"></a><a class="code" href="structrs__tm.html#ac87e43828f05bf62d0c770889b81ff15">00053</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#ac87e43828f05bf62d0c770889b81ff15" title="day of the month">tm_mday</a>;    
+<a name="l00054"></a><a class="code" href="structrs__tm.html#a34a5466d376e405f343ed4e1592d7832">00054</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#a34a5466d376e405f343ed4e1592d7832" title="month">tm_mon</a>;     
+<a name="l00055"></a><a class="code" href="structrs__tm.html#a74e582a615a448949969a0982d8a62d2">00055</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#a74e582a615a448949969a0982d8a62d2" title="year">tm_year</a>;    
+<a name="l00056"></a><a class="code" href="structrs__tm.html#a4d40217d3cd15b51e0093db1810426e4">00056</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#a4d40217d3cd15b51e0093db1810426e4" title="day of the week">tm_wday</a>;    
+<a name="l00057"></a><a class="code" href="structrs__tm.html#a589eab24c4d79f05f0b3601162ed34d0">00057</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#a589eab24c4d79f05f0b3601162ed34d0" title="day of the year">tm_yday</a>;    
+<a name="l00058"></a><a class="code" href="structrs__tm.html#a8cffdd224d2ea30a079a86ef1e41e111">00058</a>     <span class="keywordtype">int</span> <a class="code" href="structrs__tm.html#a8cffdd224d2ea30a079a86ef1e41e111" title="daylight savings time">tm_isdst</a>;   
+<a name="l00059"></a>00059 } <a class="code" href="structrs__tm.html">rs_tm</a>;
+<a name="l00060"></a>00060 
+<a name="l00070"></a>00070 <span class="keyword">extern</span> <a class="code" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> __attribute__((overloadable))
+<a name="l00071"></a>00071     <a class="code" href="rs__time_8rsh.html#a555f9324acb8c3d0c6f09a1d05478ce2">rsTime</a>(<a class="code" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *timer);
+<a name="l00072"></a>00072 
+<a name="l00083"></a>00083 extern <a class="code" href="structrs__tm.html">rs_tm</a> * __attribute__((overloadable))
+<a name="l00084"></a>00084     <a class="code" href="rs__time_8rsh.html#a08a8fcadae964f7416aef487da624110">rsLocaltime</a>(<a class="code" href="structrs__tm.html">rs_tm</a> *local, const <a class="code" href="rs__time_8rsh.html#ad2b4759a0a6a98bd79b7ad82a4b057d6">rs_time_t</a> *timer);
+<a name="l00085"></a>00085 
+<a name="l00091"></a>00091 extern <a class="code" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a> __attribute__((overloadable))
+<a name="l00092"></a>00092     <a class="code" href="rs__time_8rsh.html#a3c406e51a769718dd1c760518b9cad44">rsUptimeMillis</a>(<span class="keywordtype">void</span>);
+<a name="l00093"></a>00093 
+<a name="l00099"></a>00099 extern <a class="code" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a> __attribute__((overloadable))
+<a name="l00100"></a>00100     <a class="code" href="rs__time_8rsh.html#a24e2cc12acf1e7fdd857d1a48981395d">rsUptimeNanos</a>(<span class="keywordtype">void</span>);
+<a name="l00101"></a>00101 
+<a name="l00108"></a>00108 extern <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00109"></a>00109     <a class="code" href="rs__time_8rsh.html#adea2682186fd903752431ad848bd8bf4">rsGetDt</a>(<span class="keywordtype">void</span>);
+<a name="l00110"></a>00110 
+<a name="l00111"></a>00111 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__types_8rsh.html b/docs/html/reference/renderscript/rs__types_8rsh.html
new file mode 100644
index 0000000..bd601f2
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__types_8rsh.html
@@ -0,0 +1,846 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_types.rsh File Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#nested-classes">Data Structures</a> &#124;
+<a href="#typedef-members">Typedefs</a>  </div>
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_types.rsh File Reference</div>  </div>
+</div>
+<div class="contents">
+<div class="textblock"><code>#include &quot;stdbool.h&quot;</code><br/>
+</div><table class="memberdecls">
+<tr><td colspan="2"><h2><a name="nested-classes"></a>
+Data Structures</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__element.html">rs_element</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript element.  <a href="structrs__element.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__type.html">rs_type</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript type.  <a href="structrs__type.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__allocation.html">rs_allocation</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript allocation.  <a href="structrs__allocation.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__sampler.html">rs_sampler</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript sampler object.  <a href="structrs__sampler.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__script.html">rs_script</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript script object.  <a href="structrs__script.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__mesh.html">rs_mesh</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript mesh object.  <a href="structrs__mesh.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__program__fragment.html">rs_program_fragment</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript ProgramFragment object.  <a href="structrs__program__fragment.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__program__vertex.html">rs_program_vertex</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript ProgramVertex object.  <a href="structrs__program__vertex.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__program__raster.html">rs_program_raster</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript ProgramRaster object.  <a href="structrs__program__raster.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__program__store.html">rs_program_store</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript ProgramStore object.  <a href="structrs__program__store.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__font.html">rs_font</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque handle to a Renderscript font object.  <a href="structrs__font.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">4x4 float matrix  <a href="structrs__matrix4x4.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">3x3 float matrix  <a href="structrs__matrix3x3.html#details">More...</a><br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">2x2 float matrix  <a href="structrs__matrix2x2.html#details">More...</a><br/></td></tr>
+<tr><td colspan="2"><h2><a name="typedef-members"></a>
+Typedefs</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">int8_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">int16_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef long long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef unsigned char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef unsigned short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef unsigned long long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">size_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">ssize_t</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">double2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">double3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">double4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">uchar2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">uchar3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">ushort2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">ushort3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">ushort4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">uint2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">uint3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">uint4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">ulong2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">ulong3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">ulong4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">char2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">char3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef char&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">char4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">short2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">short3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef short&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">short4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">int2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">int3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">int4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">long2</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">long3</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">long4</a></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a></td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Define the standard Renderscript types</p>
+<p>Integers 8 bit: char, int8_t 16 bit: short, int16_t 32 bit: int, in32_t 64 bit: long, long long, int64_t</p>
+<p>Unsigned Integers 8 bit: uchar, uint8_t 16 bit: ushort, uint16_t 32 bit: uint, uint32_t 64 bit: ulong, uint64_t</p>
+<p>Floating point 32 bit: float 64 bit: double</p>
+<p>Vectors of length 2, 3, and 4 are supported for all the types above. </p>
+
+<p>Definition in file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/><h2>Typedef Documentation</h2>
+<a class="anchor" id="ac532b4c1895c8bd4fb75dc370c484351"></a><!-- doxytag: member="rs_types.rsh::char2" ref="ac532b4c1895c8bd4fb75dc370c484351" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef char <a class="el" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">char2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic char type. Provides two char fields packed into a single 16 bit field with 16 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00273">273</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a4617fb31f4c03402515efee0a9b56210"></a><!-- doxytag: member="rs_types.rsh::char3" ref="a4617fb31f4c03402515efee0a9b56210" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef char <a class="el" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">char3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic char type. Provides three char fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00278">278</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aecb498648daac97c7cc5f31c242dfa03"></a><!-- doxytag: member="rs_types.rsh::char4" ref="aecb498648daac97c7cc5f31c242dfa03" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef char <a class="el" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">char4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic char type. Provides four char fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00283">283</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a75ef868cedebc2a6eeb1bc6ca6ca49c3"></a><!-- doxytag: member="rs_types.rsh::double2" ref="a75ef868cedebc2a6eeb1bc6ca6ca49c3" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef double <a class="el" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">double2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic double type. Provides two double fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00193">193</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aa3c90d5a23d674185a13e95402eda7eb"></a><!-- doxytag: member="rs_types.rsh::double3" ref="aa3c90d5a23d674185a13e95402eda7eb" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef double <a class="el" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">double3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic double type. Provides three double fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00198">198</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a60f4b04e076f0dd0ecc99c365fc4ca21"></a><!-- doxytag: member="rs_types.rsh::double4" ref="a60f4b04e076f0dd0ecc99c365fc4ca21" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef double <a class="el" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">double4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic double type. Provides four double fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00203">203</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a5086d0fcb71f916c936af486ccf0dd41"></a><!-- doxytag: member="rs_types.rsh::float2" ref="a5086d0fcb71f916c936af486ccf0dd41" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef float <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic float type. Provides two float fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00176">176</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a0046fa0f208d0899adbcf1f8b5aafadd"></a><!-- doxytag: member="rs_types.rsh::float3" ref="a0046fa0f208d0899adbcf1f8b5aafadd" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef float <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic float type. Provides three float fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00181">181</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="adb5162dc168ddd471d948faa60b37c5e"></a><!-- doxytag: member="rs_types.rsh::float4" ref="adb5162dc168ddd471d948faa60b37c5e" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef float <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic float type. Provides four float fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00187">187</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aa343fa3b3d06292b959ffdd4c4703b06"></a><!-- doxytag: member="rs_types.rsh::int16_t" ref="aa343fa3b3d06292b959ffdd4c4703b06" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef short <a class="el" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">int16_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>16 bit integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00054">54</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a6bc1fa1354fe2145b8f12b4bbfafcf4c"></a><!-- doxytag: member="rs_types.rsh::int2" ref="a6bc1fa1354fe2145b8f12b4bbfafcf4c" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef int <a class="el" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">int2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic int type. Provides two int fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00305">305</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ad5512266b63fd06dcf450f6c9d5326c8"></a><!-- doxytag: member="rs_types.rsh::int3" ref="ad5512266b63fd06dcf450f6c9d5326c8" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef int <a class="el" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">int3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic int type. Provides three int fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00310">310</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a32f2e37ee053cf2ce8ca28d1f74630e5"></a><!-- doxytag: member="rs_types.rsh::int32_t" ref="a32f2e37ee053cf2ce8ca28d1f74630e5" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef int <a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>32 bit integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00058">58</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a897deab71f679999ed99d4153c797e70"></a><!-- doxytag: member="rs_types.rsh::int4" ref="a897deab71f679999ed99d4153c797e70" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef int <a class="el" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">int4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic int type. Provides two four fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00315">315</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a996e72f71b11a5bb8b3b7b6936b1516d"></a><!-- doxytag: member="rs_types.rsh::int64_t" ref="a996e72f71b11a5bb8b3b7b6936b1516d" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef long long <a class="el" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>64 bit integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00062">62</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ad566f6541e98b74246db1a3a3a85ad49"></a><!-- doxytag: member="rs_types.rsh::int8_t" ref="ad566f6541e98b74246db1a3a3a85ad49" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef char <a class="el" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">int8_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>8 bit integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00050">50</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="afd55d62cee0785034b73375acd0df9da"></a><!-- doxytag: member="rs_types.rsh::long2" ref="afd55d62cee0785034b73375acd0df9da" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef long <a class="el" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">long2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic long type. Provides two long fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00321">321</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ad9cedbf4050fad14138d1dcb3428ec18"></a><!-- doxytag: member="rs_types.rsh::long3" ref="ad9cedbf4050fad14138d1dcb3428ec18" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef long <a class="el" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">long3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic long type. Provides three long fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00326">326</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ae177e4918f36e5c9da36d524cdb7a2e7"></a><!-- doxytag: member="rs_types.rsh::long4" ref="ae177e4918f36e5c9da36d524cdb7a2e7" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef long <a class="el" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">long4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic long type. Provides four long fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00331">331</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a86f99f382dc35fc8ad98b524fe6d5447"></a><!-- doxytag: member="rs_types.rsh::rs_quaternion" ref="a86f99f382dc35fc8ad98b524fe6d5447" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> <a class="el" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>quaternion type for use with the quaternion functions </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00364">364</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a303d3ad18aaeacfcfeda2b8580b98796"></a><!-- doxytag: member="rs_types.rsh::short2" ref="a303d3ad18aaeacfcfeda2b8580b98796" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef short <a class="el" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">short2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic short type. Provides two short fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00289">289</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a3f4967691ae2b249511b5f3dd9e18793"></a><!-- doxytag: member="rs_types.rsh::short3" ref="a3f4967691ae2b249511b5f3dd9e18793" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef short <a class="el" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">short3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic short type. Provides three short fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00294">294</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a198219da0b1d51c8d7f8f12aad7e502d"></a><!-- doxytag: member="rs_types.rsh::short4" ref="a198219da0b1d51c8d7f8f12aad7e502d" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef short <a class="el" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">short4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic short type. Provides four short fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00299">299</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a29d85914ddff32967d85ada69854206d"></a><!-- doxytag: member="rs_types.rsh::size_t" ref="a29d85914ddff32967d85ada69854206d" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> <a class="el" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">size_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Typedef for unsigned int </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00098">98</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a170745d0d946e79c4c2a056d1d158996"></a><!-- doxytag: member="rs_types.rsh::ssize_t" ref="a170745d0d946e79c4c2a056d1d158996" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> <a class="el" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">ssize_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Typedef for int (use for 32-bit integers) </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00102">102</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a27c902d5ca78afa82d5ed75554d5cedc"></a><!-- doxytag: member="rs_types.rsh::uchar" ref="a27c902d5ca78afa82d5ed75554d5cedc" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>8 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00082">82</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aff5eb7cd53a34bb01924bf64485296de"></a><!-- doxytag: member="rs_types.rsh::uchar2" ref="aff5eb7cd53a34bb01924bf64485296de" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="el" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">uchar2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uchar type. Provides two uchar fields packed into a single 16 bit field with 16 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00209">209</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a247b5eacf2b662849668cbc33120343f"></a><!-- doxytag: member="rs_types.rsh::uchar3" ref="a247b5eacf2b662849668cbc33120343f" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="el" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">uchar3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uchar type. Provides three uchar fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00214">214</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ae6ed52a87d4ff920c303b13b00f7396d"></a><!-- doxytag: member="rs_types.rsh::uchar4" ref="ae6ed52a87d4ff920c303b13b00f7396d" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="el" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uchar type. Provides four uchar fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00219">219</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a4f5fce8c1ef282264f9214809524d836"></a><!-- doxytag: member="rs_types.rsh::uint" ref="a4f5fce8c1ef282264f9214809524d836" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>32 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00090">90</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a273cf69d639a59973b6019625df33e30"></a><!-- doxytag: member="rs_types.rsh::uint16_t" ref="a273cf69d639a59973b6019625df33e30" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef unsigned short <a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>16 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00070">70</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aaf90cd1f01a121e824fc6e1b927e7683"></a><!-- doxytag: member="rs_types.rsh::uint2" ref="aaf90cd1f01a121e824fc6e1b927e7683" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="el" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">uint2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uint type. Provides two uint fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00241">241</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ae80e36ac834c891aa76b09a220344e78"></a><!-- doxytag: member="rs_types.rsh::uint3" ref="ae80e36ac834c891aa76b09a220344e78" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="el" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">uint3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uint type. Provides three uint fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00246">246</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a435d1572bf3f880d55459d9805097f62"></a><!-- doxytag: member="rs_types.rsh::uint32_t" ref="a435d1572bf3f880d55459d9805097f62" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef unsigned int <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>32 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00074">74</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ad92f0ec6c2cdc1f11a6d7fe321047462"></a><!-- doxytag: member="rs_types.rsh::uint4" ref="ad92f0ec6c2cdc1f11a6d7fe321047462" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="el" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">uint4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic uint type. Provides four uint fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00251">251</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aaa5d1cd013383c889537491c3cfd9aad"></a><!-- doxytag: member="rs_types.rsh::uint64_t" ref="aaa5d1cd013383c889537491c3cfd9aad" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef unsigned long long <a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>64 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00078">78</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="aba7bc1797add20fe3efdf37ced1182c5"></a><!-- doxytag: member="rs_types.rsh::uint8_t" ref="aba7bc1797add20fe3efdf37ced1182c5" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef unsigned char <a class="el" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>8 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00066">66</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ab46637ef82283186e57f54756fe67203"></a><!-- doxytag: member="rs_types.rsh::ulong" ref="ab46637ef82283186e57f54756fe67203" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a> <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Typedef for unsigned long (use for 64-bit unsigned integers) </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00094">94</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a56988b12ab16acf753356f7a5c70565a"></a><!-- doxytag: member="rs_types.rsh::ulong2" ref="a56988b12ab16acf753356f7a5c70565a" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="el" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">ulong2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ulong type. Provides two ulong fields packed into a single 128 bit field with 128 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00257">257</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ac623a569c28935fbedd3a8ed27ae0696"></a><!-- doxytag: member="rs_types.rsh::ulong3" ref="ac623a569c28935fbedd3a8ed27ae0696" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="el" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">ulong3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ulong type. Provides three ulong fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00262">262</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a3029c54b8e1779a1ddbdfe875432d137"></a><!-- doxytag: member="rs_types.rsh::ulong4" ref="a3029c54b8e1779a1ddbdfe875432d137" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="el" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">ulong4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ulong type. Provides four ulong fields packed into a single 256 bit field with 256 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00267">267</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a9e58a7bf060b7a5fbf6a401d3020adca"></a><!-- doxytag: member="rs_types.rsh::ushort" ref="a9e58a7bf060b7a5fbf6a401d3020adca" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a> <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>16 bit unsigned integer type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00086">86</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a24a9d78cfc32475e2c6eb1cdec239bf2"></a><!-- doxytag: member="rs_types.rsh::ushort2" ref="a24a9d78cfc32475e2c6eb1cdec239bf2" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="el" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">ushort2</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ushort type. Provides two ushort fields packed into a single 32 bit field with 32 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00225">225</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="ab78391445785d2ca0276392a9c97fcba"></a><!-- doxytag: member="rs_types.rsh::ushort3" ref="ab78391445785d2ca0276392a9c97fcba" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="el" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">ushort3</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ushort type. Provides three ushort fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00230">230</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+<a class="anchor" id="a77a09fa01d7fc721bbc44c32aac2d487"></a><!-- doxytag: member="rs_types.rsh::ushort4" ref="a77a09fa01d7fc721bbc44c32aac2d487" args="" -->
+<div class="memitem">
+<div class="memproto">
+      <table class="memname">
+        <tr>
+          <td class="memname">typedef <a class="el" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="el" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">ushort4</a></td>
+        </tr>
+      </table>
+</div>
+<div class="memdoc">
+<p>Vector version of the basic ushort type. Provides four ushort fields packed into a single 64 bit field with 64 bit alignment. </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00235">235</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+
+</div>
+</div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/rs__types_8rsh_source.html b/docs/html/reference/renderscript/rs__types_8rsh_source.html
new file mode 100644
index 0000000..96c55e1
--- /dev/null
+++ b/docs/html/reference/renderscript/rs__types_8rsh_source.html
@@ -0,0 +1,160 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_types.rsh Source File</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li class="current"><a href="globals.html"><span>Globals</span></a></li>
+      <li><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">/src/ics-mr1/frameworks/base/libs/rs/scriptc/rs_types.rsh</div>  </div>
+</div>
+<div class="contents">
+<a href="rs__types_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
+<a name="l00002"></a>00002 <span class="comment"> * Copyright (C) 2011 The Android Open Source Project</span>
+<a name="l00003"></a>00003 <span class="comment"> *</span>
+<a name="l00004"></a>00004 <span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);</span>
+<a name="l00005"></a>00005 <span class="comment"> * you may not use this file except in compliance with the License.</span>
+<a name="l00006"></a>00006 <span class="comment"> * You may obtain a copy of the License at</span>
+<a name="l00007"></a>00007 <span class="comment"> *</span>
+<a name="l00008"></a>00008 <span class="comment"> *      http://www.apache.org/licenses/LICENSE-2.0</span>
+<a name="l00009"></a>00009 <span class="comment"> *</span>
+<a name="l00010"></a>00010 <span class="comment"> * Unless required by applicable law or agreed to in writing, software</span>
+<a name="l00011"></a>00011 <span class="comment"> * distributed under the License is distributed on an &quot;AS IS&quot; BASIS,</span>
+<a name="l00012"></a>00012 <span class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</span>
+<a name="l00013"></a>00013 <span class="comment"> * See the License for the specific language governing permissions and</span>
+<a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
+<a name="l00015"></a>00015 <span class="comment"> */</span>
+<a name="l00016"></a>00016 
+<a name="l00041"></a>00041 <span class="preprocessor">#ifndef __RS_TYPES_RSH__</span>
+<a name="l00042"></a>00042 <span class="preprocessor"></span><span class="preprocessor">#define __RS_TYPES_RSH__</span>
+<a name="l00043"></a>00043 <span class="preprocessor"></span>
+<a name="l00044"></a>00044 <span class="preprocessor">#define M_PI        3.14159265358979323846264338327950288f   </span><span class="comment">/* pi */</span>
+<a name="l00045"></a>00045 
+<a name="l00046"></a>00046 <span class="preprocessor">#include &quot;stdbool.h&quot;</span>
+<a name="l00050"></a><a class="code" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">00050</a> <span class="keyword">typedef</span> <span class="keywordtype">char</span> <a class="code" href="rs__types_8rsh.html#ad566f6541e98b74246db1a3a3a85ad49">int8_t</a>;
+<a name="l00054"></a><a class="code" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">00054</a> <span class="keyword">typedef</span> <span class="keywordtype">short</span> <a class="code" href="rs__types_8rsh.html#aa343fa3b3d06292b959ffdd4c4703b06">int16_t</a>;
+<a name="l00058"></a><a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">00058</a> <span class="keyword">typedef</span> <span class="keywordtype">int</span> <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a>;
+<a name="l00062"></a><a class="code" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">00062</a> <span class="keyword">typedef</span> <span class="keywordtype">long</span> <span class="keywordtype">long</span> <a class="code" href="rs__types_8rsh.html#a996e72f71b11a5bb8b3b7b6936b1516d">int64_t</a>;
+<a name="l00066"></a><a class="code" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">00066</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> <a class="code" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a>;
+<a name="l00070"></a><a class="code" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">00070</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">short</span> <a class="code" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a>;
+<a name="l00074"></a><a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">00074</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>;
+<a name="l00078"></a><a class="code" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">00078</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <span class="keywordtype">long</span> <a class="code" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a>;
+<a name="l00082"></a><a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">00082</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#aba7bc1797add20fe3efdf37ced1182c5">uint8_t</a> <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a>;
+<a name="l00086"></a><a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">00086</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#a273cf69d639a59973b6019625df33e30">uint16_t</a> <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a>;
+<a name="l00090"></a><a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">00090</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a>;
+<a name="l00094"></a><a class="code" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">00094</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#aaa5d1cd013383c889537491c3cfd9aad">uint64_t</a> <a class="code" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a>;
+<a name="l00098"></a><a class="code" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">00098</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> <a class="code" href="rs__types_8rsh.html#a29d85914ddff32967d85ada69854206d">size_t</a>;
+<a name="l00102"></a><a class="code" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">00102</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#a32f2e37ee053cf2ce8ca28d1f74630e5">int32_t</a> <a class="code" href="rs__types_8rsh.html#a170745d0d946e79c4c2a056d1d158996">ssize_t</a>;
+<a name="l00103"></a>00103 
+<a name="l00109"></a><a class="code" href="structrs__element.html">00109</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{ <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__element.html" title="Opaque handle to a Renderscript element.">rs_element</a>;
+<a name="l00115"></a><a class="code" href="structrs__type.html">00115</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__type.html" title="Opaque handle to a Renderscript type.">rs_type</a>;
+<a name="l00121"></a><a class="code" href="structrs__allocation.html">00121</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__allocation.html" title="Opaque handle to a Renderscript allocation.">rs_allocation</a>;
+<a name="l00127"></a><a class="code" href="structrs__sampler.html">00127</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__sampler.html" title="Opaque handle to a Renderscript sampler object.">rs_sampler</a>;
+<a name="l00133"></a><a class="code" href="structrs__script.html">00133</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__script.html" title="Opaque handle to a Renderscript script object.">rs_script</a>;
+<a name="l00139"></a><a class="code" href="structrs__mesh.html">00139</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__mesh.html" title="Opaque handle to a Renderscript mesh object.">rs_mesh</a>;
+<a name="l00145"></a><a class="code" href="structrs__program__fragment.html">00145</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__program__fragment.html" title="Opaque handle to a Renderscript ProgramFragment object.">rs_program_fragment</a>;
+<a name="l00151"></a><a class="code" href="structrs__program__vertex.html">00151</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__program__vertex.html" title="Opaque handle to a Renderscript ProgramVertex object.">rs_program_vertex</a>;
+<a name="l00157"></a><a class="code" href="structrs__program__raster.html">00157</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__program__raster.html" title="Opaque handle to a Renderscript ProgramRaster object.">rs_program_raster</a>;
+<a name="l00163"></a><a class="code" href="structrs__program__store.html">00163</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__program__store.html" title="Opaque handle to a Renderscript ProgramStore object.">rs_program_store</a>;
+<a name="l00169"></a><a class="code" href="structrs__font.html">00169</a> typedef struct { <span class="keyword">const</span> <span class="keywordtype">int</span>* <span class="keyword">const</span> p; } __attribute__((packed, aligned(4))) <a class="code" href="structrs__font.html" title="Opaque handle to a Renderscript font object.">rs_font</a>;
+<a name="l00170"></a>00170 
+<a name="l00176"></a><a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">00176</a> typedef <span class="keywordtype">float</span> <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((ext_vector_type(2)));
+<a name="l00181"></a><a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">00181</a> typedef <span class="keywordtype">float</span> <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((ext_vector_type(3)));
+<a name="l00187"></a><a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">00187</a> typedef <span class="keywordtype">float</span> <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((ext_vector_type(4)));
+<a name="l00188"></a>00188 
+<a name="l00193"></a><a class="code" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">00193</a> typedef <span class="keywordtype">double</span> <a class="code" href="rs__types_8rsh.html#a75ef868cedebc2a6eeb1bc6ca6ca49c3">double2</a> __attribute__((ext_vector_type(2)));
+<a name="l00198"></a><a class="code" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">00198</a> typedef <span class="keywordtype">double</span> <a class="code" href="rs__types_8rsh.html#aa3c90d5a23d674185a13e95402eda7eb">double3</a> __attribute__((ext_vector_type(3)));
+<a name="l00203"></a><a class="code" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">00203</a> typedef <span class="keywordtype">double</span> <a class="code" href="rs__types_8rsh.html#a60f4b04e076f0dd0ecc99c365fc4ca21">double4</a> __attribute__((ext_vector_type(4)));
+<a name="l00204"></a>00204 
+<a name="l00209"></a><a class="code" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">00209</a> typedef <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="code" href="rs__types_8rsh.html#aff5eb7cd53a34bb01924bf64485296de">uchar2</a> __attribute__((ext_vector_type(2)));
+<a name="l00214"></a><a class="code" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">00214</a> typedef <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="code" href="rs__types_8rsh.html#a247b5eacf2b662849668cbc33120343f">uchar3</a> __attribute__((ext_vector_type(3)));
+<a name="l00219"></a><a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">00219</a> typedef <a class="code" href="rs__types_8rsh.html#a27c902d5ca78afa82d5ed75554d5cedc">uchar</a> <a class="code" href="rs__types_8rsh.html#ae6ed52a87d4ff920c303b13b00f7396d">uchar4</a> __attribute__((ext_vector_type(4)));
+<a name="l00220"></a>00220 
+<a name="l00225"></a><a class="code" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">00225</a> typedef <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="code" href="rs__types_8rsh.html#a24a9d78cfc32475e2c6eb1cdec239bf2">ushort2</a> __attribute__((ext_vector_type(2)));
+<a name="l00230"></a><a class="code" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">00230</a> typedef <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="code" href="rs__types_8rsh.html#ab78391445785d2ca0276392a9c97fcba">ushort3</a> __attribute__((ext_vector_type(3)));
+<a name="l00235"></a><a class="code" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">00235</a> typedef <a class="code" href="rs__types_8rsh.html#a9e58a7bf060b7a5fbf6a401d3020adca">ushort</a> <a class="code" href="rs__types_8rsh.html#a77a09fa01d7fc721bbc44c32aac2d487">ushort4</a> __attribute__((ext_vector_type(4)));
+<a name="l00236"></a>00236 
+<a name="l00241"></a><a class="code" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">00241</a> typedef <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="code" href="rs__types_8rsh.html#aaf90cd1f01a121e824fc6e1b927e7683">uint2</a> __attribute__((ext_vector_type(2)));
+<a name="l00246"></a><a class="code" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">00246</a> typedef <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="code" href="rs__types_8rsh.html#ae80e36ac834c891aa76b09a220344e78">uint3</a> __attribute__((ext_vector_type(3)));
+<a name="l00251"></a><a class="code" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">00251</a> typedef <a class="code" href="rs__types_8rsh.html#a4f5fce8c1ef282264f9214809524d836">uint</a> <a class="code" href="rs__types_8rsh.html#ad92f0ec6c2cdc1f11a6d7fe321047462">uint4</a> __attribute__((ext_vector_type(4)));
+<a name="l00252"></a>00252 
+<a name="l00257"></a><a class="code" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">00257</a> typedef <a class="code" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="code" href="rs__types_8rsh.html#a56988b12ab16acf753356f7a5c70565a">ulong2</a> __attribute__((ext_vector_type(2)));
+<a name="l00262"></a><a class="code" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">00262</a> typedef <a class="code" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="code" href="rs__types_8rsh.html#ac623a569c28935fbedd3a8ed27ae0696">ulong3</a> __attribute__((ext_vector_type(3)));
+<a name="l00267"></a><a class="code" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">00267</a> typedef <a class="code" href="rs__types_8rsh.html#ab46637ef82283186e57f54756fe67203">ulong</a> <a class="code" href="rs__types_8rsh.html#a3029c54b8e1779a1ddbdfe875432d137">ulong4</a> __attribute__((ext_vector_type(4)));
+<a name="l00268"></a>00268 
+<a name="l00273"></a><a class="code" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">00273</a> typedef <span class="keywordtype">char</span> <a class="code" href="rs__types_8rsh.html#ac532b4c1895c8bd4fb75dc370c484351">char2</a> __attribute__((ext_vector_type(2)));
+<a name="l00278"></a><a class="code" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">00278</a> typedef <span class="keywordtype">char</span> <a class="code" href="rs__types_8rsh.html#a4617fb31f4c03402515efee0a9b56210">char3</a> __attribute__((ext_vector_type(3)));
+<a name="l00283"></a><a class="code" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">00283</a> typedef <span class="keywordtype">char</span> <a class="code" href="rs__types_8rsh.html#aecb498648daac97c7cc5f31c242dfa03">char4</a> __attribute__((ext_vector_type(4)));
+<a name="l00284"></a>00284 
+<a name="l00289"></a><a class="code" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">00289</a> typedef <span class="keywordtype">short</span> <a class="code" href="rs__types_8rsh.html#a303d3ad18aaeacfcfeda2b8580b98796">short2</a> __attribute__((ext_vector_type(2)));
+<a name="l00294"></a><a class="code" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">00294</a> typedef <span class="keywordtype">short</span> <a class="code" href="rs__types_8rsh.html#a3f4967691ae2b249511b5f3dd9e18793">short3</a> __attribute__((ext_vector_type(3)));
+<a name="l00299"></a><a class="code" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">00299</a> typedef <span class="keywordtype">short</span> <a class="code" href="rs__types_8rsh.html#a198219da0b1d51c8d7f8f12aad7e502d">short4</a> __attribute__((ext_vector_type(4)));
+<a name="l00300"></a>00300 
+<a name="l00305"></a><a class="code" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">00305</a> typedef <span class="keywordtype">int</span> <a class="code" href="rs__types_8rsh.html#a6bc1fa1354fe2145b8f12b4bbfafcf4c">int2</a> __attribute__((ext_vector_type(2)));
+<a name="l00310"></a><a class="code" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">00310</a> typedef <span class="keywordtype">int</span> <a class="code" href="rs__types_8rsh.html#ad5512266b63fd06dcf450f6c9d5326c8">int3</a> __attribute__((ext_vector_type(3)));
+<a name="l00315"></a><a class="code" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">00315</a> typedef <span class="keywordtype">int</span> <a class="code" href="rs__types_8rsh.html#a897deab71f679999ed99d4153c797e70">int4</a> __attribute__((ext_vector_type(4)));
+<a name="l00316"></a>00316 
+<a name="l00321"></a><a class="code" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">00321</a> typedef <span class="keywordtype">long</span> <a class="code" href="rs__types_8rsh.html#afd55d62cee0785034b73375acd0df9da">long2</a> __attribute__((ext_vector_type(2)));
+<a name="l00326"></a><a class="code" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">00326</a> typedef <span class="keywordtype">long</span> <a class="code" href="rs__types_8rsh.html#ad9cedbf4050fad14138d1dcb3428ec18">long3</a> __attribute__((ext_vector_type(3)));
+<a name="l00331"></a><a class="code" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">00331</a> typedef <span class="keywordtype">long</span> <a class="code" href="rs__types_8rsh.html#ae177e4918f36e5c9da36d524cdb7a2e7">long4</a> __attribute__((ext_vector_type(4)));
+<a name="l00332"></a>00332 
+<a name="l00339"></a><a class="code" href="structrs__matrix4x4.html">00339</a> typedef struct {
+<a name="l00340"></a>00340     <span class="keywordtype">float</span> m[16];
+<a name="l00341"></a>00341 } <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a>;
+<a name="l00348"></a><a class="code" href="structrs__matrix3x3.html">00348</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
+<a name="l00349"></a>00349     <span class="keywordtype">float</span> m[9];
+<a name="l00350"></a>00350 } <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a>;
+<a name="l00357"></a><a class="code" href="structrs__matrix2x2.html">00357</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
+<a name="l00358"></a>00358     <span class="keywordtype">float</span> m[4];
+<a name="l00359"></a>00359 } <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a>;
+<a name="l00360"></a>00360 
+<a name="l00364"></a><a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">00364</a> <span class="keyword">typedef</span> <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> <a class="code" href="rs__types_8rsh.html#a86f99f382dc35fc8ad98b524fe6d5447">rs_quaternion</a>;
+<a name="l00365"></a>00365 
+<a name="l00366"></a>00366 <span class="preprocessor">#define RS_PACKED __attribute__((packed, aligned(4)))</span>
+<a name="l00367"></a>00367 <span class="preprocessor"></span><span class="preprocessor">#define NULL ((const void *)0)</span>
+<a name="l00368"></a>00368 <span class="preprocessor"></span>
+<a name="l00369"></a>00369 <span class="preprocessor">#if (defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14))</span>
+<a name="l00370"></a>00370 <span class="preprocessor"></span>
+<a name="l00374"></a>00374 <span class="keyword">typedef</span> <span class="keyword">enum</span> {
+<a name="l00375"></a>00375     RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_X = 0,
+<a name="l00376"></a>00376     RS_ALLOCATION_CUBEMAP_FACE_NEGATIVE_X = 1,
+<a name="l00377"></a>00377     RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_Y = 2,
+<a name="l00378"></a>00378     RS_ALLOCATION_CUBEMAP_FACE_NEGATIVE_Y = 3,
+<a name="l00379"></a>00379     RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_Z = 4,
+<a name="l00380"></a>00380     RS_ALLOCATION_CUBEMAP_FACE_NEGATIVE_Z = 5
+<a name="l00381"></a>00381 } rs_allocation_cubemap_face;
+<a name="l00382"></a>00382 
+<a name="l00389"></a>00389 <span class="keyword">typedef</span> <span class="keyword">enum</span> {
+<a name="l00390"></a>00390     RS_ALLOCATION_USAGE_SCRIPT = 0x0001,
+<a name="l00391"></a>00391     RS_ALLOCATION_USAGE_GRAPHICS_TEXTURE = 0x0002,
+<a name="l00392"></a>00392     RS_ALLOCATION_USAGE_GRAPHICS_VERTEX = 0x0004,
+<a name="l00393"></a>00393     RS_ALLOCATION_USAGE_GRAPHICS_CONSTANTS = 0x0008,
+<a name="l00394"></a>00394     RS_ALLOCATION_USAGE_GRAPHICS_RENDER_TARGET = 0x0010
+<a name="l00395"></a>00395 } rs_allocation_usage_type;
+<a name="l00396"></a>00396 
+<a name="l00397"></a>00397 <span class="preprocessor">#endif //defined(RS_VERSION) &amp;&amp; (RS_VERSION &gt;= 14)</span>
+<a name="l00398"></a>00398 <span class="preprocessor"></span>
+<a name="l00399"></a>00399 <span class="preprocessor">#endif</span>
+</pre></div></div>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__allocation.html b/docs/html/reference/renderscript/structrs__allocation.html
new file mode 100644
index 0000000..b166fdd
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__allocation.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_allocation Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_allocation Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_allocation" -->
+<p>Opaque handle to a Renderscript allocation.  
+ <a href="structrs__allocation.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript allocation. </p>
+<p>See: android.renderscript.Allocation </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00121">121</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__element.html b/docs/html/reference/renderscript/structrs__element.html
new file mode 100644
index 0000000..79cd090
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__element.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_element Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_element Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_element" -->
+<p>Opaque handle to a Renderscript element.  
+ <a href="structrs__element.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript element. </p>
+<p>See: android.renderscript.Element </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00109">109</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__font.html b/docs/html/reference/renderscript/structrs__font.html
new file mode 100644
index 0000000..83eb649
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__font.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_font Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_font Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_font" -->
+<p>Opaque handle to a Renderscript font object.  
+ <a href="structrs__font.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript font object. </p>
+<p>See: android.renderscript.Font </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00169">169</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__matrix2x2.html b/docs/html/reference/renderscript/structrs__matrix2x2.html
new file mode 100644
index 0000000..8789066
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__matrix2x2.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_matrix2x2 Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_matrix2x2 Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_matrix2x2" -->
+<p>2x2 float matrix  
+ <a href="structrs__matrix2x2.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>2x2 float matrix </p>
+<p>Native holder for RS matrix. Elements are stored in the array at the location [row*2 + col] </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00357">357</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__matrix3x3.html b/docs/html/reference/renderscript/structrs__matrix3x3.html
new file mode 100644
index 0000000..2b036df
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__matrix3x3.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_matrix3x3 Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_matrix3x3 Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_matrix3x3" -->
+<p>3x3 float matrix  
+ <a href="structrs__matrix3x3.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>3x3 float matrix </p>
+<p>Native holder for RS matrix. Elements are stored in the array at the location [row*3 + col] </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00348">348</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__matrix4x4.html b/docs/html/reference/renderscript/structrs__matrix4x4.html
new file mode 100644
index 0000000..c696108
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__matrix4x4.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_matrix4x4 Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_matrix4x4 Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_matrix4x4" -->
+<p>4x4 float matrix  
+ <a href="structrs__matrix4x4.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>4x4 float matrix </p>
+<p>Native holder for RS matrix. Elements are stored in the array at the location [row*4 + col] </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00339">339</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__mesh.html b/docs/html/reference/renderscript/structrs__mesh.html
new file mode 100644
index 0000000..6f58a54
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__mesh.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_mesh Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_mesh Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_mesh" -->
+<p>Opaque handle to a Renderscript mesh object.  
+ <a href="structrs__mesh.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript mesh object. </p>
+<p>See: android.renderscript.Mesh </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00139">139</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__program__fragment.html b/docs/html/reference/renderscript/structrs__program__fragment.html
new file mode 100644
index 0000000..ed8eae7
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__program__fragment.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_program_fragment Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_program_fragment Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_program_fragment" -->
+<p>Opaque handle to a Renderscript ProgramFragment object.  
+ <a href="structrs__program__fragment.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript ProgramFragment object. </p>
+<p>See: android.renderscript.ProgramFragment </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00145">145</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__program__raster.html b/docs/html/reference/renderscript/structrs__program__raster.html
new file mode 100644
index 0000000..a914854
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__program__raster.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_program_raster Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_program_raster Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_program_raster" -->
+<p>Opaque handle to a Renderscript ProgramRaster object.  
+ <a href="structrs__program__raster.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript ProgramRaster object. </p>
+<p>See: android.renderscript.ProgramRaster </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00157">157</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__program__store.html b/docs/html/reference/renderscript/structrs__program__store.html
new file mode 100644
index 0000000..6ecfece
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__program__store.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_program_store Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_program_store Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_program_store" -->
+<p>Opaque handle to a Renderscript ProgramStore object.  
+ <a href="structrs__program__store.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript ProgramStore object. </p>
+<p>See: android.renderscript.ProgramStore </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00163">163</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__program__vertex.html b/docs/html/reference/renderscript/structrs__program__vertex.html
new file mode 100644
index 0000000..2b145a3
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__program__vertex.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_program_vertex Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_program_vertex Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_program_vertex" -->
+<p>Opaque handle to a Renderscript ProgramVertex object.  
+ <a href="structrs__program__vertex.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript ProgramVertex object. </p>
+<p>See: android.renderscript.ProgramVertex </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00151">151</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__sampler.html b/docs/html/reference/renderscript/structrs__sampler.html
new file mode 100644
index 0000000..58ea0de
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__sampler.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_sampler Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_sampler Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_sampler" -->
+<p>Opaque handle to a Renderscript sampler object.  
+ <a href="structrs__sampler.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript sampler object. </p>
+<p>See: android.renderscript.Sampler </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00127">127</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__script.html b/docs/html/reference/renderscript/structrs__script.html
new file mode 100644
index 0000000..0946635
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__script.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_script Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_script Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_script" -->
+<p>Opaque handle to a Renderscript script object.  
+ <a href="structrs__script.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript script object. </p>
+<p>See: android.renderscript.ScriptC </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00133">133</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__script__call.html b/docs/html/reference/renderscript/structrs__script__call.html
new file mode 100644
index 0000000..9ba0681
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__script__call.html
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_script_call Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_script_call Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_script_call" --><hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Structure to provide extra information to a rsForEach call. Primarly used to restrict the call to a subset of cells in the allocation. </p>
+
+<p>Definition at line <a class="el" href="rs__core_8rsh_source.html#l00088">88</a> of file <a class="el" href="rs__core_8rsh_source.html">rs_core.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__core_8rsh_source.html">rs_core.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__tm.html b/docs/html/reference/renderscript/structrs__tm.html
new file mode 100644
index 0000000..80f8fe9
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__tm.html
@@ -0,0 +1,75 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_tm Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="summary">
+<a href="#pub-attribs">Data Fields</a>  </div>
+  <div class="headertitle">
+<div class="title">rs_tm Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_tm" --><table class="memberdecls">
+<tr><td colspan="2"><h2><a name="pub-attribs"></a>
+Data Fields</h2></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ae1590aa8850370a4712da801edb8da9e"></a><!-- doxytag: member="rs_tm::tm_sec" ref="ae1590aa8850370a4712da801edb8da9e" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#ae1590aa8850370a4712da801edb8da9e">tm_sec</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">seconds <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abd4bd6ccf0d1f20859ecaecf850ce85b"></a><!-- doxytag: member="rs_tm::tm_min" ref="abd4bd6ccf0d1f20859ecaecf850ce85b" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#abd4bd6ccf0d1f20859ecaecf850ce85b">tm_min</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">minutes <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="afb46962bc20f8724567981adc3711b5a"></a><!-- doxytag: member="rs_tm::tm_hour" ref="afb46962bc20f8724567981adc3711b5a" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#afb46962bc20f8724567981adc3711b5a">tm_hour</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">hours <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac87e43828f05bf62d0c770889b81ff15"></a><!-- doxytag: member="rs_tm::tm_mday" ref="ac87e43828f05bf62d0c770889b81ff15" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#ac87e43828f05bf62d0c770889b81ff15">tm_mday</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">day of the month <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a34a5466d376e405f343ed4e1592d7832"></a><!-- doxytag: member="rs_tm::tm_mon" ref="a34a5466d376e405f343ed4e1592d7832" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#a34a5466d376e405f343ed4e1592d7832">tm_mon</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">month <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a74e582a615a448949969a0982d8a62d2"></a><!-- doxytag: member="rs_tm::tm_year" ref="a74e582a615a448949969a0982d8a62d2" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#a74e582a615a448949969a0982d8a62d2">tm_year</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">year <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4d40217d3cd15b51e0093db1810426e4"></a><!-- doxytag: member="rs_tm::tm_wday" ref="a4d40217d3cd15b51e0093db1810426e4" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#a4d40217d3cd15b51e0093db1810426e4">tm_wday</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">day of the week <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a589eab24c4d79f05f0b3601162ed34d0"></a><!-- doxytag: member="rs_tm::tm_yday" ref="a589eab24c4d79f05f0b3601162ed34d0" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#a589eab24c4d79f05f0b3601162ed34d0">tm_yday</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">day of the year <br/></td></tr>
+<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8cffdd224d2ea30a079a86ef1e41e111"></a><!-- doxytag: member="rs_tm::tm_isdst" ref="a8cffdd224d2ea30a079a86ef1e41e111" args="" -->
+int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structrs__tm.html#a8cffdd224d2ea30a079a86ef1e41e111">tm_isdst</a></td></tr>
+<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">daylight savings time <br/></td></tr>
+</table>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Data structure for broken-down time components.</p>
+<p>tm_sec - Seconds after the minute. This ranges from 0 to 59, but possibly up to 60 for leap seconds. tm_min - Minutes after the hour. This ranges from 0 to 59. tm_hour - Hours past midnight. This ranges from 0 to 23. tm_mday - Day of the month. This ranges from 1 to 31. tm_mon - Months since January. This ranges from 0 to 11. tm_year - Years since 1900. tm_wday - Days since Sunday. This ranges from 0 to 6. tm_yday - Days since January 1. This ranges from 0 to 365. tm_isdst - Flag to indicate whether daylight saving time is in effect. The value is positive if it is in effect, zero if it is not, and negative if the information is not available. </p>
+
+<p>Definition at line <a class="el" href="rs__time_8rsh_source.html#l00049">49</a> of file <a class="el" href="rs__time_8rsh_source.html">rs_time.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__time_8rsh_source.html">rs_time.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/structrs__type.html b/docs/html/reference/renderscript/structrs__type.html
new file mode 100644
index 0000000..f8eec3e
--- /dev/null
+++ b/docs/html/reference/renderscript/structrs__type.html
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+
+<title>rs_type Struct Reference</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+
+
+
+</head>
+<body>
+<div id="top"><!-- do not remove this div! -->
+
+
+<!-- Generated by Doxygen 1.7.5.1 -->
+  <div id="navrow1" class="tabs">
+    <ul class="tablist">
+      <li><a href="index.html"><span>Overview</span></a></li>
+      <li><a href="globals.html"><span>Globals</span></a></li>
+      <li class="current"><a href="annotated.html"><span>Structs</span></a></li>
+    </ul>
+  </div>
+</div>
+<div class="header">
+  <div class="headertitle">
+<div class="title">rs_type Struct Reference</div>  </div>
+</div>
+<div class="contents">
+<!-- doxytag: class="rs_type" -->
+<p>Opaque handle to a Renderscript type.  
+ <a href="structrs__type.html#details">More...</a></p>
+<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
+<div class="textblock"><p>Opaque handle to a Renderscript type. </p>
+<p>See: android.renderscript.Type </p>
+
+<p>Definition at line <a class="el" href="rs__types_8rsh_source.html#l00115">115</a> of file <a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a>.</p>
+</div><hr/>The documentation for this struct was generated from the following file:<ul>
+<li>/src/ics-mr1/frameworks/base/libs/rs/scriptc/<a class="el" href="rs__types_8rsh_source.html">rs_types.rsh</a></li>
+</ul>
+</div>
+
+</body>
+</html>
diff --git a/docs/html/reference/renderscript/tab_a.png b/docs/html/reference/renderscript/tab_a.png
new file mode 100644
index 0000000..2d99ef2
--- /dev/null
+++ b/docs/html/reference/renderscript/tab_a.png
Binary files differ
diff --git a/docs/html/reference/renderscript/tab_b.png b/docs/html/reference/renderscript/tab_b.png
new file mode 100644
index 0000000..b2c3d2b
--- /dev/null
+++ b/docs/html/reference/renderscript/tab_b.png
Binary files differ
diff --git a/docs/html/reference/renderscript/tab_h.png b/docs/html/reference/renderscript/tab_h.png
new file mode 100644
index 0000000..c11f48f
--- /dev/null
+++ b/docs/html/reference/renderscript/tab_h.png
Binary files differ
diff --git a/docs/html/reference/renderscript/tab_s.png b/docs/html/reference/renderscript/tab_s.png
new file mode 100644
index 0000000..978943a
--- /dev/null
+++ b/docs/html/reference/renderscript/tab_s.png
Binary files differ
diff --git a/docs/html/reference/renderscript/tabs.css b/docs/html/reference/renderscript/tabs.css
new file mode 100644
index 0000000..2192056
--- /dev/null
+++ b/docs/html/reference/renderscript/tabs.css
@@ -0,0 +1,59 @@
+.tabs, .tabs2, .tabs3 {
+    background-image: url('tab_b.png');
+    width: 100%;
+    z-index: 101;
+    font-size: 13px;
+}
+
+.tabs2 {
+    font-size: 10px;
+}
+.tabs3 {
+    font-size: 9px;
+}
+
+.tablist {
+    margin: 0;
+    padding: 0;
+    display: table;
+}
+
+.tablist li {
+    float: left;
+    display: table-cell;
+    background-image: url('tab_b.png');
+    line-height: 36px;
+    list-style: none;
+}
+
+.tablist a {
+    display: block;
+    padding: 0 20px;
+    font-weight: bold;
+    background-image:url('tab_s.png');
+    background-repeat:no-repeat;
+    background-position:right;
+    color: #283A5D;
+    text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9);
+    text-decoration: none;
+    outline: none;
+}
+
+.tabs3 .tablist a {
+    padding: 0 10px;
+}
+
+.tablist a:hover {
+    background-image: url('tab_h.png');
+    background-repeat:repeat-x;
+    color: #fff;
+    text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0);
+    text-decoration: none;
+}
+
+.tablist li.current a {
+    background-image: url('tab_a.png');
+    background-repeat:repeat-x;
+    color: #fff;
+    text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0);
+}
diff --git a/docs/html/sdk/android-4.0.3.jd b/docs/html/sdk/android-4.0.3.jd
index c17a422..1fca8df 100644
--- a/docs/html/sdk/android-4.0.3.jd
+++ b/docs/html/sdk/android-4.0.3.jd
@@ -58,12 +58,34 @@
 environment, refer to the "Installed Packages" listing in the Android SDK
 Manager.</p>
 
+<p class="caution"><strong>Important:</strong> To download the new Android
+4.0.x system components from the Android SDK Manager, you must first update the
+SDK tools to revision 14 or later and restart the Android SDK Manager. If you do not,
+the Android 4.0.x system components will not be available for download.</p>
 
 <div class="toggle-content opened" style="padding-left:1em;">
 
   <p><a href="#" onclick="return toggleContent(this)">
     <img src="{@docRoot}assets/images/triangle-opened.png"
 class="toggle-content-img" alt="" />
+    Android {@sdkPlatformVersion}, Revision 2</a> <em>(January 2012)</em>
+  </a></p>
+
+  <div class="toggle-content-toggleme" style="padding-left:2em;">
+
+<dl>
+<dt>Maintenance release. SDK Tools r14 or higher is required.
+</dt>
+</dl>
+
+  </div>
+</div>
+
+<div class="toggle-content closed" style="padding-left:1em;">
+
+  <p><a href="#" onclick="return toggleContent(this)">
+    <img src="{@docRoot}assets/images/triangle-closed.png"
+class="toggle-content-img" alt="" />
     Android {@sdkPlatformVersion}, Revision 1</a> <em>(December 2011)</em>
   </a></p>
 
@@ -71,17 +93,12 @@
 
 <dl>
 <dt>Initial release. SDK Tools r14 or higher is required.
-  <p class="caution"><strong>Important:</strong> To download the new Android
-  4.0.x system components from the Android SDK Manager, you must first update the
-  SDK tools to revision 14 or later and restart the Android SDK Manager. If you do not,
-  the Android 4.0.x system components will not be available for download.</p>
 </dt>
 </dl>
 
   </div>
 </div>
 
-
 <h2 id="api">API Overview</h2>
 
 <p>The sections below provide a technical overview of new APIs in Android 4.0.3.</p>
diff --git a/drm/common/DrmEngineBase.cpp b/drm/common/DrmEngineBase.cpp
index 9b16c36..1c345a2 100644
--- a/drm/common/DrmEngineBase.cpp
+++ b/drm/common/DrmEngineBase.cpp
@@ -120,13 +120,23 @@
 }
 
 status_t DrmEngineBase::openDecryptSession(
-    int uniqueId, DecryptHandle* decryptHandle, int fd, off64_t offset, off64_t length) {
-    return onOpenDecryptSession(uniqueId, decryptHandle, fd, offset, length);
+    int uniqueId, DecryptHandle* decryptHandle,
+    int fd, off64_t offset, off64_t length, const char* mime) {
+
+    if (!mime || mime[0] == '\0') {
+        return onOpenDecryptSession(uniqueId, decryptHandle, fd, offset, length);
+    }
+
+    return onOpenDecryptSession(uniqueId, decryptHandle, fd, offset, length, mime);
 }
 
 status_t DrmEngineBase::openDecryptSession(
-    int uniqueId, DecryptHandle* decryptHandle, const char* uri) {
-    return onOpenDecryptSession(uniqueId, decryptHandle, uri);
+    int uniqueId, DecryptHandle* decryptHandle,
+    const char* uri, const char* mime) {
+    if (!mime || mime[0] == '\0') {
+        return onOpenDecryptSession(uniqueId, decryptHandle, uri);
+    }
+    return onOpenDecryptSession(uniqueId, decryptHandle, uri, mime);
 }
 
 status_t DrmEngineBase::closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle) {
diff --git a/drm/common/IDrmManagerService.cpp b/drm/common/IDrmManagerService.cpp
index 3ed8ade..43f64f2 100644
--- a/drm/common/IDrmManagerService.cpp
+++ b/drm/common/IDrmManagerService.cpp
@@ -600,7 +600,7 @@
 }
 
 DecryptHandle* BpDrmManagerService::openDecryptSession(
-            int uniqueId, int fd, off64_t offset, off64_t length) {
+            int uniqueId, int fd, off64_t offset, off64_t length, const char* mime) {
     ALOGV("Entering BpDrmManagerService::openDecryptSession");
     Parcel data, reply;
 
@@ -609,6 +609,11 @@
     data.writeFileDescriptor(fd);
     data.writeInt64(offset);
     data.writeInt64(length);
+    String8 mimeType;
+    if (mime) {
+        mimeType = mime;
+    }
+    data.writeString8(mimeType);
 
     remote()->transact(OPEN_DECRYPT_SESSION, data, &reply);
 
@@ -620,13 +625,20 @@
     return handle;
 }
 
-DecryptHandle* BpDrmManagerService::openDecryptSession(int uniqueId, const char* uri) {
-    ALOGV("Entering BpDrmManagerService::openDecryptSession");
+DecryptHandle* BpDrmManagerService::openDecryptSession(
+        int uniqueId, const char* uri, const char* mime) {
+
+    ALOGV("Entering BpDrmManagerService::openDecryptSession: mime=%s", mime? mime: "NULL");
     Parcel data, reply;
 
     data.writeInterfaceToken(IDrmManagerService::getInterfaceDescriptor());
     data.writeInt32(uniqueId);
     data.writeString8(String8(uri));
+    String8 mimeType;
+    if (mime) {
+        mimeType = mime;
+    }
+    data.writeString8(mimeType);
 
     remote()->transact(OPEN_DECRYPT_SESSION_FROM_URI, data, &reply);
 
@@ -1265,8 +1277,10 @@
 
         const off64_t offset = data.readInt64();
         const off64_t length = data.readInt64();
+        const String8 mime = data.readString8();
+
         DecryptHandle* handle
-            = openDecryptSession(uniqueId, fd, offset, length);
+            = openDecryptSession(uniqueId, fd, offset, length, mime.string());
 
         if (NULL != handle) {
             writeDecryptHandleToParcelData(handle, reply);
@@ -1283,8 +1297,9 @@
 
         const int uniqueId = data.readInt32();
         const String8 uri = data.readString8();
+        const String8 mime = data.readString8();
 
-        DecryptHandle* handle = openDecryptSession(uniqueId, uri.string());
+        DecryptHandle* handle = openDecryptSession(uniqueId, uri.string(), mime.string());
 
         if (NULL != handle) {
             writeDecryptHandleToParcelData(handle, reply);
diff --git a/drm/drmserver/DrmManager.cpp b/drm/drmserver/DrmManager.cpp
index 3abf3d3..999295a 100644
--- a/drm/drmserver/DrmManager.cpp
+++ b/drm/drmserver/DrmManager.cpp
@@ -426,7 +426,9 @@
     return DRM_NO_ERROR;
 }
 
-DecryptHandle* DrmManager::openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length) {
+DecryptHandle* DrmManager::openDecryptSession(
+        int uniqueId, int fd, off64_t offset, off64_t length, const char* mime) {
+
     Mutex::Autolock _l(mDecryptLock);
     status_t result = DRM_ERROR_CANNOT_HANDLE;
     Vector<String8> plugInIdList = mPlugInManager.getPlugInIdList();
@@ -438,7 +440,7 @@
         for (unsigned int index = 0; index < plugInIdList.size(); index++) {
             String8 plugInId = plugInIdList.itemAt(index);
             IDrmEngine& rDrmEngine = mPlugInManager.getPlugIn(plugInId);
-            result = rDrmEngine.openDecryptSession(uniqueId, handle, fd, offset, length);
+            result = rDrmEngine.openDecryptSession(uniqueId, handle, fd, offset, length, mime);
 
             if (DRM_NO_ERROR == result) {
                 ++mDecryptSessionId;
@@ -453,7 +455,8 @@
     return handle;
 }
 
-DecryptHandle* DrmManager::openDecryptSession(int uniqueId, const char* uri) {
+DecryptHandle* DrmManager::openDecryptSession(
+        int uniqueId, const char* uri, const char* mime) {
     Mutex::Autolock _l(mDecryptLock);
     status_t result = DRM_ERROR_CANNOT_HANDLE;
     Vector<String8> plugInIdList = mPlugInManager.getPlugInIdList();
@@ -465,7 +468,7 @@
         for (unsigned int index = 0; index < plugInIdList.size(); index++) {
             String8 plugInId = plugInIdList.itemAt(index);
             IDrmEngine& rDrmEngine = mPlugInManager.getPlugIn(plugInId);
-            result = rDrmEngine.openDecryptSession(uniqueId, handle, uri);
+            result = rDrmEngine.openDecryptSession(uniqueId, handle, uri, mime);
 
             if (DRM_NO_ERROR == result) {
                 ++mDecryptSessionId;
diff --git a/drm/drmserver/DrmManagerService.cpp b/drm/drmserver/DrmManagerService.cpp
index df17ac5..caeb026 100644
--- a/drm/drmserver/DrmManagerService.cpp
+++ b/drm/drmserver/DrmManagerService.cpp
@@ -208,20 +208,20 @@
 }
 
 DecryptHandle* DrmManagerService::openDecryptSession(
-            int uniqueId, int fd, off64_t offset, off64_t length) {
+            int uniqueId, int fd, off64_t offset, off64_t length, const char* mime) {
     ALOGV("Entering DrmManagerService::openDecryptSession");
     if (isProtectedCallAllowed()) {
-        return mDrmManager->openDecryptSession(uniqueId, fd, offset, length);
+        return mDrmManager->openDecryptSession(uniqueId, fd, offset, length, mime);
     }
 
     return NULL;
 }
 
 DecryptHandle* DrmManagerService::openDecryptSession(
-            int uniqueId, const char* uri) {
+            int uniqueId, const char* uri, const char* mime) {
     ALOGV("Entering DrmManagerService::openDecryptSession with uri");
     if (isProtectedCallAllowed()) {
-        return mDrmManager->openDecryptSession(uniqueId, uri);
+        return mDrmManager->openDecryptSession(uniqueId, uri, mime);
     }
 
     return NULL;
diff --git a/drm/libdrmframework/DrmManagerClient.cpp b/drm/libdrmframework/DrmManagerClient.cpp
index c9c0d57..8768c08 100644
--- a/drm/libdrmframework/DrmManagerClient.cpp
+++ b/drm/libdrmframework/DrmManagerClient.cpp
@@ -116,12 +116,18 @@
     return mDrmManagerClientImpl->getAllSupportInfo(mUniqueId, length, drmSupportInfoArray);
 }
 
-sp<DecryptHandle> DrmManagerClient::openDecryptSession(int fd, off64_t offset, off64_t length) {
-    return mDrmManagerClientImpl->openDecryptSession(mUniqueId, fd, offset, length);
+sp<DecryptHandle> DrmManagerClient::openDecryptSession(
+        int fd, off64_t offset, off64_t length, const char* mime) {
+
+    return mDrmManagerClientImpl->openDecryptSession(
+                    mUniqueId, fd, offset, length, mime);
 }
 
-sp<DecryptHandle> DrmManagerClient::openDecryptSession(const char* uri) {
-    return mDrmManagerClientImpl->openDecryptSession(mUniqueId, uri);
+sp<DecryptHandle> DrmManagerClient::openDecryptSession(
+        const char* uri, const char* mime) {
+
+    return mDrmManagerClientImpl->openDecryptSession(
+                    mUniqueId, uri, mime);
 }
 
 status_t DrmManagerClient::closeDecryptSession(sp<DecryptHandle> &decryptHandle) {
diff --git a/drm/libdrmframework/DrmManagerClientImpl.cpp b/drm/libdrmframework/DrmManagerClientImpl.cpp
index b222b8f..fb0439e 100644
--- a/drm/libdrmframework/DrmManagerClientImpl.cpp
+++ b/drm/libdrmframework/DrmManagerClientImpl.cpp
@@ -255,15 +255,19 @@
 }
 
 sp<DecryptHandle> DrmManagerClientImpl::openDecryptSession(
-            int uniqueId, int fd, off64_t offset, off64_t length) {
-    return getDrmManagerService()->openDecryptSession(uniqueId, fd, offset, length);
+            int uniqueId, int fd, off64_t offset,
+            off64_t length, const char* mime) {
+
+    return getDrmManagerService()->openDecryptSession(
+                uniqueId, fd, offset, length, mime);
 }
 
 sp<DecryptHandle> DrmManagerClientImpl::openDecryptSession(
-        int uniqueId, const char* uri) {
+        int uniqueId, const char* uri, const char* mime) {
+
     DecryptHandle* handle = NULL;
     if (NULL != uri) {
-        handle = getDrmManagerService()->openDecryptSession(uniqueId, uri);
+        handle = getDrmManagerService()->openDecryptSession(uniqueId, uri, mime);
     }
     return handle;
 }
diff --git a/drm/libdrmframework/include/DrmManager.h b/drm/libdrmframework/include/DrmManager.h
index ac2b946..c9167d4 100644
--- a/drm/libdrmframework/include/DrmManager.h
+++ b/drm/libdrmframework/include/DrmManager.h
@@ -111,9 +111,10 @@
 
     status_t getAllSupportInfo(int uniqueId, int* length, DrmSupportInfo** drmSupportInfoArray);
 
-    DecryptHandle* openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length);
+    DecryptHandle* openDecryptSession(
+            int uniqueId, int fd, off64_t offset, off64_t length, const char* mime);
 
-    DecryptHandle* openDecryptSession(int uniqueId, const char* uri);
+    DecryptHandle* openDecryptSession(int uniqueId, const char* uri, const char* mime);
 
     status_t closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle);
 
diff --git a/drm/libdrmframework/include/DrmManagerClientImpl.h b/drm/libdrmframework/include/DrmManagerClientImpl.h
index e3338d9..2aa493f 100644
--- a/drm/libdrmframework/include/DrmManagerClientImpl.h
+++ b/drm/libdrmframework/include/DrmManagerClientImpl.h
@@ -300,20 +300,24 @@
      * @param[in] fd File descriptor of the protected content to be decrypted
      * @param[in] offset Start position of the content
      * @param[in] length The length of the protected content
+     * @param[in] mime The mime type of the protected content if it is not NULL or empty
      * @return
      *     Handle for the decryption session
      */
-    sp<DecryptHandle> openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length);
+    sp<DecryptHandle> openDecryptSession(
+            int uniqueId, int fd, off64_t offset, off64_t length, const char* mime);
 
     /**
      * Open the decrypt session to decrypt the given protected content
      *
      * @param[in] uniqueId Unique identifier for a session
      * @param[in] uri Path of the protected content to be decrypted
+     * @param[in] mime The mime type of the protected content if it is not NULL or empty
      * @return
      *     Handle for the decryption session
      */
-    sp<DecryptHandle> openDecryptSession(int uniqueId, const char* uri);
+    sp<DecryptHandle> openDecryptSession(
+            int uniqueId, const char* uri, const char* mime);
 
     /**
      * Close the decrypt session for the given handle
diff --git a/drm/libdrmframework/include/DrmManagerService.h b/drm/libdrmframework/include/DrmManagerService.h
index 9cb5804..1a8c2ae 100644
--- a/drm/libdrmframework/include/DrmManagerService.h
+++ b/drm/libdrmframework/include/DrmManagerService.h
@@ -98,9 +98,11 @@
 
     status_t getAllSupportInfo(int uniqueId, int* length, DrmSupportInfo** drmSupportInfoArray);
 
-    DecryptHandle* openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length);
+    DecryptHandle* openDecryptSession(
+        int uniqueId, int fd, off64_t offset, off64_t length, const char *mime);
 
-    DecryptHandle* openDecryptSession(int uniqueId, const char* uri);
+    DecryptHandle* openDecryptSession(
+        int uniqueId, const char* uri, const char* mime);
 
     status_t closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle);
 
diff --git a/drm/libdrmframework/include/IDrmManagerService.h b/drm/libdrmframework/include/IDrmManagerService.h
index b9618bb..a7d21c5 100644
--- a/drm/libdrmframework/include/IDrmManagerService.h
+++ b/drm/libdrmframework/include/IDrmManagerService.h
@@ -139,9 +139,12 @@
     virtual status_t getAllSupportInfo(
             int uniqueId, int* length, DrmSupportInfo** drmSupportInfoArray) = 0;
 
-    virtual DecryptHandle* openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length) = 0;
+    virtual DecryptHandle* openDecryptSession(
+                int uniqueId, int fd, off64_t offset,
+                off64_t length, const char* mime) = 0;
 
-    virtual DecryptHandle* openDecryptSession(int uniqueId, const char* uri) = 0;
+    virtual DecryptHandle* openDecryptSession(
+                int uniqueId, const char* uri, const char* mime) = 0;
 
     virtual status_t closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle) = 0;
 
@@ -222,9 +225,12 @@
     virtual status_t getAllSupportInfo(
             int uniqueId, int* length, DrmSupportInfo** drmSupportInfoArray);
 
-    virtual DecryptHandle* openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length);
+    virtual DecryptHandle* openDecryptSession(
+                int uniqueId, int fd, off64_t offset, off64_t length,
+                const char* mime);
 
-    virtual DecryptHandle* openDecryptSession(int uniqueId, const char* uri);
+    virtual DecryptHandle* openDecryptSession(
+                int uniqueId, const char* uri, const char* mime);
 
     virtual status_t closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle);
 
diff --git a/drm/libdrmframework/plugins/common/include/DrmEngineBase.h b/drm/libdrmframework/plugins/common/include/DrmEngineBase.h
index 4a5afcf..08f6e6d 100644
--- a/drm/libdrmframework/plugins/common/include/DrmEngineBase.h
+++ b/drm/libdrmframework/plugins/common/include/DrmEngineBase.h
@@ -80,10 +80,12 @@
     DrmSupportInfo* getSupportInfo(int uniqueId);
 
     status_t openDecryptSession(
-            int uniqueId, DecryptHandle* decryptHandle, int fd, off64_t offset, off64_t length);
+            int uniqueId, DecryptHandle* decryptHandle,
+            int fd, off64_t offset, off64_t length, const char* mime);
 
     status_t openDecryptSession(
-            int uniqueId, DecryptHandle* decryptHandle, const char* uri);
+            int uniqueId, DecryptHandle* decryptHandle,
+            const char* uri, const char* mime);
 
     status_t closeDecryptSession(int uniqueId, DecryptHandle* decryptHandle);
 
@@ -375,7 +377,29 @@
      *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
      */
     virtual status_t onOpenDecryptSession(
-            int uniqueId, DecryptHandle* decryptHandle, int fd, off64_t offset, off64_t length) = 0;
+            int uniqueId, DecryptHandle* decryptHandle,
+            int fd, off64_t offset, off64_t length) = 0;
+
+    /**
+     * Open the decrypt session to decrypt the given protected content
+     *
+     * @param[in] uniqueId Unique identifier for a session
+     * @param[in] decryptHandle Handle for the current decryption session
+     * @param[in] fd File descriptor of the protected content to be decrypted
+     * @param[in] offset Start position of the content
+     * @param[in] length The length of the protected content
+     * @param[in] mime Mime type of the protected content
+     *     drm plugin may do some optimization since the mime type is known.
+     * @return
+     *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
+     */
+    virtual status_t onOpenDecryptSession(
+            int uniqueId, DecryptHandle* decryptHandle,
+            int fd, off64_t offset, off64_t length,
+            const char* mime) {
+
+        return DRM_ERROR_CANNOT_HANDLE;
+    }
 
     /**
      * Open the decrypt session to decrypt the given protected content
@@ -387,7 +411,26 @@
      *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
      */
     virtual status_t onOpenDecryptSession(
-            int uniqueId, DecryptHandle* decryptHandle, const char* uri) = 0;
+            int uniqueId, DecryptHandle* decryptHandle,
+            const char* uri) = 0;
+
+    /**
+     * Open the decrypt session to decrypt the given protected content
+     *
+     * @param[in] uniqueId Unique identifier for a session
+     * @param[in] decryptHandle Handle for the current decryption session
+     * @param[in] uri Path of the protected content to be decrypted
+     * @param[in] mime Mime type of the protected content. The corresponding
+     *     drm plugin may do some optimization since the mime type is known.
+     * @return
+     *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
+     */
+    virtual status_t onOpenDecryptSession(
+            int uniqueId, DecryptHandle* decryptHandle,
+            const char* uri, const char* mime) {
+
+        return DRM_ERROR_CANNOT_HANDLE;
+    }
 
     /**
      * Close the decrypt session for the given handle
diff --git a/drm/libdrmframework/plugins/common/include/IDrmEngine.h b/drm/libdrmframework/plugins/common/include/IDrmEngine.h
index 77460f6..dcf5977 100644
--- a/drm/libdrmframework/plugins/common/include/IDrmEngine.h
+++ b/drm/libdrmframework/plugins/common/include/IDrmEngine.h
@@ -320,11 +320,14 @@
      * @param[in] fd File descriptor of the protected content to be decrypted
      * @param[in] offset Start position of the content
      * @param[in] length The length of the protected content
+     * @param[in] mime Mime type of the protected content if it is
+     *     not NULL or empty
      * @return
      *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
      */
     virtual status_t openDecryptSession(
-        int uniqueId, DecryptHandle* decryptHandle, int fd, off64_t offset, off64_t length) = 0;
+        int uniqueId, DecryptHandle* decryptHandle,
+        int fd, off64_t offset, off64_t length, const char* mime) = 0;
 
     /**
      * Open the decrypt session to decrypt the given protected content
@@ -332,11 +335,14 @@
      * @param[in] uniqueId Unique identifier for a session
      * @param[in] decryptHandle Handle for the current decryption session
      * @param[in] uri Path of the protected content to be decrypted
+     * @param[in] mime Mime type of the protected content if it is
+     *     not NULL or empty
      * @return
      *     DRM_ERROR_CANNOT_HANDLE for failure and DRM_NO_ERROR for success
      */
     virtual status_t openDecryptSession(
-        int uniqueId, DecryptHandle* decryptHandle, const char* uri) = 0;
+        int uniqueId, DecryptHandle* decryptHandle,
+        const char* uri, const char* mime) = 0;
 
     /**
      * Close the decrypt session for the given handle
diff --git a/graphics/java/android/graphics/Canvas.java b/graphics/java/android/graphics/Canvas.java
index e1c73fd..5cac42a 100644
--- a/graphics/java/android/graphics/Canvas.java
+++ b/graphics/java/android/graphics/Canvas.java
@@ -1516,6 +1516,9 @@
     /**
      * Draw the text in the array, with each character's origin specified by
      * the pos array.
+     * 
+     * This method does not support glyph composition and decomposition and
+     * should therefore not be used to render complex scripts.
      *
      * @param text     The text to be drawn
      * @param index    The index of the first character to draw
@@ -1536,6 +1539,9 @@
     /**
      * Draw the text in the array, with each character's origin specified by
      * the pos array.
+     * 
+     * This method does not support glyph composition and decomposition and
+     * should therefore not be used to render complex scripts.
      *
      * @param text  The text to be drawn
      * @param pos   Array of [x,y] positions, used to position each character
diff --git a/graphics/java/android/graphics/Picture.java b/graphics/java/android/graphics/Picture.java
index bbb2dbf..9c06fed 100644
--- a/graphics/java/android/graphics/Picture.java
+++ b/graphics/java/android/graphics/Picture.java
@@ -123,7 +123,11 @@
     }
 
     protected void finalize() throws Throwable {
-        nativeDestructor(mNativePicture);
+        try {
+            nativeDestructor(mNativePicture);
+        } finally {
+            super.finalize();
+        }
     }
     
     /*package*/ final int ni() {
diff --git a/include/drm/DrmManagerClient.h b/include/drm/DrmManagerClient.h
index b8fe46d..c47bbfb 100644
--- a/include/drm/DrmManagerClient.h
+++ b/include/drm/DrmManagerClient.h
@@ -66,19 +66,21 @@
      * @param[in] fd File descriptor of the protected content to be decrypted
      * @param[in] offset Start position of the content
      * @param[in] length The length of the protected content
+     * @param[in] mime Mime type of the protected content if it is not NULL or empty
      * @return
      *     Handle for the decryption session
      */
-    sp<DecryptHandle> openDecryptSession(int fd, off64_t offset, off64_t length);
+    sp<DecryptHandle> openDecryptSession(int fd, off64_t offset, off64_t length, const char* mime);
 
     /**
      * Open the decrypt session to decrypt the given protected content
      *
      * @param[in] uri Path of the protected content to be decrypted
+     * @param[in] mime Mime type of the protected content if it is not NULL or empty
      * @return
      *     Handle for the decryption session
      */
-    sp<DecryptHandle> openDecryptSession(const char* uri);
+    sp<DecryptHandle> openDecryptSession(const char* uri, const char* mime);
 
     /**
      * Close the decrypt session for the given handle
diff --git a/include/media/AudioRecord.h b/include/media/AudioRecord.h
index 2fb69b6..84a8f1c 100644
--- a/include/media/AudioRecord.h
+++ b/include/media/AudioRecord.h
@@ -206,7 +206,7 @@
             int         channelCount() const;
             int         channels() const;
             uint32_t    frameCount() const;
-            int         frameSize() const;
+            size_t      frameSize() const;
             int         inputSource() const;
 
 
diff --git a/include/media/AudioSystem.h b/include/media/AudioSystem.h
index 6a15f6e..4415d33 100644
--- a/include/media/AudioSystem.h
+++ b/include/media/AudioSystem.h
@@ -55,19 +55,19 @@
     static status_t getMasterMute(bool* mute);
 
     // set/get stream volume on specified output
-    static status_t setStreamVolume(int stream, float value, int output);
-    static status_t getStreamVolume(int stream, float* volume, int output);
+    static status_t setStreamVolume(audio_stream_type_t stream, float value, int output);
+    static status_t getStreamVolume(audio_stream_type_t stream, float* volume, int output);
 
     // mute/unmute stream
-    static status_t setStreamMute(int stream, bool mute);
-    static status_t getStreamMute(int stream, bool* mute);
+    static status_t setStreamMute(audio_stream_type_t stream, bool mute);
+    static status_t getStreamMute(audio_stream_type_t stream, bool* mute);
 
-    // set audio mode in audio hardware (see audio_mode_t)
-    static status_t setMode(int mode);
+    // set audio mode in audio hardware
+    static status_t setMode(audio_mode_t mode);
 
     // returns true in *state if tracks are active on the specified stream or has been active
     // in the past inPastMs milliseconds
-    static status_t isStreamActive(int stream, bool *state, uint32_t inPastMs = 0);
+    static status_t isStreamActive(audio_stream_type_t stream, bool *state, uint32_t inPastMs = 0);
 
     // set/get audio hardware parameters. The function accepts a list of parameters
     // key value pairs in the form: key1=value1;key2=value2;...
@@ -83,11 +83,17 @@
     static float linearToLog(int volume);
     static int logToLinear(float volume);
 
-    static status_t getOutputSamplingRate(int* samplingRate, int stream = AUDIO_STREAM_DEFAULT);
-    static status_t getOutputFrameCount(int* frameCount, int stream = AUDIO_STREAM_DEFAULT);
-    static status_t getOutputLatency(uint32_t* latency, int stream = AUDIO_STREAM_DEFAULT);
+    static status_t getOutputSamplingRate(int* samplingRate, audio_stream_type_t stream = AUDIO_STREAM_DEFAULT);
+    static status_t getOutputFrameCount(int* frameCount, audio_stream_type_t stream = AUDIO_STREAM_DEFAULT);
+    static status_t getOutputLatency(uint32_t* latency, audio_stream_type_t stream = AUDIO_STREAM_DEFAULT);
 
-    static bool routedToA2dpOutput(int streamType);
+    // DEPRECATED
+    static status_t getOutputSamplingRate(int* samplingRate, int stream = AUDIO_STREAM_DEFAULT);
+
+    // DEPRECATED
+    static status_t getOutputFrameCount(int* frameCount, int stream = AUDIO_STREAM_DEFAULT);
+
+    static bool routedToA2dpOutput(audio_stream_type_t streamType);
 
     static status_t getInputBufferSize(uint32_t sampleRate, int format, int channelCount,
         size_t* buffSize);
@@ -103,7 +109,7 @@
     // - BAD_VALUE: invalid parameter
     // NOTE: this feature is not supported on all hardware platforms and it is
     // necessary to check returned status before using the returned values.
-    static status_t getRenderPosition(uint32_t *halFrames, uint32_t *dspFrames, int stream = AUDIO_STREAM_DEFAULT);
+    static status_t getRenderPosition(uint32_t *halFrames, uint32_t *dspFrames, audio_stream_type_t stream = AUDIO_STREAM_DEFAULT);
 
     static unsigned int  getInputFramesLost(audio_io_handle_t ioHandle);
 
@@ -142,7 +148,7 @@
     //
     static status_t setDeviceConnectionState(audio_devices_t device, audio_policy_dev_state_t state, const char *device_address);
     static audio_policy_dev_state_t getDeviceConnectionState(audio_devices_t device, const char *device_address);
-    static status_t setPhoneState(int state);
+    static status_t setPhoneState(audio_mode_t state);
     static status_t setRingerMode(uint32_t mode, uint32_t mask);
     static status_t setForceUse(audio_policy_force_use_t usage, audio_policy_forced_cfg_t config);
     static audio_policy_forced_cfg_t getForceUse(audio_policy_force_use_t usage);
@@ -170,8 +176,12 @@
     static status_t initStreamVolume(audio_stream_type_t stream,
                                       int indexMin,
                                       int indexMax);
-    static status_t setStreamVolumeIndex(audio_stream_type_t stream, int index);
-    static status_t getStreamVolumeIndex(audio_stream_type_t stream, int *index);
+    static status_t setStreamVolumeIndex(audio_stream_type_t stream,
+                                         int index,
+                                         audio_devices_t device);
+    static status_t getStreamVolumeIndex(audio_stream_type_t stream,
+                                         int *index,
+                                         audio_devices_t device);
 
     static uint32_t getStrategyForStream(audio_stream_type_t stream);
     static uint32_t getDevicesForStream(audio_stream_type_t stream);
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h
index 60b052bd9..fe91799 100644
--- a/include/media/AudioTrack.h
+++ b/include/media/AudioTrack.h
@@ -110,7 +110,7 @@
      */
 
      static status_t getMinFrameCount(int* frameCount,
-                                      int streamType      =-1,
+                                      audio_stream_type_t streamType = AUDIO_STREAM_DEFAULT,
                                       uint32_t sampleRate = 0);
 
     /* Constructs an uninitialized AudioTrack. No connection with
@@ -142,7 +142,7 @@
      * sessionId:          Specific session ID, or zero to use default.
      */
 
-                        AudioTrack( int streamType,
+                        AudioTrack( audio_stream_type_t streamType,
                                     uint32_t sampleRate  = 0,
                                     audio_format_t format = AUDIO_FORMAT_DEFAULT,
                                     int channelMask      = 0,
@@ -153,6 +153,18 @@
                                     int notificationFrames = 0,
                                     int sessionId = 0);
 
+                        // DEPRECATED
+                        explicit AudioTrack( int streamType,
+                                    uint32_t sampleRate  = 0,
+                                    int format = AUDIO_FORMAT_DEFAULT,
+                                    int channelMask      = 0,
+                                    int frameCount       = 0,
+                                    uint32_t flags       = 0,
+                                    callback_t cbf       = 0,
+                                    void* user           = 0,
+                                    int notificationFrames = 0,
+                                    int sessionId = 0);
+
     /* Creates an audio track and registers it with AudioFlinger. With this constructor,
      * the PCM data to be rendered by AudioTrack is passed in a shared memory buffer
      * identified by the argument sharedBuffer. This prototype is for static buffer playback.
@@ -162,7 +174,7 @@
      * EVENT_UNDERRUN event.
      */
 
-                        AudioTrack( int streamType,
+                        AudioTrack( audio_stream_type_t streamType,
                                     uint32_t sampleRate = 0,
                                     audio_format_t format = AUDIO_FORMAT_DEFAULT,
                                     int channelMask     = 0,
@@ -186,7 +198,7 @@
      *  - BAD_VALUE: invalid parameter (channels, format, sampleRate...)
      *  - NO_INIT: audio server or audio hardware not initialized
      * */
-            status_t    set(int streamType      =-1,
+            status_t    set(audio_stream_type_t streamType = AUDIO_STREAM_DEFAULT,
                             uint32_t sampleRate = 0,
                             audio_format_t format = AUDIO_FORMAT_DEFAULT,
                             int channelMask     = 0,
@@ -215,11 +227,16 @@
 
     /* getters, see constructor */
 
-            int         streamType() const;
+            audio_stream_type_t streamType() const;
             audio_format_t format() const;
             int         channelCount() const;
             uint32_t    frameCount() const;
-            int         frameSize() const;
+
+    /* Return channelCount * (bit depth per channel / 8).
+     * channelCount is determined from channelMask, and bit depth comes from format.
+     */
+            size_t      frameSize() const;
+
             sp<IMemory>& sharedBuffer();
 
 
@@ -433,7 +450,7 @@
     };
 
             bool processAudioBuffer(const sp<AudioTrackThread>& thread);
-            status_t createTrack_l(int streamType,
+            status_t createTrack_l(audio_stream_type_t streamType,
                                  uint32_t sampleRate,
                                  audio_format_t format,
                                  uint32_t channelMask,
@@ -458,7 +475,7 @@
 
     audio_track_cblk_t*     mCblk;
     audio_format_t          mFormat;
-    uint8_t                 mStreamType;
+    audio_stream_type_t     mStreamType;
     uint8_t                 mChannelCount;
     uint8_t                 mMuted;
     uint8_t                 mReserved;
diff --git a/include/media/IAudioFlinger.h b/include/media/IAudioFlinger.h
index 9e3cb7f..3999479 100644
--- a/include/media/IAudioFlinger.h
+++ b/include/media/IAudioFlinger.h
@@ -46,7 +46,7 @@
      */
     virtual sp<IAudioTrack> createTrack(
                                 pid_t pid,
-                                int streamType,
+                                audio_stream_type_t streamType,
                                 uint32_t sampleRate,
                                 uint32_t format,
                                 uint32_t channelMask,
@@ -89,14 +89,14 @@
     /* set/get stream type state. This will probably be used by
      * the preference panel, mostly.
      */
-    virtual     status_t    setStreamVolume(int stream, float value, int output) = 0;
-    virtual     status_t    setStreamMute(int stream, bool muted) = 0;
+    virtual     status_t    setStreamVolume(audio_stream_type_t stream, float value, int output) = 0;
+    virtual     status_t    setStreamMute(audio_stream_type_t stream, bool muted) = 0;
 
-    virtual     float       streamVolume(int stream, int output) const = 0;
-    virtual     bool        streamMute(int stream) const = 0;
+    virtual     float       streamVolume(audio_stream_type_t stream, int output) const = 0;
+    virtual     bool        streamMute(audio_stream_type_t stream) const = 0;
 
     // set audio mode
-    virtual     status_t    setMode(int mode) = 0;
+    virtual     status_t    setMode(audio_mode_t mode) = 0;
 
     // mic mute/state
     virtual     status_t    setMicMute(bool state) = 0;
@@ -129,7 +129,7 @@
                                     uint32_t acoustics) = 0;
     virtual status_t closeInput(int input) = 0;
 
-    virtual status_t setStreamOutput(uint32_t stream, int output) = 0;
+    virtual status_t setStreamOutput(audio_stream_type_t stream, int output) = 0;
 
     virtual status_t setVoiceVolume(float volume) = 0;
 
diff --git a/include/media/IAudioPolicyService.h b/include/media/IAudioPolicyService.h
index 9807cbe..a83d806 100644
--- a/include/media/IAudioPolicyService.h
+++ b/include/media/IAudioPolicyService.h
@@ -45,7 +45,7 @@
                                               const char *device_address) = 0;
     virtual audio_policy_dev_state_t getDeviceConnectionState(audio_devices_t device,
                                                                           const char *device_address) = 0;
-    virtual status_t setPhoneState(int state) = 0;
+    virtual status_t setPhoneState(audio_mode_t state) = 0;
     virtual status_t setRingerMode(uint32_t mode, uint32_t mask) = 0;
     virtual status_t setForceUse(audio_policy_force_use_t usage, audio_policy_forced_cfg_t config) = 0;
     virtual audio_policy_forced_cfg_t getForceUse(audio_policy_force_use_t usage) = 0;
@@ -73,8 +73,12 @@
     virtual status_t initStreamVolume(audio_stream_type_t stream,
                                       int indexMin,
                                       int indexMax) = 0;
-    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream, int index) = 0;
-    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream, int *index) = 0;
+    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream,
+                                          int index,
+                                          audio_devices_t device) = 0;
+    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream,
+                                          int *index,
+                                          audio_devices_t device) = 0;
     virtual uint32_t getStrategyForStream(audio_stream_type_t stream) = 0;
     virtual uint32_t getDevicesForStream(audio_stream_type_t stream) = 0;
     virtual audio_io_handle_t getOutputForEffect(effect_descriptor_t *desc) = 0;
@@ -85,7 +89,7 @@
                                     int id) = 0;
     virtual status_t unregisterEffect(int id) = 0;
     virtual status_t setEffectEnabled(int id, bool enabled) = 0;
-    virtual bool     isStreamActive(int stream, uint32_t inPastMs = 0) const = 0;
+    virtual bool     isStreamActive(audio_stream_type_t stream, uint32_t inPastMs = 0) const = 0;
     virtual status_t queryDefaultPreProcessing(int audioSession,
                                               effect_descriptor_t *descriptors,
                                               uint32_t *count) = 0;
diff --git a/include/media/IMediaPlayer.h b/include/media/IMediaPlayer.h
index e905903..6425886 100644
--- a/include/media/IMediaPlayer.h
+++ b/include/media/IMediaPlayer.h
@@ -21,6 +21,7 @@
 #include <binder/IInterface.h>
 #include <binder/Parcel.h>
 #include <utils/KeyedVector.h>
+#include <system/audio.h>
 
 namespace android {
 
@@ -51,7 +52,7 @@
     virtual status_t        getCurrentPosition(int* msec) = 0;
     virtual status_t        getDuration(int* msec) = 0;
     virtual status_t        reset() = 0;
-    virtual status_t        setAudioStreamType(int type) = 0;
+    virtual status_t        setAudioStreamType(audio_stream_type_t type) = 0;
     virtual status_t        setLooping(int loop) = 0;
     virtual status_t        setVolume(float leftVolume, float rightVolume) = 0;
     virtual status_t        setAuxEffectSendLevel(float level) = 0;
diff --git a/include/media/MediaPlayerInterface.h b/include/media/MediaPlayerInterface.h
index 1f6bdda..7beb176 100644
--- a/include/media/MediaPlayerInterface.h
+++ b/include/media/MediaPlayerInterface.h
@@ -199,7 +199,7 @@
     virtual             ~MediaPlayerHWInterface() {}
     virtual bool        hardwareOutput() { return true; }
     virtual status_t    setVolume(float leftVolume, float rightVolume) = 0;
-    virtual status_t    setAudioStreamType(int streamType) = 0;
+    virtual status_t    setAudioStreamType(audio_stream_type_t streamType) = 0;
 };
 
 }; // namespace android
diff --git a/include/media/ToneGenerator.h b/include/media/ToneGenerator.h
index 1ad1f26..7d890bd 100644
--- a/include/media/ToneGenerator.h
+++ b/include/media/ToneGenerator.h
@@ -151,7 +151,7 @@
         NUM_SUP_TONES = LAST_SUP_TONE-FIRST_SUP_TONE+1
     };
 
-    ToneGenerator(int streamType, float volume, bool threadCanCallJava = false);
+    ToneGenerator(audio_stream_type_t streamType, float volume, bool threadCanCallJava = false);
     ~ToneGenerator();
 
     bool startTone(int toneType, int durationMs = -1);
@@ -266,7 +266,7 @@
     Mutex mCbkCondLock; // Mutex associated to mWaitCbkCond
     Condition mWaitCbkCond; // condition enabling interface to wait for audio callback completion after a change is requested
     float mVolume;  // Volume applied to audio track
-    int mStreamType; // Audio stream used for output
+    audio_stream_type_t mStreamType; // Audio stream used for output
     unsigned int mProcessSize;  // Size of audio blocks generated at a time by audioCallback() (in PCM frames).
 
     bool initAudioTrack();
diff --git a/include/media/Visualizer.h b/include/media/Visualizer.h
index 5d2c874..1a4cbca 100644
--- a/include/media/Visualizer.h
+++ b/include/media/Visualizer.h
@@ -143,7 +143,7 @@
     void periodicCapture();
     uint32_t initCaptureSize();
 
-    Mutex mLock;
+    Mutex mCaptureLock;
     uint32_t mCaptureRate;
     uint32_t mCaptureSize;
     uint32_t mSampleRate;
diff --git a/include/media/mediaplayer.h b/include/media/mediaplayer.h
index 2dc055e..00b7dd5 100644
--- a/include/media/mediaplayer.h
+++ b/include/media/mediaplayer.h
@@ -185,7 +185,7 @@
             status_t        getCurrentPosition(int *msec);
             status_t        getDuration(int *msec);
             status_t        reset();
-            status_t        setAudioStreamType(int type);
+            status_t        setAudioStreamType(audio_stream_type_t type);
             status_t        setLooping(int loop);
             bool            isLooping();
             status_t        setVolume(float leftVolume, float rightVolume);
@@ -223,7 +223,7 @@
     int                         mSeekPosition;
     bool                        mPrepareSync;
     status_t                    mPrepareStatus;
-    int                         mStreamType;
+    audio_stream_type_t         mStreamType;
     bool                        mLoop;
     float                       mLeftVolume;
     float                       mRightVolume;
diff --git a/include/media/stagefright/DataSource.h b/include/media/stagefright/DataSource.h
index 713af92..00d583e 100644
--- a/include/media/stagefright/DataSource.h
+++ b/include/media/stagefright/DataSource.h
@@ -81,7 +81,7 @@
     static void RegisterDefaultSniffers();
 
     // for DRM
-    virtual sp<DecryptHandle> DrmInitialization() {
+    virtual sp<DecryptHandle> DrmInitialization(const char *mime = NULL) {
         return NULL;
     }
     virtual void getDrmInfo(sp<DecryptHandle> &handle, DrmManagerClient **client) {};
diff --git a/include/media/stagefright/FileSource.h b/include/media/stagefright/FileSource.h
index 6cf86dc..d994cb3 100644
--- a/include/media/stagefright/FileSource.h
+++ b/include/media/stagefright/FileSource.h
@@ -38,7 +38,7 @@
 
     virtual status_t getSize(off64_t *size);
 
-    virtual sp<DecryptHandle> DrmInitialization();
+    virtual sp<DecryptHandle> DrmInitialization(const char *mime);
 
     virtual void getDrmInfo(sp<DecryptHandle> &handle, DrmManagerClient **client);
 
diff --git a/include/media/stagefright/MediaExtractor.h b/include/media/stagefright/MediaExtractor.h
index eb45237..94090ee 100644
--- a/include/media/stagefright/MediaExtractor.h
+++ b/include/media/stagefright/MediaExtractor.h
@@ -56,10 +56,10 @@
     virtual uint32_t flags() const;
 
     // for DRM
-    virtual void setDrmFlag(bool flag) {
+    void setDrmFlag(bool flag) {
         mIsDrm = flag;
     };
-    virtual bool getDrmFlag() {
+    bool getDrmFlag() {
         return mIsDrm;
     }
     virtual char* getDrmTrackInfo(size_t trackID, int *len) {
diff --git a/include/private/media/AudioTrackShared.h b/include/private/media/AudioTrackShared.h
index 046d5e9..ffc546e 100644
--- a/include/private/media/AudioTrackShared.h
+++ b/include/private/media/AudioTrackShared.h
@@ -71,21 +71,26 @@
                 uint32_t    loopStart;
                 uint32_t    loopEnd;
                 int         loopCount;
-    volatile    union {
-                    uint16_t    volume[2];
-                    uint32_t    volumeLR;
-                };
+
+                // Channel volumes are fixed point U4.12, so 0x1000 means 1.0.
+                // Left channel is in [0:15], right channel is in [16:31].
+                // Always read and write the combined pair atomically.
+                // For AudioTrack only, not used by AudioRecord.
+                uint32_t    volumeLR;
+
                 uint32_t    sampleRate;
                 // NOTE: audio_track_cblk_t::frameSize is not equal to AudioTrack::frameSize() for
                 // 8 bit PCM data: in this case,  mCblk->frameSize is based on a sample size of
                 // 16 bit because data is converted to 16 bit before being stored in buffer
 
-                uint8_t     frameSize;
+                uint8_t     frameSize;       // would normally be size_t, but 8 bits is plenty
                 uint8_t     pad1;
                 uint16_t    bufferTimeoutMs; // Maximum cumulated timeout before restarting audioflinger
 
                 uint16_t    waitTimeMs;      // Cumulated wait time
-                uint16_t    sendLevel;
+private:
+                uint16_t    mSendLevel;      // Fixed point U4.12 so 0x1000 means 1.0
+public:
     volatile    int32_t     flags;
 
                 // Cache line boundary (32 bytes)
@@ -98,6 +103,19 @@
                 uint32_t    framesAvailable_l();
                 uint32_t    framesReady();
                 bool        tryLock();
+
+                // No barriers on the following operations, so the ordering of loads/stores
+                // with respect to other parameters is UNPREDICTABLE. That's considered safe.
+
+                // for AudioTrack client only, caller must limit to 0.0 <= sendLevel <= 1.0
+                void        setSendLevel(float sendLevel) {
+                    mSendLevel = uint16_t(sendLevel * 0x1000);
+                }
+
+                // for AudioFlinger only; the return value must be validated by the caller
+                uint16_t    getSendLevel_U4_12() const {
+                    return mSendLevel;
+                }
 };
 
 
diff --git a/include/utils/TypeHelpers.h b/include/utils/TypeHelpers.h
index 7b4fb70..1f2c2d5 100644
--- a/include/utils/TypeHelpers.h
+++ b/include/utils/TypeHelpers.h
@@ -233,19 +233,15 @@
     }
 };
 
-template<>
 template <typename K, typename V>
 struct trait_trivial_ctor< key_value_pair_t<K, V> >
 { enum { value = aggregate_traits<K,V>::has_trivial_ctor }; };
-template<> 
 template <typename K, typename V>
 struct trait_trivial_dtor< key_value_pair_t<K, V> >
 { enum { value = aggregate_traits<K,V>::has_trivial_dtor }; };
-template<> 
 template <typename K, typename V>
 struct trait_trivial_copy< key_value_pair_t<K, V> >
 { enum { value = aggregate_traits<K,V>::has_trivial_copy }; };
-template<> 
 template <typename K, typename V>
 struct trait_trivial_move< key_value_pair_t<K, V> >
 { enum { value = aggregate_traits<K,V>::has_trivial_move }; };
diff --git a/libs/gui/ISurfaceComposerClient.cpp b/libs/gui/ISurfaceComposerClient.cpp
index 5ebdbd9..8fe96b1 100644
--- a/libs/gui/ISurfaceComposerClient.cpp
+++ b/libs/gui/ISurfaceComposerClient.cpp
@@ -35,15 +35,6 @@
 
 // ---------------------------------------------------------------------------
 
-/* ideally AID_GRAPHICS would be in a semi-public header
- * or there would be a way to map a user/group name to its id
- */
-#ifndef AID_GRAPHICS
-#define AID_GRAPHICS 1003
-#endif
-
-// ---------------------------------------------------------------------------
-
 namespace android {
 
 enum {
diff --git a/libs/hwui/DisplayListRenderer.cpp b/libs/hwui/DisplayListRenderer.cpp
index 656a384..824ab4f 100644
--- a/libs/hwui/DisplayListRenderer.cpp
+++ b/libs/hwui/DisplayListRenderer.cpp
@@ -60,6 +60,7 @@
     "DrawLines",
     "DrawPoints",
     "DrawText",
+    "DrawPosText",
     "ResetShader",
     "SetupShader",
     "ResetColorFilter",
@@ -482,6 +483,15 @@
                     text.text(), text.length(), count, x, y, paint, length);
             }
             break;
+            case DrawPosText: {
+                getText(&text);
+                int count = getInt();
+                int positionsCount = 0;
+                float* positions = getFloats(positionsCount);
+                SkPaint* paint = getPaint();
+                ALOGD("%s%s %s, %d, %d, %p", (char*) indent, OP_NAMES[op],
+                    text.text(), text.length(), count, paint);
+            }
             case ResetShader: {
                 ALOGD("%s%s", (char*) indent, OP_NAMES[op]);
             }
@@ -844,6 +854,17 @@
                 renderer.drawText(text.text(), text.length(), count, x, y, paint, length);
             }
             break;
+            case DrawPosText: {
+                getText(&text);
+                int count = getInt();
+                int positionsCount = 0;
+                float* positions = getFloats(positionsCount);
+                SkPaint* paint = getPaint();
+                DISPLAY_LIST_LOGD("%s%s %s, %d, %d, %p", (char*) indent,
+                        OP_NAMES[op], text.text(), text.length(), count, paint);
+                renderer.drawPosText(text.text(), text.length(), count, positions, paint);
+            }
+            break;
             case ResetShader: {
                 DISPLAY_LIST_LOGD("%s%s", (char*) indent, OP_NAMES[op]);
                 renderer.resetShader();
@@ -1216,6 +1237,17 @@
     addFloat(length < 0.0f ? paint->measureText(text, bytesCount) : length);
 }
 
+void DisplayListRenderer::drawPosText(const char* text, int bytesCount, int count,
+        const float* positions, SkPaint* paint) {
+    if (count <= 0) return;
+    addOp(DisplayList::DrawPosText);
+    addText(text, bytesCount);
+    addInt(count);
+    addFloats(positions, count * 2);
+    paint->setAntiAlias(true);
+    addPaint(paint);
+}
+
 void DisplayListRenderer::resetShader() {
     addOp(DisplayList::ResetShader);
 }
diff --git a/libs/hwui/DisplayListRenderer.h b/libs/hwui/DisplayListRenderer.h
index 5d922db..dd7ec4f 100644
--- a/libs/hwui/DisplayListRenderer.h
+++ b/libs/hwui/DisplayListRenderer.h
@@ -96,6 +96,7 @@
         DrawLines,
         DrawPoints,
         DrawText,
+        DrawPosText,
         ResetShader,
         SetupShader,
         ResetColorFilter,
@@ -291,6 +292,8 @@
     virtual void drawPoints(float* points, int count, SkPaint* paint);
     virtual void drawText(const char* text, int bytesCount, int count, float x, float y,
             SkPaint* paint, float length = 1.0f);
+    virtual void drawPosText(const char* text, int bytesCount, int count, const float* positions,
+            SkPaint* paint);
 
     virtual void resetShader();
     virtual void setupShader(SkiaShader* shader);
diff --git a/libs/hwui/FontRenderer.cpp b/libs/hwui/FontRenderer.cpp
index 790c143..74efda2 100644
--- a/libs/hwui/FontRenderer.cpp
+++ b/libs/hwui/FontRenderer.cpp
@@ -94,7 +94,8 @@
     }
 }
 
-void Font::measureCachedGlyph(CachedGlyphInfo *glyph, int x, int y, Rect *bounds) {
+void Font::measureCachedGlyph(CachedGlyphInfo *glyph, int x, int y,
+        uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH, Rect* bounds, const float* pos) {
     int nPenX = x + glyph->mBitmapLeft;
     int nPenY = y + glyph->mBitmapTop;
 
@@ -115,7 +116,8 @@
     }
 }
 
-void Font::drawCachedGlyph(CachedGlyphInfo* glyph, int x, int y) {
+void Font::drawCachedGlyph(CachedGlyphInfo* glyph, int x, int y,
+        uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH, Rect* bounds, const float* pos) {
     int nPenX = x + glyph->mBitmapLeft;
     int nPenY = y + glyph->mBitmapTop + glyph->mBitmapHeight;
 
@@ -133,8 +135,8 @@
             nPenX, nPenY - height, u1, v1, glyph->mCachedTextureLine->mCacheTexture);
 }
 
-void Font::drawCachedGlyph(CachedGlyphInfo* glyph, int x, int y,
-        uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH) {
+void Font::drawCachedGlyphBitmap(CachedGlyphInfo* glyph, int x, int y,
+        uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH, Rect* bounds, const float* pos) {
     int nPenX = x + glyph->mBitmapLeft;
     int nPenY = y + glyph->mBitmapTop;
 
@@ -181,13 +183,19 @@
         int numGlyphs, int x, int y, uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH) {
     if (bitmap != NULL && bitmapW > 0 && bitmapH > 0) {
         render(paint, text, start, len, numGlyphs, x, y, BITMAP, bitmap,
-                bitmapW, bitmapH, NULL);
+                bitmapW, bitmapH, NULL, NULL);
     } else {
         render(paint, text, start, len, numGlyphs, x, y, FRAMEBUFFER, NULL,
-                0, 0, NULL);
+                0, 0, NULL, NULL);
     }
 }
 
+void Font::render(SkPaint* paint, const char *text, uint32_t start, uint32_t len,
+            int numGlyphs, int x, int y, const float* positions) {
+    render(paint, text, start, len, numGlyphs, x, y, FRAMEBUFFER, NULL,
+            0, 0, NULL, positions);
+}
+
 void Font::measure(SkPaint* paint, const char* text, uint32_t start, uint32_t len,
         int numGlyphs, Rect *bounds) {
     if (bounds == NULL) {
@@ -195,62 +203,95 @@
         return;
     }
     bounds->set(1e6, -1e6, -1e6, 1e6);
-    render(paint, text, start, len, numGlyphs, 0, 0, MEASURE, NULL, 0, 0, bounds);
+    render(paint, text, start, len, numGlyphs, 0, 0, MEASURE, NULL, 0, 0, bounds, NULL);
 }
 
 #define SkAutoKern_AdjustF(prev, next) (((next) - (prev) + 32) >> 6 << 16)
 
 void Font::render(SkPaint* paint, const char* text, uint32_t start, uint32_t len,
         int numGlyphs, int x, int y, RenderMode mode, uint8_t *bitmap,
-        uint32_t bitmapW, uint32_t bitmapH,Rect *bounds) {
+        uint32_t bitmapW, uint32_t bitmapH, Rect *bounds, const float* positions) {
     if (numGlyphs == 0 || text == NULL || len == 0) {
         return;
     }
 
-    float penX = x;
-    int penY = y;
-    int glyphsLeft = 1;
-    if (numGlyphs > 0) {
-        glyphsLeft = numGlyphs;
-    }
-
-    SkFixed prevRsbDelta = 0;
-    penX += 0.5f;
+    int glyphsCount = 0;
 
     text += start;
 
-    while (glyphsLeft > 0) {
-        glyph_t glyph = GET_GLYPH(text);
+    static RenderGlyph gRenderGlyph[] = {
+            &android::uirenderer::Font::drawCachedGlyph,
+            &android::uirenderer::Font::drawCachedGlyphBitmap,
+            &android::uirenderer::Font::measureCachedGlyph
+    };
+    RenderGlyph render = gRenderGlyph[mode];
 
-        // Reached the end of the string
-        if (IS_END_OF_STRING(glyph)) {
-            break;
-        }
+    if (positions == NULL) {
+        SkFixed prevRsbDelta = 0;
 
-        CachedGlyphInfo* cachedGlyph = getCachedGlyph(paint, glyph);
-        penX += SkFixedToFloat(SkAutoKern_AdjustF(prevRsbDelta, cachedGlyph->mLsbDelta));
-        prevRsbDelta = cachedGlyph->mRsbDelta;
+        float penX = x;
+        int penY = y;
 
-        // If it's still not valid, we couldn't cache it, so we shouldn't draw garbage
-        if (cachedGlyph->mIsValid) {
-            switch(mode) {
-            case FRAMEBUFFER:
-                drawCachedGlyph(cachedGlyph, (int) floorf(penX), penY);
-                break;
-            case BITMAP:
-                drawCachedGlyph(cachedGlyph, (int) floorf(penX), penY, bitmap, bitmapW, bitmapH);
-                break;
-            case MEASURE:
-                measureCachedGlyph(cachedGlyph, (int) floorf(penX), penY, bounds);
+        penX += 0.5f;
+
+        while (glyphsCount < numGlyphs) {
+            glyph_t glyph = GET_GLYPH(text);
+
+            // Reached the end of the string
+            if (IS_END_OF_STRING(glyph)) {
                 break;
             }
+
+            CachedGlyphInfo* cachedGlyph = getCachedGlyph(paint, glyph);
+            penX += SkFixedToFloat(SkAutoKern_AdjustF(prevRsbDelta, cachedGlyph->mLsbDelta));
+            prevRsbDelta = cachedGlyph->mRsbDelta;
+
+            // If it's still not valid, we couldn't cache it, so we shouldn't draw garbage
+            if (cachedGlyph->mIsValid) {
+                (*this.*render)(cachedGlyph, (int) floorf(penX), penY,
+                        bitmap, bitmapW, bitmapH, bounds, positions);
+            }
+
+            penX += SkFixedToFloat(cachedGlyph->mAdvanceX);
+
+            glyphsCount++;
         }
+    } else {
+        const SkPaint::Align align = paint->getTextAlign();
 
-        penX += SkFixedToFloat(cachedGlyph->mAdvanceX);
+        // This is for renderPosText()
+        while (glyphsCount < numGlyphs) {
+            glyph_t glyph = GET_GLYPH(text);
 
-        // If we were given a specific number of glyphs, decrement
-        if (numGlyphs > 0) {
-            glyphsLeft--;
+            // Reached the end of the string
+            if (IS_END_OF_STRING(glyph)) {
+                break;
+            }
+
+            CachedGlyphInfo* cachedGlyph = getCachedGlyph(paint, glyph);
+
+            // If it's still not valid, we couldn't cache it, so we shouldn't draw garbage
+            if (cachedGlyph->mIsValid) {
+                int penX = x + positions[(glyphsCount << 1)];
+                int penY = y + positions[(glyphsCount << 1) + 1];
+
+                switch (align) {
+                    case SkPaint::kRight_Align:
+                        penX -= SkFixedToFloat(cachedGlyph->mAdvanceX);
+                        penY -= SkFixedToFloat(cachedGlyph->mAdvanceY);
+                        break;
+                    case SkPaint::kCenter_Align:
+                        penX -= SkFixedToFloat(cachedGlyph->mAdvanceX >> 1);
+                        penY -= SkFixedToFloat(cachedGlyph->mAdvanceY >> 1);
+                    default:
+                        break;
+                }
+
+                (*this.*render)(cachedGlyph, penX, penY,
+                        bitmap, bitmapW, bitmapH, bounds, positions);
+            }
+
+            glyphsCount++;
         }
     }
 }
@@ -866,21 +907,15 @@
     return image;
 }
 
-bool FontRenderer::renderText(SkPaint* paint, const Rect* clip, const char *text,
-        uint32_t startIndex, uint32_t len, int numGlyphs, int x, int y, Rect* bounds) {
+void FontRenderer::initRender(const Rect* clip, Rect* bounds) {
     checkInit();
 
-    if (!mCurrentFont) {
-        ALOGE("No font set");
-        return false;
-    }
-
     mDrawn = false;
     mBounds = bounds;
     mClip = clip;
+}
 
-    mCurrentFont->render(paint, text, startIndex, len, numGlyphs, x, y);
-
+void FontRenderer::finishRender() {
     mBounds = NULL;
     mClip = NULL;
 
@@ -888,6 +923,33 @@
         issueDrawCommand();
         mCurrentQuadIndex = 0;
     }
+}
+
+bool FontRenderer::renderText(SkPaint* paint, const Rect* clip, const char *text,
+        uint32_t startIndex, uint32_t len, int numGlyphs, int x, int y, Rect* bounds) {
+    if (!mCurrentFont) {
+        ALOGE("No font set");
+        return false;
+    }
+
+    initRender(clip, bounds);
+    mCurrentFont->render(paint, text, startIndex, len, numGlyphs, x, y);
+    finishRender();
+
+    return mDrawn;
+}
+
+bool FontRenderer::renderPosText(SkPaint* paint, const Rect* clip, const char *text,
+        uint32_t startIndex, uint32_t len, int numGlyphs, int x, int y,
+        const float* positions, Rect* bounds) {
+    if (!mCurrentFont) {
+        ALOGE("No font set");
+        return false;
+    }
+
+    initRender(clip, bounds);
+    mCurrentFont->render(paint, text, startIndex, len, numGlyphs, x, y, positions);
+    finishRender();
 
     return mDrawn;
 }
diff --git a/libs/hwui/FontRenderer.h b/libs/hwui/FontRenderer.h
index 005cdde..b767be5 100644
--- a/libs/hwui/FontRenderer.h
+++ b/libs/hwui/FontRenderer.h
@@ -151,6 +151,10 @@
     void render(SkPaint* paint, const char *text, uint32_t start, uint32_t len,
             int numGlyphs, int x, int y, uint8_t *bitmap = NULL,
             uint32_t bitmapW = 0, uint32_t bitmapH = 0);
+
+    void render(SkPaint* paint, const char *text, uint32_t start, uint32_t len,
+            int numGlyphs, int x, int y, const float* positions);
+
     /**
      * Creates a new font associated with the specified font state.
      */
@@ -160,6 +164,8 @@
 
 protected:
     friend class FontRenderer;
+    typedef void (Font::*RenderGlyph)(CachedGlyphInfo*, int, int, uint8_t*,
+            uint32_t, uint32_t, Rect*, const float*);
 
     enum RenderMode {
         FRAMEBUFFER,
@@ -169,7 +175,7 @@
 
     void render(SkPaint* paint, const char *text, uint32_t start, uint32_t len,
             int numGlyphs, int x, int y, RenderMode mode, uint8_t *bitmap,
-            uint32_t bitmapW, uint32_t bitmapH, Rect *bounds);
+            uint32_t bitmapW, uint32_t bitmapH, Rect *bounds, const float* positions);
 
     void measure(SkPaint* paint, const char* text, uint32_t start, uint32_t len,
             int numGlyphs, Rect *bounds);
@@ -183,11 +189,17 @@
     void invalidateTextureCache(CacheTextureLine *cacheLine = NULL);
 
     CachedGlyphInfo* cacheGlyph(SkPaint* paint, glyph_t glyph);
-    void updateGlyphCache(SkPaint* paint, const SkGlyph& skiaGlyph, CachedGlyphInfo *glyph);
-    void measureCachedGlyph(CachedGlyphInfo *glyph, int x, int y, Rect *bounds);
-    void drawCachedGlyph(CachedGlyphInfo *glyph, int x, int y);
-    void drawCachedGlyph(CachedGlyphInfo *glyph, int x, int y,
-            uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH);
+    void updateGlyphCache(SkPaint* paint, const SkGlyph& skiaGlyph, CachedGlyphInfo* glyph);
+
+    void measureCachedGlyph(CachedGlyphInfo* glyph, int x, int y,
+            uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
+            Rect* bounds, const float* pos);
+    void drawCachedGlyph(CachedGlyphInfo* glyph, int x, int y,
+            uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
+            Rect* bounds, const float* pos);
+    void drawCachedGlyphBitmap(CachedGlyphInfo* glyph, int x, int y,
+            uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
+            Rect* bounds, const float* pos);
 
     CachedGlyphInfo* getCachedGlyph(SkPaint* paint, glyph_t textUnit);
 
@@ -226,8 +238,12 @@
     }
 
     void setFont(SkPaint* paint, uint32_t fontId, float fontSize);
+    // bounds is an out parameter
     bool renderText(SkPaint* paint, const Rect* clip, const char *text, uint32_t startIndex,
             uint32_t len, int numGlyphs, int x, int y, Rect* bounds);
+    // bounds is an out parameter
+    bool renderPosText(SkPaint* paint, const Rect* clip, const char *text, uint32_t startIndex,
+            uint32_t len, int numGlyphs, int x, int y, const float* positions, Rect* bounds);
 
     struct DropShadow {
         DropShadow() { };
@@ -297,6 +313,8 @@
     void initVertexArrayBuffers();
 
     void checkInit();
+    void initRender(const Rect* clip, Rect* bounds);
+    void finishRender();
 
     String16 mLatinPrecache;
     void precacheLatin(SkPaint* paint);
diff --git a/libs/hwui/OpenGLRenderer.cpp b/libs/hwui/OpenGLRenderer.cpp
index 12ed205..786a4f1 100644
--- a/libs/hwui/OpenGLRenderer.cpp
+++ b/libs/hwui/OpenGLRenderer.cpp
@@ -2082,14 +2082,83 @@
     }
 }
 
-void OpenGLRenderer::drawText(const char* text, int bytesCount, int count,
-        float x, float y, SkPaint* paint, float length) {
-    if (text == NULL || count == 0) {
+void OpenGLRenderer::drawPosText(const char* text, int bytesCount, int count,
+        const float* positions, SkPaint* paint) {
+    if (text == NULL || count == 0 || mSnapshot->isIgnored() ||
+            (paint->getAlpha() == 0 && paint->getXfermode() == NULL)) {
         return;
     }
-    if (mSnapshot->isIgnored()) return;
 
-    // NOTE: AA and glyph id encoding are set in DisplayListRenderer.cpp
+    // NOTE: Skia does not support perspective transform on drawPosText yet
+    if (!mSnapshot->transform->isSimple()) {
+        return;
+    }
+
+    float x = 0.0f;
+    float y = 0.0f;
+    const bool pureTranslate = mSnapshot->transform->isPureTranslate();
+    if (pureTranslate) {
+        x = (int) floorf(x + mSnapshot->transform->getTranslateX() + 0.5f);
+        y = (int) floorf(y + mSnapshot->transform->getTranslateY() + 0.5f);
+    }
+
+    FontRenderer& fontRenderer = mCaches.fontRenderer.getFontRenderer(paint);
+    fontRenderer.setFont(paint, SkTypeface::UniqueID(paint->getTypeface()),
+            paint->getTextSize());
+
+    int alpha;
+    SkXfermode::Mode mode;
+    getAlphaAndMode(paint, &alpha, &mode);
+
+    // Pick the appropriate texture filtering
+    bool linearFilter = mSnapshot->transform->changesBounds();
+    if (pureTranslate && !linearFilter) {
+        linearFilter = fabs(y - (int) y) > 0.0f || fabs(x - (int) x) > 0.0f;
+    }
+
+    mCaches.activeTexture(0);
+    setupDraw();
+    setupDrawDirtyRegionsDisabled();
+    setupDrawWithTexture(true);
+    setupDrawAlpha8Color(paint->getColor(), alpha);
+    setupDrawColorFilter();
+    setupDrawShader();
+    setupDrawBlending(true, mode);
+    setupDrawProgram();
+    setupDrawModelView(x, y, x, y, pureTranslate, true);
+    setupDrawTexture(fontRenderer.getTexture(linearFilter));
+    setupDrawPureColorUniforms();
+    setupDrawColorFilterUniforms();
+    setupDrawShaderUniforms(pureTranslate);
+
+    const Rect* clip = pureTranslate ? mSnapshot->clipRect : &mSnapshot->getLocalClip();
+    Rect bounds(FLT_MAX / 2.0f, FLT_MAX / 2.0f, FLT_MIN / 2.0f, FLT_MIN / 2.0f);
+
+#if RENDER_LAYERS_AS_REGIONS
+    bool hasActiveLayer = hasLayer();
+#else
+    bool hasActiveLayer = false;
+#endif
+
+    if (fontRenderer.renderPosText(paint, clip, text, 0, bytesCount, count, x, y,
+            positions, hasActiveLayer ? &bounds : NULL)) {
+#if RENDER_LAYERS_AS_REGIONS
+        if (hasActiveLayer) {
+            if (!pureTranslate) {
+                mSnapshot->transform->mapRect(bounds);
+            }
+            dirtyLayerUnchecked(bounds, getRegion());
+        }
+#endif
+    }
+}
+
+void OpenGLRenderer::drawText(const char* text, int bytesCount, int count,
+        float x, float y, SkPaint* paint, float length) {
+    if (text == NULL || count == 0 || mSnapshot->isIgnored() ||
+            (paint->getAlpha() == 0 && paint->getXfermode() == NULL)) {
+        return;
+    }
 
     switch (paint->getTextAlign()) {
         case SkPaint::kCenter_Align:
@@ -2120,10 +2189,11 @@
         y = (int) floorf(y + mSnapshot->transform->getTranslateY() + 0.5f);
     }
 
-    FontRenderer& fontRenderer = mCaches.fontRenderer.getFontRenderer(paint);
 #if DEBUG_GLYPHS
     ALOGD("OpenGLRenderer drawText() with FontID=%d", SkTypeface::UniqueID(paint->getTypeface()));
 #endif
+
+    FontRenderer& fontRenderer = mCaches.fontRenderer.getFontRenderer(paint);
     fontRenderer.setFont(paint, SkTypeface::UniqueID(paint->getTypeface()),
             paint->getTextSize());
 
@@ -2165,10 +2235,6 @@
         glDrawArrays(GL_TRIANGLE_STRIP, 0, gMeshCount);
     }
 
-    if (paint->getAlpha() == 0 && paint->getXfermode() == NULL) {
-        return;
-    }
-
     // Pick the appropriate texture filtering
     bool linearFilter = mSnapshot->transform->changesBounds();
     if (pureTranslate && !linearFilter) {
diff --git a/libs/hwui/OpenGLRenderer.h b/libs/hwui/OpenGLRenderer.h
index 019e9b2..a9cda47 100644
--- a/libs/hwui/OpenGLRenderer.h
+++ b/libs/hwui/OpenGLRenderer.h
@@ -124,6 +124,8 @@
     virtual void drawPoints(float* points, int count, SkPaint* paint);
     virtual void drawText(const char* text, int bytesCount, int count, float x, float y,
             SkPaint* paint, float length = -1.0f);
+    virtual void drawPosText(const char* text, int bytesCount, int count, const float* positions,
+            SkPaint* paint);
 
     virtual void resetShader();
     virtual void setupShader(SkiaShader* shader);
diff --git a/libs/rs/driver/rsdBcc.cpp b/libs/rs/driver/rsdBcc.cpp
index 24bb288..bec6ffff 100644
--- a/libs/rs/driver/rsdBcc.cpp
+++ b/libs/rs/driver/rsdBcc.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011 The Android Open Source Project
+ * Copyright (C) 2011-2012 The Android Open Source Project
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -36,6 +36,7 @@
 
 struct DrvScript {
     int (*mRoot)();
+    int (*mRootExpand)();
     void (*mInit)();
     void (*mFreeChildren)();
 
@@ -52,6 +53,10 @@
     uint32_t mScriptTextLength;
 };
 
+typedef void (*outer_foreach_t)(
+    const android::renderscript::RsForEachStubParamStruct *,
+    uint32_t x1, uint32_t x2,
+    uint32_t instep, uint32_t outstep);
 
 static Script * setTLS(Script *sc) {
     ScriptTLSStruct * tls = (ScriptTLSStruct *)pthread_getspecific(rsdgThreadTLSKey);
@@ -123,6 +128,7 @@
     }
 
     drv->mRoot = reinterpret_cast<int (*)()>(bccGetFuncAddr(drv->mBccScript, "root"));
+    drv->mRootExpand = reinterpret_cast<int (*)()>(bccGetFuncAddr(drv->mBccScript, "root.expand"));
     drv->mInit = reinterpret_cast<void (*)()>(bccGetFuncAddr(drv->mBccScript, "init"));
     drv->mFreeChildren = reinterpret_cast<void (*)()>(bccGetFuncAddr(drv->mBccScript, ".rs.dtor"));
 
@@ -165,7 +171,12 @@
     script->mHal.info.exportedPragmaCount = drv->ME->getPragmaCount();
     script->mHal.info.exportedPragmaKeyList = drv->ME->getPragmaKeyList();
     script->mHal.info.exportedPragmaValueList = drv->ME->getPragmaValueList();
-    script->mHal.info.root = drv->mRoot;
+
+    if (drv->mRootExpand) {
+      script->mHal.info.root = drv->mRootExpand;
+    } else {
+      script->mHal.info.root = drv->mRoot;
+    }
 
     pthread_mutex_unlock(&rsdgInitMutex);
     return true;
@@ -224,7 +235,7 @@
     RsdHal * dc = (RsdHal *)mtls->rsc->mHal.drv;
     uint32_t sig = mtls->sig;
 
-    outer_foreach_t fn = dc->mForEachLaunch[sig];
+    outer_foreach_t fn = (outer_foreach_t) mtls->script->mHal.info.root;
     while (1) {
         uint32_t slice = (uint32_t)android_atomic_inc(&mtls->mSliceNum);
         uint32_t yStart = mtls->yStart + slice * mtls->mSliceSize;
@@ -240,8 +251,7 @@
             uint32_t offset = mtls->dimX * p.y;
             p.out = mtls->ptrOut + (mtls->eStrideOut * offset);
             p.in = mtls->ptrIn + (mtls->eStrideIn * offset);
-            fn(&mtls->script->mHal.info.root, &p, mtls->xStart, mtls->xEnd,
-               mtls->eStrideIn, mtls->eStrideOut);
+            fn(&p, mtls->xStart, mtls->xEnd, mtls->eStrideIn, mtls->eStrideOut);
         }
     }
 }
@@ -255,7 +265,7 @@
     RsdHal * dc = (RsdHal *)mtls->rsc->mHal.drv;
     uint32_t sig = mtls->sig;
 
-    outer_foreach_t fn = dc->mForEachLaunch[sig];
+    outer_foreach_t fn = (outer_foreach_t) mtls->script->mHal.info.root;
     while (1) {
         uint32_t slice = (uint32_t)android_atomic_inc(&mtls->mSliceNum);
         uint32_t xStart = mtls->xStart + slice * mtls->mSliceSize;
@@ -270,7 +280,7 @@
 
         p.out = mtls->ptrOut + (mtls->eStrideOut * xStart);
         p.in = mtls->ptrIn + (mtls->eStrideIn * xStart);
-        fn(&mtls->script->mHal.info.root, &p, xStart, xEnd, mtls->eStrideIn, mtls->eStrideOut);
+        fn(&p, xStart, xEnd, mtls->eStrideIn, mtls->eStrideOut);
     }
 }
 
@@ -381,7 +391,7 @@
         uint32_t sig = mtls.sig;
 
         //ALOGE("launch 3");
-        outer_foreach_t fn = dc->mForEachLaunch[sig];
+        outer_foreach_t fn = (outer_foreach_t) mtls.script->mHal.info.root;
         for (p.ar[0] = mtls.arrayStart; p.ar[0] < mtls.arrayEnd; p.ar[0]++) {
             for (p.z = mtls.zStart; p.z < mtls.zEnd; p.z++) {
                 for (p.y = mtls.yStart; p.y < mtls.yEnd; p.y++) {
@@ -390,8 +400,8 @@
                                       mtls.dimX * p.y;
                     p.out = mtls.ptrOut + (mtls.eStrideOut * offset);
                     p.in = mtls.ptrIn + (mtls.eStrideIn * offset);
-                    fn(&mtls.script->mHal.info.root, &p, mtls.xStart, mtls.xEnd,
-                       mtls.eStrideIn, mtls.eStrideOut);
+                    fn(&p, mtls.xStart, mtls.xEnd, mtls.eStrideIn,
+                       mtls.eStrideOut);
                 }
             }
         }
diff --git a/libs/rs/driver/rsdCore.cpp b/libs/rs/driver/rsdCore.cpp
index b514e21..1a535d0 100644
--- a/libs/rs/driver/rsdCore.cpp
+++ b/libs/rs/driver/rsdCore.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011 The Android Open Source Project
+ * Copyright (C) 2011-2012 The Android Open Source Project
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -43,7 +43,6 @@
 
 static void Shutdown(Context *rsc);
 static void SetPriority(const Context *rsc, int32_t priority);
-static void initForEach(outer_foreach_t* forEachLaunch);
 
 static RsdHalFunctions FunctionTable = {
     rsdGLInit,
@@ -208,8 +207,6 @@
     rsdgThreadTLSKeyCount++;
     pthread_mutex_unlock(&rsdgInitMutex);
 
-    initForEach(dc->mForEachLaunch);
-
     dc->mTlsStruct.mContext = rsc;
     dc->mTlsStruct.mScript = NULL;
     int status = pthread_setspecific(rsdgThreadTLSKey, &dc->mTlsStruct);
@@ -291,173 +288,3 @@
 
 }
 
-static void rsdForEach17(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, uint32_t);
-    (*(fe*)vRoot)(p->in, p->y);
-}
-
-static void rsdForEach18(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(void *, uint32_t);
-    (*(fe*)vRoot)(p->out, p->y);
-}
-
-static void rsdForEach19(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, void *, uint32_t);
-    (*(fe*)vRoot)(p->in, p->out, p->y);
-}
-
-static void rsdForEach21(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, const void *, uint32_t);
-    (*(fe*)vRoot)(p->in, p->usr, p->y);
-}
-
-static void rsdForEach22(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(void *, const void *, uint32_t);
-    (*(fe*)vRoot)(p->out, p->usr, p->y);
-}
-
-static void rsdForEach23(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, void *, const void *, uint32_t);
-    (*(fe*)vRoot)(p->in, p->out, p->usr, p->y);
-}
-
-static void rsdForEach25(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, uint32_t, uint32_t);
-    const uint8_t *pin = (const uint8_t *)p->in;
-    uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pin, x, y);
-        pin += instep;
-    }
-}
-
-static void rsdForEach26(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(void *, uint32_t, uint32_t);
-    uint8_t *pout = (uint8_t *)p->out;
-    uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pout, x, y);
-        pout += outstep;
-    }
-}
-
-static void rsdForEach27(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, void *, uint32_t, uint32_t);
-    uint8_t *pout = (uint8_t *)p->out;
-    const uint8_t *pin = (const uint8_t *)p->in;
-    uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pin, pout, x, y);
-        pin += instep;
-        pout += outstep;
-    }
-}
-
-static void rsdForEach29(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, const void *, uint32_t, uint32_t);
-    const uint8_t *pin = (const uint8_t *)p->in;
-    const void *usr = p->usr;
-    const uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pin, usr, x, y);
-        pin += instep;
-    }
-}
-
-static void rsdForEach30(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(void *, const void *, uint32_t, uint32_t);
-    uint8_t *pout = (uint8_t *)p->out;
-    const void *usr = p->usr;
-    const uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pout, usr, x, y);
-        pout += outstep;
-    }
-}
-
-static void rsdForEach31(const void *vRoot,
-        const android::renderscript::RsForEachStubParamStruct *p,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep) {
-    typedef void (*fe)(const void *, void *, const void *, uint32_t, uint32_t);
-    uint8_t *pout = (uint8_t *)p->out;
-    const uint8_t *pin = (const uint8_t *)p->in;
-    const void *usr = p->usr;
-    const uint32_t y = p->y;
-    for (uint32_t x = x1; x < x2; x++) {
-        (*(fe*)vRoot)(pin, pout, usr, x, y);
-        pin += instep;
-        pout += outstep;
-    }
-}
-
-
-static void initForEach(outer_foreach_t* forEachLaunch) {
-    rsAssert(forEachLaunch);
-    forEachLaunch[0x00] = NULL;
-    forEachLaunch[0x01] = rsdForEach31; // in
-    forEachLaunch[0x02] = rsdForEach30; //     out
-    forEachLaunch[0x03] = rsdForEach31; // in, out
-    forEachLaunch[0x04] = NULL;
-    forEachLaunch[0x05] = rsdForEach29;  // in,      usr
-    forEachLaunch[0x06] = rsdForEach30; //     out, usr
-    forEachLaunch[0x07] = rsdForEach31; // in, out, usr
-    forEachLaunch[0x08] = NULL;
-    forEachLaunch[0x09] = rsdForEach25; // in,           x
-    forEachLaunch[0x0a] = rsdForEach26; //     out,      x
-    forEachLaunch[0x0b] = rsdForEach27; // in, out,      x
-    forEachLaunch[0x0c] = NULL;
-    forEachLaunch[0x0d] = rsdForEach29; // in,      usr, x
-    forEachLaunch[0x0e] = rsdForEach30; //     out, usr, x
-    forEachLaunch[0x0f] = rsdForEach31; // in, out, usr, x
-    forEachLaunch[0x10] = NULL;
-    forEachLaunch[0x11] = rsdForEach17; // in               y
-    forEachLaunch[0x12] = rsdForEach18; //     out,         y
-    forEachLaunch[0x13] = rsdForEach19; // in, out,         y
-    forEachLaunch[0x14] = NULL;
-    forEachLaunch[0x15] = rsdForEach21; // in,      usr,    y
-    forEachLaunch[0x16] = rsdForEach22; //     out, usr,    y
-    forEachLaunch[0x17] = rsdForEach23; // in, out, usr,    y
-    forEachLaunch[0x18] = NULL;
-    forEachLaunch[0x19] = rsdForEach25; // in,           x, y
-    forEachLaunch[0x1a] = rsdForEach26; //     out,      x, y
-    forEachLaunch[0x1b] = rsdForEach27; // in, out,      x, y
-    forEachLaunch[0x1c] = NULL;
-    forEachLaunch[0x1d] = rsdForEach29; // in,      usr, x, y
-    forEachLaunch[0x1e] = rsdForEach30; //     out, usr, x, y
-    forEachLaunch[0x1f] = rsdForEach31; // in, out, usr, x, y
-}
-
diff --git a/libs/rs/driver/rsdCore.h b/libs/rs/driver/rsdCore.h
index ce86d11..126c87a 100644
--- a/libs/rs/driver/rsdCore.h
+++ b/libs/rs/driver/rsdCore.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011 The Android Open Source Project
+ * Copyright (C) 2011-2012 The Android Open Source Project
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -27,11 +27,6 @@
 typedef void (* InvokeFunc_t)(void);
 typedef void (*WorkerCallback_t)(void *usr, uint32_t idx);
 
-typedef void (*outer_foreach_t)(const void *,
-    const android::renderscript::RsForEachStubParamStruct *,
-                                uint32_t x1, uint32_t x2,
-                                uint32_t instep, uint32_t outstep);
-
 typedef struct RsdSymbolTableRec {
     const char * mName;
     void * mPtr;
@@ -62,8 +57,6 @@
     Workers mWorkers;
     bool mExit;
 
-    outer_foreach_t mForEachLaunch[32];
-
     ScriptTLSStruct mTlsStruct;
 
     RsdGL gl;
diff --git a/libs/rs/scriptc/rs_allocation.rsh b/libs/rs/scriptc/rs_allocation.rsh
index 1cb3a99..9ec03bf 100644
--- a/libs/rs/scriptc/rs_allocation.rsh
+++ b/libs/rs/scriptc/rs_allocation.rsh
@@ -28,13 +28,13 @@
  *
  * To use Renderscript, you need to utilize the Renderscript runtime APIs documented here
  * as well as the Android framework APIs for Renderscript.
- * For documentation on the Android framework APIs, see the <a href=
+ * For documentation on the Android framework APIs, see the <a target="_parent" href=
  * "http://developer.android.com/reference/android/renderscript/package-summary.html">
  * android.renderscript</a> package reference.
  * For more information on how to develop with Renderscript and how the runtime and
- * Android framework APIs interact, see the <a href=
+ * Android framework APIs interact, see the <a target="_parent" href=
  * "http://developer.android.com/guide/topics/renderscript/index.html">Renderscript
- * developer guide</a> and the <a href=
+ * developer guide</a> and the <a target="_parent" href=
  * "http://developer.android.com/resources/samples/RenderScript/index.html">
  * Renderscript samples</a>.
  */
diff --git a/media/java/android/media/AudioService.java b/media/java/android/media/AudioService.java
index 72876d7..2eafd68 100644
--- a/media/java/android/media/AudioService.java
+++ b/media/java/android/media/AudioService.java
@@ -110,7 +110,7 @@
     private static final int SENDMSG_QUEUE = 2;
 
     // AudioHandler message.whats
-    private static final int MSG_SET_SYSTEM_VOLUME = 0;
+    private static final int MSG_SET_DEVICE_VOLUME = 0;
     private static final int MSG_PERSIST_VOLUME = 1;
     private static final int MSG_PERSIST_RINGER_MODE = 3;
     private static final int MSG_PERSIST_VIBRATE_SETTING = 4;
@@ -124,6 +124,7 @@
     private static final int MSG_BT_HEADSET_CNCT_FAILED = 12;
     private static final int MSG_RCDISPLAY_CLEAR = 13;
     private static final int MSG_RCDISPLAY_UPDATE = 14;
+    private static final int MSG_SET_ALL_VOLUMES = 15;
 
 
     // flags for MSG_PERSIST_VOLUME indicating if current and/or last audible volume should be
@@ -329,6 +330,7 @@
     // Keyguard manager proxy
     private KeyguardManager mKeyguardManager;
 
+
     ///////////////////////////////////////////////////////////////////////////
     // Construction
     ///////////////////////////////////////////////////////////////////////////
@@ -431,12 +433,17 @@
 
         // Correct stream index values for streams with aliases
         for (int i = 0; i < numStreamTypes; i++) {
+            int device = getDeviceForStream(i);
             if (STREAM_VOLUME_ALIAS[i] != i) {
-                int index = rescaleIndex(streams[i].mIndex, STREAM_VOLUME_ALIAS[i], i);
-                streams[i].mIndex = streams[i].getValidIndex(index);
-                setStreamVolumeIndex(i, index);
-                index = rescaleIndex(streams[i].mLastAudibleIndex, STREAM_VOLUME_ALIAS[i], i);
-                streams[i].mLastAudibleIndex = streams[i].getValidIndex(index);
+                int index = rescaleIndex(streams[i].getIndex(device, false  /* lastAudible */),
+                                STREAM_VOLUME_ALIAS[i],
+                                i);
+                streams[i].mIndex.put(device, streams[i].getValidIndex(index));
+                streams[i].applyDeviceVolume(device);
+                index = rescaleIndex(streams[i].getIndex(device, true  /* lastAudible */),
+                            STREAM_VOLUME_ALIAS[i],
+                            i);
+                streams[i].mLastAudibleIndex.put(device, streams[i].getValidIndex(index));
             }
         }
     }
@@ -488,10 +495,6 @@
         restoreMediaButtonReceiver();
     }
 
-    private void setStreamVolumeIndex(int stream, int index) {
-        AudioSystem.setStreamVolumeIndex(stream, (index + 5)/10);
-    }
-
     private int rescaleIndex(int index, int srcStream, int dstStream) {
         return (index * mStreamStates[dstStream].getMaxIndex() + mStreamStates[srcStream].getMaxIndex() / 2) / mStreamStates[srcStream].getMaxIndex();
     }
@@ -535,7 +538,11 @@
         // checkForRingerModeChange() in place of STREAM_RING or STREAM_NOTIFICATION)
         int streamTypeAlias = STREAM_VOLUME_ALIAS[streamType];
         VolumeStreamState streamState = mStreamStates[streamTypeAlias];
-        final int oldIndex = (streamState.muteCount() != 0) ? streamState.mLastAudibleIndex : streamState.mIndex;
+
+        final int device = getDeviceForStream(streamTypeAlias);
+        // get last audible index if stream is muted, current index otherwise
+        final int oldIndex = streamState.getIndex(device,
+                                                  (streamState.muteCount() != 0) /* lastAudible */);
         boolean adjustVolume = true;
 
         // If either the client forces allowing ringer modes for this adjustment,
@@ -564,32 +571,32 @@
                     if (STREAM_VOLUME_ALIAS[i] == streamTypeAlias) {
                         VolumeStreamState s = mStreamStates[i];
 
-                        s.adjustLastAudibleIndex(direction);
+                        s.adjustLastAudibleIndex(direction, device);
                         // Post a persist volume msg
                         sendMsg(mAudioHandler,
                                 MSG_PERSIST_VOLUME,
                                 SENDMSG_REPLACE,
                                 PERSIST_LAST_AUDIBLE,
-                                0,
+                                device,
                                 s,
                                 PERSIST_DELAY);
                     }
                 }
             }
-            index = streamState.mLastAudibleIndex;
+            index = streamState.getIndex(device, true  /* lastAudible */);
         } else {
-            if (adjustVolume && streamState.adjustIndex(direction)) {
+            if (adjustVolume && streamState.adjustIndex(direction, device)) {
                 // Post message to set system volume (it in turn will post a message
                 // to persist). Do not change volume if stream is muted.
                 sendMsg(mAudioHandler,
-                        MSG_SET_SYSTEM_VOLUME,
+                        MSG_SET_DEVICE_VOLUME,
                         SENDMSG_NOOP,
-                        0,
+                        device,
                         0,
                         streamState,
                         0);
             }
-            index = streamState.mIndex;
+            index = streamState.getIndex(device, false  /* lastAudible */);
         }
 
         sendVolumeUpdate(streamType, oldIndex, index, flags);
@@ -600,7 +607,10 @@
         ensureValidStreamType(streamType);
         VolumeStreamState streamState = mStreamStates[STREAM_VOLUME_ALIAS[streamType]];
 
-        final int oldIndex = (streamState.muteCount() != 0) ? streamState.mLastAudibleIndex : streamState.mIndex;
+        final int device = getDeviceForStream(streamType);
+        // get last audible index if stream is muted, current index otherwise
+        final int oldIndex = streamState.getIndex(device,
+                                                  (streamState.muteCount() != 0) /* lastAudible */);
 
         // setting ring or notifications volume to 0 on voice capable devices enters silent mode
         if (mVoiceCapable && (((flags & AudioManager.FLAG_ALLOW_RINGER_MODES) != 0) ||
@@ -610,7 +620,11 @@
                 newRingerMode = System.getInt(mContentResolver, System.VIBRATE_IN_SILENT, 1) == 1
                     ? AudioManager.RINGER_MODE_VIBRATE
                     : AudioManager.RINGER_MODE_SILENT;
-                setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType], index, false, true);
+                setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType],
+                                   index,
+                                   device,
+                                   false,
+                                   true);
             } else {
                 newRingerMode = AudioManager.RINGER_MODE_NORMAL;
             }
@@ -618,9 +632,10 @@
         }
 
         index = rescaleIndex(index * 10, streamType, STREAM_VOLUME_ALIAS[streamType]);
-        setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType], index, false, true);
-
-        index = (streamState.muteCount() != 0) ? streamState.mLastAudibleIndex : streamState.mIndex;
+        setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType], index, device, false, true);
+        // get last audible index if stream is muted, current index otherwise
+        index = streamState.getIndex(device,
+                                     (streamState.muteCount() != 0) /* lastAudible */);
 
         sendVolumeUpdate(streamType, oldIndex, index, flags);
     }
@@ -648,35 +663,40 @@
      *
      * @param streamType Type of the stream
      * @param index Desired volume index of the stream
+     * @param device the device whose volume must be changed
      * @param force If true, set the volume even if the desired volume is same
      * as the current volume.
      * @param lastAudible If true, stores new index as last audible one
      */
-    private void setStreamVolumeInt(int streamType, int index, boolean force, boolean lastAudible) {
+    private void setStreamVolumeInt(int streamType,
+                                    int index,
+                                    int device,
+                                    boolean force,
+                                    boolean lastAudible) {
         VolumeStreamState streamState = mStreamStates[streamType];
 
         // If stream is muted, set last audible index only
         if (streamState.muteCount() != 0) {
             // Do not allow last audible index to be 0
             if (index != 0) {
-                streamState.setLastAudibleIndex(index);
+                streamState.setLastAudibleIndex(index, device);
                 // Post a persist volume msg
                 sendMsg(mAudioHandler,
                         MSG_PERSIST_VOLUME,
                         SENDMSG_REPLACE,
                         PERSIST_LAST_AUDIBLE,
-                        0,
+                        device,
                         streamState,
                         PERSIST_DELAY);
             }
         } else {
-            if (streamState.setIndex(index, lastAudible) || force) {
+            if (streamState.setIndex(index, device, lastAudible) || force) {
                 // Post message to set system volume (it in turn will post a message
                 // to persist).
                 sendMsg(mAudioHandler,
-                        MSG_SET_SYSTEM_VOLUME,
+                        MSG_SET_DEVICE_VOLUME,
                         SENDMSG_NOOP,
-                        0,
+                        device,
                         0,
                         streamState,
                         0);
@@ -708,7 +728,8 @@
     /** @see AudioManager#getStreamVolume(int) */
     public int getStreamVolume(int streamType) {
         ensureValidStreamType(streamType);
-        return (mStreamStates[streamType].mIndex + 5) / 10;
+        int device = getDeviceForStream(streamType);
+        return (mStreamStates[streamType].getIndex(device, false  /* lastAudible */) + 5) / 10;
     }
 
     /** @see AudioManager#getStreamMaxVolume(int) */
@@ -721,7 +742,8 @@
     /** Get last audible volume before stream was muted. */
     public int getLastAudibleStreamVolume(int streamType) {
         ensureValidStreamType(streamType);
-        return (mStreamStates[streamType].mLastAudibleIndex + 5) / 10;
+        int device = getDeviceForStream(streamType);
+        return (mStreamStates[streamType].getIndex(device, true  /* lastAudible */) + 5) / 10;
     }
 
     /** @see AudioManager#getRingerMode() */
@@ -764,9 +786,16 @@
                     // ring and notifications volume should never be 0 when not silenced
                     // on voice capable devices
                     if (mVoiceCapable &&
-                            STREAM_VOLUME_ALIAS[streamType] == AudioSystem.STREAM_RING &&
-                            mStreamStates[streamType].mLastAudibleIndex == 0) {
-                        mStreamStates[streamType].mLastAudibleIndex = 10;
+                            STREAM_VOLUME_ALIAS[streamType] == AudioSystem.STREAM_RING) {
+
+                        Set set = mStreamStates[streamType].mLastAudibleIndex.entrySet();
+                        Iterator i = set.iterator();
+                        while (i.hasNext()) {
+                            Map.Entry entry = (Map.Entry)i.next();
+                            if ((Integer)entry.getValue() == 0) {
+                                entry.setValue(10);
+                            }
+                        }
                     }
                     mStreamStates[streamType].mute(null, false);
                     mRingerModeMutedStreams &= ~(1 << streamType);
@@ -988,8 +1017,9 @@
                 }
             }
             int streamType = getActiveStreamType(AudioManager.USE_DEFAULT_STREAM_TYPE);
-            int index = mStreamStates[STREAM_VOLUME_ALIAS[streamType]].mIndex;
-            setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType], index, true, false);
+            int device = getDeviceForStream(streamType);
+            int index = mStreamStates[STREAM_VOLUME_ALIAS[streamType]].getIndex(device, false);
+            setStreamVolumeInt(STREAM_VOLUME_ALIAS[streamType], index, device, true, false);
         }
         return newModeOwnerPid;
     }
@@ -1253,28 +1283,7 @@
         for (int streamType = 0; streamType < numStreamTypes; streamType++) {
             VolumeStreamState streamState = mStreamStates[streamType];
 
-            String settingName = System.VOLUME_SETTINGS[STREAM_VOLUME_ALIAS[streamType]];
-            String lastAudibleSettingName = settingName + System.APPEND_FOR_LAST_AUDIBLE;
-            int index = Settings.System.getInt(mContentResolver,
-                                           settingName,
-                                           AudioManager.DEFAULT_STREAM_VOLUME[streamType]);
-            if (STREAM_VOLUME_ALIAS[streamType] != streamType) {
-                index = rescaleIndex(index * 10, STREAM_VOLUME_ALIAS[streamType], streamType);
-            } else {
-                index *= 10;
-            }
-            streamState.mIndex = streamState.getValidIndex(index);
-
-            index = (index + 5) / 10;
-            index = Settings.System.getInt(mContentResolver,
-                                            lastAudibleSettingName,
-                                            (index > 0) ? index : AudioManager.DEFAULT_STREAM_VOLUME[streamType]);
-            if (STREAM_VOLUME_ALIAS[streamType] != streamType) {
-                index = rescaleIndex(index * 10, STREAM_VOLUME_ALIAS[streamType], streamType);
-            } else {
-                index *= 10;
-            }
-            streamState.mLastAudibleIndex = streamState.getValidIndex(index);
+            streamState.readSettings();
 
             // unmute stream that was muted but is not affect by mute anymore
             if (streamState.muteCount() != 0 && !isStreamAffectedByMute(streamType)) {
@@ -1286,7 +1295,7 @@
             }
             // apply stream volume
             if (streamState.muteCount() == 0) {
-                setStreamVolumeIndex(streamType, streamState.mIndex);
+                streamState.applyAllVolumes();
             }
         }
 
@@ -1877,6 +1886,22 @@
         return false;
     }
 
+    private int getDeviceForStream(int stream) {
+        int device = AudioSystem.getDevicesForStream(stream);
+        if ((device & (device - 1)) != 0) {
+            // Multiple device selection is either:
+            //  - speaker + one other device: give priority to speaker in this case.
+            //  - one A2DP device + another device: happens with duplicated output. In this case
+            // retain the device on the A2DP output as the other must not correspond to an active
+            // selection if not the speaker.
+            if ((device & AudioSystem.DEVICE_OUT_SPEAKER) != 0) {
+                device = AudioSystem.DEVICE_OUT_SPEAKER;
+            } else {
+                device &= AudioSystem.DEVICE_OUT_ALL_A2DP;
+            }
+        }
+        return device;
+    }
 
     ///////////////////////////////////////////////////////////////////////////
     // Inner classes
@@ -1888,54 +1913,127 @@
         private String mVolumeIndexSettingName;
         private String mLastAudibleVolumeIndexSettingName;
         private int mIndexMax;
-        private int mIndex;
-        private int mLastAudibleIndex;
-        private ArrayList<VolumeDeathHandler> mDeathHandlers; //handles mute/solo requests client death
+        private final HashMap <Integer, Integer> mIndex = new HashMap <Integer, Integer>();
+        private final HashMap <Integer, Integer> mLastAudibleIndex =
+                                                                new HashMap <Integer, Integer>();
+        private ArrayList<VolumeDeathHandler> mDeathHandlers; //handles mute/solo clients death
 
         private VolumeStreamState(String settingName, int streamType) {
 
-            setVolumeIndexSettingName(settingName);
+            mVolumeIndexSettingName = settingName;
+            mLastAudibleVolumeIndexSettingName = settingName + System.APPEND_FOR_LAST_AUDIBLE;
 
             mStreamType = streamType;
-
-            final ContentResolver cr = mContentResolver;
             mIndexMax = MAX_STREAM_VOLUME[streamType];
-            mIndex = Settings.System.getInt(cr,
-                                            mVolumeIndexSettingName,
-                                            AudioManager.DEFAULT_STREAM_VOLUME[streamType]);
-            mLastAudibleIndex = Settings.System.getInt(cr,
-                                                       mLastAudibleVolumeIndexSettingName,
-                                                       (mIndex > 0) ? mIndex : AudioManager.DEFAULT_STREAM_VOLUME[streamType]);
             AudioSystem.initStreamVolume(streamType, 0, mIndexMax);
             mIndexMax *= 10;
-            mIndex = getValidIndex(10 * mIndex);
-            mLastAudibleIndex = getValidIndex(10 * mLastAudibleIndex);
-            setStreamVolumeIndex(streamType, mIndex);
+
+            readSettings();
+
+            applyAllVolumes();
+
             mDeathHandlers = new ArrayList<VolumeDeathHandler>();
         }
 
-        public void setVolumeIndexSettingName(String settingName) {
-            mVolumeIndexSettingName = settingName;
-            mLastAudibleVolumeIndexSettingName = settingName + System.APPEND_FOR_LAST_AUDIBLE;
+        public String getSettingNameForDevice(boolean lastAudible, int device) {
+            String name = lastAudible ?
+                            mLastAudibleVolumeIndexSettingName :
+                            mVolumeIndexSettingName;
+            String suffix = AudioSystem.getDeviceName(device);
+            if (suffix.isEmpty()) {
+                return name;
+            }
+            return name + "_" + suffix;
         }
 
-        public boolean adjustIndex(int deltaIndex) {
-            return setIndex(mIndex + deltaIndex * 10, true);
+        public void readSettings() {
+            int index = Settings.System.getInt(mContentResolver,
+                            mVolumeIndexSettingName,
+                            AudioManager.DEFAULT_STREAM_VOLUME[mStreamType]);
+
+            mIndex.clear();
+            mIndex.put(AudioSystem.DEVICE_OUT_DEFAULT, index);
+
+            index = Settings.System.getInt(mContentResolver,
+                            mLastAudibleVolumeIndexSettingName,
+                            (index > 0) ? index : AudioManager.DEFAULT_STREAM_VOLUME[mStreamType]);
+            mLastAudibleIndex.clear();
+            mLastAudibleIndex.put(AudioSystem.DEVICE_OUT_DEFAULT, index);
+
+            int remainingDevices = AudioSystem.DEVICE_OUT_ALL;
+            for (int i = 0; remainingDevices != 0; i++) {
+                int device = (1 << i);
+                if ((device & remainingDevices) == 0) {
+                    continue;
+                }
+                remainingDevices &= ~device;
+
+                // retrieve current volume for device
+                String name = getSettingNameForDevice(false, device);
+                index = Settings.System.getInt(mContentResolver, name, -1);
+                if (index == -1) {
+                    continue;
+                }
+                mIndex.put(device, getValidIndex(10 * index));
+
+                // retrieve last audible volume for device
+                name = getSettingNameForDevice(true, device);
+                index = Settings.System.getInt(mContentResolver, name, -1);
+                mLastAudibleIndex.put(device, getValidIndex(10 * index));
+            }
         }
 
-        public boolean setIndex(int index, boolean lastAudible) {
-            int oldIndex = mIndex;
-            mIndex = getValidIndex(index);
+        public void applyDeviceVolume(int device) {
+            AudioSystem.setStreamVolumeIndex(mStreamType,
+                                             (getIndex(device, false  /* lastAudible */) + 5)/10,
+                                             device);
+        }
 
-            if (oldIndex != mIndex) {
+        public void applyAllVolumes() {
+            // apply default volume first: by convention this will reset all
+            // devices volumes in audio policy manager to the supplied value
+            AudioSystem.setStreamVolumeIndex(mStreamType,
+                    (getIndex(AudioSystem.DEVICE_OUT_DEFAULT, false /* lastAudible */) + 5)/10,
+                    AudioSystem.DEVICE_OUT_DEFAULT);
+            // then apply device specific volumes
+            Set set = mIndex.entrySet();
+            Iterator i = set.iterator();
+            while (i.hasNext()) {
+                Map.Entry entry = (Map.Entry)i.next();
+                int device = ((Integer)entry.getKey()).intValue();
+                if (device != AudioSystem.DEVICE_OUT_DEFAULT) {
+                    AudioSystem.setStreamVolumeIndex(mStreamType,
+                                                     ((Integer)entry.getValue() + 5)/10,
+                                                     device);
+                }
+            }
+        }
+
+        public boolean adjustIndex(int deltaIndex, int device) {
+            return setIndex(getIndex(device,
+                                     false  /* lastAudible */) + deltaIndex * 10,
+                            device,
+                            true  /* lastAudible */);
+        }
+
+        public boolean setIndex(int index, int device, boolean lastAudible) {
+            int oldIndex = getIndex(device, false  /* lastAudible */);
+            index = getValidIndex(index);
+            mIndex.put(device, getValidIndex(index));
+
+            if (oldIndex != index) {
                 if (lastAudible) {
-                    mLastAudibleIndex = mIndex;
+                    mLastAudibleIndex.put(device, index);
                 }
                 // Apply change to all streams using this one as alias
                 int numStreamTypes = AudioSystem.getNumStreamTypes();
                 for (int streamType = numStreamTypes - 1; streamType >= 0; streamType--) {
                     if (streamType != mStreamType && STREAM_VOLUME_ALIAS[streamType] == mStreamType) {
-                        mStreamStates[streamType].setIndex(rescaleIndex(mIndex, mStreamType, streamType), lastAudible);
+                        mStreamStates[streamType].setIndex(rescaleIndex(index,
+                                                                        mStreamType,
+                                                                        streamType),
+                                                           device,
+                                                           lastAudible);
                     }
                 }
                 return true;
@@ -1944,12 +2042,29 @@
             }
         }
 
-        public void setLastAudibleIndex(int index) {
-            mLastAudibleIndex = getValidIndex(index);
+        public int getIndex(int device, boolean lastAudible) {
+            HashMap <Integer, Integer> indexes;
+            if (lastAudible) {
+                indexes = mLastAudibleIndex;
+            } else {
+                indexes = mIndex;
+            }
+            Integer index = indexes.get(device);
+            if (index == null) {
+                // there is always an entry for AudioSystem.DEVICE_OUT_DEFAULT
+                index = indexes.get(AudioSystem.DEVICE_OUT_DEFAULT);
+            }
+            return index.intValue();
         }
 
-        public void adjustLastAudibleIndex(int deltaIndex) {
-            setLastAudibleIndex(mLastAudibleIndex + deltaIndex * 10);
+        public void setLastAudibleIndex(int index, int device) {
+            mLastAudibleIndex.put(device, getValidIndex(index));
+        }
+
+        public void adjustLastAudibleIndex(int deltaIndex, int device) {
+            setLastAudibleIndex(getIndex(device,
+                                         true  /* lastAudible */) + deltaIndex * 10,
+                                device);
         }
 
         public int getMaxIndex() {
@@ -1994,10 +2109,20 @@
                                     mICallback.linkToDeath(this, 0);
                                 }
                                 mDeathHandlers.add(this);
-                                // If the stream is not yet muted by any client, set lvel to 0
+                                // If the stream is not yet muted by any client, set level to 0
                                 if (muteCount() == 0) {
-                                    setIndex(0, false);
-                                    sendMsg(mAudioHandler, MSG_SET_SYSTEM_VOLUME, SENDMSG_NOOP, 0, 0,
+                                    Set set = mIndex.entrySet();
+                                    Iterator i = set.iterator();
+                                    while (i.hasNext()) {
+                                        Map.Entry entry = (Map.Entry)i.next();
+                                        int device = ((Integer)entry.getKey()).intValue();
+                                        setIndex(0, device, false /* lastAudible */);
+                                    }
+                                    sendMsg(mAudioHandler,
+                                            MSG_SET_ALL_VOLUMES,
+                                            SENDMSG_NOOP,
+                                            0,
+                                            0,
                                             VolumeStreamState.this, 0);
                                 }
                             } catch (RemoteException e) {
@@ -2026,9 +2151,22 @@
                                     // If the stream is not muted any more, restore it's volume if
                                     // ringer mode allows it
                                     if (!isStreamAffectedByRingerMode(mStreamType) ||
-                                            getRingerMode() == AudioManager.RINGER_MODE_NORMAL) {
-                                        setIndex(mLastAudibleIndex, false);
-                                        sendMsg(mAudioHandler, MSG_SET_SYSTEM_VOLUME, SENDMSG_NOOP, 0, 0,
+                                            mRingerMode == AudioManager.RINGER_MODE_NORMAL) {
+                                        Set set = mIndex.entrySet();
+                                        Iterator i = set.iterator();
+                                        while (i.hasNext()) {
+                                            Map.Entry entry = (Map.Entry)i.next();
+                                            int device = ((Integer)entry.getKey()).intValue();
+                                            setIndex(getIndex(device,
+                                                              true  /* lastAudible */),
+                                                     device,
+                                                     false  /* lastAudible */);
+                                        }
+                                        sendMsg(mAudioHandler,
+                                                MSG_SET_ALL_VOLUMES,
+                                                SENDMSG_NOOP,
+                                                0,
+                                                0,
                                                 VolumeStreamState.this, 0);
                                     }
                                 }
@@ -2107,17 +2245,17 @@
     /** Handles internal volume messages in separate volume thread. */
     private class AudioHandler extends Handler {
 
-        private void setSystemVolume(VolumeStreamState streamState) {
+        private void setDeviceVolume(VolumeStreamState streamState, int device) {
 
-            // Adjust volume
-            setStreamVolumeIndex(streamState.mStreamType, streamState.mIndex);
+            // Apply volume
+            streamState.applyDeviceVolume(device);
 
             // Apply change to all streams using this one as alias
             int numStreamTypes = AudioSystem.getNumStreamTypes();
             for (int streamType = numStreamTypes - 1; streamType >= 0; streamType--) {
                 if (streamType != streamState.mStreamType &&
-                    STREAM_VOLUME_ALIAS[streamType] == streamState.mStreamType) {
-                    setStreamVolumeIndex(streamType, mStreamStates[streamType].mIndex);
+                        STREAM_VOLUME_ALIAS[streamType] == streamState.mStreamType) {
+                    mStreamStates[streamType].applyDeviceVolume(device);
                 }
             }
 
@@ -2126,21 +2264,39 @@
                     MSG_PERSIST_VOLUME,
                     SENDMSG_REPLACE,
                     PERSIST_CURRENT|PERSIST_LAST_AUDIBLE,
-                    0,
+                    device,
                     streamState,
                     PERSIST_DELAY);
 
         }
 
+        private void setAllVolumes(VolumeStreamState streamState) {
+
+            // Apply volume
+            streamState.applyAllVolumes();
+
+            // Apply change to all streams using this one as alias
+            int numStreamTypes = AudioSystem.getNumStreamTypes();
+            for (int streamType = numStreamTypes - 1; streamType >= 0; streamType--) {
+                if (streamType != streamState.mStreamType &&
+                        STREAM_VOLUME_ALIAS[streamType] == streamState.mStreamType) {
+                    mStreamStates[streamType].applyAllVolumes();
+                }
+            }
+        }
+
         private void persistVolume(VolumeStreamState streamState,
-                                   int persistType) {
+                                   int persistType,
+                                   int device) {
             if ((persistType & PERSIST_CURRENT) != 0) {
-                System.putInt(mContentResolver, streamState.mVolumeIndexSettingName,
-                              (streamState.mIndex + 5)/ 10);
+                System.putInt(mContentResolver,
+                          streamState.getSettingNameForDevice(false /* lastAudible */, device),
+                          (streamState.getIndex(device, false /* lastAudible */) + 5)/ 10);
             }
             if ((persistType & PERSIST_LAST_AUDIBLE) != 0) {
-                System.putInt(mContentResolver, streamState.mLastAudibleVolumeIndexSettingName,
-                    (streamState.mLastAudibleIndex + 5) / 10);
+                System.putInt(mContentResolver,
+                        streamState.getSettingNameForDevice(true /* lastAudible */, device),
+                        (streamState.getIndex(device, true  /* lastAudible */) + 5) / 10);
             }
         }
 
@@ -2223,12 +2379,16 @@
 
             switch (msg.what) {
 
-                case MSG_SET_SYSTEM_VOLUME:
-                    setSystemVolume((VolumeStreamState) msg.obj);
+                case MSG_SET_DEVICE_VOLUME:
+                    setDeviceVolume((VolumeStreamState) msg.obj, msg.arg1);
+                    break;
+
+                case MSG_SET_ALL_VOLUMES:
+                    setAllVolumes((VolumeStreamState) msg.obj);
                     break;
 
                 case MSG_PERSIST_VOLUME:
-                    persistVolume((VolumeStreamState) msg.obj, msg.arg1);
+                    persistVolume((VolumeStreamState) msg.obj, msg.arg1, msg.arg2);
                     break;
 
                 case MSG_PERSIST_RINGER_MODE:
@@ -2264,7 +2424,7 @@
                     synchronized (mConnectedDevices) {
                         Set set = mConnectedDevices.entrySet();
                         Iterator i = set.iterator();
-                        while(i.hasNext()){
+                        while (i.hasNext()) {
                             Map.Entry device = (Map.Entry)i.next();
                             AudioSystem.setDeviceConnectionState(
                                                             ((Integer)device.getKey()).intValue(),
@@ -2282,15 +2442,10 @@
                     // Restore stream volumes
                     int numStreamTypes = AudioSystem.getNumStreamTypes();
                     for (int streamType = numStreamTypes - 1; streamType >= 0; streamType--) {
-                        int index;
                         VolumeStreamState streamState = mStreamStates[streamType];
                         AudioSystem.initStreamVolume(streamType, 0, (streamState.mIndexMax + 5) / 10);
-                        if (streamState.muteCount() == 0) {
-                            index = streamState.mIndex;
-                        } else {
-                            index = 0;
-                        }
-                        setStreamVolumeIndex(streamType, index);
+
+                        streamState.applyAllVolumes();
                     }
 
                     // Restore ringer mode
diff --git a/media/java/android/media/AudioSystem.java b/media/java/android/media/AudioSystem.java
index 474a842..81145d3 100644
--- a/media/java/android/media/AudioSystem.java
+++ b/media/java/android/media/AudioSystem.java
@@ -183,6 +183,7 @@
         }
     }
 
+
     /*
      * AudioPolicyService methods
      */
@@ -202,6 +203,23 @@
     public static final int DEVICE_OUT_ANLG_DOCK_HEADSET = 0x800;
     public static final int DEVICE_OUT_DGTL_DOCK_HEADSET = 0x1000;
     public static final int DEVICE_OUT_DEFAULT = 0x8000;
+    public static final int DEVICE_OUT_ALL = (DEVICE_OUT_EARPIECE |
+                                              DEVICE_OUT_SPEAKER |
+                                              DEVICE_OUT_WIRED_HEADSET |
+                                              DEVICE_OUT_WIRED_HEADPHONE |
+                                              DEVICE_OUT_BLUETOOTH_SCO |
+                                              DEVICE_OUT_BLUETOOTH_SCO_HEADSET |
+                                              DEVICE_OUT_BLUETOOTH_SCO_CARKIT |
+                                              DEVICE_OUT_BLUETOOTH_A2DP |
+                                              DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES |
+                                              DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER |
+                                              DEVICE_OUT_AUX_DIGITAL |
+                                              DEVICE_OUT_ANLG_DOCK_HEADSET |
+                                              DEVICE_OUT_DGTL_DOCK_HEADSET |
+                                              DEVICE_OUT_DEFAULT);
+    public static final int DEVICE_OUT_ALL_A2DP = (DEVICE_OUT_BLUETOOTH_A2DP |
+                                                   DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES |
+                                                   DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER);
     // input devices
     public static final int DEVICE_IN_COMMUNICATION = 0x10000;
     public static final int DEVICE_IN_AMBIENT = 0x20000;
@@ -218,6 +236,54 @@
     public static final int DEVICE_STATE_AVAILABLE = 1;
     private static final int NUM_DEVICE_STATES = 1;
 
+    public static final String DEVICE_OUT_EARPIECE_NAME = "earpiece";
+    public static final String DEVICE_OUT_SPEAKER_NAME = "speaker";
+    public static final String DEVICE_OUT_WIRED_HEADSET_NAME = "headset";
+    public static final String DEVICE_OUT_WIRED_HEADPHONE_NAME = "headphone";
+    public static final String DEVICE_OUT_BLUETOOTH_SCO_NAME = "bt_sco";
+    public static final String DEVICE_OUT_BLUETOOTH_SCO_HEADSET_NAME = "bt_sco_hs";
+    public static final String DEVICE_OUT_BLUETOOTH_SCO_CARKIT_NAME = "bt_sco_carkit";
+    public static final String DEVICE_OUT_BLUETOOTH_A2DP_NAME = "bt_a2dp";
+    public static final String DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES_NAME = "bt_a2dp_hp";
+    public static final String DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER_NAME = "bt_a2dp_spk";
+    public static final String DEVICE_OUT_AUX_DIGITAL_NAME = "aux_digital";
+    public static final String DEVICE_OUT_ANLG_DOCK_HEADSET_NAME = "analog_dock";
+    public static final String DEVICE_OUT_DGTL_DOCK_HEADSET_NAME = "digital_dock";
+
+    public static String getDeviceName(int device)
+    {
+        switch(device) {
+        case DEVICE_OUT_EARPIECE:
+            return DEVICE_OUT_EARPIECE_NAME;
+        case DEVICE_OUT_SPEAKER:
+            return DEVICE_OUT_SPEAKER_NAME;
+        case DEVICE_OUT_WIRED_HEADSET:
+            return DEVICE_OUT_WIRED_HEADSET_NAME;
+        case DEVICE_OUT_WIRED_HEADPHONE:
+            return DEVICE_OUT_WIRED_HEADPHONE_NAME;
+        case DEVICE_OUT_BLUETOOTH_SCO:
+            return DEVICE_OUT_BLUETOOTH_SCO_NAME;
+        case DEVICE_OUT_BLUETOOTH_SCO_HEADSET:
+            return DEVICE_OUT_BLUETOOTH_SCO_HEADSET_NAME;
+        case DEVICE_OUT_BLUETOOTH_SCO_CARKIT:
+            return DEVICE_OUT_BLUETOOTH_SCO_CARKIT_NAME;
+        case DEVICE_OUT_BLUETOOTH_A2DP:
+            return DEVICE_OUT_BLUETOOTH_A2DP_NAME;
+        case DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES:
+            return DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES_NAME;
+        case DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER:
+            return DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER_NAME;
+        case DEVICE_OUT_AUX_DIGITAL:
+            return DEVICE_OUT_AUX_DIGITAL_NAME;
+        case DEVICE_OUT_ANLG_DOCK_HEADSET:
+            return DEVICE_OUT_ANLG_DOCK_HEADSET_NAME;
+        case DEVICE_OUT_DGTL_DOCK_HEADSET:
+            return DEVICE_OUT_DGTL_DOCK_HEADSET_NAME;
+        default:
+            return "";
+        }
+    }
+
     // phone state, match audio_mode???
     public static final int PHONE_STATE_OFFCALL = 0;
     public static final int PHONE_STATE_RINGING = 1;
@@ -251,7 +317,7 @@
     public static native int setForceUse(int usage, int config);
     public static native int getForceUse(int usage);
     public static native int initStreamVolume(int stream, int indexMin, int indexMax);
-    public static native int setStreamVolumeIndex(int stream, int index);
-    public static native int getStreamVolumeIndex(int stream);
+    public static native int setStreamVolumeIndex(int stream, int index, int device);
+    public static native int getStreamVolumeIndex(int stream, int device);
     public static native int getDevicesForStream(int stream);
 }
diff --git a/media/jni/android_media_MediaPlayer.cpp b/media/jni/android_media_MediaPlayer.cpp
index 39fd9a9..8ff9dd3 100644
--- a/media/jni/android_media_MediaPlayer.cpp
+++ b/media/jni/android_media_MediaPlayer.cpp
@@ -479,7 +479,7 @@
         jniThrowException(env, "java/lang/IllegalStateException", NULL);
         return;
     }
-    process_media_player_call( env, thiz, mp->setAudioStreamType(streamtype) , NULL, NULL );
+    process_media_player_call( env, thiz, mp->setAudioStreamType((audio_stream_type_t) streamtype) , NULL, NULL );
 }
 
 static void
diff --git a/media/jni/soundpool/SoundPool.cpp b/media/jni/soundpool/SoundPool.cpp
index b5303ef..0d51def 100644
--- a/media/jni/soundpool/SoundPool.cpp
+++ b/media/jni/soundpool/SoundPool.cpp
@@ -39,7 +39,7 @@
 uint32_t kDefaultSampleRate = 44100;
 uint32_t kDefaultFrameCount = 1200;
 
-SoundPool::SoundPool(int maxChannels, int streamType, int srcQuality)
+SoundPool::SoundPool(int maxChannels, audio_stream_type_t streamType, int srcQuality)
 {
     ALOGV("SoundPool constructor: maxChannels=%d, streamType=%d, srcQuality=%d",
             maxChannels, streamType, srcQuality);
@@ -570,7 +570,7 @@
         // initialize track
         int afFrameCount;
         int afSampleRate;
-        int streamType = mSoundPool->streamType();
+        audio_stream_type_t streamType = mSoundPool->streamType();
         if (AudioSystem::getOutputFrameCount(&afFrameCount, streamType) != NO_ERROR) {
             afFrameCount = kDefaultFrameCount;
         }
diff --git a/media/jni/soundpool/SoundPool.h b/media/jni/soundpool/SoundPool.h
index 1b91b3b..6b11c28 100644
--- a/media/jni/soundpool/SoundPool.h
+++ b/media/jni/soundpool/SoundPool.h
@@ -162,7 +162,7 @@
     friend class SoundPoolThread;
     friend class SoundChannel;
 public:
-    SoundPool(int maxChannels, int streamType, int srcQuality);
+    SoundPool(int maxChannels, audio_stream_type_t streamType, int srcQuality);
     ~SoundPool();
     int load(const char* url, int priority);
     int load(int fd, int64_t offset, int64_t length, int priority);
@@ -178,7 +178,7 @@
     void setPriority(int channelID, int priority);
     void setLoop(int channelID, int loop);
     void setRate(int channelID, float rate);
-    int streamType() const { return mStreamType; }
+    audio_stream_type_t streamType() const { return mStreamType; }
     int srcQuality() const { return mSrcQuality; }
 
     // called from SoundPoolThread
@@ -220,7 +220,7 @@
     List<SoundChannel*>     mStop;
     DefaultKeyedVector< int, sp<Sample> >   mSamples;
     int                     mMaxChannels;
-    int                     mStreamType;
+    audio_stream_type_t     mStreamType;
     int                     mSrcQuality;
     int                     mAllocated;
     int                     mNextSampleID;
diff --git a/media/jni/soundpool/android_media_SoundPool.cpp b/media/jni/soundpool/android_media_SoundPool.cpp
index fe1c20a..da3af9d 100644
--- a/media/jni/soundpool/android_media_SoundPool.cpp
+++ b/media/jni/soundpool/android_media_SoundPool.cpp
@@ -179,7 +179,7 @@
 android_media_SoundPool_native_setup(JNIEnv *env, jobject thiz, jobject weakRef, jint maxChannels, jint streamType, jint srcQuality)
 {
     ALOGV("android_media_SoundPool_native_setup");
-    SoundPool *ap = new SoundPool(maxChannels, streamType, srcQuality);
+    SoundPool *ap = new SoundPool(maxChannels, (audio_stream_type_t) streamType, srcQuality);
     if (ap == NULL) {
         return -1;
     }
diff --git a/media/libmedia/Android.mk b/media/libmedia/Android.mk
index 7af4a87..23670df 100644
--- a/media/libmedia/Android.mk
+++ b/media/libmedia/Android.mk
@@ -43,13 +43,12 @@
     IEffectClient.cpp \
     AudioEffect.cpp \
     Visualizer.cpp \
-    MemoryLeakTrackUtil.cpp \
-    fixedfft.cpp.arm
+    MemoryLeakTrackUtil.cpp
 
 LOCAL_SHARED_LIBRARIES := \
 	libui libcutils libutils libbinder libsonivox libicuuc libexpat \
         libcamera_client libstagefright_foundation \
-        libgui libdl
+        libgui libdl libaudioutils
 
 LOCAL_WHOLE_STATIC_LIBRARY := libmedia_helper
 
@@ -61,6 +60,7 @@
     $(TOP)/frameworks/base/include/media/stagefright/openmax \
     external/icu4c/common \
     external/expat/lib \
-    system/media/audio_effects/include
+    system/media/audio_effects/include \
+    system/media/audio_utils/include
 
 include $(BUILD_SHARED_LIBRARY)
diff --git a/media/libmedia/AudioRecord.cpp b/media/libmedia/AudioRecord.cpp
index 8e4a9d6..32b5bac 100644
--- a/media/libmedia/AudioRecord.cpp
+++ b/media/libmedia/AudioRecord.cpp
@@ -263,7 +263,7 @@
     return mFrameCount;
 }
 
-int AudioRecord::frameSize() const
+size_t AudioRecord::frameSize() const
 {
     if (audio_is_linear_pcm(mFormat)) {
         return channelCount()*audio_bytes_per_sample(mFormat);
diff --git a/media/libmedia/AudioSystem.cpp b/media/libmedia/AudioSystem.cpp
index 9d4137e..f532d35 100644
--- a/media/libmedia/AudioSystem.cpp
+++ b/media/libmedia/AudioSystem.cpp
@@ -120,7 +120,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::setStreamVolume(int stream, float value, int output)
+status_t AudioSystem::setStreamVolume(audio_stream_type_t stream, float value, int output)
 {
     if (uint32_t(stream) >= AUDIO_STREAM_CNT) return BAD_VALUE;
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
@@ -129,7 +129,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::setStreamMute(int stream, bool mute)
+status_t AudioSystem::setStreamMute(audio_stream_type_t stream, bool mute)
 {
     if (uint32_t(stream) >= AUDIO_STREAM_CNT) return BAD_VALUE;
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
@@ -138,7 +138,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::getStreamVolume(int stream, float* volume, int output)
+status_t AudioSystem::getStreamVolume(audio_stream_type_t stream, float* volume, int output)
 {
     if (uint32_t(stream) >= AUDIO_STREAM_CNT) return BAD_VALUE;
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
@@ -147,7 +147,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::getStreamMute(int stream, bool* mute)
+status_t AudioSystem::getStreamMute(audio_stream_type_t stream, bool* mute)
 {
     if (uint32_t(stream) >= AUDIO_STREAM_CNT) return BAD_VALUE;
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
@@ -156,7 +156,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::setMode(int mode)
+status_t AudioSystem::setMode(audio_mode_t mode)
 {
     if (uint32_t(mode) >= AUDIO_MODE_CNT) return BAD_VALUE;
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
@@ -203,7 +203,12 @@
     return volume ? 100 - int(dBConvertInverse * log(volume) + 0.5) : 0;
 }
 
-status_t AudioSystem::getOutputSamplingRate(int* samplingRate, int streamType)
+// DEPRECATED
+status_t AudioSystem::getOutputSamplingRate(int* samplingRate, int streamType) {
+    return getOutputSamplingRate(samplingRate, (audio_stream_type_t)streamType);
+}
+
+status_t AudioSystem::getOutputSamplingRate(int* samplingRate, audio_stream_type_t streamType)
 {
     OutputDescriptor *outputDesc;
     audio_io_handle_t output;
@@ -212,7 +217,7 @@
         streamType = AUDIO_STREAM_MUSIC;
     }
 
-    output = getOutput((audio_stream_type_t)streamType);
+    output = getOutput(streamType);
     if (output == 0) {
         return PERMISSION_DENIED;
     }
@@ -236,7 +241,12 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::getOutputFrameCount(int* frameCount, int streamType)
+// DEPRECATED
+status_t AudioSystem::getOutputFrameCount(int* frameCount, int streamType) {
+    return getOutputFrameCount(frameCount, (audio_stream_type_t)streamType);
+}
+
+status_t AudioSystem::getOutputFrameCount(int* frameCount, audio_stream_type_t streamType)
 {
     OutputDescriptor *outputDesc;
     audio_io_handle_t output;
@@ -245,7 +255,7 @@
         streamType = AUDIO_STREAM_MUSIC;
     }
 
-    output = getOutput((audio_stream_type_t)streamType);
+    output = getOutput(streamType);
     if (output == 0) {
         return PERMISSION_DENIED;
     }
@@ -267,7 +277,7 @@
     return NO_ERROR;
 }
 
-status_t AudioSystem::getOutputLatency(uint32_t* latency, int streamType)
+status_t AudioSystem::getOutputLatency(uint32_t* latency, audio_stream_type_t streamType)
 {
     OutputDescriptor *outputDesc;
     audio_io_handle_t output;
@@ -276,7 +286,7 @@
         streamType = AUDIO_STREAM_MUSIC;
     }
 
-    output = getOutput((audio_stream_type_t)streamType);
+    output = getOutput(streamType);
     if (output == 0) {
         return PERMISSION_DENIED;
     }
@@ -333,7 +343,7 @@
     return af->setVoiceVolume(value);
 }
 
-status_t AudioSystem::getRenderPosition(uint32_t *halFrames, uint32_t *dspFrames, int stream)
+status_t AudioSystem::getRenderPosition(uint32_t *halFrames, uint32_t *dspFrames, audio_stream_type_t stream)
 {
     const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger();
     if (af == 0) return PERMISSION_DENIED;
@@ -342,7 +352,7 @@
         stream = AUDIO_STREAM_MUSIC;
     }
 
-    return af->getRenderPosition(halFrames, dspFrames, getOutput((audio_stream_type_t)stream));
+    return af->getRenderPosition(halFrames, dspFrames, getOutput(stream));
 }
 
 unsigned int AudioSystem::getInputFramesLost(audio_io_handle_t ioHandle) {
@@ -467,7 +477,7 @@
     gAudioErrorCallback = cb;
 }
 
-bool AudioSystem::routedToA2dpOutput(int streamType) {
+bool AudioSystem::routedToA2dpOutput(audio_stream_type_t streamType) {
     switch(streamType) {
     case AUDIO_STREAM_MUSIC:
     case AUDIO_STREAM_VOICE_CALL:
@@ -536,7 +546,7 @@
     return aps->getDeviceConnectionState(device, device_address);
 }
 
-status_t AudioSystem::setPhoneState(int state)
+status_t AudioSystem::setPhoneState(audio_mode_t state)
 {
     const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service();
     if (aps == 0) return PERMISSION_DENIED;
@@ -668,18 +678,22 @@
     return aps->initStreamVolume(stream, indexMin, indexMax);
 }
 
-status_t AudioSystem::setStreamVolumeIndex(audio_stream_type_t stream, int index)
+status_t AudioSystem::setStreamVolumeIndex(audio_stream_type_t stream,
+                                           int index,
+                                           audio_devices_t device)
 {
     const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service();
     if (aps == 0) return PERMISSION_DENIED;
-    return aps->setStreamVolumeIndex(stream, index);
+    return aps->setStreamVolumeIndex(stream, index, device);
 }
 
-status_t AudioSystem::getStreamVolumeIndex(audio_stream_type_t stream, int *index)
+status_t AudioSystem::getStreamVolumeIndex(audio_stream_type_t stream,
+                                           int *index,
+                                           audio_devices_t device)
 {
     const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service();
     if (aps == 0) return PERMISSION_DENIED;
-    return aps->getStreamVolumeIndex(stream, index);
+    return aps->getStreamVolumeIndex(stream, index, device);
 }
 
 uint32_t AudioSystem::getStrategyForStream(audio_stream_type_t stream)
@@ -728,7 +742,7 @@
     return aps->setEffectEnabled(id, enabled);
 }
 
-status_t AudioSystem::isStreamActive(int stream, bool* state, uint32_t inPastMs)
+status_t AudioSystem::isStreamActive(audio_stream_type_t stream, bool* state, uint32_t inPastMs)
 {
     const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service();
     if (aps == 0) return PERMISSION_DENIED;
diff --git a/media/libmedia/AudioTrack.cpp b/media/libmedia/AudioTrack.cpp
index 9c650ad..837fcc3 100644
--- a/media/libmedia/AudioTrack.cpp
+++ b/media/libmedia/AudioTrack.cpp
@@ -49,7 +49,7 @@
 // static
 status_t AudioTrack::getMinFrameCount(
         int* frameCount,
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate)
 {
     int afSampleRate;
@@ -83,7 +83,7 @@
 }
 
 AudioTrack::AudioTrack(
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate,
         audio_format_t format,
         int channelMask,
@@ -104,6 +104,25 @@
 AudioTrack::AudioTrack(
         int streamType,
         uint32_t sampleRate,
+        int format,
+        int channelMask,
+        int frameCount,
+        uint32_t flags,
+        callback_t cbf,
+        void* user,
+        int notificationFrames,
+        int sessionId)
+    : mStatus(NO_INIT),
+      mPreviousPriority(ANDROID_PRIORITY_NORMAL), mPreviousSchedulingGroup(ANDROID_TGROUP_DEFAULT)
+{
+    mStatus = set((audio_stream_type_t)streamType, sampleRate, (audio_format_t)format, channelMask,
+            frameCount, flags, cbf, user, notificationFrames,
+            0, false, sessionId);
+}
+
+AudioTrack::AudioTrack(
+        audio_stream_type_t streamType,
+        uint32_t sampleRate,
         audio_format_t format,
         int channelMask,
         const sp<IMemory>& sharedBuffer,
@@ -140,7 +159,7 @@
 }
 
 status_t AudioTrack::set(
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate,
         audio_format_t format,
         int channelMask,
@@ -204,7 +223,7 @@
     uint32_t channelCount = popcount(channelMask);
 
     audio_io_handle_t output = AudioSystem::getOutput(
-                                    (audio_stream_type_t)streamType,
+                                    streamType,
                                     sampleRate, format, channelMask,
                                     (audio_policy_output_flags_t)flags);
 
@@ -215,7 +234,7 @@
 
     mVolume[LEFT] = 1.0f;
     mVolume[RIGHT] = 1.0f;
-    mSendLevel = 0;
+    mSendLevel = 0.0f;
     mFrameCount = frameCount;
     mNotificationFramesReq = notificationFrames;
     mSessionId = sessionId;
@@ -275,7 +294,7 @@
     return mLatency;
 }
 
-int AudioTrack::streamType() const
+audio_stream_type_t AudioTrack::streamType() const
 {
     return mStreamType;
 }
@@ -295,7 +314,7 @@
     return mCblk->frameCount;
 }
 
-int AudioTrack::frameSize() const
+size_t AudioTrack::frameSize() const
 {
     if (audio_is_linear_pcm(mFormat)) {
         return channelCount()*audio_bytes_per_sample(mFormat);
@@ -480,7 +499,6 @@
     mVolume[LEFT] = left;
     mVolume[RIGHT] = right;
 
-    // write must be atomic
     mCblk->volumeLR = (uint32_t(uint16_t(right * 0x1000)) << 16) | uint16_t(left * 0x1000);
 
     return NO_ERROR;
@@ -499,14 +517,14 @@
 status_t AudioTrack::setAuxEffectSendLevel(float level)
 {
     ALOGV("setAuxEffectSendLevel(%f)", level);
-    if (level > 1.0f) {
+    if (level < 0.0f || level > 1.0f) {
         return BAD_VALUE;
     }
     AutoMutex lock(mLock);
 
     mSendLevel = level;
 
-    mCblk->sendLevel = uint16_t(level * 0x1000);
+    mCblk->setSendLevel(level);
 
     return NO_ERROR;
 }
@@ -688,7 +706,7 @@
 // must be called with mLock held
 audio_io_handle_t AudioTrack::getOutput_l()
 {
-    return AudioSystem::getOutput((audio_stream_type_t)mStreamType,
+    return AudioSystem::getOutput(mStreamType,
             mCblk->sampleRate, mFormat, mChannelMask, (audio_policy_output_flags_t)mFlags);
 }
 
@@ -711,7 +729,7 @@
 
 // must be called with mLock held
 status_t AudioTrack::createTrack_l(
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate,
         audio_format_t format,
         uint32_t channelMask,
@@ -818,7 +836,7 @@
     }
 
     mCblk->volumeLR = (uint32_t(uint16_t(mVolume[RIGHT] * 0x1000)) << 16) | uint16_t(mVolume[LEFT] * 0x1000);
-    mCblk->sendLevel = uint16_t(mSendLevel * 0x1000);
+    mCblk->setSendLevel(mSendLevel);
     mAudioTrack->attachAuxEffect(mAuxEffectId);
     mCblk->bufferTimeoutMs = MAX_STARTUP_TIMEOUT_MS;
     mCblk->waitTimeMs = 0;
@@ -979,7 +997,7 @@
     ssize_t written = 0;
     const int8_t *src = (const int8_t *)buffer;
     Buffer audioBuffer;
-    size_t frameSz = (size_t)frameSize();
+    size_t frameSz = frameSize();
 
     do {
         audioBuffer.frameCount = userSize/frameSz;
@@ -1137,7 +1155,7 @@
 
         audioBuffer.size = writtenSize;
         // NOTE: mCblk->frameSize is not equal to AudioTrack::frameSize() for
-        // 8 bit PCM data: in this case,  mCblk->frameSize is based on a sampel size of
+        // 8 bit PCM data: in this case,  mCblk->frameSize is based on a sample size of
         // 16 bit.
         audioBuffer.frameCount = writtenSize/mCblk->frameSize;
 
@@ -1311,7 +1329,7 @@
     : lock(Mutex::SHARED), cv(Condition::SHARED), user(0), server(0),
     userBase(0), serverBase(0), buffers(0), frameCount(0),
     loopStart(UINT_MAX), loopEnd(UINT_MAX), loopCount(0), volumeLR(0),
-    sendLevel(0), flags(0)
+    mSendLevel(0), flags(0)
 {
 }
 
diff --git a/media/libmedia/IAudioFlinger.cpp b/media/libmedia/IAudioFlinger.cpp
index abd491f..eef551c 100644
--- a/media/libmedia/IAudioFlinger.cpp
+++ b/media/libmedia/IAudioFlinger.cpp
@@ -82,7 +82,7 @@
 
     virtual sp<IAudioTrack> createTrack(
                                 pid_t pid,
-                                int streamType,
+                                audio_stream_type_t streamType,
                                 uint32_t sampleRate,
                                 uint32_t format,
                                 uint32_t channelMask,
@@ -97,7 +97,7 @@
         sp<IAudioTrack> track;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
         data.writeInt32(pid);
-        data.writeInt32(streamType);
+        data.writeInt32((int32_t) streamType);
         data.writeInt32(sampleRate);
         data.writeInt32(format);
         data.writeInt32(channelMask);
@@ -249,47 +249,47 @@
         return reply.readInt32();
     }
 
-    virtual status_t setStreamVolume(int stream, float value, int output)
+    virtual status_t setStreamVolume(audio_stream_type_t stream, float value, int output)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeFloat(value);
         data.writeInt32(output);
         remote()->transact(SET_STREAM_VOLUME, data, &reply);
         return reply.readInt32();
     }
 
-    virtual status_t setStreamMute(int stream, bool muted)
+    virtual status_t setStreamMute(audio_stream_type_t stream, bool muted)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(muted);
         remote()->transact(SET_STREAM_MUTE, data, &reply);
         return reply.readInt32();
     }
 
-    virtual float streamVolume(int stream, int output) const
+    virtual float streamVolume(audio_stream_type_t stream, int output) const
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(output);
         remote()->transact(STREAM_VOLUME, data, &reply);
         return reply.readFloat();
     }
 
-    virtual bool streamMute(int stream) const
+    virtual bool streamMute(audio_stream_type_t stream) const
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         remote()->transact(STREAM_MUTE, data, &reply);
         return reply.readInt32();
     }
 
-    virtual status_t setMode(int mode)
+    virtual status_t setMode(audio_mode_t mode)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
@@ -468,11 +468,11 @@
         return reply.readInt32();
     }
 
-    virtual status_t setStreamOutput(uint32_t stream, int output)
+    virtual status_t setStreamOutput(audio_stream_type_t stream, int output)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioFlinger::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(output);
         remote()->transact(SET_STREAM_OUTPUT, data, &reply);
         return reply.readInt32();
@@ -687,7 +687,7 @@
             int sessionId = data.readInt32();
             status_t status;
             sp<IAudioTrack> track = createTrack(pid,
-                    streamType, sampleRate, format,
+                    (audio_stream_type_t) streamType, sampleRate, format,
                     channelCount, bufferCount, flags, buffer, output, &sessionId, &status);
             reply->writeInt32(sessionId);
             reply->writeInt32(status);
@@ -762,31 +762,31 @@
             int stream = data.readInt32();
             float volume = data.readFloat();
             int output = data.readInt32();
-            reply->writeInt32( setStreamVolume(stream, volume, output) );
+            reply->writeInt32( setStreamVolume((audio_stream_type_t) stream, volume, output) );
             return NO_ERROR;
         } break;
         case SET_STREAM_MUTE: {
             CHECK_INTERFACE(IAudioFlinger, data, reply);
             int stream = data.readInt32();
-            reply->writeInt32( setStreamMute(stream, data.readInt32()) );
+            reply->writeInt32( setStreamMute((audio_stream_type_t) stream, data.readInt32()) );
             return NO_ERROR;
         } break;
         case STREAM_VOLUME: {
             CHECK_INTERFACE(IAudioFlinger, data, reply);
             int stream = data.readInt32();
             int output = data.readInt32();
-            reply->writeFloat( streamVolume(stream, output) );
+            reply->writeFloat( streamVolume((audio_stream_type_t) stream, output) );
             return NO_ERROR;
         } break;
         case STREAM_MUTE: {
             CHECK_INTERFACE(IAudioFlinger, data, reply);
             int stream = data.readInt32();
-            reply->writeInt32( streamMute(stream) );
+            reply->writeInt32( streamMute((audio_stream_type_t) stream) );
             return NO_ERROR;
         } break;
         case SET_MODE: {
             CHECK_INTERFACE(IAudioFlinger, data, reply);
-            int mode = data.readInt32();
+            audio_mode_t mode = (audio_mode_t) data.readInt32();
             reply->writeInt32( setMode(mode) );
             return NO_ERROR;
         } break;
@@ -904,7 +904,7 @@
             CHECK_INTERFACE(IAudioFlinger, data, reply);
             uint32_t stream = data.readInt32();
             int output = data.readInt32();
-            reply->writeInt32(setStreamOutput(stream, output));
+            reply->writeInt32(setStreamOutput((audio_stream_type_t) stream, output));
             return NO_ERROR;
         } break;
         case SET_VOICE_VOLUME: {
diff --git a/media/libmedia/IAudioPolicyService.cpp b/media/libmedia/IAudioPolicyService.cpp
index 50b4855..6205ebd 100644
--- a/media/libmedia/IAudioPolicyService.cpp
+++ b/media/libmedia/IAudioPolicyService.cpp
@@ -91,7 +91,7 @@
         return static_cast <audio_policy_dev_state_t>(reply.readInt32());
     }
 
-    virtual status_t setPhoneState(int state)
+    virtual status_t setPhoneState(audio_mode_t state)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
@@ -154,7 +154,7 @@
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
         data.writeInt32(output);
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(session);
         remote()->transact(START_OUTPUT, data, &reply);
         return static_cast <status_t> (reply.readInt32());
@@ -167,7 +167,7 @@
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
         data.writeInt32(output);
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(session);
         remote()->transact(STOP_OUTPUT, data, &reply);
         return static_cast <status_t> (reply.readInt32());
@@ -240,21 +240,28 @@
         return static_cast <status_t> (reply.readInt32());
     }
 
-    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream, int index)
+    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream,
+                                          int index,
+                                          audio_devices_t device)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
         data.writeInt32(static_cast <uint32_t>(stream));
         data.writeInt32(index);
+        data.writeInt32(static_cast <uint32_t>(device));
         remote()->transact(SET_STREAM_VOLUME, data, &reply);
         return static_cast <status_t> (reply.readInt32());
     }
 
-    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream, int *index)
+    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream,
+                                          int *index,
+                                          audio_devices_t device)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
         data.writeInt32(static_cast <uint32_t>(stream));
+        data.writeInt32(static_cast <uint32_t>(device));
+
         remote()->transact(GET_STREAM_VOLUME, data, &reply);
         int lIndex = reply.readInt32();
         if (index) *index = lIndex;
@@ -324,11 +331,11 @@
         return static_cast <status_t> (reply.readInt32());
     }
 
-    virtual bool isStreamActive(int stream, uint32_t inPastMs) const
+    virtual bool isStreamActive(audio_stream_type_t stream, uint32_t inPastMs) const
     {
         Parcel data, reply;
         data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
-        data.writeInt32(stream);
+        data.writeInt32((int32_t) stream);
         data.writeInt32(inPastMs);
         remote()->transact(IS_STREAM_ACTIVE, data, &reply);
         return reply.readInt32();
@@ -394,7 +401,7 @@
 
         case SET_PHONE_STATE: {
             CHECK_INTERFACE(IAudioPolicyService, data, reply);
-            reply->writeInt32(static_cast <uint32_t>(setPhoneState(data.readInt32())));
+            reply->writeInt32(static_cast <uint32_t>(setPhoneState((audio_mode_t) data.readInt32())));
             return NO_ERROR;
         } break;
 
@@ -525,7 +532,10 @@
             audio_stream_type_t stream =
                     static_cast <audio_stream_type_t>(data.readInt32());
             int index = data.readInt32();
-            reply->writeInt32(static_cast <uint32_t>(setStreamVolumeIndex(stream, index)));
+            audio_devices_t device = static_cast <audio_devices_t>(data.readInt32());
+            reply->writeInt32(static_cast <uint32_t>(setStreamVolumeIndex(stream,
+                                                                          index,
+                                                                          device)));
             return NO_ERROR;
         } break;
 
@@ -533,8 +543,9 @@
             CHECK_INTERFACE(IAudioPolicyService, data, reply);
             audio_stream_type_t stream =
                     static_cast <audio_stream_type_t>(data.readInt32());
+            audio_devices_t device = static_cast <audio_devices_t>(data.readInt32());
             int index;
-            status_t status = getStreamVolumeIndex(stream, &index);
+            status_t status = getStreamVolumeIndex(stream, &index, device);
             reply->writeInt32(index);
             reply->writeInt32(static_cast <uint32_t>(status));
             return NO_ERROR;
@@ -598,9 +609,9 @@
 
         case IS_STREAM_ACTIVE: {
             CHECK_INTERFACE(IAudioPolicyService, data, reply);
-            int stream = data.readInt32();
+            audio_stream_type_t stream = (audio_stream_type_t) data.readInt32();
             uint32_t inPastMs = (uint32_t)data.readInt32();
-            reply->writeInt32( isStreamActive(stream, inPastMs) );
+            reply->writeInt32( isStreamActive((audio_stream_type_t) stream, inPastMs) );
             return NO_ERROR;
         } break;
 
diff --git a/media/libmedia/IMediaPlayer.cpp b/media/libmedia/IMediaPlayer.cpp
index 9c1e6b7..64cc919 100644
--- a/media/libmedia/IMediaPlayer.cpp
+++ b/media/libmedia/IMediaPlayer.cpp
@@ -198,11 +198,11 @@
         return reply.readInt32();
     }
 
-    status_t setAudioStreamType(int type)
+    status_t setAudioStreamType(audio_stream_type_t stream)
     {
         Parcel data, reply;
         data.writeInterfaceToken(IMediaPlayer::getInterfaceDescriptor());
-        data.writeInt32(type);
+        data.writeInt32((int32_t) stream);
         remote()->transact(SET_AUDIO_STREAM_TYPE, data, &reply);
         return reply.readInt32();
     }
@@ -397,7 +397,7 @@
         } break;
         case SET_AUDIO_STREAM_TYPE: {
             CHECK_INTERFACE(IMediaPlayer, data, reply);
-            reply->writeInt32(setAudioStreamType(data.readInt32()));
+            reply->writeInt32(setAudioStreamType((audio_stream_type_t) data.readInt32()));
             return NO_ERROR;
         } break;
         case SET_LOOPING: {
diff --git a/media/libmedia/ToneGenerator.cpp b/media/libmedia/ToneGenerator.cpp
index 9d32460..5ceb912 100644
--- a/media/libmedia/ToneGenerator.cpp
+++ b/media/libmedia/ToneGenerator.cpp
@@ -798,7 +798,7 @@
 //        none
 //
 ////////////////////////////////////////////////////////////////////////////////
-ToneGenerator::ToneGenerator(int streamType, float volume, bool threadCanCallJava) {
+ToneGenerator::ToneGenerator(audio_stream_type_t streamType, float volume, bool threadCanCallJava) {
 
     ALOGV("ToneGenerator constructor: streamType=%d, volume=%f\n", streamType, volume);
 
diff --git a/media/libmedia/Visualizer.cpp b/media/libmedia/Visualizer.cpp
index 66758d2..478654a 100644
--- a/media/libmedia/Visualizer.cpp
+++ b/media/libmedia/Visualizer.cpp
@@ -27,8 +27,7 @@
 #include <cutils/bitops.h>
 
 #include <media/Visualizer.h>
-
-extern void fixed_fft_real(int n, int32_t *v);
+#include <audio_utils/fixedfft.h>
 
 namespace android {
 
@@ -54,7 +53,7 @@
 
 status_t Visualizer::setEnabled(bool enabled)
 {
-    Mutex::Autolock _l(mLock);
+    Mutex::Autolock _l(mCaptureLock);
 
     sp<CaptureThread> t = mCaptureThread;
     if (t != 0) {
@@ -93,7 +92,7 @@
     if (rate > CAPTURE_RATE_MAX) {
         return BAD_VALUE;
     }
-    Mutex::Autolock _l(mLock);
+    Mutex::Autolock _l(mCaptureLock);
 
     if (mEnabled) {
         return INVALID_OPERATION;
@@ -129,7 +128,7 @@
         return BAD_VALUE;
     }
 
-    Mutex::Autolock _l(mLock);
+    Mutex::Autolock _l(mCaptureLock);
     if (mEnabled) {
         return INVALID_OPERATION;
     }
@@ -231,7 +230,7 @@
 
 void Visualizer::periodicCapture()
 {
-    Mutex::Autolock _l(mLock);
+    Mutex::Autolock _l(mCaptureLock);
     ALOGV("periodicCapture() %p mCaptureCallBack %p mCaptureFlags 0x%08x",
             this, mCaptureCallBack, mCaptureFlags);
     if (mCaptureCallBack != NULL &&
diff --git a/media/libmedia/fixedfft.cpp b/media/libmedia/fixedfft.cpp
deleted file mode 100644
index 2b495e6..0000000
--- a/media/libmedia/fixedfft.cpp
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/* A Fixed point implementation of Fast Fourier Transform (FFT). Complex numbers
- * are represented by 32-bit integers, where higher 16 bits are real part and
- * lower ones are imaginary part. Few compromises are made between efficiency,
- * accuracy, and maintainability. To make it fast, arithmetic shifts are used
- * instead of divisions, and bitwise inverses are used instead of negates. To
- * keep it small, only radix-2 Cooley-Tukey algorithm is implemented, and only
- * half of the twiddle factors are stored. Although there are still ways to make
- * it even faster or smaller, it costs too much on one of the aspects.
- */
-
-#include <stdio.h>
-#include <stdint.h>
-#ifdef __arm__
-#include <machine/cpu-features.h>
-#endif
-
-#define LOG_FFT_SIZE 10
-#define MAX_FFT_SIZE (1 << LOG_FFT_SIZE)
-
-static const int32_t twiddle[MAX_FFT_SIZE / 4] = {
-    0x00008000, 0xff378001, 0xfe6e8002, 0xfda58006, 0xfcdc800a, 0xfc13800f,
-    0xfb4a8016, 0xfa81801e, 0xf9b88027, 0xf8ef8032, 0xf827803e, 0xf75e804b,
-    0xf6958059, 0xf5cd8068, 0xf5058079, 0xf43c808b, 0xf374809e, 0xf2ac80b2,
-    0xf1e480c8, 0xf11c80de, 0xf05580f6, 0xef8d8110, 0xeec6812a, 0xedff8146,
-    0xed388163, 0xec718181, 0xebab81a0, 0xeae481c1, 0xea1e81e2, 0xe9588205,
-    0xe892822a, 0xe7cd824f, 0xe7078276, 0xe642829d, 0xe57d82c6, 0xe4b982f1,
-    0xe3f4831c, 0xe3308349, 0xe26d8377, 0xe1a983a6, 0xe0e683d6, 0xe0238407,
-    0xdf61843a, 0xde9e846e, 0xdddc84a3, 0xdd1b84d9, 0xdc598511, 0xdb998549,
-    0xdad88583, 0xda1885be, 0xd95885fa, 0xd8988637, 0xd7d98676, 0xd71b86b6,
-    0xd65c86f6, 0xd59e8738, 0xd4e1877b, 0xd42487c0, 0xd3678805, 0xd2ab884c,
-    0xd1ef8894, 0xd13488dd, 0xd0798927, 0xcfbe8972, 0xcf0489be, 0xce4b8a0c,
-    0xcd928a5a, 0xccd98aaa, 0xcc218afb, 0xcb698b4d, 0xcab28ba0, 0xc9fc8bf5,
-    0xc9468c4a, 0xc8908ca1, 0xc7db8cf8, 0xc7278d51, 0xc6738dab, 0xc5c08e06,
-    0xc50d8e62, 0xc45b8ebf, 0xc3a98f1d, 0xc2f88f7d, 0xc2488fdd, 0xc198903e,
-    0xc0e990a1, 0xc03a9105, 0xbf8c9169, 0xbedf91cf, 0xbe329236, 0xbd86929e,
-    0xbcda9307, 0xbc2f9371, 0xbb8593dc, 0xbadc9448, 0xba3394b5, 0xb98b9523,
-    0xb8e39592, 0xb83c9603, 0xb7969674, 0xb6f196e6, 0xb64c9759, 0xb5a897ce,
-    0xb5059843, 0xb46298b9, 0xb3c09930, 0xb31f99a9, 0xb27f9a22, 0xb1df9a9c,
-    0xb1409b17, 0xb0a29b94, 0xb0059c11, 0xaf689c8f, 0xaecc9d0e, 0xae319d8e,
-    0xad979e0f, 0xacfd9e91, 0xac659f14, 0xabcd9f98, 0xab36a01c, 0xaaa0a0a2,
-    0xaa0aa129, 0xa976a1b0, 0xa8e2a238, 0xa84fa2c2, 0xa7bda34c, 0xa72ca3d7,
-    0xa69ca463, 0xa60ca4f0, 0xa57ea57e, 0xa4f0a60c, 0xa463a69c, 0xa3d7a72c,
-    0xa34ca7bd, 0xa2c2a84f, 0xa238a8e2, 0xa1b0a976, 0xa129aa0a, 0xa0a2aaa0,
-    0xa01cab36, 0x9f98abcd, 0x9f14ac65, 0x9e91acfd, 0x9e0fad97, 0x9d8eae31,
-    0x9d0eaecc, 0x9c8faf68, 0x9c11b005, 0x9b94b0a2, 0x9b17b140, 0x9a9cb1df,
-    0x9a22b27f, 0x99a9b31f, 0x9930b3c0, 0x98b9b462, 0x9843b505, 0x97ceb5a8,
-    0x9759b64c, 0x96e6b6f1, 0x9674b796, 0x9603b83c, 0x9592b8e3, 0x9523b98b,
-    0x94b5ba33, 0x9448badc, 0x93dcbb85, 0x9371bc2f, 0x9307bcda, 0x929ebd86,
-    0x9236be32, 0x91cfbedf, 0x9169bf8c, 0x9105c03a, 0x90a1c0e9, 0x903ec198,
-    0x8fddc248, 0x8f7dc2f8, 0x8f1dc3a9, 0x8ebfc45b, 0x8e62c50d, 0x8e06c5c0,
-    0x8dabc673, 0x8d51c727, 0x8cf8c7db, 0x8ca1c890, 0x8c4ac946, 0x8bf5c9fc,
-    0x8ba0cab2, 0x8b4dcb69, 0x8afbcc21, 0x8aaaccd9, 0x8a5acd92, 0x8a0cce4b,
-    0x89becf04, 0x8972cfbe, 0x8927d079, 0x88ddd134, 0x8894d1ef, 0x884cd2ab,
-    0x8805d367, 0x87c0d424, 0x877bd4e1, 0x8738d59e, 0x86f6d65c, 0x86b6d71b,
-    0x8676d7d9, 0x8637d898, 0x85fad958, 0x85beda18, 0x8583dad8, 0x8549db99,
-    0x8511dc59, 0x84d9dd1b, 0x84a3dddc, 0x846ede9e, 0x843adf61, 0x8407e023,
-    0x83d6e0e6, 0x83a6e1a9, 0x8377e26d, 0x8349e330, 0x831ce3f4, 0x82f1e4b9,
-    0x82c6e57d, 0x829de642, 0x8276e707, 0x824fe7cd, 0x822ae892, 0x8205e958,
-    0x81e2ea1e, 0x81c1eae4, 0x81a0ebab, 0x8181ec71, 0x8163ed38, 0x8146edff,
-    0x812aeec6, 0x8110ef8d, 0x80f6f055, 0x80def11c, 0x80c8f1e4, 0x80b2f2ac,
-    0x809ef374, 0x808bf43c, 0x8079f505, 0x8068f5cd, 0x8059f695, 0x804bf75e,
-    0x803ef827, 0x8032f8ef, 0x8027f9b8, 0x801efa81, 0x8016fb4a, 0x800ffc13,
-    0x800afcdc, 0x8006fda5, 0x8002fe6e, 0x8001ff37,
-};
-
-/* Returns the multiplication of \conj{a} and {b}. */
-static inline int32_t mult(int32_t a, int32_t b)
-{
-#if __ARM_ARCH__ >= 6
-    int32_t t = b;
-    __asm__("smuad  %0, %0, %1"          : "+r" (t) : "r" (a));
-    __asm__("smusdx %0, %0, %1"          : "+r" (b) : "r" (a));
-    __asm__("pkhtb  %0, %0, %1, ASR #16" : "+r" (t) : "r" (b));
-    return t;
-#else
-    return (((a >> 16) * (b >> 16) + (int16_t)a * (int16_t)b) & ~0xFFFF) |
-        ((((a >> 16) * (int16_t)b - (int16_t)a * (b >> 16)) >> 16) & 0xFFFF);
-#endif
-}
-
-static inline int32_t half(int32_t a)
-{
-#if __ARM_ARCH__ >= 6
-    __asm__("shadd16 %0, %0, %1" : "+r" (a) : "r" (0));
-    return a;
-#else
-    return ((a >> 1) & ~0x8000) | (a & 0x8000);
-#endif
-}
-
-void fixed_fft(int n, int32_t *v)
-{
-    int scale = LOG_FFT_SIZE, i, p, r;
-
-    for (r = 0, i = 1; i < n; ++i) {
-        for (p = n; !(p & r); p >>= 1, r ^= p);
-        if (i < r) {
-            int32_t t = v[i];
-            v[i] = v[r];
-            v[r] = t;
-        }
-    }
-
-    for (p = 1; p < n; p <<= 1) {
-        --scale;
-
-        for (i = 0; i < n; i += p << 1) {
-            int32_t x = half(v[i]);
-            int32_t y = half(v[i + p]);
-            v[i] = x + y;
-            v[i + p] = x - y;
-        }
-
-        for (r = 1; r < p; ++r) {
-            int32_t w = MAX_FFT_SIZE / 4 - (r << scale);
-            i = w >> 31;
-            w = twiddle[(w ^ i) - i] ^ (i << 16);
-            for (i = r; i < n; i += p << 1) {
-                int32_t x = half(v[i]);
-                int32_t y = mult(w, v[i + p]);
-                v[i] = x - y;
-                v[i + p] = x + y;
-            }
-        }
-    }
-}
-
-void fixed_fft_real(int n, int32_t *v)
-{
-    int scale = LOG_FFT_SIZE, m = n >> 1, i;
-
-    fixed_fft(n, v);
-    for (i = 1; i <= n; i <<= 1, --scale);
-    v[0] = mult(~v[0], 0x80008000);
-    v[m] = half(v[m]);
-
-    for (i = 1; i < n >> 1; ++i) {
-        int32_t x = half(v[i]);
-        int32_t z = half(v[n - i]);
-        int32_t y = z - (x ^ 0xFFFF);
-        x = half(x + (z ^ 0xFFFF));
-        y = mult(y, twiddle[i << scale]);
-        v[i] = x - y;
-        v[n - i] = (x + y) ^ 0xFFFF;
-    }
-}
diff --git a/media/libmedia/mediaplayer.cpp b/media/libmedia/mediaplayer.cpp
index 4be960c..acf97a6 100644
--- a/media/libmedia/mediaplayer.cpp
+++ b/media/libmedia/mediaplayer.cpp
@@ -478,7 +478,7 @@
     return reset_l();
 }
 
-status_t MediaPlayer::setAudioStreamType(int type)
+status_t MediaPlayer::setAudioStreamType(audio_stream_type_t type)
 {
     ALOGV("MediaPlayer::setAudioStreamType");
     Mutex::Autolock _l(mLock);
diff --git a/media/libmediaplayerservice/MediaPlayerService.cpp b/media/libmediaplayerservice/MediaPlayerService.cpp
index af58cac..a0c20ae 100644
--- a/media/libmediaplayerservice/MediaPlayerService.cpp
+++ b/media/libmediaplayerservice/MediaPlayerService.cpp
@@ -1010,7 +1010,7 @@
     return p->reset();
 }
 
-status_t MediaPlayerService::Client::setAudioStreamType(int type)
+status_t MediaPlayerService::Client::setAudioStreamType(audio_stream_type_t type)
 {
     ALOGV("[%d] setAudioStreamType(%d)", mConnId, type);
     // TODO: for hardware output, call player instead
diff --git a/media/libmediaplayerservice/MediaPlayerService.h b/media/libmediaplayerservice/MediaPlayerService.h
index 66f245d..6b68b87 100644
--- a/media/libmediaplayerservice/MediaPlayerService.h
+++ b/media/libmediaplayerservice/MediaPlayerService.h
@@ -92,7 +92,7 @@
         virtual void            flush();
         virtual void            pause();
         virtual void            close();
-                void            setAudioStreamType(int streamType) { mStreamType = streamType; }
+                void            setAudioStreamType(audio_stream_type_t streamType) { mStreamType = streamType; }
                 void            setVolume(float left, float right);
                 status_t        setAuxEffectSendLevel(float level);
                 status_t        attachAuxEffect(int effectId);
@@ -108,7 +108,7 @@
         AudioTrack*             mTrack;
         AudioCallback           mCallback;
         void *                  mCallbackCookie;
-        int                     mStreamType;
+        audio_stream_type_t     mStreamType;
         float                   mLeftVolume;
         float                   mRightVolume;
         float                   mMsecsPerFrame;
@@ -149,7 +149,7 @@
         virtual void            flush() {}
         virtual void            pause() {}
         virtual void            close() {}
-                void            setAudioStreamType(int streamType) {}
+                void            setAudioStreamType(audio_stream_type_t streamType) {}
                 void            setVolume(float left, float right) {}
                 uint32_t        sampleRate() const { return mSampleRate; }
                 audio_format_t  format() const { return mFormat; }
@@ -259,7 +259,7 @@
         virtual status_t        getCurrentPosition(int* msec);
         virtual status_t        getDuration(int* msec);
         virtual status_t        reset();
-        virtual status_t        setAudioStreamType(int type);
+        virtual status_t        setAudioStreamType(audio_stream_type_t type);
         virtual status_t        setLooping(int loop);
         virtual status_t        setVolume(float leftVolume, float rightVolume);
         virtual status_t        invoke(const Parcel& request, Parcel *reply);
diff --git a/media/libmediaplayerservice/MidiFile.h b/media/libmediaplayerservice/MidiFile.h
index 2a0dcf9..dfe4318 100644
--- a/media/libmediaplayerservice/MidiFile.h
+++ b/media/libmediaplayerservice/MidiFile.h
@@ -78,7 +78,7 @@
     EAS_I32             mDuration;
     EAS_STATE           mState;
     EAS_FILE            mFileLocator;
-    int                 mStreamType;
+    audio_stream_type_t mStreamType;
     bool                mLoop;
     volatile bool       mExit;
     bool                mPaused;
diff --git a/media/libstagefright/AVIExtractor.cpp b/media/libstagefright/AVIExtractor.cpp
index a3187b7..5a6211e 100644
--- a/media/libstagefright/AVIExtractor.cpp
+++ b/media/libstagefright/AVIExtractor.cpp
@@ -577,6 +577,7 @@
         case FOURCC('a', 'v', 'c', '1'):
         case FOURCC('d', 'a', 'v', 'c'):
         case FOURCC('x', '2', '6', '4'):
+        case FOURCC('H', '2', '6', '4'):
         case FOURCC('v', 's', 's', 'h'):
             return MEDIA_MIMETYPE_VIDEO_AVC;
 
diff --git a/media/libstagefright/AwesomePlayer.cpp b/media/libstagefright/AwesomePlayer.cpp
index d0cb7ff..8480b6d 100644
--- a/media/libstagefright/AwesomePlayer.cpp
+++ b/media/libstagefright/AwesomePlayer.cpp
@@ -335,6 +335,14 @@
         return UNKNOWN_ERROR;
     }
 
+    if (extractor->getDrmFlag()) {
+        checkDrmStatus(dataSource);
+    }
+
+    return setDataSource_l(extractor);
+}
+
+void AwesomePlayer::checkDrmStatus(const sp<DataSource>& dataSource) {
     dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
     if (mDecryptHandle != NULL) {
         CHECK(mDrmManagerClient);
@@ -342,8 +350,6 @@
             notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
         }
     }
-
-    return setDataSource_l(extractor);
 }
 
 status_t AwesomePlayer::setDataSource_l(const sp<MediaExtractor> &extractor) {
@@ -2095,7 +2101,7 @@
         String8 mimeType;
         float confidence;
         sp<AMessage> dummy;
-        bool success = SniffDRM(dataSource, &mimeType, &confidence, &dummy);
+        bool success = SniffWVM(dataSource, &mimeType, &confidence, &dummy);
 
         if (!success
                 || strcasecmp(
@@ -2115,13 +2121,8 @@
         }
     }
 
-    dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
-
-    if (mDecryptHandle != NULL) {
-        CHECK(mDrmManagerClient);
-        if (RightsStatus::RIGHTS_VALID != mDecryptHandle->status) {
-            notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
-        }
+    if (extractor->getDrmFlag()) {
+        checkDrmStatus(dataSource);
     }
 
     status_t err = setDataSource_l(extractor);
diff --git a/media/libstagefright/DRMExtractor.cpp b/media/libstagefright/DRMExtractor.cpp
index 9452ab1..afc4a80 100644
--- a/media/libstagefright/DRMExtractor.cpp
+++ b/media/libstagefright/DRMExtractor.cpp
@@ -282,13 +282,13 @@
     if (decryptHandle != NULL) {
         if (decryptHandle->decryptApiType == DecryptApiType::CONTAINER_BASED) {
             *mimeType = String8("drm+container_based+") + decryptHandle->mimeType;
+            *confidence = 10.0f;
         } else if (decryptHandle->decryptApiType == DecryptApiType::ELEMENTARY_STREAM_BASED) {
             *mimeType = String8("drm+es_based+") + decryptHandle->mimeType;
-        } else if (decryptHandle->decryptApiType == DecryptApiType::WV_BASED) {
-            *mimeType = MEDIA_MIMETYPE_CONTAINER_WVM;
-            ALOGW("SniffWVM: found match\n");
+            *confidence = 10.0f;
+        } else {
+            return false;
         }
-        *confidence = 10.0f;
 
         return true;
     }
diff --git a/media/libstagefright/DataSource.cpp b/media/libstagefright/DataSource.cpp
index e471f73..d0a7880 100644
--- a/media/libstagefright/DataSource.cpp
+++ b/media/libstagefright/DataSource.cpp
@@ -32,6 +32,7 @@
 #include "include/DRMExtractor.h"
 #include "include/FLACExtractor.h"
 #include "include/AACExtractor.h"
+#include "include/WVMExtractor.h"
 
 #include "matroska/MatroskaExtractor.h"
 
@@ -120,6 +121,7 @@
     RegisterSniffer(SniffAAC);
     RegisterSniffer(SniffAVI);
     RegisterSniffer(SniffMPEG2PS);
+    RegisterSniffer(SniffWVM);
 
     char value[PROPERTY_VALUE_MAX];
     if (property_get("drm.service.enabled", value, NULL)
diff --git a/media/libstagefright/FileSource.cpp b/media/libstagefright/FileSource.cpp
index 73cb48c..01f53e4 100644
--- a/media/libstagefright/FileSource.cpp
+++ b/media/libstagefright/FileSource.cpp
@@ -127,7 +127,7 @@
     return OK;
 }
 
-sp<DecryptHandle> FileSource::DrmInitialization() {
+sp<DecryptHandle> FileSource::DrmInitialization(const char *mime) {
     if (mDrmManagerClient == NULL) {
         mDrmManagerClient = new DrmManagerClient();
     }
@@ -138,7 +138,7 @@
 
     if (mDecryptHandle == NULL) {
         mDecryptHandle = mDrmManagerClient->openDecryptSession(
-                mFd, mOffset, mLength);
+                mFd, mOffset, mLength, mime);
     }
 
     if (mDecryptHandle == NULL) {
diff --git a/media/libstagefright/NuCachedSource2.cpp b/media/libstagefright/NuCachedSource2.cpp
index 249c298..0957426 100644
--- a/media/libstagefright/NuCachedSource2.cpp
+++ b/media/libstagefright/NuCachedSource2.cpp
@@ -370,6 +370,7 @@
                     && (mSource->flags() & DataSource::kIsHTTPBasedSource)) {
                 ALOGV("Disconnecting at high watermark");
                 static_cast<HTTPBase *>(mSource.get())->disconnect();
+                mFinalStatus = -EAGAIN;
             }
         }
     } else {
@@ -549,7 +550,7 @@
 
     size_t delta = offset - mCacheOffset;
 
-    if (mFinalStatus != OK) {
+    if (mFinalStatus != OK && mNumRetriesLeft == 0) {
         if (delta >= mCache->totalSize()) {
             return mFinalStatus;
         }
@@ -591,7 +592,7 @@
     size_t totalSize = mCache->totalSize();
     CHECK_EQ(mCache->releaseFromStart(totalSize), totalSize);
 
-    mFinalStatus = OK;
+    mNumRetriesLeft = kMaxNumRetries;
     mFetching = true;
 
     return OK;
@@ -603,8 +604,8 @@
     restartPrefetcherIfNecessary_l(true /* ignore low water threshold */);
 }
 
-sp<DecryptHandle> NuCachedSource2::DrmInitialization() {
-    return mSource->DrmInitialization();
+sp<DecryptHandle> NuCachedSource2::DrmInitialization(const char* mime) {
+    return mSource->DrmInitialization(mime);
 }
 
 void NuCachedSource2::getDrmInfo(sp<DecryptHandle> &handle, DrmManagerClient **client) {
diff --git a/media/libstagefright/WVMExtractor.cpp b/media/libstagefright/WVMExtractor.cpp
index 2092cb6..1e4e049 100644
--- a/media/libstagefright/WVMExtractor.cpp
+++ b/media/libstagefright/WVMExtractor.cpp
@@ -45,17 +45,12 @@
 static Mutex gWVMutex;
 
 WVMExtractor::WVMExtractor(const sp<DataSource> &source)
-    : mDataSource(source) {
-    {
-        Mutex::Autolock autoLock(gWVMutex);
-        if (gVendorLibHandle == NULL) {
-            gVendorLibHandle = dlopen("libwvm.so", RTLD_NOW);
-        }
+    : mDataSource(source)
+{
+    Mutex::Autolock autoLock(gWVMutex);
 
-        if (gVendorLibHandle == NULL) {
-            ALOGE("Failed to open libwvm.so");
-            return;
-        }
+    if (!getVendorLibHandle()) {
+        return;
     }
 
     typedef WVMLoadableExtractor *(*GetInstanceFunc)(sp<DataSource>);
@@ -64,13 +59,28 @@
                 "_ZN7android11GetInstanceENS_2spINS_10DataSourceEEE");
 
     if (getInstanceFunc) {
+        CHECK(source->DrmInitialization(MEDIA_MIMETYPE_CONTAINER_WVM) != NULL);
         mImpl = (*getInstanceFunc)(source);
         CHECK(mImpl != NULL);
+        setDrmFlag(true);
     } else {
         ALOGE("Failed to locate GetInstance in libwvm.so");
     }
 }
 
+bool WVMExtractor::getVendorLibHandle()
+{
+    if (gVendorLibHandle == NULL) {
+        gVendorLibHandle = dlopen("libwvm.so", RTLD_NOW);
+    }
+
+    if (gVendorLibHandle == NULL) {
+        ALOGE("Failed to open libwvm.so");
+    }
+
+    return gVendorLibHandle != NULL;
+}
+
 WVMExtractor::~WVMExtractor() {
 }
 
@@ -113,5 +123,33 @@
     }
 }
 
+bool SniffWVM(
+    const sp<DataSource> &source, String8 *mimeType, float *confidence,
+        sp<AMessage> *) {
+
+    Mutex::Autolock autoLock(gWVMutex);
+
+    if (!WVMExtractor::getVendorLibHandle()) {
+        return false;
+    }
+
+    typedef WVMLoadableExtractor *(*SnifferFunc)(const sp<DataSource>&);
+    SnifferFunc snifferFunc =
+        (SnifferFunc) dlsym(gVendorLibHandle,
+                            "_ZN7android15IsWidevineMediaERKNS_2spINS_10DataSourceEEE");
+
+    if (snifferFunc) {
+        if ((*snifferFunc)(source)) {
+            *mimeType = MEDIA_MIMETYPE_CONTAINER_WVM;
+            *confidence = 10.0f;
+            return true;
+        }
+    } else {
+        ALOGE("IsWidevineMedia not found in libwvm.so");
+    }
+
+    return false;
+}
+
 } //namespace android
 
diff --git a/media/libstagefright/chromium_http/ChromiumHTTPDataSource.cpp b/media/libstagefright/chromium_http/ChromiumHTTPDataSource.cpp
index 180460b..76f7946 100644
--- a/media/libstagefright/chromium_http/ChromiumHTTPDataSource.cpp
+++ b/media/libstagefright/chromium_http/ChromiumHTTPDataSource.cpp
@@ -259,7 +259,7 @@
     mCondition.broadcast();
 }
 
-sp<DecryptHandle> ChromiumHTTPDataSource::DrmInitialization() {
+sp<DecryptHandle> ChromiumHTTPDataSource::DrmInitialization(const char* mime) {
     Mutex::Autolock autoLock(mLock);
 
     if (mDrmManagerClient == NULL) {
@@ -275,7 +275,7 @@
          * original one
          */
         mDecryptHandle = mDrmManagerClient->openDecryptSession(
-                String8(mURI.c_str()));
+                String8(mURI.c_str()), mime);
     }
 
     if (mDecryptHandle == NULL) {
diff --git a/media/libstagefright/codecs/aacenc/Android.mk b/media/libstagefright/codecs/aacenc/Android.mk
index f9cc6a3..8318ba4 100644
--- a/media/libstagefright/codecs/aacenc/Android.mk
+++ b/media/libstagefright/codecs/aacenc/Android.mk
@@ -59,7 +59,7 @@
 
 LOCAL_ARM_MODE := arm
 
-LOCAL_STATIC_LIBRARIES := 
+LOCAL_STATIC_LIBRARIES :=
 
 LOCAL_SHARED_LIBRARIES :=
 
diff --git a/media/libstagefright/codecs/aacenc/SampleCode/AAC_E_SAMPLES.c b/media/libstagefright/codecs/aacenc/SampleCode/AAC_E_SAMPLES.c
index 2ea9449..2f31de4 100644
--- a/media/libstagefright/codecs/aacenc/SampleCode/AAC_E_SAMPLES.c
+++ b/media/libstagefright/codecs/aacenc/SampleCode/AAC_E_SAMPLES.c
@@ -29,11 +29,11 @@
 #include		"cmnMemory.h"
 
 #define  VO_AAC_E_OUTPUT	  1
-#define READ_SIZE	(1024*8)	
+#define READ_SIZE	(1024*8)
 unsigned char outBuf[1024*8];
 unsigned char inBuf[READ_SIZE];
 
-const char* HelpString = 
+const char* HelpString =
 "VisualOn AAC encoder Usage:\n"
 "voAACEncTest -if <inputfile.pcm> -of <outputfile.aac> -sr <samplerate> -ch <channel> -br <bitrate> -adts <adts> \n"
 "-if input file name \n"
@@ -49,7 +49,7 @@
 {
 	// notice that:
 	// bitRate/nChannels > 8000
-	// bitRate/nChannels < 160000 
+	// bitRate/nChannels < 160000
 	// bitRate/nChannels < sampleRate*6
 	param->adtsUsed = 1;
 	param->bitRate = 0;
@@ -69,7 +69,7 @@
 		{
 			argv++;
 			argc--;
-			*input_filename = *argv; 
+			*input_filename = *argv;
 		}
 		else if (!strcmp(*argv, "-of"))
 		{
diff --git a/media/libstagefright/codecs/aacenc/basic_op/basic_op.h b/media/libstagefright/codecs/aacenc/basic_op/basic_op.h
index 8291684..ef3c31b 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/basic_op.h
+++ b/media/libstagefright/codecs/aacenc/basic_op/basic_op.h
@@ -91,7 +91,7 @@
 #else
 Word32 L_msu (Word32 L_var3, Word16 var1, Word16 var2);
 #endif
-    
+
 /* Long sub,        2 */
 #if (L_SUB_IS_INLINE)
 __inline Word32 L_sub(Word32 L_var1, Word32 L_var2);
@@ -119,7 +119,7 @@
 #else
 Word16 add (Word16 var1, Word16 var2);
 #endif
-    
+
 /* Short sub,           1   */
 #if (SUB_IS_INLINE)
 __inline Word16 sub(Word16 var1, Word16 var2);
@@ -227,48 +227,48 @@
 #if ARMV4_INASM
 __inline Word32 ASM_L_shr(Word32 L_var1, Word16 var2)
 {
-	Word32 result; 
-	asm volatile( 
-		"MOV %[result], %[L_var1], ASR %[var2] \n" 
+	Word32 result;
+	asm volatile(
+		"MOV %[result], %[L_var1], ASR %[var2] \n"
 		:[result]"=r"(result)
 		:[L_var1]"r"(L_var1), [var2]"r"(var2)
-		); 
-	return result;	
+		);
+	return result;
 }
- 
+
 __inline Word32 ASM_L_shl(Word32 L_var1, Word16 var2)
 {
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"MOV	r2, %[L_var1] \n"
 		"MOV	r3, #0x7fffffff\n"
-		"MOV	%[result], %[L_var1], ASL %[var2] \n" 
+		"MOV	%[result], %[L_var1], ASL %[var2] \n"
 		"TEQ	r2, %[result], ASR %[var2]\n"
 		"EORNE  %[result],r3,r2,ASR#31\n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1), [var2]"r"(var2)
 		:"r2", "r3"
-		); 
-	return result;	
+		);
+	return result;
 }
 
 __inline Word32 ASM_shr(Word32 L_var1, Word16 var2)
 {
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"CMP	%[var2], #15\n"
 		"MOVGE  %[var2], #15\n"
 		"MOV	%[result], %[L_var1], ASR %[var2]\n"
 		:[result]"=r"(result)
-		:[L_var1]"r"(L_var1), [var2]"r"(var2) 
-		); 
-	return result;	
-} 
+		:[L_var1]"r"(L_var1), [var2]"r"(var2)
+		);
+	return result;
+}
 
 __inline Word32 ASM_shl(Word32 L_var1, Word16 var2)
 {
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"CMP	%[var2], #16\n"
 		"MOVGE  %[var2], #16\n"
 		"MOV    %[result], %[L_var1], ASL %[var2]\n"
@@ -280,9 +280,9 @@
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1), [var2]"r"(var2)
 		:"r2", "r3"
-		); 
-	return result;	
-} 
+		);
+	return result;
+}
 #endif
 
 /*___________________________________________________________________________
@@ -300,17 +300,17 @@
 		"MOV	r3, #1\n"
 		"MOV	r2,%[L_var1],ASR#15\n"
 		"RSB	r3, r3, r3, LSL #15\n"
-		"TEQ	r2,%[L_var1],ASR#31\n"	
+		"TEQ	r2,%[L_var1],ASR#31\n"
 		"EORNE	%[result],r3,%[L_var1],ASR#31\n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1)
-		:"r2", "r3"			
+		:"r2", "r3"
 	);
 
 	return result;
 #else
     Word16 var_out;
-    
+
     //var_out = (L_var1 > (Word32)0X00007fffL) ? (MAX_16) : ((L_var1 < (Word32)0xffff8000L) ? (MIN_16) : ((Word16)L_var1));
 
     if (L_var1 > 0X00007fffL)
@@ -419,13 +419,13 @@
 __inline Word32 L_mult(Word16 var1, Word16 var2)
 {
 #if ARMV5TE_L_MULT
-	Word32 result; 
-	asm volatile( 
-		"SMULBB %[result], %[var1], %[var2] \n" 
-		"QADD %[result], %[result], %[result] \n" 
+	Word32 result;
+	asm volatile(
+		"SMULBB %[result], %[var1], %[var2] \n"
+		"QADD %[result], %[result], %[result] \n"
 		:[result]"+r"(result)
 		:[var1]"r"(var1), [var2]"r"(var2)
-		); 
+		);
 	return result;
 #else
     Word32 L_var_out;
@@ -449,14 +449,14 @@
 __inline Word32 L_msu (Word32 L_var3, Word16 var1, Word16 var2)
 {
 #if ARMV5TE_L_MSU
-	Word32 result; 
-	asm volatile( 
-		"SMULBB %[result], %[var1], %[var2] \n" 
+	Word32 result;
+	asm volatile(
+		"SMULBB %[result], %[var1], %[var2] \n"
 		"QADD %[result], %[result], %[result] \n"
 		"QSUB %[result], %[L_var3], %[result]\n"
 		:[result]"+r"(result)
 		:[L_var3]"r"(L_var3), [var1]"r"(var1), [var2]"r"(var2)
-		); 
+		);
 	return result;
 #else
     Word32 L_var_out;
@@ -473,12 +473,12 @@
 __inline Word32 L_sub(Word32 L_var1, Word32 L_var2)
 {
 #if ARMV5TE_L_SUB
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"QSUB %[result], %[L_var1], %[L_var2]\n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1), [L_var2]"r"(L_var2)
-		); 
+		);
 	return result;
 #else
     Word32 L_var_out;
@@ -588,9 +588,9 @@
 __inline Word16 add (Word16 var1, Word16 var2)
 {
 #if ARMV5TE_ADD
-	Word32 result; 
-	asm volatile( 
-		"ADD  %[result], %[var1], %[var2] \n" 
+	Word32 result;
+	asm volatile(
+		"ADD  %[result], %[var1], %[var2] \n"
 		"MOV  r3, #0x1\n"
 		"MOV  r2, %[result], ASR #15\n"
 		"RSB  r3, r3, r3, LSL, #15\n"
@@ -599,7 +599,7 @@
 		:[result]"+r"(result)
 		:[var1]"r"(var1), [var2]"r"(var2)
 		:"r2", "r3"
-		); 
+		);
 	return result;
 #else
     Word16 var_out;
@@ -618,18 +618,18 @@
 __inline Word16 sub(Word16 var1, Word16 var2)
 {
 #if ARMV5TE_SUB
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"MOV   r3, #1\n"
-		"SUB   %[result], %[var1], %[var2] \n"		
+		"SUB   %[result], %[var1], %[var2] \n"
 		"RSB   r3,r3,r3,LSL#15\n"
-		"MOV   r2, %[var1], ASR #15 \n" 
+		"MOV   r2, %[var1], ASR #15 \n"
 		"TEQ   r2, %[var1], ASR #31 \n"
 		"EORNE %[result], r3, %[result], ASR #31 \n"
 		:[result]"+r"(result)
 		:[var1]"r"(var1), [var2]"r"(var2)
 		:"r2", "r3"
-		); 
+		);
 	return result;
 #else
     Word16 var_out;
@@ -637,7 +637,7 @@
 
     L_diff = (Word32) var1 - var2;
     var_out = saturate(L_diff);
-   
+
     return (var_out);
 #endif
 }
@@ -657,16 +657,16 @@
     {
     	var_out = 0;
     	L_num = (Word32) var1;
-    
+
     	L_denom = (Word32) var2;
-    	
+
 		//return (L_num<<15)/var2;
 
     	for (iteration = 0; iteration < 15; iteration++)
     	{
     		var_out <<= 1;
     		L_num <<= 1;
-    		
+
     		if (L_num >= L_denom)
     		{
     			L_num -= L_denom;
@@ -683,8 +683,8 @@
 __inline Word16 mult (Word16 var1, Word16 var2)
 {
 #if ARMV5TE_MULT
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"SMULBB r2, %[var1], %[var2] \n"
 		"MOV	r3, #1\n"
 		"MOV	%[result], r2, ASR #15\n"
@@ -695,7 +695,7 @@
 		:[result]"+r"(result)
 		:[var1]"r"(var1), [var2]"r"(var2)
 		:"r2", "r3"
-		); 
+		);
 	return result;
 #else
     Word16 var_out;
@@ -718,8 +718,8 @@
 __inline Word16 norm_s (Word16 var1)
 {
 #if ARMV5TE_NORM_S
-	Word16 result; 
-	asm volatile( 
+	Word16 result;
+	asm volatile(
 		"MOV   r2,%[var1] \n"
 		"CMP   r2, #0\n"
 		"RSBLT %[var1], %[var1], #0 \n"
@@ -727,11 +727,11 @@
 		"SUBNE %[result], %[result], #17\n"
 		"MOVEQ %[result], #0\n"
 		"CMP   r2, #-1\n"
-		"MOVEQ %[result], #15\n" 
+		"MOVEQ %[result], #15\n"
 		:[result]"+r"(result)
 		:[var1]"r"(var1)
 		:"r2"
-		); 
+		);
 	return result;
 #else
     Word16 var_out;
@@ -768,15 +768,15 @@
 __inline Word16 norm_l (Word32 L_var1)
 {
 #if ARMV5TE_NORM_L
-	Word16 result; 
-	asm volatile( 
+	Word16 result;
+	asm volatile(
 		"CMP    %[L_var1], #0\n"
 		"CLZNE  %[result], %[L_var1]\n"
-		"SUBNE  %[result], %[result], #1\n" 
+		"SUBNE  %[result], %[result], #1\n"
 		"MOVEQ  %[result], #0\n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1)
-		); 
+		);
 	return result;
 #else
     //Word16 var_out;
@@ -805,84 +805,84 @@
     //}
     //return (var_out);
   Word16 a16;
-  Word16 r = 0 ;       
+  Word16 r = 0 ;
 
-   
+
   if ( L_var1 < 0 ) {
-    L_var1 = ~L_var1; 
+    L_var1 = ~L_var1;
   }
 
   if (0 == (L_var1 & 0x7fff8000)) {
     a16 = extract_l(L_var1);
     r += 16;
-       
+
     if (0 == (a16 & 0x7f80)) {
       r += 8;
-         
+
       if (0 == (a16 & 0x0078)) {
         r += 4;
-           
+
         if (0 == (a16 & 0x0006)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0001)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0004)) {
             r += 1;
           }
         }
       }
       else {
-           
+
         if (0 == (a16 & 0x0060)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0010)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0040)) {
             r += 1;
           }
         }
       }
-    } 
-    else { 
-         
+    }
+    else {
+
       if (0 == (a16 & 0x7800)) {
         r += 4;
-           
+
         if (0 == (a16 & 0x0600)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0100)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0400)) {
             r += 1;
           }
         }
       }
       else {
-           
+
         if (0 == (a16 & 0x6000)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x1000)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x4000)) {
             r += 1;
           }
@@ -892,38 +892,38 @@
   }
   else {
     a16 = extract_h(L_var1);
-       
+
     if (0 == (a16 & 0x7f80)) {
       r += 8;
-         
+
       if (0 == (a16 & 0x0078)) {
         r += 4 ;
-           
+
         if (0 == (a16 & 0x0006)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0001)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0004)) {
             r += 1;
           }
         }
       }
       else {
-           
+
         if (0 == (a16 & 0x0060)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0010)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0040)) {
             r += 1;
           }
@@ -931,35 +931,35 @@
       }
     }
     else {
-         
+
       if (0 == (a16 & 0x7800)) {
         r += 4;
-           
+
         if (0 == (a16 & 0x0600)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x0100)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x0400)) {
             r += 1;
           }
         }
       }
       else {
-           
+
         if (0 == (a16 & 0x6000)) {
           r += 2;
-             
+
           if (0 == (a16 & 0x1000)) {
             r += 1;
           }
         }
         else {
-             
+
           if (0 == (a16 & 0x4000)) {
             return 1;
           }
@@ -967,7 +967,7 @@
       }
     }
   }
-  
+
   return r ;
 #endif
 }
@@ -978,17 +978,17 @@
 __inline Word16 round16(Word32 L_var1)
 {
 #if ARMV5TE_ROUND
-	Word16 result; 
-	asm volatile( 
+	Word16 result;
+	asm volatile(
 		"MOV   r1,#0x00008000\n"
 		"QADD  %[result], %[L_var1], r1\n"
-		"MOV   %[result], %[result], ASR #16 \n" 
+		"MOV   %[result], %[result], ASR #16 \n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1)
 		:"r1"
-		); 
+		);
 	return result;
-#else   
+#else
     Word16 var_out;
     Word32 L_rounded;
 
@@ -1004,14 +1004,14 @@
 __inline Word32 L_mac (Word32 L_var3, Word16 var1, Word16 var2)
 {
 #if ARMV5TE_L_MAC
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"SMULBB %[result], %[var1], %[var2]\n"
 		"QADD	%[result], %[result], %[result]\n"
 		"QADD   %[result], %[result], %[L_var3]\n"
 		:[result]"+r"(result)
 		: [L_var3]"r"(L_var3), [var1]"r"(var1), [var2]"r"(var2)
-		); 
+		);
 	return result;
 #else
     Word32 L_var_out;
@@ -1028,12 +1028,12 @@
 __inline Word32 L_add (Word32 L_var1, Word32 L_var2)
 {
 #if ARMV5TE_L_ADD
-	Word32 result; 
-	asm volatile( 
+	Word32 result;
+	asm volatile(
 		"QADD %[result], %[L_var1], %[L_var2]\n"
 		:[result]"+r"(result)
 		:[L_var1]"r"(L_var1), [L_var2]"r"(L_var2)
-		); 
+		);
 	return result;
 #else
     Word32 L_var_out;
@@ -1114,7 +1114,7 @@
 
     L_var3 = L_msu (L_var3, var1, var2);
     var_out = (Word16)((L_var3 + 0x8000L) >> 16);
-    
+
     return (var_out);
 }
 #endif
diff --git a/media/libstagefright/codecs/aacenc/basic_op/basicop2.c b/media/libstagefright/codecs/aacenc/basic_op/basicop2.c
index 82d3f38..d43bbd9 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/basicop2.c
+++ b/media/libstagefright/codecs/aacenc/basic_op/basicop2.c
@@ -16,7 +16,7 @@
 /*******************************************************************************
 	File:		basicop2.c
 
-	Content:	Basic arithmetic operators. 
+	Content:	Basic arithmetic operators.
 
 *******************************************************************************/
 
@@ -462,7 +462,7 @@
     {
         L_var_out = MAX_32;
     }
-        
+
     return (L_var_out);
 }
 #endif
diff --git a/media/libstagefright/codecs/aacenc/basic_op/oper_32b.c b/media/libstagefright/codecs/aacenc/basic_op/oper_32b.c
index 0ad82f0..e48af9d 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/oper_32b.c
+++ b/media/libstagefright/codecs/aacenc/basic_op/oper_32b.c
@@ -17,7 +17,7 @@
 	File:		oper_32b.c
 
 	Content:	  This file contains operations in double precision.
- 
+
 *******************************************************************************/
 
 #include "typedef.h"
@@ -200,12 +200,12 @@
 }
 
 /*!
- 
-  \brief  calculates the log dualis times 4 of argument 
+
+  \brief  calculates the log dualis times 4 of argument
           iLog4(x) = (Word32)(4 * log(value)/log(2.0))
 
   \return ilog4 value
- 
+
 */
 Word16 iLog4(Word32 value)
 {
@@ -225,7 +225,7 @@
     iLog4 = (-(iLog4 << 2) - norm_s(tmp16)) - 1;
   }
   else {
-    iLog4 = -128; /* -(INT_BITS*4); */                                          
+    iLog4 = -128; /* -(INT_BITS*4); */
   }
 
   return iLog4;
@@ -268,79 +268,79 @@
 }
 
 static const Word32 pow2Table[POW2_TABLE_SIZE] = {
-0x7fffffff, 0x7fa765ad, 0x7f4f08ae, 0x7ef6e8da, 
-0x7e9f0606, 0x7e476009, 0x7deff6b6, 0x7d98c9e6, 
-0x7d41d96e, 0x7ceb2523, 0x7c94acde, 0x7c3e7073, 
-0x7be86fb9, 0x7b92aa88, 0x7b3d20b6, 0x7ae7d21a, 
-0x7a92be8b, 0x7a3de5df, 0x79e947ef, 0x7994e492, 
-0x7940bb9e, 0x78ecccec, 0x78991854, 0x78459dac, 
-0x77f25cce, 0x779f5591, 0x774c87cc, 0x76f9f359, 
-0x76a7980f, 0x765575c8, 0x76038c5b, 0x75b1dba2, 
-0x75606374, 0x750f23ab, 0x74be1c20, 0x746d4cac, 
-0x741cb528, 0x73cc556d, 0x737c2d55, 0x732c3cba, 
-0x72dc8374, 0x728d015d, 0x723db650, 0x71eea226, 
-0x719fc4b9, 0x71511de4, 0x7102ad80, 0x70b47368, 
-0x70666f76, 0x7018a185, 0x6fcb096f, 0x6f7da710, 
-0x6f307a41, 0x6ee382de, 0x6e96c0c3, 0x6e4a33c9, 
-0x6dfddbcc, 0x6db1b8a8, 0x6d65ca38, 0x6d1a1057, 
-0x6cce8ae1, 0x6c8339b2, 0x6c381ca6, 0x6bed3398, 
-0x6ba27e66, 0x6b57fce9, 0x6b0daeff, 0x6ac39485, 
-0x6a79ad56, 0x6a2ff94f, 0x69e6784d, 0x699d2a2c, 
-0x69540ec9, 0x690b2601, 0x68c26fb1, 0x6879ebb6, 
-0x683199ed, 0x67e97a34, 0x67a18c68, 0x6759d065, 
-0x6712460b, 0x66caed35, 0x6683c5c3, 0x663ccf92, 
-0x65f60a80, 0x65af766a, 0x6569132f, 0x6522e0ad, 
-0x64dcdec3, 0x64970d4f, 0x64516c2e, 0x640bfb41, 
-0x63c6ba64, 0x6381a978, 0x633cc85b, 0x62f816eb, 
-0x62b39509, 0x626f4292, 0x622b1f66, 0x61e72b65, 
-0x61a3666d, 0x615fd05f, 0x611c6919, 0x60d9307b, 
-0x60962665, 0x60534ab7, 0x60109d51, 0x5fce1e12, 
-0x5f8bccdb, 0x5f49a98c, 0x5f07b405, 0x5ec5ec26, 
-0x5e8451d0, 0x5e42e4e3, 0x5e01a540, 0x5dc092c7, 
-0x5d7fad59, 0x5d3ef4d7, 0x5cfe6923, 0x5cbe0a1c, 
-0x5c7dd7a4, 0x5c3dd19c, 0x5bfdf7e5, 0x5bbe4a61, 
-0x5b7ec8f2, 0x5b3f7377, 0x5b0049d4, 0x5ac14bea, 
-0x5a82799a, 0x5a43d2c6, 0x5a055751, 0x59c7071c, 
-0x5988e209, 0x594ae7fb, 0x590d18d3, 0x58cf7474, 
-0x5891fac1, 0x5854ab9b, 0x581786e6, 0x57da8c83, 
-0x579dbc57, 0x57611642, 0x57249a29, 0x56e847ef, 
-0x56ac1f75, 0x567020a0, 0x56344b52, 0x55f89f70, 
-0x55bd1cdb, 0x5581c378, 0x55469329, 0x550b8bd4, 
-0x54d0ad5b, 0x5495f7a1, 0x545b6a8b, 0x542105fd, 
-0x53e6c9db, 0x53acb607, 0x5372ca68, 0x533906e0, 
-0x52ff6b55, 0x52c5f7aa, 0x528cabc3, 0x52538786, 
-0x521a8ad7, 0x51e1b59a, 0x51a907b4, 0x5170810b, 
-0x51382182, 0x50ffe8fe, 0x50c7d765, 0x508fec9c, 
-0x50582888, 0x50208b0e, 0x4fe91413, 0x4fb1c37c, 
-0x4f7a9930, 0x4f439514, 0x4f0cb70c, 0x4ed5ff00, 
-0x4e9f6cd4, 0x4e69006e, 0x4e32b9b4, 0x4dfc988c, 
-0x4dc69cdd, 0x4d90c68b, 0x4d5b157e, 0x4d25899c, 
-0x4cf022ca, 0x4cbae0ef, 0x4c85c3f1, 0x4c50cbb8, 
-0x4c1bf829, 0x4be7492b, 0x4bb2bea5, 0x4b7e587d, 
-0x4b4a169c, 0x4b15f8e6, 0x4ae1ff43, 0x4aae299b, 
-0x4a7a77d5, 0x4a46e9d6, 0x4a137f88, 0x49e038d0, 
-0x49ad1598, 0x497a15c4, 0x4947393f, 0x49147fee, 
-0x48e1e9ba, 0x48af768a, 0x487d2646, 0x484af8d6, 
-0x4818ee22, 0x47e70611, 0x47b5408c, 0x47839d7b, 
-0x47521cc6, 0x4720be55, 0x46ef8210, 0x46be67e0, 
-0x468d6fae, 0x465c9961, 0x462be4e2, 0x45fb521a, 
-0x45cae0f2, 0x459a9152, 0x456a6323, 0x453a564d, 
-0x450a6abb, 0x44daa054, 0x44aaf702, 0x447b6ead, 
-0x444c0740, 0x441cc0a3, 0x43ed9ac0, 0x43be9580, 
-0x438fb0cb, 0x4360ec8d, 0x433248ae, 0x4303c517, 
-0x42d561b4, 0x42a71e6c, 0x4278fb2b, 0x424af7da, 
-0x421d1462, 0x41ef50ae, 0x41c1aca8, 0x41942839, 
-0x4166c34c, 0x41397dcc, 0x410c57a2, 0x40df50b8, 
-0x40b268fa, 0x4085a051, 0x4058f6a8, 0x402c6be9 
+0x7fffffff, 0x7fa765ad, 0x7f4f08ae, 0x7ef6e8da,
+0x7e9f0606, 0x7e476009, 0x7deff6b6, 0x7d98c9e6,
+0x7d41d96e, 0x7ceb2523, 0x7c94acde, 0x7c3e7073,
+0x7be86fb9, 0x7b92aa88, 0x7b3d20b6, 0x7ae7d21a,
+0x7a92be8b, 0x7a3de5df, 0x79e947ef, 0x7994e492,
+0x7940bb9e, 0x78ecccec, 0x78991854, 0x78459dac,
+0x77f25cce, 0x779f5591, 0x774c87cc, 0x76f9f359,
+0x76a7980f, 0x765575c8, 0x76038c5b, 0x75b1dba2,
+0x75606374, 0x750f23ab, 0x74be1c20, 0x746d4cac,
+0x741cb528, 0x73cc556d, 0x737c2d55, 0x732c3cba,
+0x72dc8374, 0x728d015d, 0x723db650, 0x71eea226,
+0x719fc4b9, 0x71511de4, 0x7102ad80, 0x70b47368,
+0x70666f76, 0x7018a185, 0x6fcb096f, 0x6f7da710,
+0x6f307a41, 0x6ee382de, 0x6e96c0c3, 0x6e4a33c9,
+0x6dfddbcc, 0x6db1b8a8, 0x6d65ca38, 0x6d1a1057,
+0x6cce8ae1, 0x6c8339b2, 0x6c381ca6, 0x6bed3398,
+0x6ba27e66, 0x6b57fce9, 0x6b0daeff, 0x6ac39485,
+0x6a79ad56, 0x6a2ff94f, 0x69e6784d, 0x699d2a2c,
+0x69540ec9, 0x690b2601, 0x68c26fb1, 0x6879ebb6,
+0x683199ed, 0x67e97a34, 0x67a18c68, 0x6759d065,
+0x6712460b, 0x66caed35, 0x6683c5c3, 0x663ccf92,
+0x65f60a80, 0x65af766a, 0x6569132f, 0x6522e0ad,
+0x64dcdec3, 0x64970d4f, 0x64516c2e, 0x640bfb41,
+0x63c6ba64, 0x6381a978, 0x633cc85b, 0x62f816eb,
+0x62b39509, 0x626f4292, 0x622b1f66, 0x61e72b65,
+0x61a3666d, 0x615fd05f, 0x611c6919, 0x60d9307b,
+0x60962665, 0x60534ab7, 0x60109d51, 0x5fce1e12,
+0x5f8bccdb, 0x5f49a98c, 0x5f07b405, 0x5ec5ec26,
+0x5e8451d0, 0x5e42e4e3, 0x5e01a540, 0x5dc092c7,
+0x5d7fad59, 0x5d3ef4d7, 0x5cfe6923, 0x5cbe0a1c,
+0x5c7dd7a4, 0x5c3dd19c, 0x5bfdf7e5, 0x5bbe4a61,
+0x5b7ec8f2, 0x5b3f7377, 0x5b0049d4, 0x5ac14bea,
+0x5a82799a, 0x5a43d2c6, 0x5a055751, 0x59c7071c,
+0x5988e209, 0x594ae7fb, 0x590d18d3, 0x58cf7474,
+0x5891fac1, 0x5854ab9b, 0x581786e6, 0x57da8c83,
+0x579dbc57, 0x57611642, 0x57249a29, 0x56e847ef,
+0x56ac1f75, 0x567020a0, 0x56344b52, 0x55f89f70,
+0x55bd1cdb, 0x5581c378, 0x55469329, 0x550b8bd4,
+0x54d0ad5b, 0x5495f7a1, 0x545b6a8b, 0x542105fd,
+0x53e6c9db, 0x53acb607, 0x5372ca68, 0x533906e0,
+0x52ff6b55, 0x52c5f7aa, 0x528cabc3, 0x52538786,
+0x521a8ad7, 0x51e1b59a, 0x51a907b4, 0x5170810b,
+0x51382182, 0x50ffe8fe, 0x50c7d765, 0x508fec9c,
+0x50582888, 0x50208b0e, 0x4fe91413, 0x4fb1c37c,
+0x4f7a9930, 0x4f439514, 0x4f0cb70c, 0x4ed5ff00,
+0x4e9f6cd4, 0x4e69006e, 0x4e32b9b4, 0x4dfc988c,
+0x4dc69cdd, 0x4d90c68b, 0x4d5b157e, 0x4d25899c,
+0x4cf022ca, 0x4cbae0ef, 0x4c85c3f1, 0x4c50cbb8,
+0x4c1bf829, 0x4be7492b, 0x4bb2bea5, 0x4b7e587d,
+0x4b4a169c, 0x4b15f8e6, 0x4ae1ff43, 0x4aae299b,
+0x4a7a77d5, 0x4a46e9d6, 0x4a137f88, 0x49e038d0,
+0x49ad1598, 0x497a15c4, 0x4947393f, 0x49147fee,
+0x48e1e9ba, 0x48af768a, 0x487d2646, 0x484af8d6,
+0x4818ee22, 0x47e70611, 0x47b5408c, 0x47839d7b,
+0x47521cc6, 0x4720be55, 0x46ef8210, 0x46be67e0,
+0x468d6fae, 0x465c9961, 0x462be4e2, 0x45fb521a,
+0x45cae0f2, 0x459a9152, 0x456a6323, 0x453a564d,
+0x450a6abb, 0x44daa054, 0x44aaf702, 0x447b6ead,
+0x444c0740, 0x441cc0a3, 0x43ed9ac0, 0x43be9580,
+0x438fb0cb, 0x4360ec8d, 0x433248ae, 0x4303c517,
+0x42d561b4, 0x42a71e6c, 0x4278fb2b, 0x424af7da,
+0x421d1462, 0x41ef50ae, 0x41c1aca8, 0x41942839,
+0x4166c34c, 0x41397dcc, 0x410c57a2, 0x40df50b8,
+0x40b268fa, 0x4085a051, 0x4058f6a8, 0x402c6be9
 };
 
 /*!
- 
-  \brief calculates 2 ^ (x/y) for x<=0, y > 0, x <= 32768 * y 
-  
+
+  \brief calculates 2 ^ (x/y) for x<=0, y > 0, x <= 32768 * y
+
   avoids integer division
-  
-  \return 
+
+  \return
 */
 Word32 pow2_xy(Word32 x, Word32 y)
 {
@@ -355,7 +355,7 @@
   fPart = tmp2 - iPart*y;
   iPart = min(iPart,INT_BITS-1);
 
-  res = pow2Table[(POW2_TABLE_SIZE*fPart)/y] >> iPart; 
- 
+  res = pow2Table[(POW2_TABLE_SIZE*fPart)/y] >> iPart;
+
   return(res);
 }
\ No newline at end of file
diff --git a/media/libstagefright/codecs/aacenc/basic_op/oper_32b.h b/media/libstagefright/codecs/aacenc/basic_op/oper_32b.h
index 1d35e5e..9ebd1c2 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/oper_32b.h
+++ b/media/libstagefright/codecs/aacenc/basic_op/oper_32b.h
@@ -51,21 +51,21 @@
     swHigh1 = (Word16)(L_var2 >> 16);
 
     l_var_out = (long)swLow1 * (long)var1 >> 15;
-    
+
     l_var_out += swHigh1 * var1 << 1;
-    
+
     return(l_var_out);
 }
 
 __inline Word32 L_mpy_wx(Word32 L_var2, Word16 var1)
 {
 #if ARMV5TE_L_MPY_LS
-	Word32 result; 
-	asm volatile( 
-		"SMULWB  %[result], %[L_var2], %[var1] \n" 
+	Word32 result;
+	asm volatile(
+		"SMULWB  %[result], %[L_var2], %[var1] \n"
 		:[result]"+r"(result)
 		:[L_var2]"r"(L_var2), [var1]"r"(var1)
-		); 
+		);
 	return result;
 #else
     unsigned short swLow1;
@@ -75,9 +75,9 @@
     swLow1 = (unsigned short)(L_var2);
     swHigh1 = (Word16)(L_var2 >> 16);
 
-    l_var_out = (long)swLow1 * (long)var1 >> 16;    
+    l_var_out = (long)swLow1 * (long)var1 >> 16;
     l_var_out += swHigh1 * var1;
-    
+
     return(l_var_out);
 #endif
 }
diff --git a/media/libstagefright/codecs/aacenc/basic_op/typedef.h b/media/libstagefright/codecs/aacenc/basic_op/typedef.h
index 1030803..b1f8225 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/typedef.h
+++ b/media/libstagefright/codecs/aacenc/basic_op/typedef.h
@@ -30,7 +30,7 @@
 /*
  * this is the original code from the ETSI file typedef.h
  */
-   
+
 #if defined(__BORLANDC__) || defined(__WATCOMC__) || defined(_MSC_VER) || defined(__ZTC__)
 typedef signed char Word8;
 typedef short Word16;
diff --git a/media/libstagefright/codecs/aacenc/basic_op/typedefs.h b/media/libstagefright/codecs/aacenc/basic_op/typedefs.h
index c7e774b..c924e2c 100644
--- a/media/libstagefright/codecs/aacenc/basic_op/typedefs.h
+++ b/media/libstagefright/codecs/aacenc/basic_op/typedefs.h
@@ -55,7 +55,7 @@
 #define INT_BITS   32
 /*
 ********************************************************************************
-*                         DEFINITION OF CONSTANTS 
+*                         DEFINITION OF CONSTANTS
 ********************************************************************************
 */
 /*
@@ -120,12 +120,12 @@
     #define ARMV5TE_L_MULT        1
     #define ARMV5TE_L_MAC         1
     #define ARMV5TE_L_MSU         1
-   
-    
+
+
     #define ARMV5TE_DIV_S         1
     #define ARMV5TE_ROUND         1
     #define ARMV5TE_MULT          1
-    
+
     #define ARMV5TE_NORM_S        1
     #define ARMV5TE_NORM_L        1
 	#define ARMV5TE_L_MPY_LS	  1
@@ -149,7 +149,7 @@
 #define ROUND_IS_INLINE                 1   //define round as inline function
 #define L_MAC_IS_INLINE                 1   //define L_mac as inline function
 #define L_ADD_IS_INLINE                 1   //define L_add as inline function
-#define EXTRACT_H_IS_INLINE             1   //define extract_h as inline function 
+#define EXTRACT_H_IS_INLINE             1   //define extract_h as inline function
 #define EXTRACT_L_IS_INLINE             1   //define extract_l as inline function        //???
 #define MULT_R_IS_INLINE                1   //define mult_r as inline function
 #define SHR_R_IS_INLINE                 1   //define shr_r as inline function
diff --git a/media/libstagefright/codecs/aacenc/inc/aac_rom.h b/media/libstagefright/codecs/aacenc/inc/aac_rom.h
index 784bb70..8e206b7 100644
--- a/media/libstagefright/codecs/aacenc/inc/aac_rom.h
+++ b/media/libstagefright/codecs/aacenc/inc/aac_rom.h
@@ -16,7 +16,7 @@
 /*******************************************************************************
 	File:		aac_rom.h
 
-	Content:	constant tables 
+	Content:	constant tables
 
 *******************************************************************************/
 
diff --git a/media/libstagefright/codecs/aacenc/inc/aacenc_core.h b/media/libstagefright/codecs/aacenc/inc/aacenc_core.h
index 41ba756..1acdbbc 100644
--- a/media/libstagefright/codecs/aacenc/inc/aacenc_core.h
+++ b/media/libstagefright/codecs/aacenc/inc/aacenc_core.h
@@ -47,7 +47,7 @@
 
 
 typedef struct {
-	
+
   AACENC_CONFIG config;     /* Word16 size: 8 */
 
   ELEMENT_INFO elInfo;      /* Word16 size: 4 */
diff --git a/media/libstagefright/codecs/aacenc/inc/adj_thr.h b/media/libstagefright/codecs/aacenc/inc/adj_thr.h
index f7cb888..0f4bb5e 100644
--- a/media/libstagefright/codecs/aacenc/inc/adj_thr.h
+++ b/media/libstagefright/codecs/aacenc/inc/adj_thr.h
@@ -16,7 +16,7 @@
 /*******************************************************************************
 	File:		adj_thr.h
 
-	Content:	Threshold compensation function 
+	Content:	Threshold compensation function
 
 *******************************************************************************/
 
@@ -44,7 +44,7 @@
                       PSY_OUT_ELEMENT *psyOutElement,
                       Word16 *chBitDistribution,
                       Word16 logSfbEnergy[MAX_CHANNELS][MAX_GROUPED_SFB],
-                      Word16 sfbNRelevantLines[MAX_CHANNELS][MAX_GROUPED_SFB],                      
+                      Word16 sfbNRelevantLines[MAX_CHANNELS][MAX_GROUPED_SFB],
                       QC_OUT_ELEMENT* qcOE,
 					  ELEMENT_BITS* elBits,
 					  const Word16 nChannels,
diff --git a/media/libstagefright/codecs/aacenc/inc/adj_thr_data.h b/media/libstagefright/codecs/aacenc/inc/adj_thr_data.h
index 9ac4664..30132d8 100644
--- a/media/libstagefright/codecs/aacenc/inc/adj_thr_data.h
+++ b/media/libstagefright/codecs/aacenc/inc/adj_thr_data.h
@@ -16,7 +16,7 @@
 /*******************************************************************************
 	File:		adj_thr_data.h
 
-	Content:	Threshold compensation parameter 
+	Content:	Threshold compensation parameter
 
 *******************************************************************************/
 
diff --git a/media/libstagefright/codecs/aacenc/inc/bitenc.h b/media/libstagefright/codecs/aacenc/inc/bitenc.h
index 6ded3c6..6a58aeb 100644
--- a/media/libstagefright/codecs/aacenc/inc/bitenc.h
+++ b/media/libstagefright/codecs/aacenc/inc/bitenc.h
@@ -26,7 +26,7 @@
 #include "qc_data.h"
 #include "tns.h"
 #include "channel_map.h"
-#include "interface.h"  
+#include "interface.h"
 
 struct BITSTREAMENCODER_INIT
 {
diff --git a/media/libstagefright/codecs/aacenc/inc/interface.h b/media/libstagefright/codecs/aacenc/inc/interface.h
index 966ac99..a42e6a9 100644
--- a/media/libstagefright/codecs/aacenc/inc/interface.h
+++ b/media/libstagefright/codecs/aacenc/inc/interface.h
@@ -55,11 +55,11 @@
   Word16  windowShape;
   Word16  groupingMask;
   Word16  sfbOffsets[MAX_GROUPED_SFB+1];
-  Word16  mdctScale; 
-  Word32 *sfbEnergy; 
+  Word16  mdctScale;
+  Word32 *sfbEnergy;
   Word32 *sfbSpreadedEnergy;
-  Word32 *sfbThreshold;       
-  Word32 *mdctSpectrum;        
+  Word32 *sfbThreshold;
+  Word32 *mdctSpectrum;
   Word32  sfbEnSumLR;
   Word32  sfbEnSumMS;
   Word32 sfbDist[MAX_GROUPED_SFB];
diff --git a/media/libstagefright/codecs/aacenc/inc/line_pe.h b/media/libstagefright/codecs/aacenc/inc/line_pe.h
index 038d5a3..116d5a8 100644
--- a/media/libstagefright/codecs/aacenc/inc/line_pe.h
+++ b/media/libstagefright/codecs/aacenc/inc/line_pe.h
@@ -24,8 +24,8 @@
 #define __LINE_PE_H
 
 
-#include "psy_const.h" 
-#include "interface.h" 
+#include "psy_const.h"
+#include "interface.h"
 
 
 typedef struct {
@@ -72,4 +72,4 @@
 
 
 
-#endif 
+#endif
diff --git a/media/libstagefright/codecs/aacenc/inc/psy_const.h b/media/libstagefright/codecs/aacenc/inc/psy_const.h
index b05d683..19fb9b2 100644
--- a/media/libstagefright/codecs/aacenc/inc/psy_const.h
+++ b/media/libstagefright/codecs/aacenc/inc/psy_const.h
@@ -69,7 +69,7 @@
 
 #define BLOCK_SWITCHING_OFFSET		   (1*1024+3*128+64+128)
 #define BLOCK_SWITCHING_DATA_SIZE          FRAME_LEN_LONG
-										    
+
 #define TRANSFORM_OFFSET_LONG    0
 #define TRANSFORM_OFFSET_SHORT   448
 
diff --git a/media/libstagefright/codecs/aacenc/inc/psy_main.h b/media/libstagefright/codecs/aacenc/inc/psy_main.h
index 5fcbe13..2ccac60 100644
--- a/media/libstagefright/codecs/aacenc/inc/psy_main.h
+++ b/media/libstagefright/codecs/aacenc/inc/psy_main.h
@@ -54,9 +54,9 @@
                     Word16 bandwidth);
 
 
-Word16 psyMain(Word16                   nChannels,   /*!< total number of channels */              
+Word16 psyMain(Word16                   nChannels,   /*!< total number of channels */
                ELEMENT_INFO             *elemInfo,
-               Word16                   *timeSignal, /*!< interleaved time signal */ 
+               Word16                   *timeSignal, /*!< interleaved time signal */
                PSY_DATA                 psyData[MAX_CHANNELS],
                TNS_DATA                 tnsData[MAX_CHANNELS],
                PSY_CONFIGURATION_LONG*  psyConfLong,
diff --git a/media/libstagefright/codecs/aacenc/inc/qc_main.h b/media/libstagefright/codecs/aacenc/inc/qc_main.h
index 924a06d..8f83973 100644
--- a/media/libstagefright/codecs/aacenc/inc/qc_main.h
+++ b/media/libstagefright/codecs/aacenc/inc/qc_main.h
@@ -35,7 +35,7 @@
 
 Word16 QCNew(QC_STATE *hQC, VO_MEM_OPERATOR *pMemOP);
 
-Word16 QCInit(QC_STATE *hQC, 
+Word16 QCInit(QC_STATE *hQC,
               struct QC_INIT *init);
 
 void QCDelete(QC_STATE *hQC, VO_MEM_OPERATOR *pMemOP);
diff --git a/media/libstagefright/codecs/aacenc/inc/quantize.h b/media/libstagefright/codecs/aacenc/inc/quantize.h
index 7dac2bf..1cafef6 100644
--- a/media/libstagefright/codecs/aacenc/inc/quantize.h
+++ b/media/libstagefright/codecs/aacenc/inc/quantize.h
@@ -28,7 +28,7 @@
 
 #define MAX_QUANT 8191
 
-void QuantizeSpectrum(Word16 sfbCnt, 
+void QuantizeSpectrum(Word16 sfbCnt,
                       Word16 maxSfbPerGroup,
                       Word16 sfbPerGroup,
                       Word16 *sfbOffset, Word32 *mdctSpectrum,
diff --git a/media/libstagefright/codecs/aacenc/inc/sf_estim.h b/media/libstagefright/codecs/aacenc/inc/sf_estim.h
index 11436a2..9039f25 100644
--- a/media/libstagefright/codecs/aacenc/inc/sf_estim.h
+++ b/media/libstagefright/codecs/aacenc/inc/sf_estim.h
@@ -23,7 +23,7 @@
 #ifndef __SF_ESTIM_H__
 #define __SF_ESTIM_H__
 /*
-   Scale factor estimation 
+   Scale factor estimation
  */
 #include "psy_const.h"
 #include "interface.h"
diff --git a/media/libstagefright/codecs/aacenc/inc/stat_bits.h b/media/libstagefright/codecs/aacenc/inc/stat_bits.h
index fff3d14..9cddc1d 100644
--- a/media/libstagefright/codecs/aacenc/inc/stat_bits.h
+++ b/media/libstagefright/codecs/aacenc/inc/stat_bits.h
@@ -28,7 +28,7 @@
 
 Word16 countStaticBitdemand(PSY_OUT_CHANNEL psyOutChannel[MAX_CHANNELS],
                             PSY_OUT_ELEMENT *psyOutElement,
-                            Word16 nChannels, 
+                            Word16 nChannels,
 							Word16 adtsUsed);
 
 #endif /* __STAT_BITS_H */
diff --git a/media/libstagefright/codecs/aacenc/inc/tns_param.h b/media/libstagefright/codecs/aacenc/inc/tns_param.h
index 78265bb..0aa33c3 100644
--- a/media/libstagefright/codecs/aacenc/inc/tns_param.h
+++ b/media/libstagefright/codecs/aacenc/inc/tns_param.h
@@ -44,7 +44,7 @@
 }TNS_INFO_TAB;
 
 
-void GetTnsParam(TNS_CONFIG_TABULATED *tnsConfigTab, 
+void GetTnsParam(TNS_CONFIG_TABULATED *tnsConfigTab,
                  Word32 bitRate, Word16 channels, Word16 blockType);
 
 void GetTnsMaxBands(Word32 samplingRate, Word16 blockType, Word16* tnsMaxSfb);
diff --git a/media/libstagefright/codecs/aacenc/inc/transform.h b/media/libstagefright/codecs/aacenc/inc/transform.h
index 93d5ffe..fbac7aa 100644
--- a/media/libstagefright/codecs/aacenc/inc/transform.h
+++ b/media/libstagefright/codecs/aacenc/inc/transform.h
@@ -24,7 +24,7 @@
 #define __TRANSFORM_H__
 
 #include "typedef.h"
-                  
+
 void Transform_Real(Word16 *mdctDelayBuffer,
                     Word16 *timeSignal,
                     Word16 chIncrement,     /*! channel increment */
diff --git a/media/libstagefright/codecs/aacenc/src/aac_rom.c b/media/libstagefright/codecs/aacenc/src/aac_rom.c
index 16b44e0..08792e8 100644
--- a/media/libstagefright/codecs/aacenc/src/aac_rom.c
+++ b/media/libstagefright/codecs/aacenc/src/aac_rom.c
@@ -24,14 +24,14 @@
 
 #if defined (ARMV5E) && !defined (ARMV7Neon)
 
-/* 
- *  Q30 for 128 and 1024 
+/*
+ *  Q30 for 128 and 1024
  *
  * for (i = 0; i < num/4; i++) {
  *   angle = (i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 30);
  *   x = sin(angle) * (1 << 30);
- * 
+ *
  *   angle = (num/2 - 1 - i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 30);
  *   x = sin(angle) * (1 << 30);
@@ -39,313 +39,313 @@
  */
 const int cossintab[128 + 1024] = {
 	/* 128 */
-	0x3fffec43, 0x003243f1, 0x015fd4d2, 0x3ffc38d1, 0x3ff9c13a, 0x01c454f5, 0x02f1b755, 0x3feea776, 
-	0x3fe9b8a9, 0x03562038, 0x0483259d, 0x3fd73a4a, 0x3fcfd50b, 0x04e767c5, 0x0613e1c5, 0x3fb5f4ea, 
-	0x3fac1a5b, 0x0677edbb, 0x07a3adff, 0x3f8adc77, 0x3f7e8e1e, 0x08077457, 0x09324ca7, 0x3f55f796, 
-	0x3f473759, 0x0995bdfd, 0x0abf8043, 0x3f174e70, 0x3f061e95, 0x0b228d42, 0x0c4b0b94, 0x3eceeaad, 
-	0x3ebb4ddb, 0x0cada4f5, 0x0dd4b19a, 0x3e7cd778, 0x3e66d0b4, 0x0e36c82a, 0x0f5c35a3, 0x3e212179, 
-	0x3e08b42a, 0x0fbdba40, 0x10e15b4e, 0x3dbbd6d4, 0x3da106bd, 0x11423ef0, 0x1263e699, 0x3d4d0728, 
-	0x3d2fd86c, 0x12c41a4f, 0x13e39be9, 0x3cd4c38b, 0x3cb53aaa, 0x144310dd, 0x15604013, 0x3c531e88, 
-	0x3c314060, 0x15bee78c, 0x16d99864, 0x3bc82c1f, 0x3ba3fde7, 0x173763c9, 0x184f6aab, 0x3b3401bb, 
-	0x3b0d8909, 0x18ac4b87, 0x19c17d44, 0x3a96b636, 0x3a6df8f8, 0x1a1d6544, 0x1b2f971e, 0x39f061d2, 
-	0x39c5664f, 0x1b8a7815, 0x1c997fc4, 0x39411e33, 0x3913eb0e, 0x1cf34baf, 0x1dfeff67, 0x38890663, 
-	0x3859a292, 0x1e57a86d, 0x1f5fdee6, 0x37c836c2, 0x3796a996, 0x1fb7575c, 0x20bbe7d8, 0x36fecd0e, 
-	0x36cb1e2a, 0x21122240, 0x2212e492, 0x362ce855, 0x35f71fb1, 0x2267d3a0, 0x2364a02e, 0x3552a8f4, 
-	0x351acedd, 0x23b836ca, 0x24b0e699, 0x34703095, 0x34364da6, 0x250317df, 0x25f78497, 0x3385a222, 
-	0x3349bf48, 0x264843d9, 0x273847c8, 0x329321c7, 0x32554840, 0x27878893, 0x2872feb6, 0x3198d4ea, 
-	0x31590e3e, 0x28c0b4d2, 0x29a778db, 0x3096e223, 0x30553828, 0x29f3984c, 0x2ad586a3, 0x2f8d713a, 
-	0x2f49ee0f, 0x2b2003ac, 0x2bfcf97c, 0x2e7cab1c, 0x2e37592c, 0x2c45c8a0, 0x2d1da3d5, 0x2d64b9da, 
+	0x3fffec43, 0x003243f1, 0x015fd4d2, 0x3ffc38d1, 0x3ff9c13a, 0x01c454f5, 0x02f1b755, 0x3feea776,
+	0x3fe9b8a9, 0x03562038, 0x0483259d, 0x3fd73a4a, 0x3fcfd50b, 0x04e767c5, 0x0613e1c5, 0x3fb5f4ea,
+	0x3fac1a5b, 0x0677edbb, 0x07a3adff, 0x3f8adc77, 0x3f7e8e1e, 0x08077457, 0x09324ca7, 0x3f55f796,
+	0x3f473759, 0x0995bdfd, 0x0abf8043, 0x3f174e70, 0x3f061e95, 0x0b228d42, 0x0c4b0b94, 0x3eceeaad,
+	0x3ebb4ddb, 0x0cada4f5, 0x0dd4b19a, 0x3e7cd778, 0x3e66d0b4, 0x0e36c82a, 0x0f5c35a3, 0x3e212179,
+	0x3e08b42a, 0x0fbdba40, 0x10e15b4e, 0x3dbbd6d4, 0x3da106bd, 0x11423ef0, 0x1263e699, 0x3d4d0728,
+	0x3d2fd86c, 0x12c41a4f, 0x13e39be9, 0x3cd4c38b, 0x3cb53aaa, 0x144310dd, 0x15604013, 0x3c531e88,
+	0x3c314060, 0x15bee78c, 0x16d99864, 0x3bc82c1f, 0x3ba3fde7, 0x173763c9, 0x184f6aab, 0x3b3401bb,
+	0x3b0d8909, 0x18ac4b87, 0x19c17d44, 0x3a96b636, 0x3a6df8f8, 0x1a1d6544, 0x1b2f971e, 0x39f061d2,
+	0x39c5664f, 0x1b8a7815, 0x1c997fc4, 0x39411e33, 0x3913eb0e, 0x1cf34baf, 0x1dfeff67, 0x38890663,
+	0x3859a292, 0x1e57a86d, 0x1f5fdee6, 0x37c836c2, 0x3796a996, 0x1fb7575c, 0x20bbe7d8, 0x36fecd0e,
+	0x36cb1e2a, 0x21122240, 0x2212e492, 0x362ce855, 0x35f71fb1, 0x2267d3a0, 0x2364a02e, 0x3552a8f4,
+	0x351acedd, 0x23b836ca, 0x24b0e699, 0x34703095, 0x34364da6, 0x250317df, 0x25f78497, 0x3385a222,
+	0x3349bf48, 0x264843d9, 0x273847c8, 0x329321c7, 0x32554840, 0x27878893, 0x2872feb6, 0x3198d4ea,
+	0x31590e3e, 0x28c0b4d2, 0x29a778db, 0x3096e223, 0x30553828, 0x29f3984c, 0x2ad586a3, 0x2f8d713a,
+	0x2f49ee0f, 0x2b2003ac, 0x2bfcf97c, 0x2e7cab1c, 0x2e37592c, 0x2c45c8a0, 0x2d1da3d5, 0x2d64b9da,
 	/* 1024 */
-	0x3fffffb1, 0x0006487f, 0x002bfb74, 0x3ffff0e3, 0x3fffe705, 0x00388c6e, 0x005e3f4c, 0x3fffba9b, 
-	0x3fffa6de, 0x006ad03b, 0x009082ea, 0x3fff5cd8, 0x3fff3f3c, 0x009d13c5, 0x00c2c62f, 0x3ffed79b, 
-	0x3ffeb021, 0x00cf56ef, 0x00f508fc, 0x3ffe2ae5, 0x3ffdf98c, 0x01019998, 0x01274b31, 0x3ffd56b5, 
-	0x3ffd1b7e, 0x0133dba3, 0x01598cb1, 0x3ffc5b0c, 0x3ffc15f7, 0x01661cf0, 0x018bcd5b, 0x3ffb37ec, 
-	0x3ffae8f9, 0x01985d60, 0x01be0d11, 0x3ff9ed53, 0x3ff99483, 0x01ca9cd4, 0x01f04bb4, 0x3ff87b44, 
-	0x3ff81896, 0x01fcdb2e, 0x02228924, 0x3ff6e1bf, 0x3ff67534, 0x022f184d, 0x0254c544, 0x3ff520c5, 
-	0x3ff4aa5d, 0x02615414, 0x0286fff3, 0x3ff33858, 0x3ff2b813, 0x02938e62, 0x02b93914, 0x3ff12878, 
-	0x3ff09e56, 0x02c5c71a, 0x02eb7086, 0x3feef126, 0x3fee5d28, 0x02f7fe1c, 0x031da62b, 0x3fec9265, 
-	0x3febf48b, 0x032a3349, 0x034fd9e5, 0x3fea0c35, 0x3fe96480, 0x035c6682, 0x03820b93, 0x3fe75e98, 
-	0x3fe6ad08, 0x038e97a9, 0x03b43b17, 0x3fe48990, 0x3fe3ce26, 0x03c0c69e, 0x03e66852, 0x3fe18d1f, 
-	0x3fe0c7da, 0x03f2f342, 0x04189326, 0x3fde6945, 0x3fdd9a27, 0x04251d77, 0x044abb73, 0x3fdb1e06, 
-	0x3fda450f, 0x0457451d, 0x047ce11a, 0x3fd7ab64, 0x3fd6c894, 0x04896a16, 0x04af03fc, 0x3fd4115f, 
-	0x3fd324b7, 0x04bb8c42, 0x04e123fa, 0x3fd04ffc, 0x3fcf597c, 0x04edab83, 0x051340f6, 0x3fcc673b, 
-	0x3fcb66e4, 0x051fc7b9, 0x05455ad1, 0x3fc8571f, 0x3fc74cf3, 0x0551e0c7, 0x0577716b, 0x3fc41fac, 
-	0x3fc30baa, 0x0583f68c, 0x05a984a6, 0x3fbfc0e3, 0x3fbea30c, 0x05b608eb, 0x05db9463, 0x3fbb3ac7, 
-	0x3fba131b, 0x05e817c3, 0x060da083, 0x3fb68d5b, 0x3fb55bdc, 0x061a22f7, 0x063fa8e7, 0x3fb1b8a2, 
-	0x3fb07d50, 0x064c2a67, 0x0671ad71, 0x3facbc9f, 0x3fab777b, 0x067e2df5, 0x06a3ae00, 0x3fa79954, 
-	0x3fa64a5f, 0x06b02d81, 0x06d5aa77, 0x3fa24ec6, 0x3fa0f600, 0x06e228ee, 0x0707a2b7, 0x3f9cdcf7, 
-	0x3f9b7a62, 0x0714201b, 0x073996a1, 0x3f9743eb, 0x3f95d787, 0x074612eb, 0x076b8616, 0x3f9183a5, 
-	0x3f900d72, 0x0778013d, 0x079d70f7, 0x3f8b9c28, 0x3f8a1c29, 0x07a9eaf5, 0x07cf5726, 0x3f858d79, 
-	0x3f8403ae, 0x07dbcff2, 0x08013883, 0x3f7f579b, 0x3f7dc405, 0x080db016, 0x083314f1, 0x3f78fa92, 
-	0x3f775d31, 0x083f8b43, 0x0864ec4f, 0x3f727661, 0x3f70cf38, 0x08716159, 0x0896be80, 0x3f6bcb0e, 
-	0x3f6a1a1c, 0x08a3323a, 0x08c88b65, 0x3f64f89b, 0x3f633de2, 0x08d4fdc6, 0x08fa52de, 0x3f5dff0e, 
-	0x3f5c3a8f, 0x0906c3e0, 0x092c14ce, 0x3f56de6a, 0x3f551026, 0x09388469, 0x095dd116, 0x3f4f96b4, 
-	0x3f4dbeac, 0x096a3f42, 0x098f8796, 0x3f4827f0, 0x3f464626, 0x099bf44c, 0x09c13831, 0x3f409223, 
-	0x3f3ea697, 0x09cda368, 0x09f2e2c7, 0x3f38d552, 0x3f36e006, 0x09ff4c78, 0x0a24873a, 0x3f30f181, 
-	0x3f2ef276, 0x0a30ef5e, 0x0a56256c, 0x3f28e6b6, 0x3f26ddec, 0x0a628bfa, 0x0a87bd3d, 0x3f20b4f5, 
-	0x3f1ea26e, 0x0a94222f, 0x0ab94e8f, 0x3f185c43, 0x3f164001, 0x0ac5b1dc, 0x0aead944, 0x3f0fdca5, 
-	0x3f0db6a9, 0x0af73ae5, 0x0b1c5d3d, 0x3f073621, 0x3f05066d, 0x0b28bd2a, 0x0b4dda5c, 0x3efe68bc, 
-	0x3efc2f50, 0x0b5a388d, 0x0b7f5081, 0x3ef5747b, 0x3ef3315a, 0x0b8bacf0, 0x0bb0bf8f, 0x3eec5965, 
-	0x3eea0c8e, 0x0bbd1a33, 0x0be22766, 0x3ee3177e, 0x3ee0c0f4, 0x0bee8038, 0x0c1387e9, 0x3ed9aecc, 
-	0x3ed74e91, 0x0c1fdee1, 0x0c44e0f9, 0x3ed01f55, 0x3ecdb56a, 0x0c513610, 0x0c763278, 0x3ec66920, 
-	0x3ec3f585, 0x0c8285a5, 0x0ca77c47, 0x3ebc8c31, 0x3eba0ee9, 0x0cb3cd84, 0x0cd8be47, 0x3eb2888f, 
-	0x3eb0019c, 0x0ce50d8c, 0x0d09f85b, 0x3ea85e41, 0x3ea5cda3, 0x0d1645a0, 0x0d3b2a64, 0x3e9e0d4c, 
-	0x3e9b7306, 0x0d4775a1, 0x0d6c5443, 0x3e9395b7, 0x3e90f1ca, 0x0d789d71, 0x0d9d75db, 0x3e88f788, 
-	0x3e8649f5, 0x0da9bcf2, 0x0dce8f0d, 0x3e7e32c6, 0x3e7b7b90, 0x0ddad406, 0x0dff9fba, 0x3e734778, 
-	0x3e70869f, 0x0e0be28e, 0x0e30a7c5, 0x3e6835a4, 0x3e656b2b, 0x0e3ce86b, 0x0e61a70f, 0x3e5cfd51, 
-	0x3e5a2939, 0x0e6de580, 0x0e929d7a, 0x3e519e86, 0x3e4ec0d1, 0x0e9ed9af, 0x0ec38ae8, 0x3e46194a, 
-	0x3e4331fa, 0x0ecfc4d9, 0x0ef46f3b, 0x3e3a6da4, 0x3e377cbb, 0x0f00a6df, 0x0f254a53, 0x3e2e9b9c, 
-	0x3e2ba11b, 0x0f317fa5, 0x0f561c15, 0x3e22a338, 0x3e1f9f21, 0x0f624f0c, 0x0f86e460, 0x3e168480, 
-	0x3e1376d5, 0x0f9314f5, 0x0fb7a317, 0x3e0a3f7b, 0x3e07283f, 0x0fc3d143, 0x0fe8581d, 0x3dfdd432, 
-	0x3dfab365, 0x0ff483d7, 0x10190352, 0x3df142ab, 0x3dee1851, 0x10252c94, 0x1049a49a, 0x3de48aef, 
-	0x3de15708, 0x1055cb5b, 0x107a3bd5, 0x3dd7ad05, 0x3dd46f94, 0x1086600e, 0x10aac8e6, 0x3dcaa8f5, 
-	0x3dc761fc, 0x10b6ea90, 0x10db4baf, 0x3dbd7ec7, 0x3dba2e48, 0x10e76ac3, 0x110bc413, 0x3db02e84, 
-	0x3dacd481, 0x1117e088, 0x113c31f3, 0x3da2b834, 0x3d9f54af, 0x11484bc2, 0x116c9531, 0x3d951bde, 
-	0x3d91aed9, 0x1178ac53, 0x119cedaf, 0x3d87598c, 0x3d83e309, 0x11a9021d, 0x11cd3b50, 0x3d797145, 
-	0x3d75f147, 0x11d94d02, 0x11fd7df6, 0x3d6b6313, 0x3d67d99b, 0x12098ce5, 0x122db583, 0x3d5d2efe, 
-	0x3d599c0e, 0x1239c1a7, 0x125de1da, 0x3d4ed50f, 0x3d4b38aa, 0x1269eb2b, 0x128e02dc, 0x3d40554e, 
-	0x3d3caf76, 0x129a0954, 0x12be186c, 0x3d31afc5, 0x3d2e007c, 0x12ca1c03, 0x12ee226c, 0x3d22e47c, 
-	0x3d1f2bc5, 0x12fa231b, 0x131e20c0, 0x3d13f37e, 0x3d10315a, 0x132a1e7e, 0x134e1348, 0x3d04dcd2, 
-	0x3d011145, 0x135a0e0e, 0x137df9e7, 0x3cf5a082, 0x3cf1cb8e, 0x1389f1af, 0x13add481, 0x3ce63e98, 
-	0x3ce2603f, 0x13b9c943, 0x13dda2f7, 0x3cd6b71e, 0x3cd2cf62, 0x13e994ab, 0x140d652c, 0x3cc70a1c, 
-	0x3cc318ff, 0x141953cb, 0x143d1b02, 0x3cb7379c, 0x3cb33d22, 0x14490685, 0x146cc45c, 0x3ca73fa9, 
-	0x3ca33bd3, 0x1478acbc, 0x149c611d, 0x3c97224c, 0x3c93151d, 0x14a84652, 0x14cbf127, 0x3c86df8e, 
-	0x3c82c909, 0x14d7d32a, 0x14fb745e, 0x3c76777b, 0x3c7257a2, 0x15075327, 0x152aeaa3, 0x3c65ea1c, 
-	0x3c61c0f1, 0x1536c62b, 0x155a53d9, 0x3c55377b, 0x3c510501, 0x15662c18, 0x1589afe3, 0x3c445fa2, 
-	0x3c4023dd, 0x159584d3, 0x15b8fea4, 0x3c33629d, 0x3c2f1d8e, 0x15c4d03e, 0x15e83fff, 0x3c224075, 
-	0x3c1df21f, 0x15f40e3a, 0x161773d6, 0x3c10f935, 0x3c0ca19b, 0x16233eac, 0x16469a0d, 0x3bff8ce8, 
-	0x3bfb2c0c, 0x16526176, 0x1675b286, 0x3bedfb99, 0x3be9917e, 0x1681767c, 0x16a4bd25, 0x3bdc4552, 
-	0x3bd7d1fa, 0x16b07d9f, 0x16d3b9cc, 0x3bca6a1d, 0x3bc5ed8d, 0x16df76c3, 0x1702a85e, 0x3bb86a08, 
-	0x3bb3e440, 0x170e61cc, 0x173188be, 0x3ba6451b, 0x3ba1b620, 0x173d3e9b, 0x17605ad0, 0x3b93fb63, 
-	0x3b8f6337, 0x176c0d15, 0x178f1e76, 0x3b818ceb, 0x3b7ceb90, 0x179acd1c, 0x17bdd394, 0x3b6ef9be, 
-	0x3b6a4f38, 0x17c97e93, 0x17ec7a0d, 0x3b5c41e8, 0x3b578e39, 0x17f8215e, 0x181b11c4, 0x3b496574, 
-	0x3b44a8a0, 0x1826b561, 0x18499a9d, 0x3b36646e, 0x3b319e77, 0x18553a7d, 0x1878147a, 0x3b233ee1, 
-	0x3b1e6fca, 0x1883b097, 0x18a67f3f, 0x3b0ff4d9, 0x3b0b1ca6, 0x18b21791, 0x18d4dad0, 0x3afc8663, 
-	0x3af7a516, 0x18e06f50, 0x1903270f, 0x3ae8f38b, 0x3ae40926, 0x190eb7b7, 0x193163e1, 0x3ad53c5b, 
-	0x3ad048e3, 0x193cf0a9, 0x195f9128, 0x3ac160e1, 0x3abc6458, 0x196b1a09, 0x198daec8, 0x3aad6129, 
-	0x3aa85b92, 0x199933bb, 0x19bbbca6, 0x3a993d3e, 0x3a942e9d, 0x19c73da3, 0x19e9baa3, 0x3a84f52f, 
-	0x3a7fdd86, 0x19f537a4, 0x1a17a8a5, 0x3a708906, 0x3a6b6859, 0x1a2321a2, 0x1a45868e, 0x3a5bf8d1, 
-	0x3a56cf23, 0x1a50fb81, 0x1a735442, 0x3a47449c, 0x3a4211f0, 0x1a7ec524, 0x1aa111a6, 0x3a326c74, 
-	0x3a2d30cd, 0x1aac7e6f, 0x1acebe9d, 0x3a1d7066, 0x3a182bc8, 0x1ada2746, 0x1afc5b0a, 0x3a08507f, 
-	0x3a0302ed, 0x1b07bf8c, 0x1b29e6d2, 0x39f30ccc, 0x39edb649, 0x1b354727, 0x1b5761d8, 0x39dda55a, 
-	0x39d845e9, 0x1b62bdf8, 0x1b84cc01, 0x39c81a36, 0x39c2b1da, 0x1b9023e5, 0x1bb22530, 0x39b26b6d, 
-	0x39acfa2b, 0x1bbd78d2, 0x1bdf6d4a, 0x399c990d, 0x39971ee7, 0x1beabca1, 0x1c0ca432, 0x3986a324, 
-	0x3981201e, 0x1c17ef39, 0x1c39c9cd, 0x397089bf, 0x396afddc, 0x1c45107c, 0x1c66ddfe, 0x395a4ceb, 
-	0x3954b82e, 0x1c72204f, 0x1c93e0ab, 0x3943ecb6, 0x393e4f23, 0x1c9f1e96, 0x1cc0d1b6, 0x392d692f, 
-	0x3927c2c9, 0x1ccc0b35, 0x1cedb106, 0x3916c262, 0x3911132d, 0x1cf8e611, 0x1d1a7e7d, 0x38fff85e, 
-	0x38fa405e, 0x1d25af0d, 0x1d473a00, 0x38e90b31, 0x38e34a69, 0x1d52660f, 0x1d73e374, 0x38d1fae9, 
-	0x38cc315d, 0x1d7f0afb, 0x1da07abc, 0x38bac795, 0x38b4f547, 0x1dab9db5, 0x1dccffbf, 0x38a37142, 
-	0x389d9637, 0x1dd81e21, 0x1df9725f, 0x388bf7ff, 0x3886143b, 0x1e048c24, 0x1e25d282, 0x38745bdb, 
-	0x386e6f60, 0x1e30e7a4, 0x1e52200c, 0x385c9ce3, 0x3856a7b6, 0x1e5d3084, 0x1e7e5ae2, 0x3844bb28, 
-	0x383ebd4c, 0x1e8966a8, 0x1eaa82e9, 0x382cb6b7, 0x3826b030, 0x1eb589f7, 0x1ed69805, 0x38148f9f, 
-	0x380e8071, 0x1ee19a54, 0x1f029a1c, 0x37fc45ef, 0x37f62e1d, 0x1f0d97a5, 0x1f2e8911, 0x37e3d9b7, 
-	0x37ddb945, 0x1f3981ce, 0x1f5a64cb, 0x37cb4b04, 0x37c521f6, 0x1f6558b5, 0x1f862d2d, 0x37b299e7, 
-	0x37ac6841, 0x1f911c3d, 0x1fb1e21d, 0x3799c66f, 0x37938c34, 0x1fbccc4d, 0x1fdd8381, 0x3780d0aa, 
-	0x377a8ddf, 0x1fe868c8, 0x2009113c, 0x3767b8a9, 0x37616d51, 0x2013f196, 0x20348b35, 0x374e7e7b, 
-	0x37482a9a, 0x203f6699, 0x205ff14f, 0x3735222f, 0x372ec5c9, 0x206ac7b8, 0x208b4372, 0x371ba3d4, 
-	0x37153eee, 0x209614d9, 0x20b68181, 0x3702037c, 0x36fb9618, 0x20c14ddf, 0x20e1ab63, 0x36e84135, 
-	0x36e1cb58, 0x20ec72b1, 0x210cc0fc, 0x36ce5d10, 0x36c7debd, 0x21178334, 0x2137c232, 0x36b4571b, 
-	0x36add058, 0x21427f4d, 0x2162aeea, 0x369a2f69, 0x3693a038, 0x216d66e2, 0x218d870b, 0x367fe608, 
-	0x36794e6e, 0x219839d8, 0x21b84a79, 0x36657b08, 0x365edb09, 0x21c2f815, 0x21e2f91a, 0x364aee7b, 
-	0x3644461b, 0x21eda17f, 0x220d92d4, 0x36304070, 0x36298fb4, 0x221835fb, 0x2238178d, 0x361570f8, 
-	0x360eb7e3, 0x2242b56f, 0x22628729, 0x35fa8023, 0x35f3beba, 0x226d1fc1, 0x228ce191, 0x35df6e03, 
-	0x35d8a449, 0x229774d7, 0x22b726a8, 0x35c43aa7, 0x35bd68a1, 0x22c1b496, 0x22e15655, 0x35a8e621, 
-	0x35a20bd3, 0x22ebdee5, 0x230b707e, 0x358d7081, 0x35868def, 0x2315f3a8, 0x23357509, 0x3571d9d9, 
-	0x356aef08, 0x233ff2c8, 0x235f63dc, 0x35562239, 0x354f2f2c, 0x2369dc29, 0x23893cdd, 0x353a49b2, 
-	0x35334e6f, 0x2393afb2, 0x23b2fff3, 0x351e5056, 0x35174ce0, 0x23bd6d48, 0x23dcad03, 0x35023636, 
-	0x34fb2a92, 0x23e714d3, 0x240643f4, 0x34e5fb63, 0x34dee795, 0x2410a639, 0x242fc4ad, 0x34c99fef, 
-	0x34c283fb, 0x243a215f, 0x24592f13, 0x34ad23eb, 0x34a5ffd5, 0x2463862c, 0x2482830d, 0x34908768, 
-	0x34895b36, 0x248cd487, 0x24abc082, 0x3473ca79, 0x346c962f, 0x24b60c57, 0x24d4e757, 0x3456ed2f, 
-	0x344fb0d1, 0x24df2d81, 0x24fdf775, 0x3439ef9c, 0x3432ab2e, 0x250837ed, 0x2526f0c1, 0x341cd1d2, 
-	0x34158559, 0x25312b81, 0x254fd323, 0x33ff93e2, 0x33f83f62, 0x255a0823, 0x25789e80, 0x33e235df, 
-	0x33dad95e, 0x2582cdbc, 0x25a152c0, 0x33c4b7db, 0x33bd535c, 0x25ab7c30, 0x25c9efca, 0x33a719e8, 
-	0x339fad70, 0x25d41369, 0x25f27584, 0x33895c18, 0x3381e7ac, 0x25fc934b, 0x261ae3d6, 0x336b7e7e, 
-	0x33640223, 0x2624fbbf, 0x26433aa7, 0x334d812d, 0x3345fce6, 0x264d4cac, 0x266b79dd, 0x332f6435, 
-	0x3327d808, 0x267585f8, 0x2693a161, 0x331127ab, 0x3309939c, 0x269da78b, 0x26bbb119, 0x32f2cba1, 
-	0x32eb2fb5, 0x26c5b14c, 0x26e3a8ec, 0x32d45029, 0x32ccac64, 0x26eda322, 0x270b88c2, 0x32b5b557, 
-	0x32ae09be, 0x27157cf5, 0x27335082, 0x3296fb3d, 0x328f47d5, 0x273d3eac, 0x275b0014, 0x327821ee, 
-	0x327066bc, 0x2764e82f, 0x27829760, 0x3259297d, 0x32516686, 0x278c7965, 0x27aa164c, 0x323a11fe, 
-	0x32324746, 0x27b3f235, 0x27d17cc1, 0x321adb83, 0x3213090f, 0x27db5288, 0x27f8caa5, 0x31fb8620, 
-	0x31f3abf5, 0x28029a45, 0x281fffe2, 0x31dc11e8, 0x31d4300b, 0x2829c954, 0x28471c5e, 0x31bc7eee, 
-	0x31b49564, 0x2850df9d, 0x286e2002, 0x319ccd46, 0x3194dc14, 0x2877dd07, 0x28950ab6, 0x317cfd04, 
-	0x3175042e, 0x289ec17a, 0x28bbdc61, 0x315d0e3b, 0x31550dc6, 0x28c58cdf, 0x28e294eb, 0x313d00ff, 
-	0x3134f8f1, 0x28ec3f1e, 0x2909343e, 0x311cd564, 0x3114c5c0, 0x2912d81f, 0x292fba40, 0x30fc8b7d, 
-	0x30f47449, 0x293957c9, 0x295626da, 0x30dc235e, 0x30d404a0, 0x295fbe06, 0x297c79f5, 0x30bb9d1c, 
-	0x30b376d8, 0x29860abd, 0x29a2b378, 0x309af8ca, 0x3092cb05, 0x29ac3dd7, 0x29c8d34d, 0x307a367c, 
-	0x3072013c, 0x29d2573c, 0x29eed95b, 0x30595648, 0x30511991, 0x29f856d5, 0x2a14c58b, 0x30385840, 
-	0x30301418, 0x2a1e3c8a, 0x2a3a97c7, 0x30173c7a, 0x300ef0e5, 0x2a440844, 0x2a604ff5, 0x2ff6030a, 
-	0x2fedb00d, 0x2a69b9ec, 0x2a85ee00, 0x2fd4ac04, 0x2fcc51a5, 0x2a8f516b, 0x2aab71d0, 0x2fb3377c, 
-	0x2faad5c1, 0x2ab4cea9, 0x2ad0db4e, 0x2f91a589, 0x2f893c75, 0x2ada318e, 0x2af62a63, 0x2f6ff63d, 
-	0x2f6785d7, 0x2aff7a05, 0x2b1b5ef8, 0x2f4e29af, 0x2f45b1fb, 0x2b24a7f6, 0x2b4078f5, 0x2f2c3ff2, 
-	0x2f23c0f6, 0x2b49bb4a, 0x2b657844, 0x2f0a391d, 0x2f01b2de, 0x2b6eb3ea, 0x2b8a5cce, 0x2ee81543, 
-	0x2edf87c6, 0x2b9391c0, 0x2baf267d, 0x2ec5d479, 0x2ebd3fc4, 0x2bb854b4, 0x2bd3d53a, 0x2ea376d6, 
-	0x2e9adaee, 0x2bdcfcb0, 0x2bf868ed, 0x2e80fc6e, 0x2e785958, 0x2c01899e, 0x2c1ce181, 0x2e5e6556, 
-	0x2e55bb17, 0x2c25fb66, 0x2c413edf, 0x2e3bb1a4, 0x2e330042, 0x2c4a51f3, 0x2c6580f1, 0x2e18e16d, 
-	0x2e1028ed, 0x2c6e8d2e, 0x2c89a79f, 0x2df5f4c7, 0x2ded352f, 0x2c92ad01, 0x2cadb2d5, 0x2dd2ebc7, 
-	0x2dca251c, 0x2cb6b155, 0x2cd1a27b, 0x2dafc683, 0x2da6f8ca, 0x2cda9a14, 0x2cf5767c, 0x2d8c8510, 
+	0x3fffffb1, 0x0006487f, 0x002bfb74, 0x3ffff0e3, 0x3fffe705, 0x00388c6e, 0x005e3f4c, 0x3fffba9b,
+	0x3fffa6de, 0x006ad03b, 0x009082ea, 0x3fff5cd8, 0x3fff3f3c, 0x009d13c5, 0x00c2c62f, 0x3ffed79b,
+	0x3ffeb021, 0x00cf56ef, 0x00f508fc, 0x3ffe2ae5, 0x3ffdf98c, 0x01019998, 0x01274b31, 0x3ffd56b5,
+	0x3ffd1b7e, 0x0133dba3, 0x01598cb1, 0x3ffc5b0c, 0x3ffc15f7, 0x01661cf0, 0x018bcd5b, 0x3ffb37ec,
+	0x3ffae8f9, 0x01985d60, 0x01be0d11, 0x3ff9ed53, 0x3ff99483, 0x01ca9cd4, 0x01f04bb4, 0x3ff87b44,
+	0x3ff81896, 0x01fcdb2e, 0x02228924, 0x3ff6e1bf, 0x3ff67534, 0x022f184d, 0x0254c544, 0x3ff520c5,
+	0x3ff4aa5d, 0x02615414, 0x0286fff3, 0x3ff33858, 0x3ff2b813, 0x02938e62, 0x02b93914, 0x3ff12878,
+	0x3ff09e56, 0x02c5c71a, 0x02eb7086, 0x3feef126, 0x3fee5d28, 0x02f7fe1c, 0x031da62b, 0x3fec9265,
+	0x3febf48b, 0x032a3349, 0x034fd9e5, 0x3fea0c35, 0x3fe96480, 0x035c6682, 0x03820b93, 0x3fe75e98,
+	0x3fe6ad08, 0x038e97a9, 0x03b43b17, 0x3fe48990, 0x3fe3ce26, 0x03c0c69e, 0x03e66852, 0x3fe18d1f,
+	0x3fe0c7da, 0x03f2f342, 0x04189326, 0x3fde6945, 0x3fdd9a27, 0x04251d77, 0x044abb73, 0x3fdb1e06,
+	0x3fda450f, 0x0457451d, 0x047ce11a, 0x3fd7ab64, 0x3fd6c894, 0x04896a16, 0x04af03fc, 0x3fd4115f,
+	0x3fd324b7, 0x04bb8c42, 0x04e123fa, 0x3fd04ffc, 0x3fcf597c, 0x04edab83, 0x051340f6, 0x3fcc673b,
+	0x3fcb66e4, 0x051fc7b9, 0x05455ad1, 0x3fc8571f, 0x3fc74cf3, 0x0551e0c7, 0x0577716b, 0x3fc41fac,
+	0x3fc30baa, 0x0583f68c, 0x05a984a6, 0x3fbfc0e3, 0x3fbea30c, 0x05b608eb, 0x05db9463, 0x3fbb3ac7,
+	0x3fba131b, 0x05e817c3, 0x060da083, 0x3fb68d5b, 0x3fb55bdc, 0x061a22f7, 0x063fa8e7, 0x3fb1b8a2,
+	0x3fb07d50, 0x064c2a67, 0x0671ad71, 0x3facbc9f, 0x3fab777b, 0x067e2df5, 0x06a3ae00, 0x3fa79954,
+	0x3fa64a5f, 0x06b02d81, 0x06d5aa77, 0x3fa24ec6, 0x3fa0f600, 0x06e228ee, 0x0707a2b7, 0x3f9cdcf7,
+	0x3f9b7a62, 0x0714201b, 0x073996a1, 0x3f9743eb, 0x3f95d787, 0x074612eb, 0x076b8616, 0x3f9183a5,
+	0x3f900d72, 0x0778013d, 0x079d70f7, 0x3f8b9c28, 0x3f8a1c29, 0x07a9eaf5, 0x07cf5726, 0x3f858d79,
+	0x3f8403ae, 0x07dbcff2, 0x08013883, 0x3f7f579b, 0x3f7dc405, 0x080db016, 0x083314f1, 0x3f78fa92,
+	0x3f775d31, 0x083f8b43, 0x0864ec4f, 0x3f727661, 0x3f70cf38, 0x08716159, 0x0896be80, 0x3f6bcb0e,
+	0x3f6a1a1c, 0x08a3323a, 0x08c88b65, 0x3f64f89b, 0x3f633de2, 0x08d4fdc6, 0x08fa52de, 0x3f5dff0e,
+	0x3f5c3a8f, 0x0906c3e0, 0x092c14ce, 0x3f56de6a, 0x3f551026, 0x09388469, 0x095dd116, 0x3f4f96b4,
+	0x3f4dbeac, 0x096a3f42, 0x098f8796, 0x3f4827f0, 0x3f464626, 0x099bf44c, 0x09c13831, 0x3f409223,
+	0x3f3ea697, 0x09cda368, 0x09f2e2c7, 0x3f38d552, 0x3f36e006, 0x09ff4c78, 0x0a24873a, 0x3f30f181,
+	0x3f2ef276, 0x0a30ef5e, 0x0a56256c, 0x3f28e6b6, 0x3f26ddec, 0x0a628bfa, 0x0a87bd3d, 0x3f20b4f5,
+	0x3f1ea26e, 0x0a94222f, 0x0ab94e8f, 0x3f185c43, 0x3f164001, 0x0ac5b1dc, 0x0aead944, 0x3f0fdca5,
+	0x3f0db6a9, 0x0af73ae5, 0x0b1c5d3d, 0x3f073621, 0x3f05066d, 0x0b28bd2a, 0x0b4dda5c, 0x3efe68bc,
+	0x3efc2f50, 0x0b5a388d, 0x0b7f5081, 0x3ef5747b, 0x3ef3315a, 0x0b8bacf0, 0x0bb0bf8f, 0x3eec5965,
+	0x3eea0c8e, 0x0bbd1a33, 0x0be22766, 0x3ee3177e, 0x3ee0c0f4, 0x0bee8038, 0x0c1387e9, 0x3ed9aecc,
+	0x3ed74e91, 0x0c1fdee1, 0x0c44e0f9, 0x3ed01f55, 0x3ecdb56a, 0x0c513610, 0x0c763278, 0x3ec66920,
+	0x3ec3f585, 0x0c8285a5, 0x0ca77c47, 0x3ebc8c31, 0x3eba0ee9, 0x0cb3cd84, 0x0cd8be47, 0x3eb2888f,
+	0x3eb0019c, 0x0ce50d8c, 0x0d09f85b, 0x3ea85e41, 0x3ea5cda3, 0x0d1645a0, 0x0d3b2a64, 0x3e9e0d4c,
+	0x3e9b7306, 0x0d4775a1, 0x0d6c5443, 0x3e9395b7, 0x3e90f1ca, 0x0d789d71, 0x0d9d75db, 0x3e88f788,
+	0x3e8649f5, 0x0da9bcf2, 0x0dce8f0d, 0x3e7e32c6, 0x3e7b7b90, 0x0ddad406, 0x0dff9fba, 0x3e734778,
+	0x3e70869f, 0x0e0be28e, 0x0e30a7c5, 0x3e6835a4, 0x3e656b2b, 0x0e3ce86b, 0x0e61a70f, 0x3e5cfd51,
+	0x3e5a2939, 0x0e6de580, 0x0e929d7a, 0x3e519e86, 0x3e4ec0d1, 0x0e9ed9af, 0x0ec38ae8, 0x3e46194a,
+	0x3e4331fa, 0x0ecfc4d9, 0x0ef46f3b, 0x3e3a6da4, 0x3e377cbb, 0x0f00a6df, 0x0f254a53, 0x3e2e9b9c,
+	0x3e2ba11b, 0x0f317fa5, 0x0f561c15, 0x3e22a338, 0x3e1f9f21, 0x0f624f0c, 0x0f86e460, 0x3e168480,
+	0x3e1376d5, 0x0f9314f5, 0x0fb7a317, 0x3e0a3f7b, 0x3e07283f, 0x0fc3d143, 0x0fe8581d, 0x3dfdd432,
+	0x3dfab365, 0x0ff483d7, 0x10190352, 0x3df142ab, 0x3dee1851, 0x10252c94, 0x1049a49a, 0x3de48aef,
+	0x3de15708, 0x1055cb5b, 0x107a3bd5, 0x3dd7ad05, 0x3dd46f94, 0x1086600e, 0x10aac8e6, 0x3dcaa8f5,
+	0x3dc761fc, 0x10b6ea90, 0x10db4baf, 0x3dbd7ec7, 0x3dba2e48, 0x10e76ac3, 0x110bc413, 0x3db02e84,
+	0x3dacd481, 0x1117e088, 0x113c31f3, 0x3da2b834, 0x3d9f54af, 0x11484bc2, 0x116c9531, 0x3d951bde,
+	0x3d91aed9, 0x1178ac53, 0x119cedaf, 0x3d87598c, 0x3d83e309, 0x11a9021d, 0x11cd3b50, 0x3d797145,
+	0x3d75f147, 0x11d94d02, 0x11fd7df6, 0x3d6b6313, 0x3d67d99b, 0x12098ce5, 0x122db583, 0x3d5d2efe,
+	0x3d599c0e, 0x1239c1a7, 0x125de1da, 0x3d4ed50f, 0x3d4b38aa, 0x1269eb2b, 0x128e02dc, 0x3d40554e,
+	0x3d3caf76, 0x129a0954, 0x12be186c, 0x3d31afc5, 0x3d2e007c, 0x12ca1c03, 0x12ee226c, 0x3d22e47c,
+	0x3d1f2bc5, 0x12fa231b, 0x131e20c0, 0x3d13f37e, 0x3d10315a, 0x132a1e7e, 0x134e1348, 0x3d04dcd2,
+	0x3d011145, 0x135a0e0e, 0x137df9e7, 0x3cf5a082, 0x3cf1cb8e, 0x1389f1af, 0x13add481, 0x3ce63e98,
+	0x3ce2603f, 0x13b9c943, 0x13dda2f7, 0x3cd6b71e, 0x3cd2cf62, 0x13e994ab, 0x140d652c, 0x3cc70a1c,
+	0x3cc318ff, 0x141953cb, 0x143d1b02, 0x3cb7379c, 0x3cb33d22, 0x14490685, 0x146cc45c, 0x3ca73fa9,
+	0x3ca33bd3, 0x1478acbc, 0x149c611d, 0x3c97224c, 0x3c93151d, 0x14a84652, 0x14cbf127, 0x3c86df8e,
+	0x3c82c909, 0x14d7d32a, 0x14fb745e, 0x3c76777b, 0x3c7257a2, 0x15075327, 0x152aeaa3, 0x3c65ea1c,
+	0x3c61c0f1, 0x1536c62b, 0x155a53d9, 0x3c55377b, 0x3c510501, 0x15662c18, 0x1589afe3, 0x3c445fa2,
+	0x3c4023dd, 0x159584d3, 0x15b8fea4, 0x3c33629d, 0x3c2f1d8e, 0x15c4d03e, 0x15e83fff, 0x3c224075,
+	0x3c1df21f, 0x15f40e3a, 0x161773d6, 0x3c10f935, 0x3c0ca19b, 0x16233eac, 0x16469a0d, 0x3bff8ce8,
+	0x3bfb2c0c, 0x16526176, 0x1675b286, 0x3bedfb99, 0x3be9917e, 0x1681767c, 0x16a4bd25, 0x3bdc4552,
+	0x3bd7d1fa, 0x16b07d9f, 0x16d3b9cc, 0x3bca6a1d, 0x3bc5ed8d, 0x16df76c3, 0x1702a85e, 0x3bb86a08,
+	0x3bb3e440, 0x170e61cc, 0x173188be, 0x3ba6451b, 0x3ba1b620, 0x173d3e9b, 0x17605ad0, 0x3b93fb63,
+	0x3b8f6337, 0x176c0d15, 0x178f1e76, 0x3b818ceb, 0x3b7ceb90, 0x179acd1c, 0x17bdd394, 0x3b6ef9be,
+	0x3b6a4f38, 0x17c97e93, 0x17ec7a0d, 0x3b5c41e8, 0x3b578e39, 0x17f8215e, 0x181b11c4, 0x3b496574,
+	0x3b44a8a0, 0x1826b561, 0x18499a9d, 0x3b36646e, 0x3b319e77, 0x18553a7d, 0x1878147a, 0x3b233ee1,
+	0x3b1e6fca, 0x1883b097, 0x18a67f3f, 0x3b0ff4d9, 0x3b0b1ca6, 0x18b21791, 0x18d4dad0, 0x3afc8663,
+	0x3af7a516, 0x18e06f50, 0x1903270f, 0x3ae8f38b, 0x3ae40926, 0x190eb7b7, 0x193163e1, 0x3ad53c5b,
+	0x3ad048e3, 0x193cf0a9, 0x195f9128, 0x3ac160e1, 0x3abc6458, 0x196b1a09, 0x198daec8, 0x3aad6129,
+	0x3aa85b92, 0x199933bb, 0x19bbbca6, 0x3a993d3e, 0x3a942e9d, 0x19c73da3, 0x19e9baa3, 0x3a84f52f,
+	0x3a7fdd86, 0x19f537a4, 0x1a17a8a5, 0x3a708906, 0x3a6b6859, 0x1a2321a2, 0x1a45868e, 0x3a5bf8d1,
+	0x3a56cf23, 0x1a50fb81, 0x1a735442, 0x3a47449c, 0x3a4211f0, 0x1a7ec524, 0x1aa111a6, 0x3a326c74,
+	0x3a2d30cd, 0x1aac7e6f, 0x1acebe9d, 0x3a1d7066, 0x3a182bc8, 0x1ada2746, 0x1afc5b0a, 0x3a08507f,
+	0x3a0302ed, 0x1b07bf8c, 0x1b29e6d2, 0x39f30ccc, 0x39edb649, 0x1b354727, 0x1b5761d8, 0x39dda55a,
+	0x39d845e9, 0x1b62bdf8, 0x1b84cc01, 0x39c81a36, 0x39c2b1da, 0x1b9023e5, 0x1bb22530, 0x39b26b6d,
+	0x39acfa2b, 0x1bbd78d2, 0x1bdf6d4a, 0x399c990d, 0x39971ee7, 0x1beabca1, 0x1c0ca432, 0x3986a324,
+	0x3981201e, 0x1c17ef39, 0x1c39c9cd, 0x397089bf, 0x396afddc, 0x1c45107c, 0x1c66ddfe, 0x395a4ceb,
+	0x3954b82e, 0x1c72204f, 0x1c93e0ab, 0x3943ecb6, 0x393e4f23, 0x1c9f1e96, 0x1cc0d1b6, 0x392d692f,
+	0x3927c2c9, 0x1ccc0b35, 0x1cedb106, 0x3916c262, 0x3911132d, 0x1cf8e611, 0x1d1a7e7d, 0x38fff85e,
+	0x38fa405e, 0x1d25af0d, 0x1d473a00, 0x38e90b31, 0x38e34a69, 0x1d52660f, 0x1d73e374, 0x38d1fae9,
+	0x38cc315d, 0x1d7f0afb, 0x1da07abc, 0x38bac795, 0x38b4f547, 0x1dab9db5, 0x1dccffbf, 0x38a37142,
+	0x389d9637, 0x1dd81e21, 0x1df9725f, 0x388bf7ff, 0x3886143b, 0x1e048c24, 0x1e25d282, 0x38745bdb,
+	0x386e6f60, 0x1e30e7a4, 0x1e52200c, 0x385c9ce3, 0x3856a7b6, 0x1e5d3084, 0x1e7e5ae2, 0x3844bb28,
+	0x383ebd4c, 0x1e8966a8, 0x1eaa82e9, 0x382cb6b7, 0x3826b030, 0x1eb589f7, 0x1ed69805, 0x38148f9f,
+	0x380e8071, 0x1ee19a54, 0x1f029a1c, 0x37fc45ef, 0x37f62e1d, 0x1f0d97a5, 0x1f2e8911, 0x37e3d9b7,
+	0x37ddb945, 0x1f3981ce, 0x1f5a64cb, 0x37cb4b04, 0x37c521f6, 0x1f6558b5, 0x1f862d2d, 0x37b299e7,
+	0x37ac6841, 0x1f911c3d, 0x1fb1e21d, 0x3799c66f, 0x37938c34, 0x1fbccc4d, 0x1fdd8381, 0x3780d0aa,
+	0x377a8ddf, 0x1fe868c8, 0x2009113c, 0x3767b8a9, 0x37616d51, 0x2013f196, 0x20348b35, 0x374e7e7b,
+	0x37482a9a, 0x203f6699, 0x205ff14f, 0x3735222f, 0x372ec5c9, 0x206ac7b8, 0x208b4372, 0x371ba3d4,
+	0x37153eee, 0x209614d9, 0x20b68181, 0x3702037c, 0x36fb9618, 0x20c14ddf, 0x20e1ab63, 0x36e84135,
+	0x36e1cb58, 0x20ec72b1, 0x210cc0fc, 0x36ce5d10, 0x36c7debd, 0x21178334, 0x2137c232, 0x36b4571b,
+	0x36add058, 0x21427f4d, 0x2162aeea, 0x369a2f69, 0x3693a038, 0x216d66e2, 0x218d870b, 0x367fe608,
+	0x36794e6e, 0x219839d8, 0x21b84a79, 0x36657b08, 0x365edb09, 0x21c2f815, 0x21e2f91a, 0x364aee7b,
+	0x3644461b, 0x21eda17f, 0x220d92d4, 0x36304070, 0x36298fb4, 0x221835fb, 0x2238178d, 0x361570f8,
+	0x360eb7e3, 0x2242b56f, 0x22628729, 0x35fa8023, 0x35f3beba, 0x226d1fc1, 0x228ce191, 0x35df6e03,
+	0x35d8a449, 0x229774d7, 0x22b726a8, 0x35c43aa7, 0x35bd68a1, 0x22c1b496, 0x22e15655, 0x35a8e621,
+	0x35a20bd3, 0x22ebdee5, 0x230b707e, 0x358d7081, 0x35868def, 0x2315f3a8, 0x23357509, 0x3571d9d9,
+	0x356aef08, 0x233ff2c8, 0x235f63dc, 0x35562239, 0x354f2f2c, 0x2369dc29, 0x23893cdd, 0x353a49b2,
+	0x35334e6f, 0x2393afb2, 0x23b2fff3, 0x351e5056, 0x35174ce0, 0x23bd6d48, 0x23dcad03, 0x35023636,
+	0x34fb2a92, 0x23e714d3, 0x240643f4, 0x34e5fb63, 0x34dee795, 0x2410a639, 0x242fc4ad, 0x34c99fef,
+	0x34c283fb, 0x243a215f, 0x24592f13, 0x34ad23eb, 0x34a5ffd5, 0x2463862c, 0x2482830d, 0x34908768,
+	0x34895b36, 0x248cd487, 0x24abc082, 0x3473ca79, 0x346c962f, 0x24b60c57, 0x24d4e757, 0x3456ed2f,
+	0x344fb0d1, 0x24df2d81, 0x24fdf775, 0x3439ef9c, 0x3432ab2e, 0x250837ed, 0x2526f0c1, 0x341cd1d2,
+	0x34158559, 0x25312b81, 0x254fd323, 0x33ff93e2, 0x33f83f62, 0x255a0823, 0x25789e80, 0x33e235df,
+	0x33dad95e, 0x2582cdbc, 0x25a152c0, 0x33c4b7db, 0x33bd535c, 0x25ab7c30, 0x25c9efca, 0x33a719e8,
+	0x339fad70, 0x25d41369, 0x25f27584, 0x33895c18, 0x3381e7ac, 0x25fc934b, 0x261ae3d6, 0x336b7e7e,
+	0x33640223, 0x2624fbbf, 0x26433aa7, 0x334d812d, 0x3345fce6, 0x264d4cac, 0x266b79dd, 0x332f6435,
+	0x3327d808, 0x267585f8, 0x2693a161, 0x331127ab, 0x3309939c, 0x269da78b, 0x26bbb119, 0x32f2cba1,
+	0x32eb2fb5, 0x26c5b14c, 0x26e3a8ec, 0x32d45029, 0x32ccac64, 0x26eda322, 0x270b88c2, 0x32b5b557,
+	0x32ae09be, 0x27157cf5, 0x27335082, 0x3296fb3d, 0x328f47d5, 0x273d3eac, 0x275b0014, 0x327821ee,
+	0x327066bc, 0x2764e82f, 0x27829760, 0x3259297d, 0x32516686, 0x278c7965, 0x27aa164c, 0x323a11fe,
+	0x32324746, 0x27b3f235, 0x27d17cc1, 0x321adb83, 0x3213090f, 0x27db5288, 0x27f8caa5, 0x31fb8620,
+	0x31f3abf5, 0x28029a45, 0x281fffe2, 0x31dc11e8, 0x31d4300b, 0x2829c954, 0x28471c5e, 0x31bc7eee,
+	0x31b49564, 0x2850df9d, 0x286e2002, 0x319ccd46, 0x3194dc14, 0x2877dd07, 0x28950ab6, 0x317cfd04,
+	0x3175042e, 0x289ec17a, 0x28bbdc61, 0x315d0e3b, 0x31550dc6, 0x28c58cdf, 0x28e294eb, 0x313d00ff,
+	0x3134f8f1, 0x28ec3f1e, 0x2909343e, 0x311cd564, 0x3114c5c0, 0x2912d81f, 0x292fba40, 0x30fc8b7d,
+	0x30f47449, 0x293957c9, 0x295626da, 0x30dc235e, 0x30d404a0, 0x295fbe06, 0x297c79f5, 0x30bb9d1c,
+	0x30b376d8, 0x29860abd, 0x29a2b378, 0x309af8ca, 0x3092cb05, 0x29ac3dd7, 0x29c8d34d, 0x307a367c,
+	0x3072013c, 0x29d2573c, 0x29eed95b, 0x30595648, 0x30511991, 0x29f856d5, 0x2a14c58b, 0x30385840,
+	0x30301418, 0x2a1e3c8a, 0x2a3a97c7, 0x30173c7a, 0x300ef0e5, 0x2a440844, 0x2a604ff5, 0x2ff6030a,
+	0x2fedb00d, 0x2a69b9ec, 0x2a85ee00, 0x2fd4ac04, 0x2fcc51a5, 0x2a8f516b, 0x2aab71d0, 0x2fb3377c,
+	0x2faad5c1, 0x2ab4cea9, 0x2ad0db4e, 0x2f91a589, 0x2f893c75, 0x2ada318e, 0x2af62a63, 0x2f6ff63d,
+	0x2f6785d7, 0x2aff7a05, 0x2b1b5ef8, 0x2f4e29af, 0x2f45b1fb, 0x2b24a7f6, 0x2b4078f5, 0x2f2c3ff2,
+	0x2f23c0f6, 0x2b49bb4a, 0x2b657844, 0x2f0a391d, 0x2f01b2de, 0x2b6eb3ea, 0x2b8a5cce, 0x2ee81543,
+	0x2edf87c6, 0x2b9391c0, 0x2baf267d, 0x2ec5d479, 0x2ebd3fc4, 0x2bb854b4, 0x2bd3d53a, 0x2ea376d6,
+	0x2e9adaee, 0x2bdcfcb0, 0x2bf868ed, 0x2e80fc6e, 0x2e785958, 0x2c01899e, 0x2c1ce181, 0x2e5e6556,
+	0x2e55bb17, 0x2c25fb66, 0x2c413edf, 0x2e3bb1a4, 0x2e330042, 0x2c4a51f3, 0x2c6580f1, 0x2e18e16d,
+	0x2e1028ed, 0x2c6e8d2e, 0x2c89a79f, 0x2df5f4c7, 0x2ded352f, 0x2c92ad01, 0x2cadb2d5, 0x2dd2ebc7,
+	0x2dca251c, 0x2cb6b155, 0x2cd1a27b, 0x2dafc683, 0x2da6f8ca, 0x2cda9a14, 0x2cf5767c, 0x2d8c8510,
 	0x2d83b04f, 0x2cfe6728, 0x2d192ec1, 0x2d692784, 0x2d604bc0, 0x2d22187a, 0x2d3ccb34, 0x2d45adf6
 };
 
 
 const int twidTab512[(8*6 + 32*6 + 128*6)/2] = {
-	0x40000000, 0x40000000, 0x40000000, 0x3b20187d, 
-	0x3ec50c7c, 0x3536238e, 0x2d412d41, 0x3b20187d, 
-	0x187d3b20, 0x187d3b20, 0x3536238e, 0xf3843ec5, 
-	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xe7833b20, 
-	0x238e3536, 0xc13b0c7c, 0xd2bf2d41, 0x187d3b20, 
-	0xc4e0e783, 0xc4e0187d, 0x0c7c3ec5, 0xdc72caca, 
+	0x40000000, 0x40000000, 0x40000000, 0x3b20187d,
+	0x3ec50c7c, 0x3536238e, 0x2d412d41, 0x3b20187d,
+	0x187d3b20, 0x187d3b20, 0x3536238e, 0xf3843ec5,
+	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xe7833b20,
+	0x238e3536, 0xc13b0c7c, 0xd2bf2d41, 0x187d3b20,
+	0xc4e0e783, 0xc4e0187d, 0x0c7c3ec5, 0xdc72caca,
 
-	0x40000000, 0x40000000, 0x40000000, 0x3fb10645, 
-	0x3fec0323, 0x3f4e0964, 0x3ec50c7c, 0x3fb10645, 
-	0x3d3e1294, 0x3d3e1294, 0x3f4e0964, 0x39da1b5d, 
-	0x3b20187d, 0x3ec50c7c, 0x3536238e, 0x38711e2b, 
-	0x3e140f8c, 0x2f6b2afa, 0x3536238e, 0x3d3e1294, 
-	0x28993179, 0x31792899, 0x3c42158f, 0x20e736e5, 
-	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x28993179, 
-	0x39da1b5d, 0x0f8c3e14, 0x238e3536, 0x38711e2b, 
-	0x06453fb1, 0x1e2b3871, 0x36e520e7, 0xfcdd3fec, 
-	0x187d3b20, 0x3536238e, 0xf3843ec5, 0x12943d3e, 
-	0x3367261f, 0xea713c42, 0x0c7c3ec5, 0x31792899, 
-	0xe1d53871, 0x06453fb1, 0x2f6b2afa, 0xd9e13367, 
-	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xf9bb3fb1, 
-	0x2afa2f6b, 0xcc99261f, 0xf3843ec5, 0x28993179, 
-	0xc78f1e2b, 0xed6c3d3e, 0x261f3367, 0xc3be158f, 
-	0xe7833b20, 0x238e3536, 0xc13b0c7c, 0xe1d53871, 
-	0x20e736e5, 0xc0140323, 0xdc723536, 0x1e2b3871, 
-	0xc04ff9bb, 0xd7673179, 0x1b5d39da, 0xc1ecf074, 
-	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xce872899, 
-	0x158f3c42, 0xc91bdf19, 0xcaca238e, 0x12943d3e, 
-	0xce87d767, 0xc78f1e2b, 0x0f8c3e14, 0xd506d095, 
-	0xc4e0187d, 0x0c7c3ec5, 0xdc72caca, 0xc2c21294, 
-	0x09643f4e, 0xe4a3c626, 0xc13b0c7c, 0x06453fb1, 
-	0xed6cc2c2, 0xc04f0645, 0x03233fec, 0xf69cc0b2, 
+	0x40000000, 0x40000000, 0x40000000, 0x3fb10645,
+	0x3fec0323, 0x3f4e0964, 0x3ec50c7c, 0x3fb10645,
+	0x3d3e1294, 0x3d3e1294, 0x3f4e0964, 0x39da1b5d,
+	0x3b20187d, 0x3ec50c7c, 0x3536238e, 0x38711e2b,
+	0x3e140f8c, 0x2f6b2afa, 0x3536238e, 0x3d3e1294,
+	0x28993179, 0x31792899, 0x3c42158f, 0x20e736e5,
+	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x28993179,
+	0x39da1b5d, 0x0f8c3e14, 0x238e3536, 0x38711e2b,
+	0x06453fb1, 0x1e2b3871, 0x36e520e7, 0xfcdd3fec,
+	0x187d3b20, 0x3536238e, 0xf3843ec5, 0x12943d3e,
+	0x3367261f, 0xea713c42, 0x0c7c3ec5, 0x31792899,
+	0xe1d53871, 0x06453fb1, 0x2f6b2afa, 0xd9e13367,
+	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xf9bb3fb1,
+	0x2afa2f6b, 0xcc99261f, 0xf3843ec5, 0x28993179,
+	0xc78f1e2b, 0xed6c3d3e, 0x261f3367, 0xc3be158f,
+	0xe7833b20, 0x238e3536, 0xc13b0c7c, 0xe1d53871,
+	0x20e736e5, 0xc0140323, 0xdc723536, 0x1e2b3871,
+	0xc04ff9bb, 0xd7673179, 0x1b5d39da, 0xc1ecf074,
+	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xce872899,
+	0x158f3c42, 0xc91bdf19, 0xcaca238e, 0x12943d3e,
+	0xce87d767, 0xc78f1e2b, 0x0f8c3e14, 0xd506d095,
+	0xc4e0187d, 0x0c7c3ec5, 0xdc72caca, 0xc2c21294,
+	0x09643f4e, 0xe4a3c626, 0xc13b0c7c, 0x06453fb1,
+	0xed6cc2c2, 0xc04f0645, 0x03233fec, 0xf69cc0b2,
 
-	0x40000000, 0x40000000, 0x40000000, 0x3ffb0192, 
-	0x3ffe00c9, 0x3ff4025b, 0x3fec0323, 0x3ffb0192, 
-	0x3fd304b5, 0x3fd304b5, 0x3ff4025b, 0x3f9c070d, 
-	0x3fb10645, 0x3fec0323, 0x3f4e0964, 0x3f8407d5, 
-	0x3fe103ec, 0x3eeb0bb6, 0x3f4e0964, 0x3fd304b5, 
-	0x3e710e05, 0x3f0e0af1, 0x3fc3057d, 0x3de2104f, 
-	0x3ec50c7c, 0x3fb10645, 0x3d3e1294, 0x3e710e05, 
-	0x3f9c070d, 0x3c8414d1, 0x3e140f8c, 0x3f8407d5, 
-	0x3bb61708, 0x3dae1111, 0x3f6a089c, 0x3ad21937, 
-	0x3d3e1294, 0x3f4e0964, 0x39da1b5d, 0x3cc51413, 
-	0x3f2f0a2a, 0x38cf1d79, 0x3c42158f, 0x3f0e0af1, 
-	0x37af1f8b, 0x3bb61708, 0x3eeb0bb6, 0x367c2192, 
-	0x3b20187d, 0x3ec50c7c, 0x3536238e, 0x3a8219ef, 
-	0x3e9c0d41, 0x33de257d, 0x39da1b5d, 0x3e710e05, 
-	0x3274275f, 0x392a1cc6, 0x3e440ec9, 0x30f82934, 
-	0x38711e2b, 0x3e140f8c, 0x2f6b2afa, 0x37af1f8b, 
-	0x3de2104f, 0x2dce2cb2, 0x36e520e7, 0x3dae1111, 
-	0x2c212e5a, 0x3612223d, 0x3d7711d3, 0x2a652ff1, 
-	0x3536238e, 0x3d3e1294, 0x28993179, 0x345324da, 
-	0x3d021354, 0x26c032ee, 0x3367261f, 0x3cc51413, 
-	0x24da3453, 0x3274275f, 0x3c8414d1, 0x22e635a5, 
-	0x31792899, 0x3c42158f, 0x20e736e5, 0x307629cd, 
-	0x3bfd164c, 0x1edc3811, 0x2f6b2afa, 0x3bb61708, 
-	0x1cc6392a, 0x2e5a2c21, 0x3b6c17c3, 0x1aa63a2f, 
-	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x2c212e5a, 
-	0x3ad21937, 0x164c3bfd, 0x2afa2f6b, 0x3a8219ef, 
-	0x14133cc5, 0x29cd3076, 0x3a2f1aa6, 0x11d33d77, 
-	0x28993179, 0x39da1b5d, 0x0f8c3e14, 0x275f3274, 
-	0x39831c12, 0x0d413e9c, 0x261f3367, 0x392a1cc6, 
-	0x0af13f0e, 0x24da3453, 0x38cf1d79, 0x089c3f6a, 
-	0x238e3536, 0x38711e2b, 0x06453fb1, 0x223d3612, 
-	0x38111edc, 0x03ec3fe1, 0x20e736e5, 0x37af1f8b, 
-	0x01923ffb, 0x1f8b37af, 0x374b2039, 0xff373ffe, 
-	0x1e2b3871, 0x36e520e7, 0xfcdd3fec, 0x1cc6392a, 
-	0x367c2192, 0xfa833fc3, 0x1b5d39da, 0x3612223d, 
-	0xf82b3f84, 0x19ef3a82, 0x35a522e6, 0xf5d63f2f, 
-	0x187d3b20, 0x3536238e, 0xf3843ec5, 0x17083bb6, 
-	0x34c62434, 0xf1373e44, 0x158f3c42, 0x345324da, 
-	0xeeef3dae, 0x14133cc5, 0x33de257d, 0xecac3d02, 
-	0x12943d3e, 0x3367261f, 0xea713c42, 0x11113dae, 
-	0x32ee26c0, 0xe83d3b6c, 0x0f8c3e14, 0x3274275f, 
-	0xe6113a82, 0x0e053e71, 0x31f727fd, 0xe3ee3983, 
-	0x0c7c3ec5, 0x31792899, 0xe1d53871, 0x0af13f0e, 
-	0x30f82934, 0xdfc7374b, 0x09643f4e, 0x307629cd, 
-	0xddc33612, 0x07d53f84, 0x2ff12a65, 0xdbcc34c6, 
-	0x06453fb1, 0x2f6b2afa, 0xd9e13367, 0x04b53fd3, 
-	0x2ee32b8e, 0xd80331f7, 0x03233fec, 0x2e5a2c21, 
-	0xd6333076, 0x01923ffb, 0x2dce2cb2, 0xd4722ee3, 
-	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xfe6e3ffb, 
-	0x2cb22dce, 0xd11d2b8e, 0xfcdd3fec, 0x2c212e5a, 
-	0xcf8a29cd, 0xfb4b3fd3, 0x2b8e2ee3, 0xce0927fd, 
-	0xf9bb3fb1, 0x2afa2f6b, 0xcc99261f, 0xf82b3f84, 
-	0x2a652ff1, 0xcb3a2434, 0xf69c3f4e, 0x29cd3076, 
-	0xc9ee223d, 0xf50f3f0e, 0x293430f8, 0xc8b52039, 
-	0xf3843ec5, 0x28993179, 0xc78f1e2b, 0xf1fb3e71, 
-	0x27fd31f7, 0xc67d1c12, 0xf0743e14, 0x275f3274, 
-	0xc57e19ef, 0xeeef3dae, 0x26c032ee, 0xc49417c3, 
-	0xed6c3d3e, 0x261f3367, 0xc3be158f, 0xebed3cc5, 
-	0x257d33de, 0xc2fe1354, 0xea713c42, 0x24da3453, 
-	0xc2521111, 0xe8f83bb6, 0x243434c6, 0xc1bc0ec9, 
-	0xe7833b20, 0x238e3536, 0xc13b0c7c, 0xe6113a82, 
-	0x22e635a5, 0xc0d10a2a, 0xe4a339da, 0x223d3612, 
-	0xc07c07d5, 0xe33a392a, 0x2192367c, 0xc03d057d, 
-	0xe1d53871, 0x20e736e5, 0xc0140323, 0xe07537af, 
-	0x2039374b, 0xc00200c9, 0xdf1936e5, 0x1f8b37af, 
-	0xc005fe6e, 0xddc33612, 0x1edc3811, 0xc01ffc14, 
-	0xdc723536, 0x1e2b3871, 0xc04ff9bb, 0xdb263453, 
-	0x1d7938cf, 0xc096f764, 0xd9e13367, 0x1cc6392a, 
-	0xc0f2f50f, 0xd8a13274, 0x1c123983, 0xc164f2bf, 
-	0xd7673179, 0x1b5d39da, 0xc1ecf074, 0xd6333076, 
-	0x1aa63a2f, 0xc289ee2d, 0xd5062f6b, 0x19ef3a82, 
-	0xc33bebed, 0xd3df2e5a, 0x19373ad2, 0xc403e9b4, 
-	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xd1a62c21, 
-	0x17c33b6c, 0xc5d1e55a, 0xd0952afa, 0x17083bb6, 
-	0xc6d6e33a, 0xcf8a29cd, 0x164c3bfd, 0xc7efe124, 
-	0xce872899, 0x158f3c42, 0xc91bdf19, 0xcd8c275f, 
-	0x14d13c84, 0xca5bdd1a, 0xcc99261f, 0x14133cc5, 
-	0xcbaddb26, 0xcbad24da, 0x13543d02, 0xcd12d940, 
-	0xcaca238e, 0x12943d3e, 0xce87d767, 0xc9ee223d, 
-	0x11d33d77, 0xd00fd59b, 0xc91b20e7, 0x11113dae, 
-	0xd1a6d3df, 0xc8511f8b, 0x104f3de2, 0xd34ed232, 
-	0xc78f1e2b, 0x0f8c3e14, 0xd506d095, 0xc6d61cc6, 
-	0x0ec93e44, 0xd6cccf08, 0xc6261b5d, 0x0e053e71, 
-	0xd8a1cd8c, 0xc57e19ef, 0x0d413e9c, 0xda83cc22, 
-	0xc4e0187d, 0x0c7c3ec5, 0xdc72caca, 0xc44a1708, 
-	0x0bb63eeb, 0xde6ec984, 0xc3be158f, 0x0af13f0e, 
-	0xe075c851, 0xc33b1413, 0x0a2a3f2f, 0xe287c731, 
-	0xc2c21294, 0x09643f4e, 0xe4a3c626, 0xc2521111, 
-	0x089c3f6a, 0xe6c9c52e, 0xc1ec0f8c, 0x07d53f84, 
-	0xe8f8c44a, 0xc18f0e05, 0x070d3f9c, 0xeb2fc37c, 
-	0xc13b0c7c, 0x06453fb1, 0xed6cc2c2, 0xc0f20af1, 
-	0x057d3fc3, 0xefb1c21e, 0xc0b20964, 0x04b53fd3, 
-	0xf1fbc18f, 0xc07c07d5, 0x03ec3fe1, 0xf44ac115, 
-	0xc04f0645, 0x03233fec, 0xf69cc0b2, 0xc02d04b5, 
-	0x025b3ff4, 0xf8f3c064, 0xc0140323, 0x01923ffb, 
-	0xfb4bc02d, 0xc0050192, 0x00c93ffe, 0xfda5c00c	
+	0x40000000, 0x40000000, 0x40000000, 0x3ffb0192,
+	0x3ffe00c9, 0x3ff4025b, 0x3fec0323, 0x3ffb0192,
+	0x3fd304b5, 0x3fd304b5, 0x3ff4025b, 0x3f9c070d,
+	0x3fb10645, 0x3fec0323, 0x3f4e0964, 0x3f8407d5,
+	0x3fe103ec, 0x3eeb0bb6, 0x3f4e0964, 0x3fd304b5,
+	0x3e710e05, 0x3f0e0af1, 0x3fc3057d, 0x3de2104f,
+	0x3ec50c7c, 0x3fb10645, 0x3d3e1294, 0x3e710e05,
+	0x3f9c070d, 0x3c8414d1, 0x3e140f8c, 0x3f8407d5,
+	0x3bb61708, 0x3dae1111, 0x3f6a089c, 0x3ad21937,
+	0x3d3e1294, 0x3f4e0964, 0x39da1b5d, 0x3cc51413,
+	0x3f2f0a2a, 0x38cf1d79, 0x3c42158f, 0x3f0e0af1,
+	0x37af1f8b, 0x3bb61708, 0x3eeb0bb6, 0x367c2192,
+	0x3b20187d, 0x3ec50c7c, 0x3536238e, 0x3a8219ef,
+	0x3e9c0d41, 0x33de257d, 0x39da1b5d, 0x3e710e05,
+	0x3274275f, 0x392a1cc6, 0x3e440ec9, 0x30f82934,
+	0x38711e2b, 0x3e140f8c, 0x2f6b2afa, 0x37af1f8b,
+	0x3de2104f, 0x2dce2cb2, 0x36e520e7, 0x3dae1111,
+	0x2c212e5a, 0x3612223d, 0x3d7711d3, 0x2a652ff1,
+	0x3536238e, 0x3d3e1294, 0x28993179, 0x345324da,
+	0x3d021354, 0x26c032ee, 0x3367261f, 0x3cc51413,
+	0x24da3453, 0x3274275f, 0x3c8414d1, 0x22e635a5,
+	0x31792899, 0x3c42158f, 0x20e736e5, 0x307629cd,
+	0x3bfd164c, 0x1edc3811, 0x2f6b2afa, 0x3bb61708,
+	0x1cc6392a, 0x2e5a2c21, 0x3b6c17c3, 0x1aa63a2f,
+	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x2c212e5a,
+	0x3ad21937, 0x164c3bfd, 0x2afa2f6b, 0x3a8219ef,
+	0x14133cc5, 0x29cd3076, 0x3a2f1aa6, 0x11d33d77,
+	0x28993179, 0x39da1b5d, 0x0f8c3e14, 0x275f3274,
+	0x39831c12, 0x0d413e9c, 0x261f3367, 0x392a1cc6,
+	0x0af13f0e, 0x24da3453, 0x38cf1d79, 0x089c3f6a,
+	0x238e3536, 0x38711e2b, 0x06453fb1, 0x223d3612,
+	0x38111edc, 0x03ec3fe1, 0x20e736e5, 0x37af1f8b,
+	0x01923ffb, 0x1f8b37af, 0x374b2039, 0xff373ffe,
+	0x1e2b3871, 0x36e520e7, 0xfcdd3fec, 0x1cc6392a,
+	0x367c2192, 0xfa833fc3, 0x1b5d39da, 0x3612223d,
+	0xf82b3f84, 0x19ef3a82, 0x35a522e6, 0xf5d63f2f,
+	0x187d3b20, 0x3536238e, 0xf3843ec5, 0x17083bb6,
+	0x34c62434, 0xf1373e44, 0x158f3c42, 0x345324da,
+	0xeeef3dae, 0x14133cc5, 0x33de257d, 0xecac3d02,
+	0x12943d3e, 0x3367261f, 0xea713c42, 0x11113dae,
+	0x32ee26c0, 0xe83d3b6c, 0x0f8c3e14, 0x3274275f,
+	0xe6113a82, 0x0e053e71, 0x31f727fd, 0xe3ee3983,
+	0x0c7c3ec5, 0x31792899, 0xe1d53871, 0x0af13f0e,
+	0x30f82934, 0xdfc7374b, 0x09643f4e, 0x307629cd,
+	0xddc33612, 0x07d53f84, 0x2ff12a65, 0xdbcc34c6,
+	0x06453fb1, 0x2f6b2afa, 0xd9e13367, 0x04b53fd3,
+	0x2ee32b8e, 0xd80331f7, 0x03233fec, 0x2e5a2c21,
+	0xd6333076, 0x01923ffb, 0x2dce2cb2, 0xd4722ee3,
+	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xfe6e3ffb,
+	0x2cb22dce, 0xd11d2b8e, 0xfcdd3fec, 0x2c212e5a,
+	0xcf8a29cd, 0xfb4b3fd3, 0x2b8e2ee3, 0xce0927fd,
+	0xf9bb3fb1, 0x2afa2f6b, 0xcc99261f, 0xf82b3f84,
+	0x2a652ff1, 0xcb3a2434, 0xf69c3f4e, 0x29cd3076,
+	0xc9ee223d, 0xf50f3f0e, 0x293430f8, 0xc8b52039,
+	0xf3843ec5, 0x28993179, 0xc78f1e2b, 0xf1fb3e71,
+	0x27fd31f7, 0xc67d1c12, 0xf0743e14, 0x275f3274,
+	0xc57e19ef, 0xeeef3dae, 0x26c032ee, 0xc49417c3,
+	0xed6c3d3e, 0x261f3367, 0xc3be158f, 0xebed3cc5,
+	0x257d33de, 0xc2fe1354, 0xea713c42, 0x24da3453,
+	0xc2521111, 0xe8f83bb6, 0x243434c6, 0xc1bc0ec9,
+	0xe7833b20, 0x238e3536, 0xc13b0c7c, 0xe6113a82,
+	0x22e635a5, 0xc0d10a2a, 0xe4a339da, 0x223d3612,
+	0xc07c07d5, 0xe33a392a, 0x2192367c, 0xc03d057d,
+	0xe1d53871, 0x20e736e5, 0xc0140323, 0xe07537af,
+	0x2039374b, 0xc00200c9, 0xdf1936e5, 0x1f8b37af,
+	0xc005fe6e, 0xddc33612, 0x1edc3811, 0xc01ffc14,
+	0xdc723536, 0x1e2b3871, 0xc04ff9bb, 0xdb263453,
+	0x1d7938cf, 0xc096f764, 0xd9e13367, 0x1cc6392a,
+	0xc0f2f50f, 0xd8a13274, 0x1c123983, 0xc164f2bf,
+	0xd7673179, 0x1b5d39da, 0xc1ecf074, 0xd6333076,
+	0x1aa63a2f, 0xc289ee2d, 0xd5062f6b, 0x19ef3a82,
+	0xc33bebed, 0xd3df2e5a, 0x19373ad2, 0xc403e9b4,
+	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xd1a62c21,
+	0x17c33b6c, 0xc5d1e55a, 0xd0952afa, 0x17083bb6,
+	0xc6d6e33a, 0xcf8a29cd, 0x164c3bfd, 0xc7efe124,
+	0xce872899, 0x158f3c42, 0xc91bdf19, 0xcd8c275f,
+	0x14d13c84, 0xca5bdd1a, 0xcc99261f, 0x14133cc5,
+	0xcbaddb26, 0xcbad24da, 0x13543d02, 0xcd12d940,
+	0xcaca238e, 0x12943d3e, 0xce87d767, 0xc9ee223d,
+	0x11d33d77, 0xd00fd59b, 0xc91b20e7, 0x11113dae,
+	0xd1a6d3df, 0xc8511f8b, 0x104f3de2, 0xd34ed232,
+	0xc78f1e2b, 0x0f8c3e14, 0xd506d095, 0xc6d61cc6,
+	0x0ec93e44, 0xd6cccf08, 0xc6261b5d, 0x0e053e71,
+	0xd8a1cd8c, 0xc57e19ef, 0x0d413e9c, 0xda83cc22,
+	0xc4e0187d, 0x0c7c3ec5, 0xdc72caca, 0xc44a1708,
+	0x0bb63eeb, 0xde6ec984, 0xc3be158f, 0x0af13f0e,
+	0xe075c851, 0xc33b1413, 0x0a2a3f2f, 0xe287c731,
+	0xc2c21294, 0x09643f4e, 0xe4a3c626, 0xc2521111,
+	0x089c3f6a, 0xe6c9c52e, 0xc1ec0f8c, 0x07d53f84,
+	0xe8f8c44a, 0xc18f0e05, 0x070d3f9c, 0xeb2fc37c,
+	0xc13b0c7c, 0x06453fb1, 0xed6cc2c2, 0xc0f20af1,
+	0x057d3fc3, 0xefb1c21e, 0xc0b20964, 0x04b53fd3,
+	0xf1fbc18f, 0xc07c07d5, 0x03ec3fe1, 0xf44ac115,
+	0xc04f0645, 0x03233fec, 0xf69cc0b2, 0xc02d04b5,
+	0x025b3ff4, 0xf8f3c064, 0xc0140323, 0x01923ffb,
+	0xfb4bc02d, 0xc0050192, 0x00c93ffe, 0xfda5c00c
 };
 
 const int twidTab64[(4*6 + 16*6)/2] = {
-	0x40000000, 0x40000000, 0x40000000, 0x2d412d41, 
-	0x3b20187d, 0x187d3b20, 0x00004000, 0x2d412d41, 
-	0xd2bf2d41, 0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 
+	0x40000000, 0x40000000, 0x40000000, 0x2d412d41,
+	0x3b20187d, 0x187d3b20, 0x00004000, 0x2d412d41,
+	0xd2bf2d41, 0xd2bf2d41, 0x187d3b20, 0xc4e0e783,
 
-	0x40000000, 0x40000000, 0x40000000, 0x3ec50c7c, 
-	0x3fb10645, 0x3d3e1294, 0x3b20187d, 0x3ec50c7c, 
-	0x3536238e, 0x3536238e, 0x3d3e1294, 0x28993179, 
-	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x238e3536, 
-	0x38711e2b, 0x06453fb1, 0x187d3b20, 0x3536238e, 
-	0xf3843ec5, 0x0c7c3ec5, 0x31792899, 0xe1d53871, 
-	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xf3843ec5, 
-	0x28993179, 0xc78f1e2b, 0xe7833b20, 0x238e3536, 
-	0xc13b0c7c, 0xdc723536, 0x1e2b3871, 0xc04ff9bb, 
-	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xcaca238e, 
-	0x12943d3e, 0xce87d767, 0xc4e0187d, 0x0c7c3ec5, 
-	0xdc72caca, 0xc13b0c7c, 0x06453fb1, 0xed6cc2c2 
+	0x40000000, 0x40000000, 0x40000000, 0x3ec50c7c,
+	0x3fb10645, 0x3d3e1294, 0x3b20187d, 0x3ec50c7c,
+	0x3536238e, 0x3536238e, 0x3d3e1294, 0x28993179,
+	0x2d412d41, 0x3b20187d, 0x187d3b20, 0x238e3536,
+	0x38711e2b, 0x06453fb1, 0x187d3b20, 0x3536238e,
+	0xf3843ec5, 0x0c7c3ec5, 0x31792899, 0xe1d53871,
+	0x00004000, 0x2d412d41, 0xd2bf2d41, 0xf3843ec5,
+	0x28993179, 0xc78f1e2b, 0xe7833b20, 0x238e3536,
+	0xc13b0c7c, 0xdc723536, 0x1e2b3871, 0xc04ff9bb,
+	0xd2bf2d41, 0x187d3b20, 0xc4e0e783, 0xcaca238e,
+	0x12943d3e, 0xce87d767, 0xc4e0187d, 0x0c7c3ec5,
+	0xdc72caca, 0xc13b0c7c, 0x06453fb1, 0xed6cc2c2
 };
 
 #elif defined ARMV7Neon
-/* 
- *  Q29 for 128 and 1024 
+/*
+ *  Q29 for 128 and 1024
  *
  * for (i = 0; i < num/4; i++) {
  *   angle = (i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 29);
  *   x = sin(angle) * (1 << 29);
- * 
+ *
  *   angle = (num/2 - 1 - i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 29);
  *   x = sin(angle) * (1 << 29);
@@ -353,313 +353,313 @@
  */
 const int cossintab[128 + 1024] = {
 	/* 128 */
-	0x1ffff621, 0x001921f9, 0x00afea69, 0x1ffe1c68, 0x1ffce09d, 0x00e22a7a, 0x0178dbaa, 0x1ff753bb, 
-	0x1ff4dc55, 0x01ab101c, 0x024192cf, 0x1feb9d25, 0x1fe7ea85, 0x0273b3e2, 0x0309f0e2, 0x1fdafa75, 
-	0x1fd60d2e, 0x033bf6dd, 0x03d1d700, 0x1fc56e3b, 0x1fbf470f, 0x0403ba2b, 0x04992653, 0x1faafbcb, 
-	0x1fa39bac, 0x04cadefe, 0x055fc022, 0x1f8ba738, 0x1f830f4a, 0x059146a1, 0x062585ca, 0x1f677557, 
-	0x1f5da6ed, 0x0656d27a, 0x06ea58cd, 0x1f3e6bbc, 0x1f33685a, 0x071b6415, 0x07ae1ad2, 0x1f1090bd, 
-	0x1f045a15, 0x07dedd20, 0x0870ada7, 0x1eddeb6a, 0x1ed0835f, 0x08a11f78, 0x0931f34d, 0x1ea68394, 
-	0x1e97ec36, 0x09620d27, 0x09f1cdf5, 0x1e6a61c5, 0x1e5a9d55, 0x0a21886e, 0x0ab02009, 0x1e298f44, 
-	0x1e18a030, 0x0adf73c6, 0x0b6ccc32, 0x1de4160f, 0x1dd1fef4, 0x0b9bb1e5, 0x0c27b555, 0x1d9a00de, 
-	0x1d86c484, 0x0c5625c3, 0x0ce0bea2, 0x1d4b5b1b, 0x1d36fc7c, 0x0d0eb2a2, 0x0d97cb8f, 0x1cf830e9, 
-	0x1ce2b328, 0x0dc53c0a, 0x0e4cbfe2, 0x1ca08f1a, 0x1c89f587, 0x0e79a5d7, 0x0eff7fb3, 0x1c448331, 
-	0x1c2cd149, 0x0f2bd437, 0x0fafef73, 0x1be41b61, 0x1bcb54cb, 0x0fdbabae, 0x105df3ec, 0x1b7f6687, 
-	0x1b658f15, 0x10891120, 0x11097249, 0x1b16742a, 0x1afb8fd9, 0x1133e9d0, 0x11b25017, 0x1aa9547a, 
-	0x1a8d676e, 0x11dc1b65, 0x1258734d, 0x1a38184a, 0x1a1b26d3, 0x12818bef, 0x12fbc24b, 0x19c2d111, 
-	0x19a4dfa4, 0x132421ec, 0x139c23e4, 0x194990e4, 0x192aa420, 0x13c3c44a, 0x14397f5b, 0x18cc6a75, 
-	0x18ac871f, 0x14605a69, 0x14d3bc6d, 0x184b7112, 0x182a9c14, 0x14f9cc26, 0x156ac352, 0x17c6b89d, 
+	0x1ffff621, 0x001921f9, 0x00afea69, 0x1ffe1c68, 0x1ffce09d, 0x00e22a7a, 0x0178dbaa, 0x1ff753bb,
+	0x1ff4dc55, 0x01ab101c, 0x024192cf, 0x1feb9d25, 0x1fe7ea85, 0x0273b3e2, 0x0309f0e2, 0x1fdafa75,
+	0x1fd60d2e, 0x033bf6dd, 0x03d1d700, 0x1fc56e3b, 0x1fbf470f, 0x0403ba2b, 0x04992653, 0x1faafbcb,
+	0x1fa39bac, 0x04cadefe, 0x055fc022, 0x1f8ba738, 0x1f830f4a, 0x059146a1, 0x062585ca, 0x1f677557,
+	0x1f5da6ed, 0x0656d27a, 0x06ea58cd, 0x1f3e6bbc, 0x1f33685a, 0x071b6415, 0x07ae1ad2, 0x1f1090bd,
+	0x1f045a15, 0x07dedd20, 0x0870ada7, 0x1eddeb6a, 0x1ed0835f, 0x08a11f78, 0x0931f34d, 0x1ea68394,
+	0x1e97ec36, 0x09620d27, 0x09f1cdf5, 0x1e6a61c5, 0x1e5a9d55, 0x0a21886e, 0x0ab02009, 0x1e298f44,
+	0x1e18a030, 0x0adf73c6, 0x0b6ccc32, 0x1de4160f, 0x1dd1fef4, 0x0b9bb1e5, 0x0c27b555, 0x1d9a00de,
+	0x1d86c484, 0x0c5625c3, 0x0ce0bea2, 0x1d4b5b1b, 0x1d36fc7c, 0x0d0eb2a2, 0x0d97cb8f, 0x1cf830e9,
+	0x1ce2b328, 0x0dc53c0a, 0x0e4cbfe2, 0x1ca08f1a, 0x1c89f587, 0x0e79a5d7, 0x0eff7fb3, 0x1c448331,
+	0x1c2cd149, 0x0f2bd437, 0x0fafef73, 0x1be41b61, 0x1bcb54cb, 0x0fdbabae, 0x105df3ec, 0x1b7f6687,
+	0x1b658f15, 0x10891120, 0x11097249, 0x1b16742a, 0x1afb8fd9, 0x1133e9d0, 0x11b25017, 0x1aa9547a,
+	0x1a8d676e, 0x11dc1b65, 0x1258734d, 0x1a38184a, 0x1a1b26d3, 0x12818bef, 0x12fbc24b, 0x19c2d111,
+	0x19a4dfa4, 0x132421ec, 0x139c23e4, 0x194990e4, 0x192aa420, 0x13c3c44a, 0x14397f5b, 0x18cc6a75,
+	0x18ac871f, 0x14605a69, 0x14d3bc6d, 0x184b7112, 0x182a9c14, 0x14f9cc26, 0x156ac352, 0x17c6b89d,
 	0x17a4f708, 0x159001d6, 0x15fe7cbe, 0x173e558e, 0x171bac96, 0x1622e450, 0x168ed1eb, 0x16b25ced,
 	/* 1024 */
-	0x1fffffd9, 0x0003243f, 0x0015fdba, 0x1ffff872, 0x1ffff382, 0x001c4637, 0x002f1fa6, 0x1fffdd4d, 
-	0x1fffd36f, 0x0035681d, 0x00484175, 0x1fffae6c, 0x1fff9f9e, 0x004e89e3, 0x00616318, 0x1fff6bce, 
-	0x1fff5811, 0x0067ab77, 0x007a847e, 0x1fff1572, 0x1ffefcc6, 0x0080cccc, 0x0093a599, 0x1ffeab5b, 
-	0x1ffe8dbf, 0x0099edd2, 0x00acc658, 0x1ffe2d86, 0x1ffe0afc, 0x00b30e78, 0x00c5e6ad, 0x1ffd9bf6, 
-	0x1ffd747c, 0x00cc2eb0, 0x00df0688, 0x1ffcf6aa, 0x1ffcca41, 0x00e54e6a, 0x00f825da, 0x1ffc3da2, 
-	0x1ffc0c4b, 0x00fe6d97, 0x01114492, 0x1ffb70e0, 0x1ffb3a9a, 0x01178c27, 0x012a62a2, 0x1ffa9063, 
-	0x1ffa552e, 0x0130aa0a, 0x01437ffa, 0x1ff99c2c, 0x1ff95c09, 0x0149c731, 0x015c9c8a, 0x1ff8943c, 
-	0x1ff84f2b, 0x0162e38d, 0x0175b843, 0x1ff77893, 0x1ff72e94, 0x017bff0e, 0x018ed316, 0x1ff64932, 
-	0x1ff5fa46, 0x019519a5, 0x01a7ecf2, 0x1ff5061b, 0x1ff4b240, 0x01ae3341, 0x01c105c9, 0x1ff3af4c, 
-	0x1ff35684, 0x01c74bd5, 0x01da1d8c, 0x1ff244c8, 0x1ff1e713, 0x01e0634f, 0x01f33429, 0x1ff0c68f, 
-	0x1ff063ed, 0x01f979a1, 0x020c4993, 0x1fef34a3, 0x1feecd14, 0x02128ebb, 0x02255db9, 0x1fed8f03, 
-	0x1fed2287, 0x022ba28f, 0x023e708d, 0x1febd5b2, 0x1feb644a, 0x0244b50b, 0x025781fe, 0x1fea08b0, 
-	0x1fe9925c, 0x025dc621, 0x027091fd, 0x1fe827fe, 0x1fe7acbe, 0x0276d5c1, 0x0289a07b, 0x1fe6339d, 
-	0x1fe5b372, 0x028fe3dd, 0x02a2ad69, 0x1fe42b90, 0x1fe3a679, 0x02a8f063, 0x02bbb8b6, 0x1fe20fd6, 
-	0x1fe185d5, 0x02c1fb46, 0x02d4c253, 0x1fdfe071, 0x1fdf5186, 0x02db0475, 0x02edca32, 0x1fdd9d64, 
-	0x1fdd098e, 0x02f40be2, 0x0306d042, 0x1fdb46ae, 0x1fdaadee, 0x030d117c, 0x031fd474, 0x1fd8dc51, 
-	0x1fd83ea8, 0x03261534, 0x0338d6b8, 0x1fd65e4f, 0x1fd5bbbd, 0x033f16fb, 0x0351d700, 0x1fd3ccaa, 
-	0x1fd32530, 0x035816c1, 0x036ad53c, 0x1fd12763, 0x1fd07b00, 0x03711477, 0x0383d15c, 0x1fce6e7c, 
-	0x1fcdbd31, 0x038a100e, 0x039ccb51, 0x1fcba1f5, 0x1fcaebc3, 0x03a30975, 0x03b5c30b, 0x1fc8c1d2, 
-	0x1fc806b9, 0x03bc009f, 0x03ceb87c, 0x1fc5ce14, 0x1fc50e14, 0x03d4f57a, 0x03e7ab93, 0x1fc2c6bd, 
-	0x1fc201d7, 0x03ede7f9, 0x04009c42, 0x1fbfabcd, 0x1fbee202, 0x0406d80b, 0x04198a78, 0x1fbc7d49, 
-	0x1fbbae99, 0x041fc5a1, 0x04327628, 0x1fb93b31, 0x1fb8679c, 0x0438b0ac, 0x044b5f40, 0x1fb5e587, 
-	0x1fb50d0e, 0x0451991d, 0x046445b2, 0x1fb27c4e, 0x1fb19ef1, 0x046a7ee3, 0x047d296f, 0x1faeff87, 
-	0x1fae1d47, 0x048361f0, 0x04960a67, 0x1fab6f35, 0x1faa8813, 0x049c4235, 0x04aee88b, 0x1fa7cb5a, 
-	0x1fa6df56, 0x04b51fa1, 0x04c7c3cb, 0x1fa413f8, 0x1fa32313, 0x04cdfa26, 0x04e09c18, 0x1fa04912, 
-	0x1f9f534c, 0x04e6d1b4, 0x04f97163, 0x1f9c6aa9, 0x1f9b7003, 0x04ffa63c, 0x0512439d, 0x1f9878c1, 
-	0x1f97793b, 0x051877af, 0x052b12b6, 0x1f94735b, 0x1f936ef6, 0x053145fd, 0x0543de9e, 0x1f905a7a, 
-	0x1f8f5137, 0x054a1117, 0x055ca748, 0x1f8c2e21, 0x1f8b2000, 0x0562d8ee, 0x05756ca2, 0x1f87ee52, 
-	0x1f86db55, 0x057b9d73, 0x058e2e9f, 0x1f839b10, 0x1f828336, 0x05945e95, 0x05a6ed2e, 0x1f7f345e, 
-	0x1f7e17a8, 0x05ad1c47, 0x05bfa840, 0x1f7aba3e, 0x1f7998ad, 0x05c5d678, 0x05d85fc7, 0x1f762cb2, 
-	0x1f750647, 0x05de8d19, 0x05f113b3, 0x1f718bbf, 0x1f70607a, 0x05f7401c, 0x0609c3f5, 0x1f6cd766, 
-	0x1f6ba748, 0x060fef71, 0x0622707d, 0x1f680fab, 0x1f66dab5, 0x06289b08, 0x063b193c, 0x1f633490, 
-	0x1f61fac3, 0x064142d3, 0x0653be23, 0x1f5e4619, 0x1f5d0775, 0x0659e6c2, 0x066c5f24, 0x1f594448, 
-	0x1f5800ce, 0x067286c6, 0x0684fc2e, 0x1f542f21, 0x1f52e6d2, 0x068b22d0, 0x069d9532, 0x1f4f06a6, 
-	0x1f4db983, 0x06a3bad0, 0x06b62a22, 0x1f49cadc, 0x1f4878e5, 0x06bc4eb9, 0x06cebaee, 0x1f447bc4, 
-	0x1f4324fb, 0x06d4de79, 0x06e74786, 0x1f3f1963, 0x1f3dbdc8, 0x06ed6a03, 0x06ffcfdd, 0x1f39a3bc, 
-	0x1f384350, 0x0705f147, 0x071853e3, 0x1f341ad2, 0x1f32b595, 0x071e7436, 0x0730d388, 0x1f2e7ea9, 
-	0x1f2d149d, 0x0736f2c0, 0x07494ebd, 0x1f28cf43, 0x1f276069, 0x074f6cd7, 0x0761c574, 0x1f230ca5, 
-	0x1f2198fd, 0x0767e26c, 0x077a379d, 0x1f1d36d2, 0x1f1bbe5d, 0x07805370, 0x0792a52a, 0x1f174dce, 
-	0x1f15d08d, 0x0798bfd3, 0x07ab0e0a, 0x1f11519c, 0x1f0fcf91, 0x07b12786, 0x07c37230, 0x1f0b4240, 
-	0x1f09bb6b, 0x07c98a7a, 0x07dbd18c, 0x1f051fbe, 0x1f03941f, 0x07e1e8a1, 0x07f42c0e, 0x1efeea19, 
-	0x1efd59b3, 0x07fa41eb, 0x080c81a9, 0x1ef8a155, 0x1ef70c28, 0x0812964a, 0x0824d24d, 0x1ef24577, 
-	0x1ef0ab84, 0x082ae5ad, 0x083d1dea, 0x1eebd682, 0x1eea37ca, 0x08433007, 0x08556473, 0x1ee5547a, 
-	0x1ee3b0fe, 0x085b7548, 0x086da5d8, 0x1edebf64, 0x1edd1724, 0x0873b562, 0x0885e209, 0x1ed81742, 
-	0x1ed66a41, 0x088bf044, 0x089e18f9, 0x1ed15c1a, 0x1ecfaa57, 0x08a425e1, 0x08b64a98, 0x1eca8def, 
-	0x1ec8d76c, 0x08bc562a, 0x08ce76d8, 0x1ec3acc6, 0x1ec1f184, 0x08d4810f, 0x08e69da8, 0x1ebcb8a3, 
-	0x1ebaf8a3, 0x08eca681, 0x08febefb, 0x1eb5b18a, 0x1eb3eccd, 0x0904c673, 0x0916dac2, 0x1eae977f, 
-	0x1eacce07, 0x091ce0d4, 0x092ef0ed, 0x1ea76a87, 0x1ea59c55, 0x0934f596, 0x0947016e, 0x1ea02aa7, 
-	0x1e9e57bb, 0x094d04aa, 0x095f0c36, 0x1e98d7e2, 0x1e97003e, 0x09650e01, 0x09771136, 0x1e91723e, 
-	0x1e8f95e3, 0x097d118d, 0x098f1060, 0x1e89f9bf, 0x1e8818ad, 0x09950f3f, 0x09a709a4, 0x1e826e69, 
-	0x1e8088a2, 0x09ad0707, 0x09befcf4, 0x1e7ad041, 0x1e78e5c7, 0x09c4f8d8, 0x09d6ea40, 0x1e731f4c, 
-	0x1e71301f, 0x09dce4a1, 0x09eed17b, 0x1e6b5b8f, 0x1e6967b1, 0x09f4ca56, 0x0a06b296, 0x1e63850e, 
-	0x1e618c80, 0x0a0ca9e6, 0x0a1e8d81, 0x1e5b9bce, 0x1e599e91, 0x0a248343, 0x0a36622e, 0x1e539fd4, 
-	0x1e519dea, 0x0a3c565e, 0x0a4e308f, 0x1e4b9126, 0x1e498a8e, 0x0a542329, 0x0a65f894, 0x1e436fc7, 
-	0x1e416485, 0x0a6be995, 0x0a7dba2f, 0x1e3b3bbd, 0x1e392bd1, 0x0a83a993, 0x0a957551, 0x1e32f50e, 
-	0x1e30e079, 0x0a9b6315, 0x0aad29ec, 0x1e2a9bbd, 0x1e288281, 0x0ab3160c, 0x0ac4d7f1, 0x1e222fd1, 
-	0x1e2011ee, 0x0acac26a, 0x0adc7f52, 0x1e19b14f, 0x1e178ec7, 0x0ae2681f, 0x0af41fff, 0x1e11203b, 
-	0x1e0ef910, 0x0afa071d, 0x0b0bb9eb, 0x1e087c9b, 0x1e0650ce, 0x0b119f56, 0x0b234d07, 0x1dffc674, 
-	0x1dfd9606, 0x0b2930bb, 0x0b3ad943, 0x1df6fdcc, 0x1df4c8bf, 0x0b40bb3e, 0x0b525e92, 0x1dee22a9, 
-	0x1debe8fd, 0x0b583ecf, 0x0b69dce6, 0x1de5350f, 0x1de2f6c6, 0x0b6fbb62, 0x0b81542f, 0x1ddc3504, 
-	0x1dd9f220, 0x0b8730e6, 0x0b98c45f, 0x1dd3228e, 0x1dd0db10, 0x0b9e9f4d, 0x0bb02d68, 0x1dc9fdb2, 
-	0x1dc7b19b, 0x0bb6068a, 0x0bc78f3b, 0x1dc0c676, 0x1dbe75c8, 0x0bcd668e, 0x0bdee9ca, 0x1db77cdf, 
-	0x1db5279c, 0x0be4bf4a, 0x0bf63d07, 0x1dae20f4, 0x1dabc71d, 0x0bfc10af, 0x0c0d88e2, 0x1da4b2ba, 
-	0x1da25450, 0x0c135ab0, 0x0c24cd4e, 0x1d9b3237, 0x1d98cf3b, 0x0c2a9d3e, 0x0c3c0a3d, 0x1d919f70, 
-	0x1d8f37e5, 0x0c41d84b, 0x0c533fa0, 0x1d87fa6d, 0x1d858e53, 0x0c590bc9, 0x0c6a6d68, 0x1d7e4332, 
-	0x1d7bd28b, 0x0c7037a8, 0x0c819388, 0x1d7479c5, 0x1d720493, 0x0c875bdb, 0x0c98b1f0, 0x1d6a9e2e, 
-	0x1d682472, 0x0c9e7854, 0x0cafc894, 0x1d60b070, 0x1d5e322c, 0x0cb58d04, 0x0cc6d764, 0x1d56b094, 
-	0x1d542dc9, 0x0ccc99de, 0x0cddde53, 0x1d4c9e9f, 0x1d4a174f, 0x0ce39ed2, 0x0cf4dd52, 0x1d427a97, 
-	0x1d3feec3, 0x0cfa9bd2, 0x0d0bd452, 0x1d384483, 0x1d35b42d, 0x0d1190d1, 0x0d22c347, 0x1d2dfc68, 
-	0x1d2b6791, 0x0d287dc1, 0x0d39aa21, 0x1d23a24e, 0x1d2108f8, 0x0d3f6292, 0x0d5088d3, 0x1d19363a, 
-	0x1d169867, 0x0d563f38, 0x0d675f4e, 0x1d0eb833, 0x1d0c15e4, 0x0d6d13a3, 0x0d7e2d85, 0x1d04283f, 
-	0x1d018176, 0x0d83dfc6, 0x0d94f369, 0x1cf98666, 0x1cf6db24, 0x0d9aa393, 0x0dabb0ec, 0x1ceed2ad, 
-	0x1cec22f4, 0x0db15efc, 0x0dc26600, 0x1ce40d1b, 0x1ce158ed, 0x0dc811f3, 0x0dd91298, 0x1cd935b7, 
-	0x1cd67d15, 0x0ddebc69, 0x0defb6a5, 0x1cce4c87, 0x1ccb8f74, 0x0df55e51, 0x0e065219, 0x1cc35192, 
-	0x1cc0900f, 0x0e0bf79c, 0x0e1ce4e6, 0x1cb844df, 0x1cb57eee, 0x0e22883e, 0x0e336eff, 0x1cad2675, 
-	0x1caa5c17, 0x0e391027, 0x0e49f055, 0x1ca1f65b, 0x1c9f2792, 0x0e4f8f4b, 0x0e6068db, 0x1c96b497, 
-	0x1c93e165, 0x0e66059a, 0x0e76d883, 0x1c8b6131, 0x1c888997, 0x0e7c7308, 0x0e8d3f3e, 0x1c7ffc2f, 
-	0x1c7d202f, 0x0e92d787, 0x0ea39d00, 0x1c748599, 0x1c71a535, 0x0ea93308, 0x0eb9f1ba, 0x1c68fd75, 
-	0x1c6618ae, 0x0ebf857d, 0x0ed03d5e, 0x1c5d63ca, 0x1c5a7aa4, 0x0ed5ceda, 0x0ee67fdf, 0x1c51b8a1, 
-	0x1c4ecb1c, 0x0eec0f10, 0x0efcb92f, 0x1c45fc00, 0x1c430a1d, 0x0f024612, 0x0f12e941, 0x1c3a2ded, 
-	0x1c3737b0, 0x0f1873d2, 0x0f291006, 0x1c2e4e72, 0x1c2b53db, 0x0f2e9842, 0x0f3f2d71, 0x1c225d94, 
-	0x1c1f5ea6, 0x0f44b354, 0x0f554175, 0x1c165b5b, 0x1c135818, 0x0f5ac4fc, 0x0f6b4c03, 0x1c0a47cf, 
-	0x1c074038, 0x0f70cd2a, 0x0f814d0e, 0x1bfe22f8, 0x1bfb170f, 0x0f86cbd3, 0x0f974489, 0x1bf1ecdb, 
-	0x1beedca2, 0x0f9cc0e7, 0x0fad3265, 0x1be5a582, 0x1be290fb, 0x0fb2ac5a, 0x0fc31697, 0x1bd94cf4, 
-	0x1bd63421, 0x0fc88e1e, 0x0fd8f10f, 0x1bcce337, 0x1bc9c61a, 0x0fde6626, 0x0feec1c0, 0x1bc06855, 
-	0x1bbd46f0, 0x0ff43464, 0x1004889e, 0x1bb3dc55, 0x1bb0b6a9, 0x1009f8cb, 0x101a459a, 0x1ba73f3d, 
-	0x1ba4154d, 0x101fb34d, 0x102ff8a8, 0x1b9a9117, 0x1b9762e4, 0x103563dc, 0x1045a1b9, 0x1b8dd1ea, 
-	0x1b8a9f77, 0x104b0a6c, 0x105b40c1, 0x1b8101be, 0x1b7dcb0c, 0x1060a6ef, 0x1070d5b1, 0x1b74209b, 
-	0x1b70e5ac, 0x10763958, 0x1086607e, 0x1b672e88, 0x1b63ef5f, 0x108bc19a, 0x109be119, 0x1b5a2b8e, 
-	0x1b56e82c, 0x10a13fa6, 0x10b15775, 0x1b4d17b4, 0x1b49d01c, 0x10b6b371, 0x10c6c385, 0x1b3ff304, 
-	0x1b3ca737, 0x10cc1cec, 0x10dc253c, 0x1b32bd84, 0x1b2f6d85, 0x10e17c0b, 0x10f17c8d, 0x1b25773d, 
-	0x1b22230e, 0x10f6d0c0, 0x1106c96a, 0x1b182038, 0x1b14c7da, 0x110c1afe, 0x111c0bc6, 0x1b0ab87c, 
-	0x1b075bf1, 0x11215ab8, 0x11314395, 0x1afd4012, 0x1af9df5d, 0x11368fe1, 0x114670c8, 0x1aefb702, 
-	0x1aec5225, 0x114bba6b, 0x115b9354, 0x1ae21d54, 0x1adeb451, 0x1160da4b, 0x1170ab2a, 0x1ad47311, 
-	0x1ad105e9, 0x1175ef72, 0x1185b83f, 0x1ac6b841, 0x1ac346f8, 0x118af9d4, 0x119aba84, 0x1ab8ecec, 
-	0x1ab57784, 0x119ff964, 0x11afb1ee, 0x1aab111c, 0x1aa79796, 0x11b4ee14, 0x11c49e6f, 0x1a9d24d9, 
-	0x1a99a737, 0x11c9d7d9, 0x11d97ff9, 0x1a8f282b, 0x1a8ba670, 0x11deb6a4, 0x11ee5682, 0x1a811b1b, 
-	0x1a7d9549, 0x11f38a6a, 0x120321fa, 0x1a72fdb2, 0x1a6f73ca, 0x1208531c, 0x1217e256, 0x1a64cff8, 
-	0x1a6141fd, 0x121d10af, 0x122c9789, 0x1a5691f5, 0x1a52ffeb, 0x1231c316, 0x12414186, 0x1a4843b4, 
-	0x1a44ad9b, 0x12466a44, 0x1255e041, 0x1a39e53d, 0x1a364b17, 0x125b062b, 0x126a73ac, 0x1a2b7698, 
-	0x1a27d868, 0x126f96c1, 0x127efbbb, 0x1a1cf7ce, 0x1a195597, 0x12841bf6, 0x12937861, 0x1a0e68e9, 
-	0x1a0ac2ac, 0x129895c0, 0x12a7e991, 0x19ffc9f1, 0x19fc1fb1, 0x12ad0412, 0x12bc4f40, 0x19f11af0, 
-	0x19ed6caf, 0x12c166de, 0x12d0a960, 0x19e25bee, 0x19dea9ae, 0x12d5be18, 0x12e4f7e5, 0x19d38cf4, 
-	0x19cfd6b8, 0x12ea09b4, 0x12f93ac2, 0x19c4ae0c, 0x19c0f3d6, 0x12fe49a6, 0x130d71eb, 0x19b5bf3f, 
-	0x19b20111, 0x13127de0, 0x13219d53, 0x19a6c096, 0x19a2fe73, 0x1326a656, 0x1335bcef, 0x1997b21b, 
-	0x1993ec04, 0x133ac2fc, 0x1349d0b0, 0x198893d6, 0x1984c9ce, 0x134ed3c5, 0x135dd88c, 0x197965d0, 
-	0x197597da, 0x1362d8a6, 0x1371d476, 0x196a2815, 0x19665632, 0x1376d191, 0x1385c461, 0x195adaab, 
-	0x195704df, 0x138abe7b, 0x1399a841, 0x194b7d9e, 0x1947a3eb, 0x139e9f56, 0x13ad800a, 0x193c10f7, 
-	0x1938335e, 0x13b27417, 0x13c14bb0, 0x192c94bf, 0x1928b343, 0x13c63cb2, 0x13d50b26, 0x191d08ff, 
-	0x191923a3, 0x13d9f91b, 0x13e8be60, 0x190d6dc1, 0x19098488, 0x13eda944, 0x13fc6553, 0x18fdc310, 
-	0x18f9d5fa, 0x14014d23, 0x140ffff1, 0x18ee08f4, 0x18ea1805, 0x1414e4aa, 0x14238e2f, 0x18de3f77, 
-	0x18da4ab2, 0x14286fce, 0x14371001, 0x18ce66a3, 0x18ca6e0a, 0x143bee83, 0x144a855b, 0x18be7e82, 
-	0x18ba8217, 0x144f60bd, 0x145dee30, 0x18ae871e, 0x18aa86e3, 0x1462c670, 0x14714a76, 0x189e8080, 
-	0x189a7c78, 0x14761f8f, 0x14849a1f, 0x188e6ab2, 0x188a62e0, 0x14896c0f, 0x1497dd20, 0x187e45be, 
-	0x187a3a25, 0x149cabe4, 0x14ab136d, 0x186e11af, 0x186a0250, 0x14afdf03, 0x14be3cfa, 0x185dce8e, 
-	0x1859bb6c, 0x14c3055e, 0x14d159bc, 0x184d7c65, 0x18496583, 0x14d61eeb, 0x14e469a6, 0x183d1b3e, 
-	0x1839009e, 0x14e92b9e, 0x14f76cad, 0x182cab24, 0x18288cc8, 0x14fc2b6a, 0x150a62c6, 0x181c2c20, 
-	0x18180a0c, 0x150f1e45, 0x151d4be3, 0x180b9e3d, 0x18077873, 0x15220422, 0x153027fb, 0x17fb0185, 
-	0x17f6d807, 0x1534dcf6, 0x1542f700, 0x17ea5602, 0x17e628d3, 0x1547a8b5, 0x1555b8e8, 0x17d99bbe, 
-	0x17d56ae0, 0x155a6754, 0x15686da7, 0x17c8d2c4, 0x17c49e3b, 0x156d18c7, 0x157b1532, 0x17b7fb1f, 
-	0x17b3c2ec, 0x157fbd03, 0x158daf7c, 0x17a714d7, 0x17a2d8fe, 0x159253fb, 0x15a03c7a, 0x17961ff9, 
-	0x1791e07b, 0x15a4dda5, 0x15b2bc22, 0x17851c8e, 0x1780d96f, 0x15b759f5, 0x15c52e67, 0x17740aa1, 
-	0x176fc3e3, 0x15c9c8e0, 0x15d7933f, 0x1762ea3d, 0x175e9fe2, 0x15dc2a5a, 0x15e9ea9d, 0x1751bb6b, 
-	0x174d6d77, 0x15ee7e58, 0x15fc3477, 0x17407e37, 0x173c2cac, 0x1600c4cf, 0x160e70c1, 0x172f32ab, 
-	0x172add8c, 0x1612fdb3, 0x16209f70, 0x171dd8d2, 0x17198021, 0x162528fa, 0x1632c078, 0x170c70b7, 
-	0x17081477, 0x16374697, 0x1644d3d0, 0x16fafa64, 0x16f69a97, 0x16495680, 0x1656d96a, 0x16e975e4, 
-	0x16e5128e, 0x165b58aa, 0x1668d13e, 0x16d7e341, 0x16d37c65, 0x166d4d0a, 0x167abb3e, 0x16c64288, 
+	0x1fffffd9, 0x0003243f, 0x0015fdba, 0x1ffff872, 0x1ffff382, 0x001c4637, 0x002f1fa6, 0x1fffdd4d,
+	0x1fffd36f, 0x0035681d, 0x00484175, 0x1fffae6c, 0x1fff9f9e, 0x004e89e3, 0x00616318, 0x1fff6bce,
+	0x1fff5811, 0x0067ab77, 0x007a847e, 0x1fff1572, 0x1ffefcc6, 0x0080cccc, 0x0093a599, 0x1ffeab5b,
+	0x1ffe8dbf, 0x0099edd2, 0x00acc658, 0x1ffe2d86, 0x1ffe0afc, 0x00b30e78, 0x00c5e6ad, 0x1ffd9bf6,
+	0x1ffd747c, 0x00cc2eb0, 0x00df0688, 0x1ffcf6aa, 0x1ffcca41, 0x00e54e6a, 0x00f825da, 0x1ffc3da2,
+	0x1ffc0c4b, 0x00fe6d97, 0x01114492, 0x1ffb70e0, 0x1ffb3a9a, 0x01178c27, 0x012a62a2, 0x1ffa9063,
+	0x1ffa552e, 0x0130aa0a, 0x01437ffa, 0x1ff99c2c, 0x1ff95c09, 0x0149c731, 0x015c9c8a, 0x1ff8943c,
+	0x1ff84f2b, 0x0162e38d, 0x0175b843, 0x1ff77893, 0x1ff72e94, 0x017bff0e, 0x018ed316, 0x1ff64932,
+	0x1ff5fa46, 0x019519a5, 0x01a7ecf2, 0x1ff5061b, 0x1ff4b240, 0x01ae3341, 0x01c105c9, 0x1ff3af4c,
+	0x1ff35684, 0x01c74bd5, 0x01da1d8c, 0x1ff244c8, 0x1ff1e713, 0x01e0634f, 0x01f33429, 0x1ff0c68f,
+	0x1ff063ed, 0x01f979a1, 0x020c4993, 0x1fef34a3, 0x1feecd14, 0x02128ebb, 0x02255db9, 0x1fed8f03,
+	0x1fed2287, 0x022ba28f, 0x023e708d, 0x1febd5b2, 0x1feb644a, 0x0244b50b, 0x025781fe, 0x1fea08b0,
+	0x1fe9925c, 0x025dc621, 0x027091fd, 0x1fe827fe, 0x1fe7acbe, 0x0276d5c1, 0x0289a07b, 0x1fe6339d,
+	0x1fe5b372, 0x028fe3dd, 0x02a2ad69, 0x1fe42b90, 0x1fe3a679, 0x02a8f063, 0x02bbb8b6, 0x1fe20fd6,
+	0x1fe185d5, 0x02c1fb46, 0x02d4c253, 0x1fdfe071, 0x1fdf5186, 0x02db0475, 0x02edca32, 0x1fdd9d64,
+	0x1fdd098e, 0x02f40be2, 0x0306d042, 0x1fdb46ae, 0x1fdaadee, 0x030d117c, 0x031fd474, 0x1fd8dc51,
+	0x1fd83ea8, 0x03261534, 0x0338d6b8, 0x1fd65e4f, 0x1fd5bbbd, 0x033f16fb, 0x0351d700, 0x1fd3ccaa,
+	0x1fd32530, 0x035816c1, 0x036ad53c, 0x1fd12763, 0x1fd07b00, 0x03711477, 0x0383d15c, 0x1fce6e7c,
+	0x1fcdbd31, 0x038a100e, 0x039ccb51, 0x1fcba1f5, 0x1fcaebc3, 0x03a30975, 0x03b5c30b, 0x1fc8c1d2,
+	0x1fc806b9, 0x03bc009f, 0x03ceb87c, 0x1fc5ce14, 0x1fc50e14, 0x03d4f57a, 0x03e7ab93, 0x1fc2c6bd,
+	0x1fc201d7, 0x03ede7f9, 0x04009c42, 0x1fbfabcd, 0x1fbee202, 0x0406d80b, 0x04198a78, 0x1fbc7d49,
+	0x1fbbae99, 0x041fc5a1, 0x04327628, 0x1fb93b31, 0x1fb8679c, 0x0438b0ac, 0x044b5f40, 0x1fb5e587,
+	0x1fb50d0e, 0x0451991d, 0x046445b2, 0x1fb27c4e, 0x1fb19ef1, 0x046a7ee3, 0x047d296f, 0x1faeff87,
+	0x1fae1d47, 0x048361f0, 0x04960a67, 0x1fab6f35, 0x1faa8813, 0x049c4235, 0x04aee88b, 0x1fa7cb5a,
+	0x1fa6df56, 0x04b51fa1, 0x04c7c3cb, 0x1fa413f8, 0x1fa32313, 0x04cdfa26, 0x04e09c18, 0x1fa04912,
+	0x1f9f534c, 0x04e6d1b4, 0x04f97163, 0x1f9c6aa9, 0x1f9b7003, 0x04ffa63c, 0x0512439d, 0x1f9878c1,
+	0x1f97793b, 0x051877af, 0x052b12b6, 0x1f94735b, 0x1f936ef6, 0x053145fd, 0x0543de9e, 0x1f905a7a,
+	0x1f8f5137, 0x054a1117, 0x055ca748, 0x1f8c2e21, 0x1f8b2000, 0x0562d8ee, 0x05756ca2, 0x1f87ee52,
+	0x1f86db55, 0x057b9d73, 0x058e2e9f, 0x1f839b10, 0x1f828336, 0x05945e95, 0x05a6ed2e, 0x1f7f345e,
+	0x1f7e17a8, 0x05ad1c47, 0x05bfa840, 0x1f7aba3e, 0x1f7998ad, 0x05c5d678, 0x05d85fc7, 0x1f762cb2,
+	0x1f750647, 0x05de8d19, 0x05f113b3, 0x1f718bbf, 0x1f70607a, 0x05f7401c, 0x0609c3f5, 0x1f6cd766,
+	0x1f6ba748, 0x060fef71, 0x0622707d, 0x1f680fab, 0x1f66dab5, 0x06289b08, 0x063b193c, 0x1f633490,
+	0x1f61fac3, 0x064142d3, 0x0653be23, 0x1f5e4619, 0x1f5d0775, 0x0659e6c2, 0x066c5f24, 0x1f594448,
+	0x1f5800ce, 0x067286c6, 0x0684fc2e, 0x1f542f21, 0x1f52e6d2, 0x068b22d0, 0x069d9532, 0x1f4f06a6,
+	0x1f4db983, 0x06a3bad0, 0x06b62a22, 0x1f49cadc, 0x1f4878e5, 0x06bc4eb9, 0x06cebaee, 0x1f447bc4,
+	0x1f4324fb, 0x06d4de79, 0x06e74786, 0x1f3f1963, 0x1f3dbdc8, 0x06ed6a03, 0x06ffcfdd, 0x1f39a3bc,
+	0x1f384350, 0x0705f147, 0x071853e3, 0x1f341ad2, 0x1f32b595, 0x071e7436, 0x0730d388, 0x1f2e7ea9,
+	0x1f2d149d, 0x0736f2c0, 0x07494ebd, 0x1f28cf43, 0x1f276069, 0x074f6cd7, 0x0761c574, 0x1f230ca5,
+	0x1f2198fd, 0x0767e26c, 0x077a379d, 0x1f1d36d2, 0x1f1bbe5d, 0x07805370, 0x0792a52a, 0x1f174dce,
+	0x1f15d08d, 0x0798bfd3, 0x07ab0e0a, 0x1f11519c, 0x1f0fcf91, 0x07b12786, 0x07c37230, 0x1f0b4240,
+	0x1f09bb6b, 0x07c98a7a, 0x07dbd18c, 0x1f051fbe, 0x1f03941f, 0x07e1e8a1, 0x07f42c0e, 0x1efeea19,
+	0x1efd59b3, 0x07fa41eb, 0x080c81a9, 0x1ef8a155, 0x1ef70c28, 0x0812964a, 0x0824d24d, 0x1ef24577,
+	0x1ef0ab84, 0x082ae5ad, 0x083d1dea, 0x1eebd682, 0x1eea37ca, 0x08433007, 0x08556473, 0x1ee5547a,
+	0x1ee3b0fe, 0x085b7548, 0x086da5d8, 0x1edebf64, 0x1edd1724, 0x0873b562, 0x0885e209, 0x1ed81742,
+	0x1ed66a41, 0x088bf044, 0x089e18f9, 0x1ed15c1a, 0x1ecfaa57, 0x08a425e1, 0x08b64a98, 0x1eca8def,
+	0x1ec8d76c, 0x08bc562a, 0x08ce76d8, 0x1ec3acc6, 0x1ec1f184, 0x08d4810f, 0x08e69da8, 0x1ebcb8a3,
+	0x1ebaf8a3, 0x08eca681, 0x08febefb, 0x1eb5b18a, 0x1eb3eccd, 0x0904c673, 0x0916dac2, 0x1eae977f,
+	0x1eacce07, 0x091ce0d4, 0x092ef0ed, 0x1ea76a87, 0x1ea59c55, 0x0934f596, 0x0947016e, 0x1ea02aa7,
+	0x1e9e57bb, 0x094d04aa, 0x095f0c36, 0x1e98d7e2, 0x1e97003e, 0x09650e01, 0x09771136, 0x1e91723e,
+	0x1e8f95e3, 0x097d118d, 0x098f1060, 0x1e89f9bf, 0x1e8818ad, 0x09950f3f, 0x09a709a4, 0x1e826e69,
+	0x1e8088a2, 0x09ad0707, 0x09befcf4, 0x1e7ad041, 0x1e78e5c7, 0x09c4f8d8, 0x09d6ea40, 0x1e731f4c,
+	0x1e71301f, 0x09dce4a1, 0x09eed17b, 0x1e6b5b8f, 0x1e6967b1, 0x09f4ca56, 0x0a06b296, 0x1e63850e,
+	0x1e618c80, 0x0a0ca9e6, 0x0a1e8d81, 0x1e5b9bce, 0x1e599e91, 0x0a248343, 0x0a36622e, 0x1e539fd4,
+	0x1e519dea, 0x0a3c565e, 0x0a4e308f, 0x1e4b9126, 0x1e498a8e, 0x0a542329, 0x0a65f894, 0x1e436fc7,
+	0x1e416485, 0x0a6be995, 0x0a7dba2f, 0x1e3b3bbd, 0x1e392bd1, 0x0a83a993, 0x0a957551, 0x1e32f50e,
+	0x1e30e079, 0x0a9b6315, 0x0aad29ec, 0x1e2a9bbd, 0x1e288281, 0x0ab3160c, 0x0ac4d7f1, 0x1e222fd1,
+	0x1e2011ee, 0x0acac26a, 0x0adc7f52, 0x1e19b14f, 0x1e178ec7, 0x0ae2681f, 0x0af41fff, 0x1e11203b,
+	0x1e0ef910, 0x0afa071d, 0x0b0bb9eb, 0x1e087c9b, 0x1e0650ce, 0x0b119f56, 0x0b234d07, 0x1dffc674,
+	0x1dfd9606, 0x0b2930bb, 0x0b3ad943, 0x1df6fdcc, 0x1df4c8bf, 0x0b40bb3e, 0x0b525e92, 0x1dee22a9,
+	0x1debe8fd, 0x0b583ecf, 0x0b69dce6, 0x1de5350f, 0x1de2f6c6, 0x0b6fbb62, 0x0b81542f, 0x1ddc3504,
+	0x1dd9f220, 0x0b8730e6, 0x0b98c45f, 0x1dd3228e, 0x1dd0db10, 0x0b9e9f4d, 0x0bb02d68, 0x1dc9fdb2,
+	0x1dc7b19b, 0x0bb6068a, 0x0bc78f3b, 0x1dc0c676, 0x1dbe75c8, 0x0bcd668e, 0x0bdee9ca, 0x1db77cdf,
+	0x1db5279c, 0x0be4bf4a, 0x0bf63d07, 0x1dae20f4, 0x1dabc71d, 0x0bfc10af, 0x0c0d88e2, 0x1da4b2ba,
+	0x1da25450, 0x0c135ab0, 0x0c24cd4e, 0x1d9b3237, 0x1d98cf3b, 0x0c2a9d3e, 0x0c3c0a3d, 0x1d919f70,
+	0x1d8f37e5, 0x0c41d84b, 0x0c533fa0, 0x1d87fa6d, 0x1d858e53, 0x0c590bc9, 0x0c6a6d68, 0x1d7e4332,
+	0x1d7bd28b, 0x0c7037a8, 0x0c819388, 0x1d7479c5, 0x1d720493, 0x0c875bdb, 0x0c98b1f0, 0x1d6a9e2e,
+	0x1d682472, 0x0c9e7854, 0x0cafc894, 0x1d60b070, 0x1d5e322c, 0x0cb58d04, 0x0cc6d764, 0x1d56b094,
+	0x1d542dc9, 0x0ccc99de, 0x0cddde53, 0x1d4c9e9f, 0x1d4a174f, 0x0ce39ed2, 0x0cf4dd52, 0x1d427a97,
+	0x1d3feec3, 0x0cfa9bd2, 0x0d0bd452, 0x1d384483, 0x1d35b42d, 0x0d1190d1, 0x0d22c347, 0x1d2dfc68,
+	0x1d2b6791, 0x0d287dc1, 0x0d39aa21, 0x1d23a24e, 0x1d2108f8, 0x0d3f6292, 0x0d5088d3, 0x1d19363a,
+	0x1d169867, 0x0d563f38, 0x0d675f4e, 0x1d0eb833, 0x1d0c15e4, 0x0d6d13a3, 0x0d7e2d85, 0x1d04283f,
+	0x1d018176, 0x0d83dfc6, 0x0d94f369, 0x1cf98666, 0x1cf6db24, 0x0d9aa393, 0x0dabb0ec, 0x1ceed2ad,
+	0x1cec22f4, 0x0db15efc, 0x0dc26600, 0x1ce40d1b, 0x1ce158ed, 0x0dc811f3, 0x0dd91298, 0x1cd935b7,
+	0x1cd67d15, 0x0ddebc69, 0x0defb6a5, 0x1cce4c87, 0x1ccb8f74, 0x0df55e51, 0x0e065219, 0x1cc35192,
+	0x1cc0900f, 0x0e0bf79c, 0x0e1ce4e6, 0x1cb844df, 0x1cb57eee, 0x0e22883e, 0x0e336eff, 0x1cad2675,
+	0x1caa5c17, 0x0e391027, 0x0e49f055, 0x1ca1f65b, 0x1c9f2792, 0x0e4f8f4b, 0x0e6068db, 0x1c96b497,
+	0x1c93e165, 0x0e66059a, 0x0e76d883, 0x1c8b6131, 0x1c888997, 0x0e7c7308, 0x0e8d3f3e, 0x1c7ffc2f,
+	0x1c7d202f, 0x0e92d787, 0x0ea39d00, 0x1c748599, 0x1c71a535, 0x0ea93308, 0x0eb9f1ba, 0x1c68fd75,
+	0x1c6618ae, 0x0ebf857d, 0x0ed03d5e, 0x1c5d63ca, 0x1c5a7aa4, 0x0ed5ceda, 0x0ee67fdf, 0x1c51b8a1,
+	0x1c4ecb1c, 0x0eec0f10, 0x0efcb92f, 0x1c45fc00, 0x1c430a1d, 0x0f024612, 0x0f12e941, 0x1c3a2ded,
+	0x1c3737b0, 0x0f1873d2, 0x0f291006, 0x1c2e4e72, 0x1c2b53db, 0x0f2e9842, 0x0f3f2d71, 0x1c225d94,
+	0x1c1f5ea6, 0x0f44b354, 0x0f554175, 0x1c165b5b, 0x1c135818, 0x0f5ac4fc, 0x0f6b4c03, 0x1c0a47cf,
+	0x1c074038, 0x0f70cd2a, 0x0f814d0e, 0x1bfe22f8, 0x1bfb170f, 0x0f86cbd3, 0x0f974489, 0x1bf1ecdb,
+	0x1beedca2, 0x0f9cc0e7, 0x0fad3265, 0x1be5a582, 0x1be290fb, 0x0fb2ac5a, 0x0fc31697, 0x1bd94cf4,
+	0x1bd63421, 0x0fc88e1e, 0x0fd8f10f, 0x1bcce337, 0x1bc9c61a, 0x0fde6626, 0x0feec1c0, 0x1bc06855,
+	0x1bbd46f0, 0x0ff43464, 0x1004889e, 0x1bb3dc55, 0x1bb0b6a9, 0x1009f8cb, 0x101a459a, 0x1ba73f3d,
+	0x1ba4154d, 0x101fb34d, 0x102ff8a8, 0x1b9a9117, 0x1b9762e4, 0x103563dc, 0x1045a1b9, 0x1b8dd1ea,
+	0x1b8a9f77, 0x104b0a6c, 0x105b40c1, 0x1b8101be, 0x1b7dcb0c, 0x1060a6ef, 0x1070d5b1, 0x1b74209b,
+	0x1b70e5ac, 0x10763958, 0x1086607e, 0x1b672e88, 0x1b63ef5f, 0x108bc19a, 0x109be119, 0x1b5a2b8e,
+	0x1b56e82c, 0x10a13fa6, 0x10b15775, 0x1b4d17b4, 0x1b49d01c, 0x10b6b371, 0x10c6c385, 0x1b3ff304,
+	0x1b3ca737, 0x10cc1cec, 0x10dc253c, 0x1b32bd84, 0x1b2f6d85, 0x10e17c0b, 0x10f17c8d, 0x1b25773d,
+	0x1b22230e, 0x10f6d0c0, 0x1106c96a, 0x1b182038, 0x1b14c7da, 0x110c1afe, 0x111c0bc6, 0x1b0ab87c,
+	0x1b075bf1, 0x11215ab8, 0x11314395, 0x1afd4012, 0x1af9df5d, 0x11368fe1, 0x114670c8, 0x1aefb702,
+	0x1aec5225, 0x114bba6b, 0x115b9354, 0x1ae21d54, 0x1adeb451, 0x1160da4b, 0x1170ab2a, 0x1ad47311,
+	0x1ad105e9, 0x1175ef72, 0x1185b83f, 0x1ac6b841, 0x1ac346f8, 0x118af9d4, 0x119aba84, 0x1ab8ecec,
+	0x1ab57784, 0x119ff964, 0x11afb1ee, 0x1aab111c, 0x1aa79796, 0x11b4ee14, 0x11c49e6f, 0x1a9d24d9,
+	0x1a99a737, 0x11c9d7d9, 0x11d97ff9, 0x1a8f282b, 0x1a8ba670, 0x11deb6a4, 0x11ee5682, 0x1a811b1b,
+	0x1a7d9549, 0x11f38a6a, 0x120321fa, 0x1a72fdb2, 0x1a6f73ca, 0x1208531c, 0x1217e256, 0x1a64cff8,
+	0x1a6141fd, 0x121d10af, 0x122c9789, 0x1a5691f5, 0x1a52ffeb, 0x1231c316, 0x12414186, 0x1a4843b4,
+	0x1a44ad9b, 0x12466a44, 0x1255e041, 0x1a39e53d, 0x1a364b17, 0x125b062b, 0x126a73ac, 0x1a2b7698,
+	0x1a27d868, 0x126f96c1, 0x127efbbb, 0x1a1cf7ce, 0x1a195597, 0x12841bf6, 0x12937861, 0x1a0e68e9,
+	0x1a0ac2ac, 0x129895c0, 0x12a7e991, 0x19ffc9f1, 0x19fc1fb1, 0x12ad0412, 0x12bc4f40, 0x19f11af0,
+	0x19ed6caf, 0x12c166de, 0x12d0a960, 0x19e25bee, 0x19dea9ae, 0x12d5be18, 0x12e4f7e5, 0x19d38cf4,
+	0x19cfd6b8, 0x12ea09b4, 0x12f93ac2, 0x19c4ae0c, 0x19c0f3d6, 0x12fe49a6, 0x130d71eb, 0x19b5bf3f,
+	0x19b20111, 0x13127de0, 0x13219d53, 0x19a6c096, 0x19a2fe73, 0x1326a656, 0x1335bcef, 0x1997b21b,
+	0x1993ec04, 0x133ac2fc, 0x1349d0b0, 0x198893d6, 0x1984c9ce, 0x134ed3c5, 0x135dd88c, 0x197965d0,
+	0x197597da, 0x1362d8a6, 0x1371d476, 0x196a2815, 0x19665632, 0x1376d191, 0x1385c461, 0x195adaab,
+	0x195704df, 0x138abe7b, 0x1399a841, 0x194b7d9e, 0x1947a3eb, 0x139e9f56, 0x13ad800a, 0x193c10f7,
+	0x1938335e, 0x13b27417, 0x13c14bb0, 0x192c94bf, 0x1928b343, 0x13c63cb2, 0x13d50b26, 0x191d08ff,
+	0x191923a3, 0x13d9f91b, 0x13e8be60, 0x190d6dc1, 0x19098488, 0x13eda944, 0x13fc6553, 0x18fdc310,
+	0x18f9d5fa, 0x14014d23, 0x140ffff1, 0x18ee08f4, 0x18ea1805, 0x1414e4aa, 0x14238e2f, 0x18de3f77,
+	0x18da4ab2, 0x14286fce, 0x14371001, 0x18ce66a3, 0x18ca6e0a, 0x143bee83, 0x144a855b, 0x18be7e82,
+	0x18ba8217, 0x144f60bd, 0x145dee30, 0x18ae871e, 0x18aa86e3, 0x1462c670, 0x14714a76, 0x189e8080,
+	0x189a7c78, 0x14761f8f, 0x14849a1f, 0x188e6ab2, 0x188a62e0, 0x14896c0f, 0x1497dd20, 0x187e45be,
+	0x187a3a25, 0x149cabe4, 0x14ab136d, 0x186e11af, 0x186a0250, 0x14afdf03, 0x14be3cfa, 0x185dce8e,
+	0x1859bb6c, 0x14c3055e, 0x14d159bc, 0x184d7c65, 0x18496583, 0x14d61eeb, 0x14e469a6, 0x183d1b3e,
+	0x1839009e, 0x14e92b9e, 0x14f76cad, 0x182cab24, 0x18288cc8, 0x14fc2b6a, 0x150a62c6, 0x181c2c20,
+	0x18180a0c, 0x150f1e45, 0x151d4be3, 0x180b9e3d, 0x18077873, 0x15220422, 0x153027fb, 0x17fb0185,
+	0x17f6d807, 0x1534dcf6, 0x1542f700, 0x17ea5602, 0x17e628d3, 0x1547a8b5, 0x1555b8e8, 0x17d99bbe,
+	0x17d56ae0, 0x155a6754, 0x15686da7, 0x17c8d2c4, 0x17c49e3b, 0x156d18c7, 0x157b1532, 0x17b7fb1f,
+	0x17b3c2ec, 0x157fbd03, 0x158daf7c, 0x17a714d7, 0x17a2d8fe, 0x159253fb, 0x15a03c7a, 0x17961ff9,
+	0x1791e07b, 0x15a4dda5, 0x15b2bc22, 0x17851c8e, 0x1780d96f, 0x15b759f5, 0x15c52e67, 0x17740aa1,
+	0x176fc3e3, 0x15c9c8e0, 0x15d7933f, 0x1762ea3d, 0x175e9fe2, 0x15dc2a5a, 0x15e9ea9d, 0x1751bb6b,
+	0x174d6d77, 0x15ee7e58, 0x15fc3477, 0x17407e37, 0x173c2cac, 0x1600c4cf, 0x160e70c1, 0x172f32ab,
+	0x172add8c, 0x1612fdb3, 0x16209f70, 0x171dd8d2, 0x17198021, 0x162528fa, 0x1632c078, 0x170c70b7,
+	0x17081477, 0x16374697, 0x1644d3d0, 0x16fafa64, 0x16f69a97, 0x16495680, 0x1656d96a, 0x16e975e4,
+	0x16e5128e, 0x165b58aa, 0x1668d13e, 0x16d7e341, 0x16d37c65, 0x166d4d0a, 0x167abb3e, 0x16c64288,
 	0x16c1d827, 0x167f3394, 0x168c9760, 0x16b493c2, 0x16b025e0, 0x16910c3d, 0x169e659a, 0x16a2d6fb
 };
 
 const int twidTab512[8*6 + 32*6 + 128*6] = {
-	0x20000000, 0x00000000, 0x1d906bcf, 0x0c3ef153, 0x16a09e66, 0x16a09e66, 0x0c3ef153, 0x1d906bcf, 
-	0x20000000, 0x00000000, 0x1f6297d0, 0x063e2e0f, 0x1d906bcf, 0x0c3ef153, 0x1a9b6629, 0x11c73b3a, 
-	0x20000000, 0x00000000, 0x1a9b6629, 0x11c73b3a, 0x0c3ef153, 0x1d906bcf, 0xf9c1d1f1, 0x1f6297d0, 
-	0x00000000, 0x20000000, 0xf3c10ead, 0x1d906bcf, 0xe95f619a, 0x16a09e66, 0xe26f9431, 0x0c3ef153, 
-	0x16a09e66, 0x16a09e66, 0x11c73b3a, 0x1a9b6629, 0x0c3ef153, 0x1d906bcf, 0x063e2e0f, 0x1f6297d0, 
-	0xe95f619a, 0x16a09e66, 0xe09d6830, 0x063e2e0f, 0xe26f9431, 0xf3c10ead, 0xee38c4c6, 0xe56499d7, 
+	0x20000000, 0x00000000, 0x1d906bcf, 0x0c3ef153, 0x16a09e66, 0x16a09e66, 0x0c3ef153, 0x1d906bcf,
+	0x20000000, 0x00000000, 0x1f6297d0, 0x063e2e0f, 0x1d906bcf, 0x0c3ef153, 0x1a9b6629, 0x11c73b3a,
+	0x20000000, 0x00000000, 0x1a9b6629, 0x11c73b3a, 0x0c3ef153, 0x1d906bcf, 0xf9c1d1f1, 0x1f6297d0,
+	0x00000000, 0x20000000, 0xf3c10ead, 0x1d906bcf, 0xe95f619a, 0x16a09e66, 0xe26f9431, 0x0c3ef153,
+	0x16a09e66, 0x16a09e66, 0x11c73b3a, 0x1a9b6629, 0x0c3ef153, 0x1d906bcf, 0x063e2e0f, 0x1f6297d0,
+	0xe95f619a, 0x16a09e66, 0xe09d6830, 0x063e2e0f, 0xe26f9431, 0xf3c10ead, 0xee38c4c6, 0xe56499d7,
 
-	0x20000000, 0x00000000, 0x1fd88da4, 0x0322f4d8, 0x1f6297d0, 0x063e2e0f, 0x1e9f4157, 0x094a0317, 
-	0x20000000, 0x00000000, 0x1ff621e3, 0x0191f65f, 0x1fd88da4, 0x0322f4d8, 0x1fa7557f, 0x04b2041c, 
-	0x20000000, 0x00000000, 0x1fa7557f, 0x04b2041c, 0x1e9f4157, 0x094a0317, 0x1ced7af4, 0x0dae8805, 
-	0x1d906bcf, 0x0c3ef153, 0x1c38b2f2, 0x0f15ae9c, 0x1a9b6629, 0x11c73b3a, 0x18bc806b, 0x144cf325, 
-	0x1f6297d0, 0x063e2e0f, 0x1f0a7efc, 0x07c67e5f, 0x1e9f4157, 0x094a0317, 0x1e212105, 0x0ac7cd3b, 
-	0x1a9b6629, 0x11c73b3a, 0x17b5df22, 0x157d6935, 0x144cf325, 0x18bc806b, 0x10738799, 0x1b728345, 
-	0x16a09e66, 0x16a09e66, 0x144cf325, 0x18bc806b, 0x11c73b3a, 0x1a9b6629, 0x0f15ae9c, 0x1c38b2f2, 
-	0x1d906bcf, 0x0c3ef153, 0x1ced7af4, 0x0dae8805, 0x1c38b2f2, 0x0f15ae9c, 0x1b728345, 0x10738799, 
-	0x0c3ef153, 0x1d906bcf, 0x07c67e5f, 0x1f0a7efc, 0x0322f4d8, 0x1fd88da4, 0xfe6e09a1, 0x1ff621e3, 
-	0x0c3ef153, 0x1d906bcf, 0x094a0317, 0x1e9f4157, 0x063e2e0f, 0x1f6297d0, 0x0322f4d8, 0x1fd88da4, 
-	0x1a9b6629, 0x11c73b3a, 0x19b3e048, 0x130ff7fd, 0x18bc806b, 0x144cf325, 0x17b5df22, 0x157d6935, 
-	0xf9c1d1f1, 0x1f6297d0, 0xf53832c5, 0x1e212105, 0xf0ea5164, 0x1c38b2f2, 0xecf00803, 0x19b3e048, 
-	0x00000000, 0x20000000, 0xfcdd0b28, 0x1fd88da4, 0xf9c1d1f1, 0x1f6297d0, 0xf6b5fce9, 0x1e9f4157, 
-	0x16a09e66, 0x16a09e66, 0x157d6935, 0x17b5df22, 0x144cf325, 0x18bc806b, 0x130ff7fd, 0x19b3e048, 
-	0xe95f619a, 0x16a09e66, 0xe64c1fb8, 0x130ff7fd, 0xe3c74d0e, 0x0f15ae9c, 0xe1dedefb, 0x0ac7cd3b, 
-	0xf3c10ead, 0x1d906bcf, 0xf0ea5164, 0x1c38b2f2, 0xee38c4c6, 0x1a9b6629, 0xebb30cdb, 0x18bc806b, 
-	0x11c73b3a, 0x1a9b6629, 0x10738799, 0x1b728345, 0x0f15ae9c, 0x1c38b2f2, 0x0dae8805, 0x1ced7af4, 
-	0xe09d6830, 0x063e2e0f, 0xe009de1d, 0x0191f65f, 0xe027725c, 0xfcdd0b28, 0xe0f58104, 0xf83981a1, 
-	0xe95f619a, 0x16a09e66, 0xe7437f95, 0x144cf325, 0xe56499d7, 0x11c73b3a, 0xe3c74d0e, 0x0f15ae9c, 
-	0x0c3ef153, 0x1d906bcf, 0x0ac7cd3b, 0x1e212105, 0x094a0317, 0x1e9f4157, 0x07c67e5f, 0x1f0a7efc, 
-	0xe26f9431, 0xf3c10ead, 0xe48d7cbb, 0xef8c7867, 0xe7437f95, 0xebb30cdb, 0xea8296cb, 0xe84a20de, 
-	0xe26f9431, 0x0c3ef153, 0xe160bea9, 0x094a0317, 0xe09d6830, 0x063e2e0f, 0xe027725c, 0x0322f4d8, 
-	0x063e2e0f, 0x1f6297d0, 0x04b2041c, 0x1fa7557f, 0x0322f4d8, 0x1fd88da4, 0x0191f65f, 0x1ff621e3, 
-	0xee38c4c6, 0xe56499d7, 0xf25177fb, 0xe312850c, 0xf6b5fce9, 0xe160bea9, 0xfb4dfbe4, 0xe058aa81, 
+	0x20000000, 0x00000000, 0x1fd88da4, 0x0322f4d8, 0x1f6297d0, 0x063e2e0f, 0x1e9f4157, 0x094a0317,
+	0x20000000, 0x00000000, 0x1ff621e3, 0x0191f65f, 0x1fd88da4, 0x0322f4d8, 0x1fa7557f, 0x04b2041c,
+	0x20000000, 0x00000000, 0x1fa7557f, 0x04b2041c, 0x1e9f4157, 0x094a0317, 0x1ced7af4, 0x0dae8805,
+	0x1d906bcf, 0x0c3ef153, 0x1c38b2f2, 0x0f15ae9c, 0x1a9b6629, 0x11c73b3a, 0x18bc806b, 0x144cf325,
+	0x1f6297d0, 0x063e2e0f, 0x1f0a7efc, 0x07c67e5f, 0x1e9f4157, 0x094a0317, 0x1e212105, 0x0ac7cd3b,
+	0x1a9b6629, 0x11c73b3a, 0x17b5df22, 0x157d6935, 0x144cf325, 0x18bc806b, 0x10738799, 0x1b728345,
+	0x16a09e66, 0x16a09e66, 0x144cf325, 0x18bc806b, 0x11c73b3a, 0x1a9b6629, 0x0f15ae9c, 0x1c38b2f2,
+	0x1d906bcf, 0x0c3ef153, 0x1ced7af4, 0x0dae8805, 0x1c38b2f2, 0x0f15ae9c, 0x1b728345, 0x10738799,
+	0x0c3ef153, 0x1d906bcf, 0x07c67e5f, 0x1f0a7efc, 0x0322f4d8, 0x1fd88da4, 0xfe6e09a1, 0x1ff621e3,
+	0x0c3ef153, 0x1d906bcf, 0x094a0317, 0x1e9f4157, 0x063e2e0f, 0x1f6297d0, 0x0322f4d8, 0x1fd88da4,
+	0x1a9b6629, 0x11c73b3a, 0x19b3e048, 0x130ff7fd, 0x18bc806b, 0x144cf325, 0x17b5df22, 0x157d6935,
+	0xf9c1d1f1, 0x1f6297d0, 0xf53832c5, 0x1e212105, 0xf0ea5164, 0x1c38b2f2, 0xecf00803, 0x19b3e048,
+	0x00000000, 0x20000000, 0xfcdd0b28, 0x1fd88da4, 0xf9c1d1f1, 0x1f6297d0, 0xf6b5fce9, 0x1e9f4157,
+	0x16a09e66, 0x16a09e66, 0x157d6935, 0x17b5df22, 0x144cf325, 0x18bc806b, 0x130ff7fd, 0x19b3e048,
+	0xe95f619a, 0x16a09e66, 0xe64c1fb8, 0x130ff7fd, 0xe3c74d0e, 0x0f15ae9c, 0xe1dedefb, 0x0ac7cd3b,
+	0xf3c10ead, 0x1d906bcf, 0xf0ea5164, 0x1c38b2f2, 0xee38c4c6, 0x1a9b6629, 0xebb30cdb, 0x18bc806b,
+	0x11c73b3a, 0x1a9b6629, 0x10738799, 0x1b728345, 0x0f15ae9c, 0x1c38b2f2, 0x0dae8805, 0x1ced7af4,
+	0xe09d6830, 0x063e2e0f, 0xe009de1d, 0x0191f65f, 0xe027725c, 0xfcdd0b28, 0xe0f58104, 0xf83981a1,
+	0xe95f619a, 0x16a09e66, 0xe7437f95, 0x144cf325, 0xe56499d7, 0x11c73b3a, 0xe3c74d0e, 0x0f15ae9c,
+	0x0c3ef153, 0x1d906bcf, 0x0ac7cd3b, 0x1e212105, 0x094a0317, 0x1e9f4157, 0x07c67e5f, 0x1f0a7efc,
+	0xe26f9431, 0xf3c10ead, 0xe48d7cbb, 0xef8c7867, 0xe7437f95, 0xebb30cdb, 0xea8296cb, 0xe84a20de,
+	0xe26f9431, 0x0c3ef153, 0xe160bea9, 0x094a0317, 0xe09d6830, 0x063e2e0f, 0xe027725c, 0x0322f4d8,
+	0x063e2e0f, 0x1f6297d0, 0x04b2041c, 0x1fa7557f, 0x0322f4d8, 0x1fd88da4, 0x0191f65f, 0x1ff621e3,
+	0xee38c4c6, 0xe56499d7, 0xf25177fb, 0xe312850c, 0xf6b5fce9, 0xe160bea9, 0xfb4dfbe4, 0xe058aa81,
 
-	0x20000000, 0x00000000, 0x1ffd8861, 0x00c90ab0, 0x1ff621e3, 0x0191f65f, 0x1fe9cdad, 0x025aa412, 
-	0x20000000, 0x00000000, 0x1fff6217, 0x00648748, 0x1ffd8861, 0x00c90ab0, 0x1ffa72f0, 0x012d8657, 
-	0x20000000, 0x00000000, 0x1ffa72f0, 0x012d8657, 0x1fe9cdad, 0x025aa412, 0x1fce15fd, 0x0386f0b9, 
-	0x1fd88da4, 0x0322f4d8, 0x1fc26471, 0x03eac9cb, 0x1fa7557f, 0x04b2041c, 0x1f8764fa, 0x05788511, 
-	0x1ff621e3, 0x0191f65f, 0x1ff09566, 0x01f656e8, 0x1fe9cdad, 0x025aa412, 0x1fe1cafd, 0x02beda01, 
-	0x1fa7557f, 0x04b2041c, 0x1f7599a4, 0x05db7678, 0x1f38f3ac, 0x0702e09b, 0x1ef178a4, 0x0827dc07, 
-	0x1f6297d0, 0x063e2e0f, 0x1f38f3ac, 0x0702e09b, 0x1f0a7efc, 0x07c67e5f, 0x1ed740e7, 0x0888e931, 
-	0x1fd88da4, 0x0322f4d8, 0x1fce15fd, 0x0386f0b9, 0x1fc26471, 0x03eac9cb, 0x1fb57972, 0x044e7c34, 
-	0x1e9f4157, 0x094a0317, 0x1e426a4b, 0x0a68f121, 0x1ddb13b7, 0x0b844298, 0x1d696174, 0x0c9b9532, 
-	0x1e9f4157, 0x094a0317, 0x1e6288ec, 0x0a09ae4a, 0x1e212105, 0x0ac7cd3b, 0x1ddb13b7, 0x0b844298, 
-	0x1fa7557f, 0x04b2041c, 0x1f97f925, 0x05155dac, 0x1f8764fa, 0x05788511, 0x1f7599a4, 0x05db7678, 
-	0x1ced7af4, 0x0dae8805, 0x1c678b35, 0x0ebcbbae, 0x1bd7c0ac, 0x0fc5d26e, 0x1b3e4d3f, 0x10c9704d, 
-	0x1d906bcf, 0x0c3ef153, 0x1d4134d1, 0x0cf7bca2, 0x1ced7af4, 0x0dae8805, 0x1c954b21, 0x0e63374d, 
-	0x1f6297d0, 0x063e2e0f, 0x1f4e603b, 0x06a0a809, 0x1f38f3ac, 0x0702e09b, 0x1f2252f7, 0x0764d3f9, 
-	0x1a9b6629, 0x11c73b3a, 0x19ef43ef, 0x12bedb26, 0x193a224a, 0x13affa29, 0x187c4010, 0x149a449c, 
-	0x1c38b2f2, 0x0f15ae9c, 0x1bd7c0ac, 0x0fc5d26e, 0x1b728345, 0x10738799, 0x1b090a58, 0x111eb354, 
-	0x1f0a7efc, 0x07c67e5f, 0x1ef178a4, 0x0827dc07, 0x1ed740e7, 0x0888e931, 0x1ebbd8c9, 0x08e9a220, 
-	0x17b5df22, 0x157d6935, 0x16e74455, 0x16591926, 0x1610b755, 0x172d0838, 0x15328293, 0x17f8ece3, 
-	0x1a9b6629, 0x11c73b3a, 0x1a29a7a0, 0x126d054d, 0x19b3e048, 0x130ff7fd, 0x193a224a, 0x13affa29, 
-	0x1e9f4157, 0x094a0317, 0x1e817bab, 0x09aa0861, 0x1e6288ec, 0x0a09ae4a, 0x1e426a4b, 0x0a68f121, 
-	0x144cf325, 0x18bc806b, 0x136058b1, 0x19777ef5, 0x126d054d, 0x1a29a7a0, 0x11734d64, 0x1ad2bc9e, 
-	0x18bc806b, 0x144cf325, 0x183b0e0c, 0x14e6cabc, 0x17b5df22, 0x157d6935, 0x172d0838, 0x1610b755, 
-	0x1e212105, 0x0ac7cd3b, 0x1dfeae62, 0x0b263eef, 0x1ddb13b7, 0x0b844298, 0x1db65262, 0x0be1d499, 
-	0x10738799, 0x1b728345, 0x0f6e0ca9, 0x1c08c426, 0x0e63374d, 0x1c954b21, 0x0d536416, 0x1d17e774, 
-	0x16a09e66, 0x16a09e66, 0x1610b755, 0x172d0838, 0x157d6935, 0x17b5df22, 0x14e6cabc, 0x183b0e0c, 
-	0x1d906bcf, 0x0c3ef153, 0x1d696174, 0x0c9b9532, 0x1d4134d1, 0x0cf7bca2, 0x1d17e774, 0x0d536416, 
-	0x0c3ef153, 0x1d906bcf, 0x0b263eef, 0x1dfeae62, 0x0a09ae4a, 0x1e6288ec, 0x08e9a220, 0x1ebbd8c9, 
-	0x144cf325, 0x18bc806b, 0x13affa29, 0x193a224a, 0x130ff7fd, 0x19b3e048, 0x126d054d, 0x1a29a7a0, 
-	0x1ced7af4, 0x0dae8805, 0x1cc1f0f4, 0x0e0924ec, 0x1c954b21, 0x0e63374d, 0x1c678b35, 0x0ebcbbae, 
-	0x07c67e5f, 0x1f0a7efc, 0x06a0a809, 0x1f4e603b, 0x05788511, 0x1f8764fa, 0x044e7c34, 0x1fb57972, 
-	0x11c73b3a, 0x1a9b6629, 0x111eb354, 0x1b090a58, 0x10738799, 0x1b728345, 0x0fc5d26e, 0x1bd7c0ac, 
-	0x1c38b2f2, 0x0f15ae9c, 0x1c08c426, 0x0f6e0ca9, 0x1bd7c0ac, 0x0fc5d26e, 0x1ba5aa67, 0x101cfc87, 
-	0x0322f4d8, 0x1fd88da4, 0x01f656e8, 0x1ff09566, 0x00c90ab0, 0x1ffd8861, 0xff9b78b8, 0x1fff6217, 
-	0x0f15ae9c, 0x1c38b2f2, 0x0e63374d, 0x1c954b21, 0x0dae8805, 0x1ced7af4, 0x0cf7bca2, 0x1d4134d1, 
-	0x1b728345, 0x10738799, 0x1b3e4d3f, 0x10c9704d, 0x1b090a58, 0x111eb354, 0x1ad2bc9e, 0x11734d64, 
-	0xfe6e09a1, 0x1ff621e3, 0xfd4125ff, 0x1fe1cafd, 0xfc153635, 0x1fc26471, 0xfaeaa254, 0x1f97f925, 
-	0x0c3ef153, 0x1d906bcf, 0x0b844298, 0x1ddb13b7, 0x0ac7cd3b, 0x1e212105, 0x0a09ae4a, 0x1e6288ec, 
-	0x1a9b6629, 0x11c73b3a, 0x1a63091b, 0x121a7999, 0x1a29a7a0, 0x126d054d, 0x19ef43ef, 0x12bedb26, 
-	0xf9c1d1f1, 0x1f6297d0, 0xf89b2c07, 0x1f2252f7, 0xf77716cf, 0x1ed740e7, 0xf655f79f, 0x1e817bab, 
-	0x094a0317, 0x1e9f4157, 0x0888e931, 0x1ed740e7, 0x07c67e5f, 0x1f0a7efc, 0x0702e09b, 0x1f38f3ac, 
-	0x19b3e048, 0x130ff7fd, 0x19777ef5, 0x136058b1, 0x193a224a, 0x13affa29, 0x18fbcca4, 0x13fed953, 
-	0xf53832c5, 0x1e212105, 0xf41e2b67, 0x1db65262, 0xf308435e, 0x1d4134d1, 0xf1f6db14, 0x1cc1f0f4, 
-	0x063e2e0f, 0x1f6297d0, 0x05788511, 0x1f8764fa, 0x04b2041c, 0x1fa7557f, 0x03eac9cb, 0x1fc26471, 
-	0x18bc806b, 0x144cf325, 0x187c4010, 0x149a449c, 0x183b0e0c, 0x14e6cabc, 0x17f8ece3, 0x15328293, 
-	0xf0ea5164, 0x1c38b2f2, 0xefe30379, 0x1ba5aa67, 0xeee14cac, 0x1b090a58, 0xede58667, 0x1a63091b, 
-	0x0322f4d8, 0x1fd88da4, 0x025aa412, 0x1fe9cdad, 0x0191f65f, 0x1ff621e3, 0x00c90ab0, 0x1ffd8861, 
-	0x17b5df22, 0x157d6935, 0x1771e75f, 0x15c77bbe, 0x172d0838, 0x1610b755, 0x16e74455, 0x16591926, 
-	0xecf00803, 0x19b3e048, 0xec0126ad, 0x18fbcca4, 0xeb193544, 0x183b0e0c, 0xea388442, 0x1771e75f, 
-	0x00000000, 0x20000000, 0xff36f550, 0x1ffd8861, 0xfe6e09a1, 0x1ff621e3, 0xfda55bee, 0x1fe9cdad, 
-	0x16a09e66, 0x16a09e66, 0x16591926, 0x16e74455, 0x1610b755, 0x172d0838, 0x15c77bbe, 0x1771e75f, 
-	0xe95f619a, 0x16a09e66, 0xe88e18a1, 0x15c77bbe, 0xe7c4f1f4, 0x14e6cabc, 0xe704335c, 0x13fed953, 
-	0xfcdd0b28, 0x1fd88da4, 0xfc153635, 0x1fc26471, 0xfb4dfbe4, 0x1fa7557f, 0xfa877aef, 0x1f8764fa, 
-	0x157d6935, 0x17b5df22, 0x15328293, 0x17f8ece3, 0x14e6cabc, 0x183b0e0c, 0x149a449c, 0x187c4010, 
-	0xe64c1fb8, 0x130ff7fd, 0xe59cf6e5, 0x121a7999, 0xe4f6f5a8, 0x111eb354, 0xe45a5599, 0x101cfc87, 
-	0xf9c1d1f1, 0x1f6297d0, 0xf8fd1f65, 0x1f38f3ac, 0xf83981a1, 0x1f0a7efc, 0xf77716cf, 0x1ed740e7, 
-	0x144cf325, 0x18bc806b, 0x13fed953, 0x18fbcca4, 0x13affa29, 0x193a224a, 0x136058b1, 0x19777ef5, 
-	0xe3c74d0e, 0x0f15ae9c, 0xe33e0f0c, 0x0e0924ec, 0xe2becb2f, 0x0cf7bca2, 0xe249ad9e, 0x0be1d499, 
-	0xf6b5fce9, 0x1e9f4157, 0xf5f651b6, 0x1e6288ec, 0xf53832c5, 0x1e212105, 0xf47bbd68, 0x1ddb13b7, 
-	0x130ff7fd, 0x19b3e048, 0x12bedb26, 0x19ef43ef, 0x126d054d, 0x1a29a7a0, 0x121a7999, 0x1a63091b, 
-	0xe1dedefb, 0x0ac7cd3b, 0xe17e8455, 0x09aa0861, 0xe128bf19, 0x0888e931, 0xe0ddad09, 0x0764d3f9, 
-	0xf3c10ead, 0x1d906bcf, 0xf308435e, 0x1d4134d1, 0xf25177fb, 0x1ced7af4, 0xf19cc8b3, 0x1c954b21, 
-	0x11c73b3a, 0x1a9b6629, 0x11734d64, 0x1ad2bc9e, 0x111eb354, 0x1b090a58, 0x10c9704d, 0x1b3e4d3f, 
-	0xe09d6830, 0x063e2e0f, 0xe06806db, 0x05155dac, 0xe03d9b8f, 0x03eac9cb, 0xe01e3503, 0x02beda01, 
-	0xf0ea5164, 0x1c38b2f2, 0xf03a2d92, 0x1bd7c0ac, 0xef8c7867, 0x1b728345, 0xeee14cac, 0x1b090a58, 
-	0x10738799, 0x1b728345, 0x101cfc87, 0x1ba5aa67, 0x0fc5d26e, 0x1bd7c0ac, 0x0f6e0ca9, 0x1c08c426, 
-	0xe009de1d, 0x0191f65f, 0xe0009de9, 0x00648748, 0xe002779f, 0xff36f550, 0xe00f6a9a, 0xfe09a918, 
-	0xee38c4c6, 0x1a9b6629, 0xed92fab3, 0x1a29a7a0, 0xecf00803, 0x19b3e048, 0xec5005d7, 0x193a224a, 
-	0x0f15ae9c, 0x1c38b2f2, 0x0ebcbbae, 0x1c678b35, 0x0e63374d, 0x1c954b21, 0x0e0924ec, 0x1cc1f0f4, 
-	0xe027725c, 0xfcdd0b28, 0xe04a868e, 0xfbb183cc, 0xe0789b06, 0xfa877aef, 0xe0b19fc5, 0xf95f57f7, 
-	0xebb30cdb, 0x18bc806b, 0xeb193544, 0x183b0e0c, 0xea8296cb, 0x17b5df22, 0xe9ef48ab, 0x172d0838, 
-	0x0dae8805, 0x1ced7af4, 0x0d536416, 0x1d17e774, 0x0cf7bca2, 0x1d4134d1, 0x0c9b9532, 0x1d696174, 
-	0xe0f58104, 0xf83981a1, 0xe1442737, 0xf7165de0, 0xe19d7714, 0xf5f651b6, 0xe201519e, 0xf4d9c111, 
-	0xe95f619a, 0x16a09e66, 0xe8d2f7c8, 0x1610b755, 0xe84a20de, 0x157d6935, 0xe7c4f1f4, 0x14e6cabc, 
-	0x0c3ef153, 0x1d906bcf, 0x0be1d499, 0x1db65262, 0x0b844298, 0x1ddb13b7, 0x0b263eef, 0x1dfeae62, 
-	0xe26f9431, 0xf3c10ead, 0xe2e8188c, 0xf2ac9bea, 0xe36ab4df, 0xf19cc8b3, 0xe3f73bda, 0xf091f357, 
-	0xe7437f95, 0x144cf325, 0xe6c5ddb6, 0x13affa29, 0xe64c1fb8, 0x130ff7fd, 0xe5d65860, 0x126d054d, 
-	0x0ac7cd3b, 0x1e212105, 0x0a68f121, 0x1e426a4b, 0x0a09ae4a, 0x1e6288ec, 0x09aa0861, 0x1e817bab, 
-	0xe48d7cbb, 0xef8c7867, 0xe52d4362, 0xee8cb29c, 0xe5d65860, 0xed92fab3, 0xe688810b, 0xec9fa74f, 
-	0xe56499d7, 0x11c73b3a, 0xe4f6f5a8, 0x111eb354, 0xe48d7cbb, 0x10738799, 0xe4283f54, 0x0fc5d26e, 
-	0x094a0317, 0x1e9f4157, 0x08e9a220, 0x1ebbd8c9, 0x0888e931, 0x1ed740e7, 0x0827dc07, 0x1ef178a4, 
-	0xe7437f95, 0xebb30cdb, 0xe807131d, 0xeacd7d6d, 0xe8d2f7c8, 0xe9ef48ab, 0xe9a6e6da, 0xe918bbab, 
-	0xe3c74d0e, 0x0f15ae9c, 0xe36ab4df, 0x0e63374d, 0xe312850c, 0x0dae8805, 0xe2becb2f, 0x0cf7bca2, 
-	0x07c67e5f, 0x1f0a7efc, 0x0764d3f9, 0x1f2252f7, 0x0702e09b, 0x1f38f3ac, 0x06a0a809, 0x1f4e603b, 
-	0xea8296cb, 0xe84a20de, 0xeb65bb64, 0xe783bff0, 0xec5005d7, 0xe6c5ddb6, 0xed4124da, 0xe610bc11, 
-	0xe26f9431, 0x0c3ef153, 0xe224ec49, 0x0b844298, 0xe1dedefb, 0x0ac7cd3b, 0xe19d7714, 0x0a09ae4a, 
-	0x063e2e0f, 0x1f6297d0, 0x05db7678, 0x1f7599a4, 0x05788511, 0x1f8764fa, 0x05155dac, 0x1f97f925, 
-	0xee38c4c6, 0xe56499d7, 0xef368fb3, 0xe4c1b2c1, 0xf03a2d92, 0xe4283f54, 0xf1434452, 0xe39874cb, 
-	0xe160bea9, 0x094a0317, 0xe128bf19, 0x0888e931, 0xe0f58104, 0x07c67e5f, 0xe0c70c54, 0x0702e09b, 
-	0x04b2041c, 0x1fa7557f, 0x044e7c34, 0x1fb57972, 0x03eac9cb, 0x1fc26471, 0x0386f0b9, 0x1fce15fd, 
-	0xf25177fb, 0xe312850c, 0xf3646ace, 0xe2969e8c, 0xf47bbd68, 0xe224ec49, 0xf5970edf, 0xe1bd95b5, 
-	0xe09d6830, 0x063e2e0f, 0xe0789b06, 0x05788511, 0xe058aa81, 0x04b2041c, 0xe03d9b8f, 0x03eac9cb, 
-	0x0322f4d8, 0x1fd88da4, 0x02beda01, 0x1fe1cafd, 0x025aa412, 0x1fe9cdad, 0x01f656e8, 0x1ff09566, 
-	0xf6b5fce9, 0xe160bea9, 0xf7d823f9, 0xe10e875c, 0xf8fd1f65, 0xe0c70c54, 0xfa248988, 0xe08a665c, 
-	0xe027725c, 0x0322f4d8, 0xe0163253, 0x025aa412, 0xe009de1d, 0x0191f65f, 0xe002779f, 0x00c90ab0, 
-	0x0191f65f, 0x1ff621e3, 0x012d8657, 0x1ffa72f0, 0x00c90ab0, 0x1ffd8861, 0x00648748, 0x1fff6217, 
+	0x20000000, 0x00000000, 0x1ffd8861, 0x00c90ab0, 0x1ff621e3, 0x0191f65f, 0x1fe9cdad, 0x025aa412,
+	0x20000000, 0x00000000, 0x1fff6217, 0x00648748, 0x1ffd8861, 0x00c90ab0, 0x1ffa72f0, 0x012d8657,
+	0x20000000, 0x00000000, 0x1ffa72f0, 0x012d8657, 0x1fe9cdad, 0x025aa412, 0x1fce15fd, 0x0386f0b9,
+	0x1fd88da4, 0x0322f4d8, 0x1fc26471, 0x03eac9cb, 0x1fa7557f, 0x04b2041c, 0x1f8764fa, 0x05788511,
+	0x1ff621e3, 0x0191f65f, 0x1ff09566, 0x01f656e8, 0x1fe9cdad, 0x025aa412, 0x1fe1cafd, 0x02beda01,
+	0x1fa7557f, 0x04b2041c, 0x1f7599a4, 0x05db7678, 0x1f38f3ac, 0x0702e09b, 0x1ef178a4, 0x0827dc07,
+	0x1f6297d0, 0x063e2e0f, 0x1f38f3ac, 0x0702e09b, 0x1f0a7efc, 0x07c67e5f, 0x1ed740e7, 0x0888e931,
+	0x1fd88da4, 0x0322f4d8, 0x1fce15fd, 0x0386f0b9, 0x1fc26471, 0x03eac9cb, 0x1fb57972, 0x044e7c34,
+	0x1e9f4157, 0x094a0317, 0x1e426a4b, 0x0a68f121, 0x1ddb13b7, 0x0b844298, 0x1d696174, 0x0c9b9532,
+	0x1e9f4157, 0x094a0317, 0x1e6288ec, 0x0a09ae4a, 0x1e212105, 0x0ac7cd3b, 0x1ddb13b7, 0x0b844298,
+	0x1fa7557f, 0x04b2041c, 0x1f97f925, 0x05155dac, 0x1f8764fa, 0x05788511, 0x1f7599a4, 0x05db7678,
+	0x1ced7af4, 0x0dae8805, 0x1c678b35, 0x0ebcbbae, 0x1bd7c0ac, 0x0fc5d26e, 0x1b3e4d3f, 0x10c9704d,
+	0x1d906bcf, 0x0c3ef153, 0x1d4134d1, 0x0cf7bca2, 0x1ced7af4, 0x0dae8805, 0x1c954b21, 0x0e63374d,
+	0x1f6297d0, 0x063e2e0f, 0x1f4e603b, 0x06a0a809, 0x1f38f3ac, 0x0702e09b, 0x1f2252f7, 0x0764d3f9,
+	0x1a9b6629, 0x11c73b3a, 0x19ef43ef, 0x12bedb26, 0x193a224a, 0x13affa29, 0x187c4010, 0x149a449c,
+	0x1c38b2f2, 0x0f15ae9c, 0x1bd7c0ac, 0x0fc5d26e, 0x1b728345, 0x10738799, 0x1b090a58, 0x111eb354,
+	0x1f0a7efc, 0x07c67e5f, 0x1ef178a4, 0x0827dc07, 0x1ed740e7, 0x0888e931, 0x1ebbd8c9, 0x08e9a220,
+	0x17b5df22, 0x157d6935, 0x16e74455, 0x16591926, 0x1610b755, 0x172d0838, 0x15328293, 0x17f8ece3,
+	0x1a9b6629, 0x11c73b3a, 0x1a29a7a0, 0x126d054d, 0x19b3e048, 0x130ff7fd, 0x193a224a, 0x13affa29,
+	0x1e9f4157, 0x094a0317, 0x1e817bab, 0x09aa0861, 0x1e6288ec, 0x0a09ae4a, 0x1e426a4b, 0x0a68f121,
+	0x144cf325, 0x18bc806b, 0x136058b1, 0x19777ef5, 0x126d054d, 0x1a29a7a0, 0x11734d64, 0x1ad2bc9e,
+	0x18bc806b, 0x144cf325, 0x183b0e0c, 0x14e6cabc, 0x17b5df22, 0x157d6935, 0x172d0838, 0x1610b755,
+	0x1e212105, 0x0ac7cd3b, 0x1dfeae62, 0x0b263eef, 0x1ddb13b7, 0x0b844298, 0x1db65262, 0x0be1d499,
+	0x10738799, 0x1b728345, 0x0f6e0ca9, 0x1c08c426, 0x0e63374d, 0x1c954b21, 0x0d536416, 0x1d17e774,
+	0x16a09e66, 0x16a09e66, 0x1610b755, 0x172d0838, 0x157d6935, 0x17b5df22, 0x14e6cabc, 0x183b0e0c,
+	0x1d906bcf, 0x0c3ef153, 0x1d696174, 0x0c9b9532, 0x1d4134d1, 0x0cf7bca2, 0x1d17e774, 0x0d536416,
+	0x0c3ef153, 0x1d906bcf, 0x0b263eef, 0x1dfeae62, 0x0a09ae4a, 0x1e6288ec, 0x08e9a220, 0x1ebbd8c9,
+	0x144cf325, 0x18bc806b, 0x13affa29, 0x193a224a, 0x130ff7fd, 0x19b3e048, 0x126d054d, 0x1a29a7a0,
+	0x1ced7af4, 0x0dae8805, 0x1cc1f0f4, 0x0e0924ec, 0x1c954b21, 0x0e63374d, 0x1c678b35, 0x0ebcbbae,
+	0x07c67e5f, 0x1f0a7efc, 0x06a0a809, 0x1f4e603b, 0x05788511, 0x1f8764fa, 0x044e7c34, 0x1fb57972,
+	0x11c73b3a, 0x1a9b6629, 0x111eb354, 0x1b090a58, 0x10738799, 0x1b728345, 0x0fc5d26e, 0x1bd7c0ac,
+	0x1c38b2f2, 0x0f15ae9c, 0x1c08c426, 0x0f6e0ca9, 0x1bd7c0ac, 0x0fc5d26e, 0x1ba5aa67, 0x101cfc87,
+	0x0322f4d8, 0x1fd88da4, 0x01f656e8, 0x1ff09566, 0x00c90ab0, 0x1ffd8861, 0xff9b78b8, 0x1fff6217,
+	0x0f15ae9c, 0x1c38b2f2, 0x0e63374d, 0x1c954b21, 0x0dae8805, 0x1ced7af4, 0x0cf7bca2, 0x1d4134d1,
+	0x1b728345, 0x10738799, 0x1b3e4d3f, 0x10c9704d, 0x1b090a58, 0x111eb354, 0x1ad2bc9e, 0x11734d64,
+	0xfe6e09a1, 0x1ff621e3, 0xfd4125ff, 0x1fe1cafd, 0xfc153635, 0x1fc26471, 0xfaeaa254, 0x1f97f925,
+	0x0c3ef153, 0x1d906bcf, 0x0b844298, 0x1ddb13b7, 0x0ac7cd3b, 0x1e212105, 0x0a09ae4a, 0x1e6288ec,
+	0x1a9b6629, 0x11c73b3a, 0x1a63091b, 0x121a7999, 0x1a29a7a0, 0x126d054d, 0x19ef43ef, 0x12bedb26,
+	0xf9c1d1f1, 0x1f6297d0, 0xf89b2c07, 0x1f2252f7, 0xf77716cf, 0x1ed740e7, 0xf655f79f, 0x1e817bab,
+	0x094a0317, 0x1e9f4157, 0x0888e931, 0x1ed740e7, 0x07c67e5f, 0x1f0a7efc, 0x0702e09b, 0x1f38f3ac,
+	0x19b3e048, 0x130ff7fd, 0x19777ef5, 0x136058b1, 0x193a224a, 0x13affa29, 0x18fbcca4, 0x13fed953,
+	0xf53832c5, 0x1e212105, 0xf41e2b67, 0x1db65262, 0xf308435e, 0x1d4134d1, 0xf1f6db14, 0x1cc1f0f4,
+	0x063e2e0f, 0x1f6297d0, 0x05788511, 0x1f8764fa, 0x04b2041c, 0x1fa7557f, 0x03eac9cb, 0x1fc26471,
+	0x18bc806b, 0x144cf325, 0x187c4010, 0x149a449c, 0x183b0e0c, 0x14e6cabc, 0x17f8ece3, 0x15328293,
+	0xf0ea5164, 0x1c38b2f2, 0xefe30379, 0x1ba5aa67, 0xeee14cac, 0x1b090a58, 0xede58667, 0x1a63091b,
+	0x0322f4d8, 0x1fd88da4, 0x025aa412, 0x1fe9cdad, 0x0191f65f, 0x1ff621e3, 0x00c90ab0, 0x1ffd8861,
+	0x17b5df22, 0x157d6935, 0x1771e75f, 0x15c77bbe, 0x172d0838, 0x1610b755, 0x16e74455, 0x16591926,
+	0xecf00803, 0x19b3e048, 0xec0126ad, 0x18fbcca4, 0xeb193544, 0x183b0e0c, 0xea388442, 0x1771e75f,
+	0x00000000, 0x20000000, 0xff36f550, 0x1ffd8861, 0xfe6e09a1, 0x1ff621e3, 0xfda55bee, 0x1fe9cdad,
+	0x16a09e66, 0x16a09e66, 0x16591926, 0x16e74455, 0x1610b755, 0x172d0838, 0x15c77bbe, 0x1771e75f,
+	0xe95f619a, 0x16a09e66, 0xe88e18a1, 0x15c77bbe, 0xe7c4f1f4, 0x14e6cabc, 0xe704335c, 0x13fed953,
+	0xfcdd0b28, 0x1fd88da4, 0xfc153635, 0x1fc26471, 0xfb4dfbe4, 0x1fa7557f, 0xfa877aef, 0x1f8764fa,
+	0x157d6935, 0x17b5df22, 0x15328293, 0x17f8ece3, 0x14e6cabc, 0x183b0e0c, 0x149a449c, 0x187c4010,
+	0xe64c1fb8, 0x130ff7fd, 0xe59cf6e5, 0x121a7999, 0xe4f6f5a8, 0x111eb354, 0xe45a5599, 0x101cfc87,
+	0xf9c1d1f1, 0x1f6297d0, 0xf8fd1f65, 0x1f38f3ac, 0xf83981a1, 0x1f0a7efc, 0xf77716cf, 0x1ed740e7,
+	0x144cf325, 0x18bc806b, 0x13fed953, 0x18fbcca4, 0x13affa29, 0x193a224a, 0x136058b1, 0x19777ef5,
+	0xe3c74d0e, 0x0f15ae9c, 0xe33e0f0c, 0x0e0924ec, 0xe2becb2f, 0x0cf7bca2, 0xe249ad9e, 0x0be1d499,
+	0xf6b5fce9, 0x1e9f4157, 0xf5f651b6, 0x1e6288ec, 0xf53832c5, 0x1e212105, 0xf47bbd68, 0x1ddb13b7,
+	0x130ff7fd, 0x19b3e048, 0x12bedb26, 0x19ef43ef, 0x126d054d, 0x1a29a7a0, 0x121a7999, 0x1a63091b,
+	0xe1dedefb, 0x0ac7cd3b, 0xe17e8455, 0x09aa0861, 0xe128bf19, 0x0888e931, 0xe0ddad09, 0x0764d3f9,
+	0xf3c10ead, 0x1d906bcf, 0xf308435e, 0x1d4134d1, 0xf25177fb, 0x1ced7af4, 0xf19cc8b3, 0x1c954b21,
+	0x11c73b3a, 0x1a9b6629, 0x11734d64, 0x1ad2bc9e, 0x111eb354, 0x1b090a58, 0x10c9704d, 0x1b3e4d3f,
+	0xe09d6830, 0x063e2e0f, 0xe06806db, 0x05155dac, 0xe03d9b8f, 0x03eac9cb, 0xe01e3503, 0x02beda01,
+	0xf0ea5164, 0x1c38b2f2, 0xf03a2d92, 0x1bd7c0ac, 0xef8c7867, 0x1b728345, 0xeee14cac, 0x1b090a58,
+	0x10738799, 0x1b728345, 0x101cfc87, 0x1ba5aa67, 0x0fc5d26e, 0x1bd7c0ac, 0x0f6e0ca9, 0x1c08c426,
+	0xe009de1d, 0x0191f65f, 0xe0009de9, 0x00648748, 0xe002779f, 0xff36f550, 0xe00f6a9a, 0xfe09a918,
+	0xee38c4c6, 0x1a9b6629, 0xed92fab3, 0x1a29a7a0, 0xecf00803, 0x19b3e048, 0xec5005d7, 0x193a224a,
+	0x0f15ae9c, 0x1c38b2f2, 0x0ebcbbae, 0x1c678b35, 0x0e63374d, 0x1c954b21, 0x0e0924ec, 0x1cc1f0f4,
+	0xe027725c, 0xfcdd0b28, 0xe04a868e, 0xfbb183cc, 0xe0789b06, 0xfa877aef, 0xe0b19fc5, 0xf95f57f7,
+	0xebb30cdb, 0x18bc806b, 0xeb193544, 0x183b0e0c, 0xea8296cb, 0x17b5df22, 0xe9ef48ab, 0x172d0838,
+	0x0dae8805, 0x1ced7af4, 0x0d536416, 0x1d17e774, 0x0cf7bca2, 0x1d4134d1, 0x0c9b9532, 0x1d696174,
+	0xe0f58104, 0xf83981a1, 0xe1442737, 0xf7165de0, 0xe19d7714, 0xf5f651b6, 0xe201519e, 0xf4d9c111,
+	0xe95f619a, 0x16a09e66, 0xe8d2f7c8, 0x1610b755, 0xe84a20de, 0x157d6935, 0xe7c4f1f4, 0x14e6cabc,
+	0x0c3ef153, 0x1d906bcf, 0x0be1d499, 0x1db65262, 0x0b844298, 0x1ddb13b7, 0x0b263eef, 0x1dfeae62,
+	0xe26f9431, 0xf3c10ead, 0xe2e8188c, 0xf2ac9bea, 0xe36ab4df, 0xf19cc8b3, 0xe3f73bda, 0xf091f357,
+	0xe7437f95, 0x144cf325, 0xe6c5ddb6, 0x13affa29, 0xe64c1fb8, 0x130ff7fd, 0xe5d65860, 0x126d054d,
+	0x0ac7cd3b, 0x1e212105, 0x0a68f121, 0x1e426a4b, 0x0a09ae4a, 0x1e6288ec, 0x09aa0861, 0x1e817bab,
+	0xe48d7cbb, 0xef8c7867, 0xe52d4362, 0xee8cb29c, 0xe5d65860, 0xed92fab3, 0xe688810b, 0xec9fa74f,
+	0xe56499d7, 0x11c73b3a, 0xe4f6f5a8, 0x111eb354, 0xe48d7cbb, 0x10738799, 0xe4283f54, 0x0fc5d26e,
+	0x094a0317, 0x1e9f4157, 0x08e9a220, 0x1ebbd8c9, 0x0888e931, 0x1ed740e7, 0x0827dc07, 0x1ef178a4,
+	0xe7437f95, 0xebb30cdb, 0xe807131d, 0xeacd7d6d, 0xe8d2f7c8, 0xe9ef48ab, 0xe9a6e6da, 0xe918bbab,
+	0xe3c74d0e, 0x0f15ae9c, 0xe36ab4df, 0x0e63374d, 0xe312850c, 0x0dae8805, 0xe2becb2f, 0x0cf7bca2,
+	0x07c67e5f, 0x1f0a7efc, 0x0764d3f9, 0x1f2252f7, 0x0702e09b, 0x1f38f3ac, 0x06a0a809, 0x1f4e603b,
+	0xea8296cb, 0xe84a20de, 0xeb65bb64, 0xe783bff0, 0xec5005d7, 0xe6c5ddb6, 0xed4124da, 0xe610bc11,
+	0xe26f9431, 0x0c3ef153, 0xe224ec49, 0x0b844298, 0xe1dedefb, 0x0ac7cd3b, 0xe19d7714, 0x0a09ae4a,
+	0x063e2e0f, 0x1f6297d0, 0x05db7678, 0x1f7599a4, 0x05788511, 0x1f8764fa, 0x05155dac, 0x1f97f925,
+	0xee38c4c6, 0xe56499d7, 0xef368fb3, 0xe4c1b2c1, 0xf03a2d92, 0xe4283f54, 0xf1434452, 0xe39874cb,
+	0xe160bea9, 0x094a0317, 0xe128bf19, 0x0888e931, 0xe0f58104, 0x07c67e5f, 0xe0c70c54, 0x0702e09b,
+	0x04b2041c, 0x1fa7557f, 0x044e7c34, 0x1fb57972, 0x03eac9cb, 0x1fc26471, 0x0386f0b9, 0x1fce15fd,
+	0xf25177fb, 0xe312850c, 0xf3646ace, 0xe2969e8c, 0xf47bbd68, 0xe224ec49, 0xf5970edf, 0xe1bd95b5,
+	0xe09d6830, 0x063e2e0f, 0xe0789b06, 0x05788511, 0xe058aa81, 0x04b2041c, 0xe03d9b8f, 0x03eac9cb,
+	0x0322f4d8, 0x1fd88da4, 0x02beda01, 0x1fe1cafd, 0x025aa412, 0x1fe9cdad, 0x01f656e8, 0x1ff09566,
+	0xf6b5fce9, 0xe160bea9, 0xf7d823f9, 0xe10e875c, 0xf8fd1f65, 0xe0c70c54, 0xfa248988, 0xe08a665c,
+	0xe027725c, 0x0322f4d8, 0xe0163253, 0x025aa412, 0xe009de1d, 0x0191f65f, 0xe002779f, 0x00c90ab0,
+	0x0191f65f, 0x1ff621e3, 0x012d8657, 0x1ffa72f0, 0x00c90ab0, 0x1ffd8861, 0x00648748, 0x1fff6217,
 	0xfb4dfbe4, 0xe058aa81, 0xfc790f47, 0xe031ea03, 0xfda55bee, 0xe0163253, 0xfed279a9, 0xe0058d10
 };
 
 const int twidTab64[4*6 + 16*6] = {
-	0x20000000, 0x00000000, 0x16a09e66, 0x16a09e66, 0x00000000, 0x20000000, 0xe95f619a, 0x16a09e66, 
-	0x20000000, 0x00000000, 0x1d906bcf, 0x0c3ef153, 0x16a09e66, 0x16a09e66, 0x0c3ef153, 0x1d906bcf, 
-	0x20000000, 0x00000000, 0x0c3ef153, 0x1d906bcf, 0xe95f619a, 0x16a09e66, 0xe26f9431, 0xf3c10ead, 
+	0x20000000, 0x00000000, 0x16a09e66, 0x16a09e66, 0x00000000, 0x20000000, 0xe95f619a, 0x16a09e66,
+	0x20000000, 0x00000000, 0x1d906bcf, 0x0c3ef153, 0x16a09e66, 0x16a09e66, 0x0c3ef153, 0x1d906bcf,
+	0x20000000, 0x00000000, 0x0c3ef153, 0x1d906bcf, 0xe95f619a, 0x16a09e66, 0xe26f9431, 0xf3c10ead,
 
-	0x20000000, 0x00000000, 0x1f6297d0, 0x063e2e0f, 0x1d906bcf, 0x0c3ef153, 0x1a9b6629, 0x11c73b3a, 
-	0x20000000, 0x00000000, 0x1fd88da4, 0x0322f4d8, 0x1f6297d0, 0x063e2e0f, 0x1e9f4157, 0x094a0317, 
-	0x20000000, 0x00000000, 0x1e9f4157, 0x094a0317, 0x1a9b6629, 0x11c73b3a, 0x144cf325, 0x18bc806b, 
-	0x16a09e66, 0x16a09e66, 0x11c73b3a, 0x1a9b6629, 0x0c3ef153, 0x1d906bcf, 0x063e2e0f, 0x1f6297d0, 
-	0x1d906bcf, 0x0c3ef153, 0x1c38b2f2, 0x0f15ae9c, 0x1a9b6629, 0x11c73b3a, 0x18bc806b, 0x144cf325, 
-	0x0c3ef153, 0x1d906bcf, 0x0322f4d8, 0x1fd88da4, 0xf9c1d1f1, 0x1f6297d0, 0xf0ea5164, 0x1c38b2f2, 
-	0x00000000, 0x20000000, 0xf9c1d1f1, 0x1f6297d0, 0xf3c10ead, 0x1d906bcf, 0xee38c4c6, 0x1a9b6629, 
-	0x16a09e66, 0x16a09e66, 0x144cf325, 0x18bc806b, 0x11c73b3a, 0x1a9b6629, 0x0f15ae9c, 0x1c38b2f2, 
-	0xe95f619a, 0x16a09e66, 0xe3c74d0e, 0x0f15ae9c, 0xe09d6830, 0x063e2e0f, 0xe027725c, 0xfcdd0b28, 
-	0xe95f619a, 0x16a09e66, 0xe56499d7, 0x11c73b3a, 0xe26f9431, 0x0c3ef153, 0xe09d6830, 0x063e2e0f, 
-	0x0c3ef153, 0x1d906bcf, 0x094a0317, 0x1e9f4157, 0x063e2e0f, 0x1f6297d0, 0x0322f4d8, 0x1fd88da4, 
+	0x20000000, 0x00000000, 0x1f6297d0, 0x063e2e0f, 0x1d906bcf, 0x0c3ef153, 0x1a9b6629, 0x11c73b3a,
+	0x20000000, 0x00000000, 0x1fd88da4, 0x0322f4d8, 0x1f6297d0, 0x063e2e0f, 0x1e9f4157, 0x094a0317,
+	0x20000000, 0x00000000, 0x1e9f4157, 0x094a0317, 0x1a9b6629, 0x11c73b3a, 0x144cf325, 0x18bc806b,
+	0x16a09e66, 0x16a09e66, 0x11c73b3a, 0x1a9b6629, 0x0c3ef153, 0x1d906bcf, 0x063e2e0f, 0x1f6297d0,
+	0x1d906bcf, 0x0c3ef153, 0x1c38b2f2, 0x0f15ae9c, 0x1a9b6629, 0x11c73b3a, 0x18bc806b, 0x144cf325,
+	0x0c3ef153, 0x1d906bcf, 0x0322f4d8, 0x1fd88da4, 0xf9c1d1f1, 0x1f6297d0, 0xf0ea5164, 0x1c38b2f2,
+	0x00000000, 0x20000000, 0xf9c1d1f1, 0x1f6297d0, 0xf3c10ead, 0x1d906bcf, 0xee38c4c6, 0x1a9b6629,
+	0x16a09e66, 0x16a09e66, 0x144cf325, 0x18bc806b, 0x11c73b3a, 0x1a9b6629, 0x0f15ae9c, 0x1c38b2f2,
+	0xe95f619a, 0x16a09e66, 0xe3c74d0e, 0x0f15ae9c, 0xe09d6830, 0x063e2e0f, 0xe027725c, 0xfcdd0b28,
+	0xe95f619a, 0x16a09e66, 0xe56499d7, 0x11c73b3a, 0xe26f9431, 0x0c3ef153, 0xe09d6830, 0x063e2e0f,
+	0x0c3ef153, 0x1d906bcf, 0x094a0317, 0x1e9f4157, 0x063e2e0f, 0x1f6297d0, 0x0322f4d8, 0x1fd88da4,
 	0xe26f9431, 0xf3c10ead, 0xe7437f95, 0xebb30cdb, 0xee38c4c6, 0xe56499d7, 0xf6b5fce9, 0xe160bea9
 };
 
 #else
 
-/* 
- *  Q30 for 128 and 1024 
+/*
+ *  Q30 for 128 and 1024
  *
  * for (i = 0; i < num/4; i++) {
  *   angle = (i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 30);
  *   x = sin(angle) * (1 << 30);
- * 
+ *
  *   angle = (num/2 - 1 - i + 0.125) * M_PI / num;
  *   x = cos(angle) * (1 << 30);
  *   x = sin(angle) * (1 << 30);
@@ -667,379 +667,379 @@
  */
 const int cossintab[128 + 1024] = {
 	/* 128 */
-	0x3fffec43, 0x003243f1, 0x015fd4d2, 0x3ffc38d1, 0x3ff9c13a, 0x01c454f5, 0x02f1b755, 0x3feea776, 
-	0x3fe9b8a9, 0x03562038, 0x0483259d, 0x3fd73a4a, 0x3fcfd50b, 0x04e767c5, 0x0613e1c5, 0x3fb5f4ea, 
-	0x3fac1a5b, 0x0677edbb, 0x07a3adff, 0x3f8adc77, 0x3f7e8e1e, 0x08077457, 0x09324ca7, 0x3f55f796, 
-	0x3f473759, 0x0995bdfd, 0x0abf8043, 0x3f174e70, 0x3f061e95, 0x0b228d42, 0x0c4b0b94, 0x3eceeaad, 
-	0x3ebb4ddb, 0x0cada4f5, 0x0dd4b19a, 0x3e7cd778, 0x3e66d0b4, 0x0e36c82a, 0x0f5c35a3, 0x3e212179, 
-	0x3e08b42a, 0x0fbdba40, 0x10e15b4e, 0x3dbbd6d4, 0x3da106bd, 0x11423ef0, 0x1263e699, 0x3d4d0728, 
-	0x3d2fd86c, 0x12c41a4f, 0x13e39be9, 0x3cd4c38b, 0x3cb53aaa, 0x144310dd, 0x15604013, 0x3c531e88, 
-	0x3c314060, 0x15bee78c, 0x16d99864, 0x3bc82c1f, 0x3ba3fde7, 0x173763c9, 0x184f6aab, 0x3b3401bb, 
-	0x3b0d8909, 0x18ac4b87, 0x19c17d44, 0x3a96b636, 0x3a6df8f8, 0x1a1d6544, 0x1b2f971e, 0x39f061d2, 
-	0x39c5664f, 0x1b8a7815, 0x1c997fc4, 0x39411e33, 0x3913eb0e, 0x1cf34baf, 0x1dfeff67, 0x38890663, 
-	0x3859a292, 0x1e57a86d, 0x1f5fdee6, 0x37c836c2, 0x3796a996, 0x1fb7575c, 0x20bbe7d8, 0x36fecd0e, 
-	0x36cb1e2a, 0x21122240, 0x2212e492, 0x362ce855, 0x35f71fb1, 0x2267d3a0, 0x2364a02e, 0x3552a8f4, 
-	0x351acedd, 0x23b836ca, 0x24b0e699, 0x34703095, 0x34364da6, 0x250317df, 0x25f78497, 0x3385a222, 
-	0x3349bf48, 0x264843d9, 0x273847c8, 0x329321c7, 0x32554840, 0x27878893, 0x2872feb6, 0x3198d4ea, 
-	0x31590e3e, 0x28c0b4d2, 0x29a778db, 0x3096e223, 0x30553828, 0x29f3984c, 0x2ad586a3, 0x2f8d713a, 
-	0x2f49ee0f, 0x2b2003ac, 0x2bfcf97c, 0x2e7cab1c, 0x2e37592c, 0x2c45c8a0, 0x2d1da3d5, 0x2d64b9da, 
+	0x3fffec43, 0x003243f1, 0x015fd4d2, 0x3ffc38d1, 0x3ff9c13a, 0x01c454f5, 0x02f1b755, 0x3feea776,
+	0x3fe9b8a9, 0x03562038, 0x0483259d, 0x3fd73a4a, 0x3fcfd50b, 0x04e767c5, 0x0613e1c5, 0x3fb5f4ea,
+	0x3fac1a5b, 0x0677edbb, 0x07a3adff, 0x3f8adc77, 0x3f7e8e1e, 0x08077457, 0x09324ca7, 0x3f55f796,
+	0x3f473759, 0x0995bdfd, 0x0abf8043, 0x3f174e70, 0x3f061e95, 0x0b228d42, 0x0c4b0b94, 0x3eceeaad,
+	0x3ebb4ddb, 0x0cada4f5, 0x0dd4b19a, 0x3e7cd778, 0x3e66d0b4, 0x0e36c82a, 0x0f5c35a3, 0x3e212179,
+	0x3e08b42a, 0x0fbdba40, 0x10e15b4e, 0x3dbbd6d4, 0x3da106bd, 0x11423ef0, 0x1263e699, 0x3d4d0728,
+	0x3d2fd86c, 0x12c41a4f, 0x13e39be9, 0x3cd4c38b, 0x3cb53aaa, 0x144310dd, 0x15604013, 0x3c531e88,
+	0x3c314060, 0x15bee78c, 0x16d99864, 0x3bc82c1f, 0x3ba3fde7, 0x173763c9, 0x184f6aab, 0x3b3401bb,
+	0x3b0d8909, 0x18ac4b87, 0x19c17d44, 0x3a96b636, 0x3a6df8f8, 0x1a1d6544, 0x1b2f971e, 0x39f061d2,
+	0x39c5664f, 0x1b8a7815, 0x1c997fc4, 0x39411e33, 0x3913eb0e, 0x1cf34baf, 0x1dfeff67, 0x38890663,
+	0x3859a292, 0x1e57a86d, 0x1f5fdee6, 0x37c836c2, 0x3796a996, 0x1fb7575c, 0x20bbe7d8, 0x36fecd0e,
+	0x36cb1e2a, 0x21122240, 0x2212e492, 0x362ce855, 0x35f71fb1, 0x2267d3a0, 0x2364a02e, 0x3552a8f4,
+	0x351acedd, 0x23b836ca, 0x24b0e699, 0x34703095, 0x34364da6, 0x250317df, 0x25f78497, 0x3385a222,
+	0x3349bf48, 0x264843d9, 0x273847c8, 0x329321c7, 0x32554840, 0x27878893, 0x2872feb6, 0x3198d4ea,
+	0x31590e3e, 0x28c0b4d2, 0x29a778db, 0x3096e223, 0x30553828, 0x29f3984c, 0x2ad586a3, 0x2f8d713a,
+	0x2f49ee0f, 0x2b2003ac, 0x2bfcf97c, 0x2e7cab1c, 0x2e37592c, 0x2c45c8a0, 0x2d1da3d5, 0x2d64b9da,
 	/* 1024 */
-	0x3fffffb1, 0x0006487f, 0x002bfb74, 0x3ffff0e3, 0x3fffe705, 0x00388c6e, 0x005e3f4c, 0x3fffba9b, 
-	0x3fffa6de, 0x006ad03b, 0x009082ea, 0x3fff5cd8, 0x3fff3f3c, 0x009d13c5, 0x00c2c62f, 0x3ffed79b, 
-	0x3ffeb021, 0x00cf56ef, 0x00f508fc, 0x3ffe2ae5, 0x3ffdf98c, 0x01019998, 0x01274b31, 0x3ffd56b5, 
-	0x3ffd1b7e, 0x0133dba3, 0x01598cb1, 0x3ffc5b0c, 0x3ffc15f7, 0x01661cf0, 0x018bcd5b, 0x3ffb37ec, 
-	0x3ffae8f9, 0x01985d60, 0x01be0d11, 0x3ff9ed53, 0x3ff99483, 0x01ca9cd4, 0x01f04bb4, 0x3ff87b44, 
-	0x3ff81896, 0x01fcdb2e, 0x02228924, 0x3ff6e1bf, 0x3ff67534, 0x022f184d, 0x0254c544, 0x3ff520c5, 
-	0x3ff4aa5d, 0x02615414, 0x0286fff3, 0x3ff33858, 0x3ff2b813, 0x02938e62, 0x02b93914, 0x3ff12878, 
-	0x3ff09e56, 0x02c5c71a, 0x02eb7086, 0x3feef126, 0x3fee5d28, 0x02f7fe1c, 0x031da62b, 0x3fec9265, 
-	0x3febf48b, 0x032a3349, 0x034fd9e5, 0x3fea0c35, 0x3fe96480, 0x035c6682, 0x03820b93, 0x3fe75e98, 
-	0x3fe6ad08, 0x038e97a9, 0x03b43b17, 0x3fe48990, 0x3fe3ce26, 0x03c0c69e, 0x03e66852, 0x3fe18d1f, 
-	0x3fe0c7da, 0x03f2f342, 0x04189326, 0x3fde6945, 0x3fdd9a27, 0x04251d77, 0x044abb73, 0x3fdb1e06, 
-	0x3fda450f, 0x0457451d, 0x047ce11a, 0x3fd7ab64, 0x3fd6c894, 0x04896a16, 0x04af03fc, 0x3fd4115f, 
-	0x3fd324b7, 0x04bb8c42, 0x04e123fa, 0x3fd04ffc, 0x3fcf597c, 0x04edab83, 0x051340f6, 0x3fcc673b, 
-	0x3fcb66e4, 0x051fc7b9, 0x05455ad1, 0x3fc8571f, 0x3fc74cf3, 0x0551e0c7, 0x0577716b, 0x3fc41fac, 
-	0x3fc30baa, 0x0583f68c, 0x05a984a6, 0x3fbfc0e3, 0x3fbea30c, 0x05b608eb, 0x05db9463, 0x3fbb3ac7, 
-	0x3fba131b, 0x05e817c3, 0x060da083, 0x3fb68d5b, 0x3fb55bdc, 0x061a22f7, 0x063fa8e7, 0x3fb1b8a2, 
-	0x3fb07d50, 0x064c2a67, 0x0671ad71, 0x3facbc9f, 0x3fab777b, 0x067e2df5, 0x06a3ae00, 0x3fa79954, 
-	0x3fa64a5f, 0x06b02d81, 0x06d5aa77, 0x3fa24ec6, 0x3fa0f600, 0x06e228ee, 0x0707a2b7, 0x3f9cdcf7, 
-	0x3f9b7a62, 0x0714201b, 0x073996a1, 0x3f9743eb, 0x3f95d787, 0x074612eb, 0x076b8616, 0x3f9183a5, 
-	0x3f900d72, 0x0778013d, 0x079d70f7, 0x3f8b9c28, 0x3f8a1c29, 0x07a9eaf5, 0x07cf5726, 0x3f858d79, 
-	0x3f8403ae, 0x07dbcff2, 0x08013883, 0x3f7f579b, 0x3f7dc405, 0x080db016, 0x083314f1, 0x3f78fa92, 
-	0x3f775d31, 0x083f8b43, 0x0864ec4f, 0x3f727661, 0x3f70cf38, 0x08716159, 0x0896be80, 0x3f6bcb0e, 
-	0x3f6a1a1c, 0x08a3323a, 0x08c88b65, 0x3f64f89b, 0x3f633de2, 0x08d4fdc6, 0x08fa52de, 0x3f5dff0e, 
-	0x3f5c3a8f, 0x0906c3e0, 0x092c14ce, 0x3f56de6a, 0x3f551026, 0x09388469, 0x095dd116, 0x3f4f96b4, 
-	0x3f4dbeac, 0x096a3f42, 0x098f8796, 0x3f4827f0, 0x3f464626, 0x099bf44c, 0x09c13831, 0x3f409223, 
-	0x3f3ea697, 0x09cda368, 0x09f2e2c7, 0x3f38d552, 0x3f36e006, 0x09ff4c78, 0x0a24873a, 0x3f30f181, 
-	0x3f2ef276, 0x0a30ef5e, 0x0a56256c, 0x3f28e6b6, 0x3f26ddec, 0x0a628bfa, 0x0a87bd3d, 0x3f20b4f5, 
-	0x3f1ea26e, 0x0a94222f, 0x0ab94e8f, 0x3f185c43, 0x3f164001, 0x0ac5b1dc, 0x0aead944, 0x3f0fdca5, 
-	0x3f0db6a9, 0x0af73ae5, 0x0b1c5d3d, 0x3f073621, 0x3f05066d, 0x0b28bd2a, 0x0b4dda5c, 0x3efe68bc, 
-	0x3efc2f50, 0x0b5a388d, 0x0b7f5081, 0x3ef5747b, 0x3ef3315a, 0x0b8bacf0, 0x0bb0bf8f, 0x3eec5965, 
-	0x3eea0c8e, 0x0bbd1a33, 0x0be22766, 0x3ee3177e, 0x3ee0c0f4, 0x0bee8038, 0x0c1387e9, 0x3ed9aecc, 
-	0x3ed74e91, 0x0c1fdee1, 0x0c44e0f9, 0x3ed01f55, 0x3ecdb56a, 0x0c513610, 0x0c763278, 0x3ec66920, 
-	0x3ec3f585, 0x0c8285a5, 0x0ca77c47, 0x3ebc8c31, 0x3eba0ee9, 0x0cb3cd84, 0x0cd8be47, 0x3eb2888f, 
-	0x3eb0019c, 0x0ce50d8c, 0x0d09f85b, 0x3ea85e41, 0x3ea5cda3, 0x0d1645a0, 0x0d3b2a64, 0x3e9e0d4c, 
-	0x3e9b7306, 0x0d4775a1, 0x0d6c5443, 0x3e9395b7, 0x3e90f1ca, 0x0d789d71, 0x0d9d75db, 0x3e88f788, 
-	0x3e8649f5, 0x0da9bcf2, 0x0dce8f0d, 0x3e7e32c6, 0x3e7b7b90, 0x0ddad406, 0x0dff9fba, 0x3e734778, 
-	0x3e70869f, 0x0e0be28e, 0x0e30a7c5, 0x3e6835a4, 0x3e656b2b, 0x0e3ce86b, 0x0e61a70f, 0x3e5cfd51, 
-	0x3e5a2939, 0x0e6de580, 0x0e929d7a, 0x3e519e86, 0x3e4ec0d1, 0x0e9ed9af, 0x0ec38ae8, 0x3e46194a, 
-	0x3e4331fa, 0x0ecfc4d9, 0x0ef46f3b, 0x3e3a6da4, 0x3e377cbb, 0x0f00a6df, 0x0f254a53, 0x3e2e9b9c, 
-	0x3e2ba11b, 0x0f317fa5, 0x0f561c15, 0x3e22a338, 0x3e1f9f21, 0x0f624f0c, 0x0f86e460, 0x3e168480, 
-	0x3e1376d5, 0x0f9314f5, 0x0fb7a317, 0x3e0a3f7b, 0x3e07283f, 0x0fc3d143, 0x0fe8581d, 0x3dfdd432, 
-	0x3dfab365, 0x0ff483d7, 0x10190352, 0x3df142ab, 0x3dee1851, 0x10252c94, 0x1049a49a, 0x3de48aef, 
-	0x3de15708, 0x1055cb5b, 0x107a3bd5, 0x3dd7ad05, 0x3dd46f94, 0x1086600e, 0x10aac8e6, 0x3dcaa8f5, 
-	0x3dc761fc, 0x10b6ea90, 0x10db4baf, 0x3dbd7ec7, 0x3dba2e48, 0x10e76ac3, 0x110bc413, 0x3db02e84, 
-	0x3dacd481, 0x1117e088, 0x113c31f3, 0x3da2b834, 0x3d9f54af, 0x11484bc2, 0x116c9531, 0x3d951bde, 
-	0x3d91aed9, 0x1178ac53, 0x119cedaf, 0x3d87598c, 0x3d83e309, 0x11a9021d, 0x11cd3b50, 0x3d797145, 
-	0x3d75f147, 0x11d94d02, 0x11fd7df6, 0x3d6b6313, 0x3d67d99b, 0x12098ce5, 0x122db583, 0x3d5d2efe, 
-	0x3d599c0e, 0x1239c1a7, 0x125de1da, 0x3d4ed50f, 0x3d4b38aa, 0x1269eb2b, 0x128e02dc, 0x3d40554e, 
-	0x3d3caf76, 0x129a0954, 0x12be186c, 0x3d31afc5, 0x3d2e007c, 0x12ca1c03, 0x12ee226c, 0x3d22e47c, 
-	0x3d1f2bc5, 0x12fa231b, 0x131e20c0, 0x3d13f37e, 0x3d10315a, 0x132a1e7e, 0x134e1348, 0x3d04dcd2, 
-	0x3d011145, 0x135a0e0e, 0x137df9e7, 0x3cf5a082, 0x3cf1cb8e, 0x1389f1af, 0x13add481, 0x3ce63e98, 
-	0x3ce2603f, 0x13b9c943, 0x13dda2f7, 0x3cd6b71e, 0x3cd2cf62, 0x13e994ab, 0x140d652c, 0x3cc70a1c, 
-	0x3cc318ff, 0x141953cb, 0x143d1b02, 0x3cb7379c, 0x3cb33d22, 0x14490685, 0x146cc45c, 0x3ca73fa9, 
-	0x3ca33bd3, 0x1478acbc, 0x149c611d, 0x3c97224c, 0x3c93151d, 0x14a84652, 0x14cbf127, 0x3c86df8e, 
-	0x3c82c909, 0x14d7d32a, 0x14fb745e, 0x3c76777b, 0x3c7257a2, 0x15075327, 0x152aeaa3, 0x3c65ea1c, 
-	0x3c61c0f1, 0x1536c62b, 0x155a53d9, 0x3c55377b, 0x3c510501, 0x15662c18, 0x1589afe3, 0x3c445fa2, 
-	0x3c4023dd, 0x159584d3, 0x15b8fea4, 0x3c33629d, 0x3c2f1d8e, 0x15c4d03e, 0x15e83fff, 0x3c224075, 
-	0x3c1df21f, 0x15f40e3a, 0x161773d6, 0x3c10f935, 0x3c0ca19b, 0x16233eac, 0x16469a0d, 0x3bff8ce8, 
-	0x3bfb2c0c, 0x16526176, 0x1675b286, 0x3bedfb99, 0x3be9917e, 0x1681767c, 0x16a4bd25, 0x3bdc4552, 
-	0x3bd7d1fa, 0x16b07d9f, 0x16d3b9cc, 0x3bca6a1d, 0x3bc5ed8d, 0x16df76c3, 0x1702a85e, 0x3bb86a08, 
-	0x3bb3e440, 0x170e61cc, 0x173188be, 0x3ba6451b, 0x3ba1b620, 0x173d3e9b, 0x17605ad0, 0x3b93fb63, 
-	0x3b8f6337, 0x176c0d15, 0x178f1e76, 0x3b818ceb, 0x3b7ceb90, 0x179acd1c, 0x17bdd394, 0x3b6ef9be, 
-	0x3b6a4f38, 0x17c97e93, 0x17ec7a0d, 0x3b5c41e8, 0x3b578e39, 0x17f8215e, 0x181b11c4, 0x3b496574, 
-	0x3b44a8a0, 0x1826b561, 0x18499a9d, 0x3b36646e, 0x3b319e77, 0x18553a7d, 0x1878147a, 0x3b233ee1, 
-	0x3b1e6fca, 0x1883b097, 0x18a67f3f, 0x3b0ff4d9, 0x3b0b1ca6, 0x18b21791, 0x18d4dad0, 0x3afc8663, 
-	0x3af7a516, 0x18e06f50, 0x1903270f, 0x3ae8f38b, 0x3ae40926, 0x190eb7b7, 0x193163e1, 0x3ad53c5b, 
-	0x3ad048e3, 0x193cf0a9, 0x195f9128, 0x3ac160e1, 0x3abc6458, 0x196b1a09, 0x198daec8, 0x3aad6129, 
-	0x3aa85b92, 0x199933bb, 0x19bbbca6, 0x3a993d3e, 0x3a942e9d, 0x19c73da3, 0x19e9baa3, 0x3a84f52f, 
-	0x3a7fdd86, 0x19f537a4, 0x1a17a8a5, 0x3a708906, 0x3a6b6859, 0x1a2321a2, 0x1a45868e, 0x3a5bf8d1, 
-	0x3a56cf23, 0x1a50fb81, 0x1a735442, 0x3a47449c, 0x3a4211f0, 0x1a7ec524, 0x1aa111a6, 0x3a326c74, 
-	0x3a2d30cd, 0x1aac7e6f, 0x1acebe9d, 0x3a1d7066, 0x3a182bc8, 0x1ada2746, 0x1afc5b0a, 0x3a08507f, 
-	0x3a0302ed, 0x1b07bf8c, 0x1b29e6d2, 0x39f30ccc, 0x39edb649, 0x1b354727, 0x1b5761d8, 0x39dda55a, 
-	0x39d845e9, 0x1b62bdf8, 0x1b84cc01, 0x39c81a36, 0x39c2b1da, 0x1b9023e5, 0x1bb22530, 0x39b26b6d, 
-	0x39acfa2b, 0x1bbd78d2, 0x1bdf6d4a, 0x399c990d, 0x39971ee7, 0x1beabca1, 0x1c0ca432, 0x3986a324, 
-	0x3981201e, 0x1c17ef39, 0x1c39c9cd, 0x397089bf, 0x396afddc, 0x1c45107c, 0x1c66ddfe, 0x395a4ceb, 
-	0x3954b82e, 0x1c72204f, 0x1c93e0ab, 0x3943ecb6, 0x393e4f23, 0x1c9f1e96, 0x1cc0d1b6, 0x392d692f, 
-	0x3927c2c9, 0x1ccc0b35, 0x1cedb106, 0x3916c262, 0x3911132d, 0x1cf8e611, 0x1d1a7e7d, 0x38fff85e, 
-	0x38fa405e, 0x1d25af0d, 0x1d473a00, 0x38e90b31, 0x38e34a69, 0x1d52660f, 0x1d73e374, 0x38d1fae9, 
-	0x38cc315d, 0x1d7f0afb, 0x1da07abc, 0x38bac795, 0x38b4f547, 0x1dab9db5, 0x1dccffbf, 0x38a37142, 
-	0x389d9637, 0x1dd81e21, 0x1df9725f, 0x388bf7ff, 0x3886143b, 0x1e048c24, 0x1e25d282, 0x38745bdb, 
-	0x386e6f60, 0x1e30e7a4, 0x1e52200c, 0x385c9ce3, 0x3856a7b6, 0x1e5d3084, 0x1e7e5ae2, 0x3844bb28, 
-	0x383ebd4c, 0x1e8966a8, 0x1eaa82e9, 0x382cb6b7, 0x3826b030, 0x1eb589f7, 0x1ed69805, 0x38148f9f, 
-	0x380e8071, 0x1ee19a54, 0x1f029a1c, 0x37fc45ef, 0x37f62e1d, 0x1f0d97a5, 0x1f2e8911, 0x37e3d9b7, 
-	0x37ddb945, 0x1f3981ce, 0x1f5a64cb, 0x37cb4b04, 0x37c521f6, 0x1f6558b5, 0x1f862d2d, 0x37b299e7, 
-	0x37ac6841, 0x1f911c3d, 0x1fb1e21d, 0x3799c66f, 0x37938c34, 0x1fbccc4d, 0x1fdd8381, 0x3780d0aa, 
-	0x377a8ddf, 0x1fe868c8, 0x2009113c, 0x3767b8a9, 0x37616d51, 0x2013f196, 0x20348b35, 0x374e7e7b, 
-	0x37482a9a, 0x203f6699, 0x205ff14f, 0x3735222f, 0x372ec5c9, 0x206ac7b8, 0x208b4372, 0x371ba3d4, 
-	0x37153eee, 0x209614d9, 0x20b68181, 0x3702037c, 0x36fb9618, 0x20c14ddf, 0x20e1ab63, 0x36e84135, 
-	0x36e1cb58, 0x20ec72b1, 0x210cc0fc, 0x36ce5d10, 0x36c7debd, 0x21178334, 0x2137c232, 0x36b4571b, 
-	0x36add058, 0x21427f4d, 0x2162aeea, 0x369a2f69, 0x3693a038, 0x216d66e2, 0x218d870b, 0x367fe608, 
-	0x36794e6e, 0x219839d8, 0x21b84a79, 0x36657b08, 0x365edb09, 0x21c2f815, 0x21e2f91a, 0x364aee7b, 
-	0x3644461b, 0x21eda17f, 0x220d92d4, 0x36304070, 0x36298fb4, 0x221835fb, 0x2238178d, 0x361570f8, 
-	0x360eb7e3, 0x2242b56f, 0x22628729, 0x35fa8023, 0x35f3beba, 0x226d1fc1, 0x228ce191, 0x35df6e03, 
-	0x35d8a449, 0x229774d7, 0x22b726a8, 0x35c43aa7, 0x35bd68a1, 0x22c1b496, 0x22e15655, 0x35a8e621, 
-	0x35a20bd3, 0x22ebdee5, 0x230b707e, 0x358d7081, 0x35868def, 0x2315f3a8, 0x23357509, 0x3571d9d9, 
-	0x356aef08, 0x233ff2c8, 0x235f63dc, 0x35562239, 0x354f2f2c, 0x2369dc29, 0x23893cdd, 0x353a49b2, 
-	0x35334e6f, 0x2393afb2, 0x23b2fff3, 0x351e5056, 0x35174ce0, 0x23bd6d48, 0x23dcad03, 0x35023636, 
-	0x34fb2a92, 0x23e714d3, 0x240643f4, 0x34e5fb63, 0x34dee795, 0x2410a639, 0x242fc4ad, 0x34c99fef, 
-	0x34c283fb, 0x243a215f, 0x24592f13, 0x34ad23eb, 0x34a5ffd5, 0x2463862c, 0x2482830d, 0x34908768, 
-	0x34895b36, 0x248cd487, 0x24abc082, 0x3473ca79, 0x346c962f, 0x24b60c57, 0x24d4e757, 0x3456ed2f, 
-	0x344fb0d1, 0x24df2d81, 0x24fdf775, 0x3439ef9c, 0x3432ab2e, 0x250837ed, 0x2526f0c1, 0x341cd1d2, 
-	0x34158559, 0x25312b81, 0x254fd323, 0x33ff93e2, 0x33f83f62, 0x255a0823, 0x25789e80, 0x33e235df, 
-	0x33dad95e, 0x2582cdbc, 0x25a152c0, 0x33c4b7db, 0x33bd535c, 0x25ab7c30, 0x25c9efca, 0x33a719e8, 
-	0x339fad70, 0x25d41369, 0x25f27584, 0x33895c18, 0x3381e7ac, 0x25fc934b, 0x261ae3d6, 0x336b7e7e, 
-	0x33640223, 0x2624fbbf, 0x26433aa7, 0x334d812d, 0x3345fce6, 0x264d4cac, 0x266b79dd, 0x332f6435, 
-	0x3327d808, 0x267585f8, 0x2693a161, 0x331127ab, 0x3309939c, 0x269da78b, 0x26bbb119, 0x32f2cba1, 
-	0x32eb2fb5, 0x26c5b14c, 0x26e3a8ec, 0x32d45029, 0x32ccac64, 0x26eda322, 0x270b88c2, 0x32b5b557, 
-	0x32ae09be, 0x27157cf5, 0x27335082, 0x3296fb3d, 0x328f47d5, 0x273d3eac, 0x275b0014, 0x327821ee, 
-	0x327066bc, 0x2764e82f, 0x27829760, 0x3259297d, 0x32516686, 0x278c7965, 0x27aa164c, 0x323a11fe, 
-	0x32324746, 0x27b3f235, 0x27d17cc1, 0x321adb83, 0x3213090f, 0x27db5288, 0x27f8caa5, 0x31fb8620, 
-	0x31f3abf5, 0x28029a45, 0x281fffe2, 0x31dc11e8, 0x31d4300b, 0x2829c954, 0x28471c5e, 0x31bc7eee, 
-	0x31b49564, 0x2850df9d, 0x286e2002, 0x319ccd46, 0x3194dc14, 0x2877dd07, 0x28950ab6, 0x317cfd04, 
-	0x3175042e, 0x289ec17a, 0x28bbdc61, 0x315d0e3b, 0x31550dc6, 0x28c58cdf, 0x28e294eb, 0x313d00ff, 
-	0x3134f8f1, 0x28ec3f1e, 0x2909343e, 0x311cd564, 0x3114c5c0, 0x2912d81f, 0x292fba40, 0x30fc8b7d, 
-	0x30f47449, 0x293957c9, 0x295626da, 0x30dc235e, 0x30d404a0, 0x295fbe06, 0x297c79f5, 0x30bb9d1c, 
-	0x30b376d8, 0x29860abd, 0x29a2b378, 0x309af8ca, 0x3092cb05, 0x29ac3dd7, 0x29c8d34d, 0x307a367c, 
-	0x3072013c, 0x29d2573c, 0x29eed95b, 0x30595648, 0x30511991, 0x29f856d5, 0x2a14c58b, 0x30385840, 
-	0x30301418, 0x2a1e3c8a, 0x2a3a97c7, 0x30173c7a, 0x300ef0e5, 0x2a440844, 0x2a604ff5, 0x2ff6030a, 
-	0x2fedb00d, 0x2a69b9ec, 0x2a85ee00, 0x2fd4ac04, 0x2fcc51a5, 0x2a8f516b, 0x2aab71d0, 0x2fb3377c, 
-	0x2faad5c1, 0x2ab4cea9, 0x2ad0db4e, 0x2f91a589, 0x2f893c75, 0x2ada318e, 0x2af62a63, 0x2f6ff63d, 
-	0x2f6785d7, 0x2aff7a05, 0x2b1b5ef8, 0x2f4e29af, 0x2f45b1fb, 0x2b24a7f6, 0x2b4078f5, 0x2f2c3ff2, 
-	0x2f23c0f6, 0x2b49bb4a, 0x2b657844, 0x2f0a391d, 0x2f01b2de, 0x2b6eb3ea, 0x2b8a5cce, 0x2ee81543, 
-	0x2edf87c6, 0x2b9391c0, 0x2baf267d, 0x2ec5d479, 0x2ebd3fc4, 0x2bb854b4, 0x2bd3d53a, 0x2ea376d6, 
-	0x2e9adaee, 0x2bdcfcb0, 0x2bf868ed, 0x2e80fc6e, 0x2e785958, 0x2c01899e, 0x2c1ce181, 0x2e5e6556, 
-	0x2e55bb17, 0x2c25fb66, 0x2c413edf, 0x2e3bb1a4, 0x2e330042, 0x2c4a51f3, 0x2c6580f1, 0x2e18e16d, 
-	0x2e1028ed, 0x2c6e8d2e, 0x2c89a79f, 0x2df5f4c7, 0x2ded352f, 0x2c92ad01, 0x2cadb2d5, 0x2dd2ebc7, 
-	0x2dca251c, 0x2cb6b155, 0x2cd1a27b, 0x2dafc683, 0x2da6f8ca, 0x2cda9a14, 0x2cf5767c, 0x2d8c8510, 
+	0x3fffffb1, 0x0006487f, 0x002bfb74, 0x3ffff0e3, 0x3fffe705, 0x00388c6e, 0x005e3f4c, 0x3fffba9b,
+	0x3fffa6de, 0x006ad03b, 0x009082ea, 0x3fff5cd8, 0x3fff3f3c, 0x009d13c5, 0x00c2c62f, 0x3ffed79b,
+	0x3ffeb021, 0x00cf56ef, 0x00f508fc, 0x3ffe2ae5, 0x3ffdf98c, 0x01019998, 0x01274b31, 0x3ffd56b5,
+	0x3ffd1b7e, 0x0133dba3, 0x01598cb1, 0x3ffc5b0c, 0x3ffc15f7, 0x01661cf0, 0x018bcd5b, 0x3ffb37ec,
+	0x3ffae8f9, 0x01985d60, 0x01be0d11, 0x3ff9ed53, 0x3ff99483, 0x01ca9cd4, 0x01f04bb4, 0x3ff87b44,
+	0x3ff81896, 0x01fcdb2e, 0x02228924, 0x3ff6e1bf, 0x3ff67534, 0x022f184d, 0x0254c544, 0x3ff520c5,
+	0x3ff4aa5d, 0x02615414, 0x0286fff3, 0x3ff33858, 0x3ff2b813, 0x02938e62, 0x02b93914, 0x3ff12878,
+	0x3ff09e56, 0x02c5c71a, 0x02eb7086, 0x3feef126, 0x3fee5d28, 0x02f7fe1c, 0x031da62b, 0x3fec9265,
+	0x3febf48b, 0x032a3349, 0x034fd9e5, 0x3fea0c35, 0x3fe96480, 0x035c6682, 0x03820b93, 0x3fe75e98,
+	0x3fe6ad08, 0x038e97a9, 0x03b43b17, 0x3fe48990, 0x3fe3ce26, 0x03c0c69e, 0x03e66852, 0x3fe18d1f,
+	0x3fe0c7da, 0x03f2f342, 0x04189326, 0x3fde6945, 0x3fdd9a27, 0x04251d77, 0x044abb73, 0x3fdb1e06,
+	0x3fda450f, 0x0457451d, 0x047ce11a, 0x3fd7ab64, 0x3fd6c894, 0x04896a16, 0x04af03fc, 0x3fd4115f,
+	0x3fd324b7, 0x04bb8c42, 0x04e123fa, 0x3fd04ffc, 0x3fcf597c, 0x04edab83, 0x051340f6, 0x3fcc673b,
+	0x3fcb66e4, 0x051fc7b9, 0x05455ad1, 0x3fc8571f, 0x3fc74cf3, 0x0551e0c7, 0x0577716b, 0x3fc41fac,
+	0x3fc30baa, 0x0583f68c, 0x05a984a6, 0x3fbfc0e3, 0x3fbea30c, 0x05b608eb, 0x05db9463, 0x3fbb3ac7,
+	0x3fba131b, 0x05e817c3, 0x060da083, 0x3fb68d5b, 0x3fb55bdc, 0x061a22f7, 0x063fa8e7, 0x3fb1b8a2,
+	0x3fb07d50, 0x064c2a67, 0x0671ad71, 0x3facbc9f, 0x3fab777b, 0x067e2df5, 0x06a3ae00, 0x3fa79954,
+	0x3fa64a5f, 0x06b02d81, 0x06d5aa77, 0x3fa24ec6, 0x3fa0f600, 0x06e228ee, 0x0707a2b7, 0x3f9cdcf7,
+	0x3f9b7a62, 0x0714201b, 0x073996a1, 0x3f9743eb, 0x3f95d787, 0x074612eb, 0x076b8616, 0x3f9183a5,
+	0x3f900d72, 0x0778013d, 0x079d70f7, 0x3f8b9c28, 0x3f8a1c29, 0x07a9eaf5, 0x07cf5726, 0x3f858d79,
+	0x3f8403ae, 0x07dbcff2, 0x08013883, 0x3f7f579b, 0x3f7dc405, 0x080db016, 0x083314f1, 0x3f78fa92,
+	0x3f775d31, 0x083f8b43, 0x0864ec4f, 0x3f727661, 0x3f70cf38, 0x08716159, 0x0896be80, 0x3f6bcb0e,
+	0x3f6a1a1c, 0x08a3323a, 0x08c88b65, 0x3f64f89b, 0x3f633de2, 0x08d4fdc6, 0x08fa52de, 0x3f5dff0e,
+	0x3f5c3a8f, 0x0906c3e0, 0x092c14ce, 0x3f56de6a, 0x3f551026, 0x09388469, 0x095dd116, 0x3f4f96b4,
+	0x3f4dbeac, 0x096a3f42, 0x098f8796, 0x3f4827f0, 0x3f464626, 0x099bf44c, 0x09c13831, 0x3f409223,
+	0x3f3ea697, 0x09cda368, 0x09f2e2c7, 0x3f38d552, 0x3f36e006, 0x09ff4c78, 0x0a24873a, 0x3f30f181,
+	0x3f2ef276, 0x0a30ef5e, 0x0a56256c, 0x3f28e6b6, 0x3f26ddec, 0x0a628bfa, 0x0a87bd3d, 0x3f20b4f5,
+	0x3f1ea26e, 0x0a94222f, 0x0ab94e8f, 0x3f185c43, 0x3f164001, 0x0ac5b1dc, 0x0aead944, 0x3f0fdca5,
+	0x3f0db6a9, 0x0af73ae5, 0x0b1c5d3d, 0x3f073621, 0x3f05066d, 0x0b28bd2a, 0x0b4dda5c, 0x3efe68bc,
+	0x3efc2f50, 0x0b5a388d, 0x0b7f5081, 0x3ef5747b, 0x3ef3315a, 0x0b8bacf0, 0x0bb0bf8f, 0x3eec5965,
+	0x3eea0c8e, 0x0bbd1a33, 0x0be22766, 0x3ee3177e, 0x3ee0c0f4, 0x0bee8038, 0x0c1387e9, 0x3ed9aecc,
+	0x3ed74e91, 0x0c1fdee1, 0x0c44e0f9, 0x3ed01f55, 0x3ecdb56a, 0x0c513610, 0x0c763278, 0x3ec66920,
+	0x3ec3f585, 0x0c8285a5, 0x0ca77c47, 0x3ebc8c31, 0x3eba0ee9, 0x0cb3cd84, 0x0cd8be47, 0x3eb2888f,
+	0x3eb0019c, 0x0ce50d8c, 0x0d09f85b, 0x3ea85e41, 0x3ea5cda3, 0x0d1645a0, 0x0d3b2a64, 0x3e9e0d4c,
+	0x3e9b7306, 0x0d4775a1, 0x0d6c5443, 0x3e9395b7, 0x3e90f1ca, 0x0d789d71, 0x0d9d75db, 0x3e88f788,
+	0x3e8649f5, 0x0da9bcf2, 0x0dce8f0d, 0x3e7e32c6, 0x3e7b7b90, 0x0ddad406, 0x0dff9fba, 0x3e734778,
+	0x3e70869f, 0x0e0be28e, 0x0e30a7c5, 0x3e6835a4, 0x3e656b2b, 0x0e3ce86b, 0x0e61a70f, 0x3e5cfd51,
+	0x3e5a2939, 0x0e6de580, 0x0e929d7a, 0x3e519e86, 0x3e4ec0d1, 0x0e9ed9af, 0x0ec38ae8, 0x3e46194a,
+	0x3e4331fa, 0x0ecfc4d9, 0x0ef46f3b, 0x3e3a6da4, 0x3e377cbb, 0x0f00a6df, 0x0f254a53, 0x3e2e9b9c,
+	0x3e2ba11b, 0x0f317fa5, 0x0f561c15, 0x3e22a338, 0x3e1f9f21, 0x0f624f0c, 0x0f86e460, 0x3e168480,
+	0x3e1376d5, 0x0f9314f5, 0x0fb7a317, 0x3e0a3f7b, 0x3e07283f, 0x0fc3d143, 0x0fe8581d, 0x3dfdd432,
+	0x3dfab365, 0x0ff483d7, 0x10190352, 0x3df142ab, 0x3dee1851, 0x10252c94, 0x1049a49a, 0x3de48aef,
+	0x3de15708, 0x1055cb5b, 0x107a3bd5, 0x3dd7ad05, 0x3dd46f94, 0x1086600e, 0x10aac8e6, 0x3dcaa8f5,
+	0x3dc761fc, 0x10b6ea90, 0x10db4baf, 0x3dbd7ec7, 0x3dba2e48, 0x10e76ac3, 0x110bc413, 0x3db02e84,
+	0x3dacd481, 0x1117e088, 0x113c31f3, 0x3da2b834, 0x3d9f54af, 0x11484bc2, 0x116c9531, 0x3d951bde,
+	0x3d91aed9, 0x1178ac53, 0x119cedaf, 0x3d87598c, 0x3d83e309, 0x11a9021d, 0x11cd3b50, 0x3d797145,
+	0x3d75f147, 0x11d94d02, 0x11fd7df6, 0x3d6b6313, 0x3d67d99b, 0x12098ce5, 0x122db583, 0x3d5d2efe,
+	0x3d599c0e, 0x1239c1a7, 0x125de1da, 0x3d4ed50f, 0x3d4b38aa, 0x1269eb2b, 0x128e02dc, 0x3d40554e,
+	0x3d3caf76, 0x129a0954, 0x12be186c, 0x3d31afc5, 0x3d2e007c, 0x12ca1c03, 0x12ee226c, 0x3d22e47c,
+	0x3d1f2bc5, 0x12fa231b, 0x131e20c0, 0x3d13f37e, 0x3d10315a, 0x132a1e7e, 0x134e1348, 0x3d04dcd2,
+	0x3d011145, 0x135a0e0e, 0x137df9e7, 0x3cf5a082, 0x3cf1cb8e, 0x1389f1af, 0x13add481, 0x3ce63e98,
+	0x3ce2603f, 0x13b9c943, 0x13dda2f7, 0x3cd6b71e, 0x3cd2cf62, 0x13e994ab, 0x140d652c, 0x3cc70a1c,
+	0x3cc318ff, 0x141953cb, 0x143d1b02, 0x3cb7379c, 0x3cb33d22, 0x14490685, 0x146cc45c, 0x3ca73fa9,
+	0x3ca33bd3, 0x1478acbc, 0x149c611d, 0x3c97224c, 0x3c93151d, 0x14a84652, 0x14cbf127, 0x3c86df8e,
+	0x3c82c909, 0x14d7d32a, 0x14fb745e, 0x3c76777b, 0x3c7257a2, 0x15075327, 0x152aeaa3, 0x3c65ea1c,
+	0x3c61c0f1, 0x1536c62b, 0x155a53d9, 0x3c55377b, 0x3c510501, 0x15662c18, 0x1589afe3, 0x3c445fa2,
+	0x3c4023dd, 0x159584d3, 0x15b8fea4, 0x3c33629d, 0x3c2f1d8e, 0x15c4d03e, 0x15e83fff, 0x3c224075,
+	0x3c1df21f, 0x15f40e3a, 0x161773d6, 0x3c10f935, 0x3c0ca19b, 0x16233eac, 0x16469a0d, 0x3bff8ce8,
+	0x3bfb2c0c, 0x16526176, 0x1675b286, 0x3bedfb99, 0x3be9917e, 0x1681767c, 0x16a4bd25, 0x3bdc4552,
+	0x3bd7d1fa, 0x16b07d9f, 0x16d3b9cc, 0x3bca6a1d, 0x3bc5ed8d, 0x16df76c3, 0x1702a85e, 0x3bb86a08,
+	0x3bb3e440, 0x170e61cc, 0x173188be, 0x3ba6451b, 0x3ba1b620, 0x173d3e9b, 0x17605ad0, 0x3b93fb63,
+	0x3b8f6337, 0x176c0d15, 0x178f1e76, 0x3b818ceb, 0x3b7ceb90, 0x179acd1c, 0x17bdd394, 0x3b6ef9be,
+	0x3b6a4f38, 0x17c97e93, 0x17ec7a0d, 0x3b5c41e8, 0x3b578e39, 0x17f8215e, 0x181b11c4, 0x3b496574,
+	0x3b44a8a0, 0x1826b561, 0x18499a9d, 0x3b36646e, 0x3b319e77, 0x18553a7d, 0x1878147a, 0x3b233ee1,
+	0x3b1e6fca, 0x1883b097, 0x18a67f3f, 0x3b0ff4d9, 0x3b0b1ca6, 0x18b21791, 0x18d4dad0, 0x3afc8663,
+	0x3af7a516, 0x18e06f50, 0x1903270f, 0x3ae8f38b, 0x3ae40926, 0x190eb7b7, 0x193163e1, 0x3ad53c5b,
+	0x3ad048e3, 0x193cf0a9, 0x195f9128, 0x3ac160e1, 0x3abc6458, 0x196b1a09, 0x198daec8, 0x3aad6129,
+	0x3aa85b92, 0x199933bb, 0x19bbbca6, 0x3a993d3e, 0x3a942e9d, 0x19c73da3, 0x19e9baa3, 0x3a84f52f,
+	0x3a7fdd86, 0x19f537a4, 0x1a17a8a5, 0x3a708906, 0x3a6b6859, 0x1a2321a2, 0x1a45868e, 0x3a5bf8d1,
+	0x3a56cf23, 0x1a50fb81, 0x1a735442, 0x3a47449c, 0x3a4211f0, 0x1a7ec524, 0x1aa111a6, 0x3a326c74,
+	0x3a2d30cd, 0x1aac7e6f, 0x1acebe9d, 0x3a1d7066, 0x3a182bc8, 0x1ada2746, 0x1afc5b0a, 0x3a08507f,
+	0x3a0302ed, 0x1b07bf8c, 0x1b29e6d2, 0x39f30ccc, 0x39edb649, 0x1b354727, 0x1b5761d8, 0x39dda55a,
+	0x39d845e9, 0x1b62bdf8, 0x1b84cc01, 0x39c81a36, 0x39c2b1da, 0x1b9023e5, 0x1bb22530, 0x39b26b6d,
+	0x39acfa2b, 0x1bbd78d2, 0x1bdf6d4a, 0x399c990d, 0x39971ee7, 0x1beabca1, 0x1c0ca432, 0x3986a324,
+	0x3981201e, 0x1c17ef39, 0x1c39c9cd, 0x397089bf, 0x396afddc, 0x1c45107c, 0x1c66ddfe, 0x395a4ceb,
+	0x3954b82e, 0x1c72204f, 0x1c93e0ab, 0x3943ecb6, 0x393e4f23, 0x1c9f1e96, 0x1cc0d1b6, 0x392d692f,
+	0x3927c2c9, 0x1ccc0b35, 0x1cedb106, 0x3916c262, 0x3911132d, 0x1cf8e611, 0x1d1a7e7d, 0x38fff85e,
+	0x38fa405e, 0x1d25af0d, 0x1d473a00, 0x38e90b31, 0x38e34a69, 0x1d52660f, 0x1d73e374, 0x38d1fae9,
+	0x38cc315d, 0x1d7f0afb, 0x1da07abc, 0x38bac795, 0x38b4f547, 0x1dab9db5, 0x1dccffbf, 0x38a37142,
+	0x389d9637, 0x1dd81e21, 0x1df9725f, 0x388bf7ff, 0x3886143b, 0x1e048c24, 0x1e25d282, 0x38745bdb,
+	0x386e6f60, 0x1e30e7a4, 0x1e52200c, 0x385c9ce3, 0x3856a7b6, 0x1e5d3084, 0x1e7e5ae2, 0x3844bb28,
+	0x383ebd4c, 0x1e8966a8, 0x1eaa82e9, 0x382cb6b7, 0x3826b030, 0x1eb589f7, 0x1ed69805, 0x38148f9f,
+	0x380e8071, 0x1ee19a54, 0x1f029a1c, 0x37fc45ef, 0x37f62e1d, 0x1f0d97a5, 0x1f2e8911, 0x37e3d9b7,
+	0x37ddb945, 0x1f3981ce, 0x1f5a64cb, 0x37cb4b04, 0x37c521f6, 0x1f6558b5, 0x1f862d2d, 0x37b299e7,
+	0x37ac6841, 0x1f911c3d, 0x1fb1e21d, 0x3799c66f, 0x37938c34, 0x1fbccc4d, 0x1fdd8381, 0x3780d0aa,
+	0x377a8ddf, 0x1fe868c8, 0x2009113c, 0x3767b8a9, 0x37616d51, 0x2013f196, 0x20348b35, 0x374e7e7b,
+	0x37482a9a, 0x203f6699, 0x205ff14f, 0x3735222f, 0x372ec5c9, 0x206ac7b8, 0x208b4372, 0x371ba3d4,
+	0x37153eee, 0x209614d9, 0x20b68181, 0x3702037c, 0x36fb9618, 0x20c14ddf, 0x20e1ab63, 0x36e84135,
+	0x36e1cb58, 0x20ec72b1, 0x210cc0fc, 0x36ce5d10, 0x36c7debd, 0x21178334, 0x2137c232, 0x36b4571b,
+	0x36add058, 0x21427f4d, 0x2162aeea, 0x369a2f69, 0x3693a038, 0x216d66e2, 0x218d870b, 0x367fe608,
+	0x36794e6e, 0x219839d8, 0x21b84a79, 0x36657b08, 0x365edb09, 0x21c2f815, 0x21e2f91a, 0x364aee7b,
+	0x3644461b, 0x21eda17f, 0x220d92d4, 0x36304070, 0x36298fb4, 0x221835fb, 0x2238178d, 0x361570f8,
+	0x360eb7e3, 0x2242b56f, 0x22628729, 0x35fa8023, 0x35f3beba, 0x226d1fc1, 0x228ce191, 0x35df6e03,
+	0x35d8a449, 0x229774d7, 0x22b726a8, 0x35c43aa7, 0x35bd68a1, 0x22c1b496, 0x22e15655, 0x35a8e621,
+	0x35a20bd3, 0x22ebdee5, 0x230b707e, 0x358d7081, 0x35868def, 0x2315f3a8, 0x23357509, 0x3571d9d9,
+	0x356aef08, 0x233ff2c8, 0x235f63dc, 0x35562239, 0x354f2f2c, 0x2369dc29, 0x23893cdd, 0x353a49b2,
+	0x35334e6f, 0x2393afb2, 0x23b2fff3, 0x351e5056, 0x35174ce0, 0x23bd6d48, 0x23dcad03, 0x35023636,
+	0x34fb2a92, 0x23e714d3, 0x240643f4, 0x34e5fb63, 0x34dee795, 0x2410a639, 0x242fc4ad, 0x34c99fef,
+	0x34c283fb, 0x243a215f, 0x24592f13, 0x34ad23eb, 0x34a5ffd5, 0x2463862c, 0x2482830d, 0x34908768,
+	0x34895b36, 0x248cd487, 0x24abc082, 0x3473ca79, 0x346c962f, 0x24b60c57, 0x24d4e757, 0x3456ed2f,
+	0x344fb0d1, 0x24df2d81, 0x24fdf775, 0x3439ef9c, 0x3432ab2e, 0x250837ed, 0x2526f0c1, 0x341cd1d2,
+	0x34158559, 0x25312b81, 0x254fd323, 0x33ff93e2, 0x33f83f62, 0x255a0823, 0x25789e80, 0x33e235df,
+	0x33dad95e, 0x2582cdbc, 0x25a152c0, 0x33c4b7db, 0x33bd535c, 0x25ab7c30, 0x25c9efca, 0x33a719e8,
+	0x339fad70, 0x25d41369, 0x25f27584, 0x33895c18, 0x3381e7ac, 0x25fc934b, 0x261ae3d6, 0x336b7e7e,
+	0x33640223, 0x2624fbbf, 0x26433aa7, 0x334d812d, 0x3345fce6, 0x264d4cac, 0x266b79dd, 0x332f6435,
+	0x3327d808, 0x267585f8, 0x2693a161, 0x331127ab, 0x3309939c, 0x269da78b, 0x26bbb119, 0x32f2cba1,
+	0x32eb2fb5, 0x26c5b14c, 0x26e3a8ec, 0x32d45029, 0x32ccac64, 0x26eda322, 0x270b88c2, 0x32b5b557,
+	0x32ae09be, 0x27157cf5, 0x27335082, 0x3296fb3d, 0x328f47d5, 0x273d3eac, 0x275b0014, 0x327821ee,
+	0x327066bc, 0x2764e82f, 0x27829760, 0x3259297d, 0x32516686, 0x278c7965, 0x27aa164c, 0x323a11fe,
+	0x32324746, 0x27b3f235, 0x27d17cc1, 0x321adb83, 0x3213090f, 0x27db5288, 0x27f8caa5, 0x31fb8620,
+	0x31f3abf5, 0x28029a45, 0x281fffe2, 0x31dc11e8, 0x31d4300b, 0x2829c954, 0x28471c5e, 0x31bc7eee,
+	0x31b49564, 0x2850df9d, 0x286e2002, 0x319ccd46, 0x3194dc14, 0x2877dd07, 0x28950ab6, 0x317cfd04,
+	0x3175042e, 0x289ec17a, 0x28bbdc61, 0x315d0e3b, 0x31550dc6, 0x28c58cdf, 0x28e294eb, 0x313d00ff,
+	0x3134f8f1, 0x28ec3f1e, 0x2909343e, 0x311cd564, 0x3114c5c0, 0x2912d81f, 0x292fba40, 0x30fc8b7d,
+	0x30f47449, 0x293957c9, 0x295626da, 0x30dc235e, 0x30d404a0, 0x295fbe06, 0x297c79f5, 0x30bb9d1c,
+	0x30b376d8, 0x29860abd, 0x29a2b378, 0x309af8ca, 0x3092cb05, 0x29ac3dd7, 0x29c8d34d, 0x307a367c,
+	0x3072013c, 0x29d2573c, 0x29eed95b, 0x30595648, 0x30511991, 0x29f856d5, 0x2a14c58b, 0x30385840,
+	0x30301418, 0x2a1e3c8a, 0x2a3a97c7, 0x30173c7a, 0x300ef0e5, 0x2a440844, 0x2a604ff5, 0x2ff6030a,
+	0x2fedb00d, 0x2a69b9ec, 0x2a85ee00, 0x2fd4ac04, 0x2fcc51a5, 0x2a8f516b, 0x2aab71d0, 0x2fb3377c,
+	0x2faad5c1, 0x2ab4cea9, 0x2ad0db4e, 0x2f91a589, 0x2f893c75, 0x2ada318e, 0x2af62a63, 0x2f6ff63d,
+	0x2f6785d7, 0x2aff7a05, 0x2b1b5ef8, 0x2f4e29af, 0x2f45b1fb, 0x2b24a7f6, 0x2b4078f5, 0x2f2c3ff2,
+	0x2f23c0f6, 0x2b49bb4a, 0x2b657844, 0x2f0a391d, 0x2f01b2de, 0x2b6eb3ea, 0x2b8a5cce, 0x2ee81543,
+	0x2edf87c6, 0x2b9391c0, 0x2baf267d, 0x2ec5d479, 0x2ebd3fc4, 0x2bb854b4, 0x2bd3d53a, 0x2ea376d6,
+	0x2e9adaee, 0x2bdcfcb0, 0x2bf868ed, 0x2e80fc6e, 0x2e785958, 0x2c01899e, 0x2c1ce181, 0x2e5e6556,
+	0x2e55bb17, 0x2c25fb66, 0x2c413edf, 0x2e3bb1a4, 0x2e330042, 0x2c4a51f3, 0x2c6580f1, 0x2e18e16d,
+	0x2e1028ed, 0x2c6e8d2e, 0x2c89a79f, 0x2df5f4c7, 0x2ded352f, 0x2c92ad01, 0x2cadb2d5, 0x2dd2ebc7,
+	0x2dca251c, 0x2cb6b155, 0x2cd1a27b, 0x2dafc683, 0x2da6f8ca, 0x2cda9a14, 0x2cf5767c, 0x2d8c8510,
 	0x2d83b04f, 0x2cfe6728, 0x2d192ec1, 0x2d692784, 0x2d604bc0, 0x2d22187a, 0x2d3ccb34, 0x2d45adf6
 };
 
 const int twidTab512[8*6 + 32*6 + 128*6] = {
-	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3b20d79e, 0x187de2a6, 
-	0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 
-	0x187de2a6, 0x3b20d79e, 0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f, 
-	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xe7821d5a, 0x3b20d79e, 
-	0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 
-	0xc4df2862, 0xe7821d5a, 0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae, 
+	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3b20d79e, 0x187de2a6,
+	0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6,
+	0x187de2a6, 0x3b20d79e, 0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f,
+	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xe7821d5a, 0x3b20d79e,
+	0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e,
+	0xc4df2862, 0xe7821d5a, 0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae,
 
-	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3fb11b47, 0x0645e9af, 
-	0x3fec43c6, 0x0323ecbe, 0x3f4eaafe, 0x09640837, 0x3ec52f9f, 0x0c7c5c1e, 0x3fb11b47, 0x0645e9af, 
-	0x3d3e82ad, 0x1294062e, 0x3d3e82ad, 0x1294062e, 0x3f4eaafe, 0x09640837, 0x39daf5e8, 0x1b5d1009, 
-	0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x387165e3, 0x1e2b5d38, 
-	0x3e14fdf7, 0x0f8cfcbd, 0x2f6bbe44, 0x2afad269, 0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e, 
-	0x2899e64a, 0x317900d6, 0x317900d6, 0x2899e64a, 0x3c424209, 0x158f9a75, 0x20e70f32, 0x36e5068a, 
-	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x2899e64a, 0x317900d6, 
-	0x39daf5e8, 0x1b5d1009, 0x0f8cfcbd, 0x3e14fdf7, 0x238e7673, 0x3536cc52, 0x387165e3, 0x1e2b5d38, 
-	0x0645e9af, 0x3fb11b47, 0x1e2b5d38, 0x387165e3, 0x36e5068a, 0x20e70f32, 0xfcdc1342, 0x3fec43c6, 
-	0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f, 0x1294062e, 0x3d3e82ad, 
-	0x3367c08f, 0x261feff9, 0xea70658b, 0x3c424209, 0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a, 
-	0xe1d4a2c8, 0x387165e3, 0x0645e9af, 0x3fb11b47, 0x2f6bbe44, 0x2afad269, 0xd9e01007, 0x3367c08f, 
-	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xf9ba1651, 0x3fb11b47, 
-	0x2afad269, 0x2f6bbe44, 0xcc983f71, 0x261feff9, 0xf383a3e2, 0x3ec52f9f, 0x2899e64a, 0x317900d6, 
-	0xc78e9a1d, 0x1e2b5d38, 0xed6bf9d2, 0x3d3e82ad, 0x261feff9, 0x3367c08f, 0xc3bdbdf7, 0x158f9a75, 
-	0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xe1d4a2c8, 0x387165e3, 
-	0x20e70f32, 0x36e5068a, 0xc013bc3a, 0x0323ecbe, 0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3, 
-	0xc04ee4b9, 0xf9ba1651, 0xd76619b6, 0x317900d6, 0x1b5d1009, 0x39daf5e8, 0xc1eb0209, 0xf0730343, 
-	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xce86ff2a, 0x2899e64a, 
-	0x158f9a75, 0x3c424209, 0xc91af976, 0xdf18f0ce, 0xcac933ae, 0x238e7673, 0x1294062e, 0x3d3e82ad, 
-	0xce86ff2a, 0xd76619b6, 0xc78e9a1d, 0x1e2b5d38, 0x0f8cfcbd, 0x3e14fdf7, 0xd5052d97, 0xd09441bc, 
-	0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae, 0xc2c17d53, 0x1294062e, 
-	0x09640837, 0x3f4eaafe, 0xe4a2eff7, 0xc6250a18, 0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47, 
-	0xed6bf9d2, 0xc2c17d53, 0xc04ee4b9, 0x0645e9af, 0x0323ecbe, 0x3fec43c6, 0xf69bf7c9, 0xc0b15502, 
+	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3fb11b47, 0x0645e9af,
+	0x3fec43c6, 0x0323ecbe, 0x3f4eaafe, 0x09640837, 0x3ec52f9f, 0x0c7c5c1e, 0x3fb11b47, 0x0645e9af,
+	0x3d3e82ad, 0x1294062e, 0x3d3e82ad, 0x1294062e, 0x3f4eaafe, 0x09640837, 0x39daf5e8, 0x1b5d1009,
+	0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x387165e3, 0x1e2b5d38,
+	0x3e14fdf7, 0x0f8cfcbd, 0x2f6bbe44, 0x2afad269, 0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e,
+	0x2899e64a, 0x317900d6, 0x317900d6, 0x2899e64a, 0x3c424209, 0x158f9a75, 0x20e70f32, 0x36e5068a,
+	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x2899e64a, 0x317900d6,
+	0x39daf5e8, 0x1b5d1009, 0x0f8cfcbd, 0x3e14fdf7, 0x238e7673, 0x3536cc52, 0x387165e3, 0x1e2b5d38,
+	0x0645e9af, 0x3fb11b47, 0x1e2b5d38, 0x387165e3, 0x36e5068a, 0x20e70f32, 0xfcdc1342, 0x3fec43c6,
+	0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f, 0x1294062e, 0x3d3e82ad,
+	0x3367c08f, 0x261feff9, 0xea70658b, 0x3c424209, 0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a,
+	0xe1d4a2c8, 0x387165e3, 0x0645e9af, 0x3fb11b47, 0x2f6bbe44, 0x2afad269, 0xd9e01007, 0x3367c08f,
+	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xf9ba1651, 0x3fb11b47,
+	0x2afad269, 0x2f6bbe44, 0xcc983f71, 0x261feff9, 0xf383a3e2, 0x3ec52f9f, 0x2899e64a, 0x317900d6,
+	0xc78e9a1d, 0x1e2b5d38, 0xed6bf9d2, 0x3d3e82ad, 0x261feff9, 0x3367c08f, 0xc3bdbdf7, 0x158f9a75,
+	0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xe1d4a2c8, 0x387165e3,
+	0x20e70f32, 0x36e5068a, 0xc013bc3a, 0x0323ecbe, 0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3,
+	0xc04ee4b9, 0xf9ba1651, 0xd76619b6, 0x317900d6, 0x1b5d1009, 0x39daf5e8, 0xc1eb0209, 0xf0730343,
+	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xce86ff2a, 0x2899e64a,
+	0x158f9a75, 0x3c424209, 0xc91af976, 0xdf18f0ce, 0xcac933ae, 0x238e7673, 0x1294062e, 0x3d3e82ad,
+	0xce86ff2a, 0xd76619b6, 0xc78e9a1d, 0x1e2b5d38, 0x0f8cfcbd, 0x3e14fdf7, 0xd5052d97, 0xd09441bc,
+	0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae, 0xc2c17d53, 0x1294062e,
+	0x09640837, 0x3f4eaafe, 0xe4a2eff7, 0xc6250a18, 0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47,
+	0xed6bf9d2, 0xc2c17d53, 0xc04ee4b9, 0x0645e9af, 0x0323ecbe, 0x3fec43c6, 0xf69bf7c9, 0xc0b15502,
 
-	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3ffb10c1, 0x0192155f, 
-	0x3ffec42d, 0x00c90e8f, 0x3ff4e5df, 0x025b0cae, 0x3fec43c6, 0x0323ecbe, 0x3ffb10c1, 0x0192155f, 
-	0x3fd39b5a, 0x04b54824, 0x3fd39b5a, 0x04b54824, 0x3ff4e5df, 0x025b0cae, 0x3f9c2bfa, 0x070de171, 
-	0x3fb11b47, 0x0645e9af, 0x3fec43c6, 0x0323ecbe, 0x3f4eaafe, 0x09640837, 0x3f84c8e1, 0x07d59395, 
-	0x3fe12acb, 0x03ecadcf, 0x3eeb3347, 0x0bb6ecef, 0x3f4eaafe, 0x09640837, 0x3fd39b5a, 0x04b54824, 
-	0x3e71e758, 0x0e05c135, 0x3f0ec9f4, 0x0af10a22, 0x3fc395f9, 0x057db402, 0x3de2f147, 0x104fb80e, 
-	0x3ec52f9f, 0x0c7c5c1e, 0x3fb11b47, 0x0645e9af, 0x3d3e82ad, 0x1294062e, 0x3e71e758, 0x0e05c135, 
-	0x3f9c2bfa, 0x070de171, 0x3c84d496, 0x14d1e242, 0x3e14fdf7, 0x0f8cfcbd, 0x3f84c8e1, 0x07d59395, 
-	0x3bb6276d, 0x17088530, 0x3dae81ce, 0x1111d262, 0x3f6af2e3, 0x089cf867, 0x3ad2c2e7, 0x19372a63, 
-	0x3d3e82ad, 0x1294062e, 0x3f4eaafe, 0x09640837, 0x39daf5e8, 0x1b5d1009, 0x3cc511d8, 0x14135c94, 
-	0x3f2ff249, 0x0a2abb58, 0x38cf1669, 0x1d79775b, 0x3c424209, 0x158f9a75, 0x3f0ec9f4, 0x0af10a22, 
-	0x37af8158, 0x1f8ba4db, 0x3bb6276d, 0x17088530, 0x3eeb3347, 0x0bb6ecef, 0x367c9a7d, 0x2192e09a, 
-	0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x3a8269a2, 0x19ef7943, 
-	0x3e9cc076, 0x0d415012, 0x33de87de, 0x257db64b, 0x39daf5e8, 0x1b5d1009, 0x3e71e758, 0x0e05c135, 
-	0x32744493, 0x275ff452, 0x392a9642, 0x1cc66e99, 0x3e44a5ee, 0x0ec9a7f2, 0x30f8801f, 0x29348937, 
-	0x387165e3, 0x1e2b5d38, 0x3e14fdf7, 0x0f8cfcbd, 0x2f6bbe44, 0x2afad269, 0x37af8158, 0x1f8ba4db, 
-	0x3de2f147, 0x104fb80e, 0x2dce88a9, 0x2cb2324b, 0x36e5068a, 0x20e70f32, 0x3dae81ce, 0x1111d262, 
-	0x2c216eaa, 0x2e5a106f, 0x361214b0, 0x223d66a8, 0x3d77b191, 0x11d3443f, 0x2a650525, 0x2ff1d9c6, 
-	0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e, 0x2899e64a, 0x317900d6, 0x34534f40, 0x24da0a99, 
-	0x3d02f756, 0x135410c2, 0x26c0b162, 0x32eefde9, 0x3367c08f, 0x261feff9, 0x3cc511d8, 0x14135c94, 
-	0x24da0a99, 0x34534f40, 0x32744493, 0x275ff452, 0x3c84d496, 0x14d1e242, 0x22e69ac7, 0x35a5793c, 
-	0x317900d6, 0x2899e64a, 0x3c424209, 0x158f9a75, 0x20e70f32, 0x36e5068a, 0x30761c17, 0x29cd9577, 
-	0x3bfd5cc4, 0x164c7ddd, 0x1edc1952, 0x3811884c, 0x2f6bbe44, 0x2afad269, 0x3bb6276d, 0x17088530, 
-	0x1cc66e99, 0x392a9642, 0x2e5a106f, 0x2c216eaa, 0x3b6ca4c4, 0x17c3a931, 0x1aa6c82b, 0x3a2fcee8, 
-	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x2c216eaa, 0x2e5a106f, 
-	0x3ad2c2e7, 0x19372a63, 0x164c7ddd, 0x3bfd5cc4, 0x2afad269, 0x2f6bbe44, 0x3a8269a2, 0x19ef7943, 
-	0x14135c94, 0x3cc511d8, 0x29cd9577, 0x30761c17, 0x3a2fcee8, 0x1aa6c82b, 0x11d3443f, 0x3d77b191, 
-	0x2899e64a, 0x317900d6, 0x39daf5e8, 0x1b5d1009, 0x0f8cfcbd, 0x3e14fdf7, 0x275ff452, 0x32744493, 
-	0x3983e1e7, 0x1c1249d8, 0x0d415012, 0x3e9cc076, 0x261feff9, 0x3367c08f, 0x392a9642, 0x1cc66e99, 
-	0x0af10a22, 0x3f0ec9f4, 0x24da0a99, 0x34534f40, 0x38cf1669, 0x1d79775b, 0x089cf867, 0x3f6af2e3, 
-	0x238e7673, 0x3536cc52, 0x387165e3, 0x1e2b5d38, 0x0645e9af, 0x3fb11b47, 0x223d66a8, 0x361214b0, 
-	0x3811884c, 0x1edc1952, 0x03ecadcf, 0x3fe12acb, 0x20e70f32, 0x36e5068a, 0x37af8158, 0x1f8ba4db, 
-	0x0192155f, 0x3ffb10c1, 0x1f8ba4db, 0x37af8158, 0x374b54ce, 0x2039f90e, 0xff36f171, 0x3ffec42d, 
-	0x1e2b5d38, 0x387165e3, 0x36e5068a, 0x20e70f32, 0xfcdc1342, 0x3fec43c6, 0x1cc66e99, 0x392a9642, 
-	0x367c9a7d, 0x2192e09a, 0xfa824bfe, 0x3fc395f9, 0x1b5d1009, 0x39daf5e8, 0x361214b0, 0x223d66a8, 
-	0xf82a6c6b, 0x3f84c8e1, 0x19ef7943, 0x3a8269a2, 0x35a5793c, 0x22e69ac7, 0xf5d544a8, 0x3f2ff249, 
-	0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f, 0x17088530, 0x3bb6276d, 
-	0x34c61236, 0x2434f332, 0xf136580e, 0x3e44a5ee, 0x158f9a75, 0x3c424209, 0x34534f40, 0x24da0a99, 
-	0xeeee2d9e, 0x3dae81ce, 0x14135c94, 0x3cc511d8, 0x33de87de, 0x257db64b, 0xecabef3e, 0x3d02f756, 
-	0x1294062e, 0x3d3e82ad, 0x3367c08f, 0x261feff9, 0xea70658b, 0x3c424209, 0x1111d262, 0x3dae81ce, 
-	0x32eefde9, 0x26c0b162, 0xe83c56cf, 0x3b6ca4c4, 0x0f8cfcbd, 0x3e14fdf7, 0x32744493, 0x275ff452, 
-	0xe61086bd, 0x3a8269a2, 0x0e05c135, 0x3e71e758, 0x31f79947, 0x27fdb2a6, 0xe3edb628, 0x3983e1e7, 
-	0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a, 0xe1d4a2c8, 0x387165e3, 0x0af10a22, 0x3f0ec9f4, 
-	0x30f8801f, 0x29348937, 0xdfc606f2, 0x374b54ce, 0x09640837, 0x3f4eaafe, 0x30761c17, 0x29cd9577, 
-	0xddc29958, 0x361214b0, 0x07d59395, 0x3f84c8e1, 0x2ff1d9c6, 0x2a650525, 0xdbcb0cce, 0x34c61236, 
-	0x0645e9af, 0x3fb11b47, 0x2f6bbe44, 0x2afad269, 0xd9e01007, 0x3367c08f, 0x04b54824, 0x3fd39b5a, 
-	0x2ee3cebe, 0x2b8ef77c, 0xd8024d5a, 0x31f79947, 0x0323ecbe, 0x3fec43c6, 0x2e5a106f, 0x2c216eaa, 
-	0xd6326a89, 0x30761c17, 0x0192155f, 0x3ffb10c1, 0x2dce88a9, 0x2cb2324b, 0xd4710884, 0x2ee3cebe, 
-	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xfe6deaa1, 0x3ffb10c1, 
-	0x2cb2324b, 0x2dce88a9, 0xd11c3142, 0x2b8ef77c, 0xfcdc1342, 0x3fec43c6, 0x2c216eaa, 0x2e5a106f, 
-	0xcf89e3e9, 0x29cd9577, 0xfb4ab7dc, 0x3fd39b5a, 0x2b8ef77c, 0x2ee3cebe, 0xce0866b9, 0x27fdb2a6, 
-	0xf9ba1651, 0x3fb11b47, 0x2afad269, 0x2f6bbe44, 0xcc983f71, 0x261feff9, 0xf82a6c6b, 0x3f84c8e1, 
-	0x2a650525, 0x2ff1d9c6, 0xcb39edca, 0x2434f332, 0xf69bf7c9, 0x3f4eaafe, 0x29cd9577, 0x30761c17, 
-	0xc9edeb50, 0x223d66a8, 0xf50ef5de, 0x3f0ec9f4, 0x29348937, 0x30f8801f, 0xc8b4ab32, 0x2039f90e, 
-	0xf383a3e2, 0x3ec52f9f, 0x2899e64a, 0x317900d6, 0xc78e9a1d, 0x1e2b5d38, 0xf1fa3ecb, 0x3e71e758, 
-	0x27fdb2a6, 0x31f79947, 0xc67c1e19, 0x1c1249d8, 0xf0730343, 0x3e14fdf7, 0x275ff452, 0x32744493, 
-	0xc57d965e, 0x19ef7943, 0xeeee2d9e, 0x3dae81ce, 0x26c0b162, 0x32eefde9, 0xc4935b3c, 0x17c3a931, 
-	0xed6bf9d2, 0x3d3e82ad, 0x261feff9, 0x3367c08f, 0xc3bdbdf7, 0x158f9a75, 0xebeca36c, 0x3cc511d8, 
-	0x257db64b, 0x33de87de, 0xc2fd08aa, 0x135410c2, 0xea70658b, 0x3c424209, 0x24da0a99, 0x34534f40, 
-	0xc2517e32, 0x1111d262, 0xe8f77ad0, 0x3bb6276d, 0x2434f332, 0x34c61236, 0xc1bb5a12, 0x0ec9a7f2, 
-	0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xe61086bd, 0x3a8269a2, 
-	0x22e69ac7, 0x35a5793c, 0xc0d00db7, 0x0a2abb58, 0xe4a2eff7, 0x39daf5e8, 0x223d66a8, 0x361214b0, 
-	0xc07b371f, 0x07d59395, 0xe3399167, 0x392a9642, 0x2192e09a, 0x367c9a7d, 0xc03c6a07, 0x057db402, 
-	0xe1d4a2c8, 0x387165e3, 0x20e70f32, 0x36e5068a, 0xc013bc3a, 0x0323ecbe, 0xe0745b25, 0x37af8158, 
-	0x2039f90e, 0x374b54ce, 0xc0013bd3, 0x00c90e8f, 0xdf18f0ce, 0x36e5068a, 0x1f8ba4db, 0x37af8158, 
-	0xc004ef3f, 0xfe6deaa1, 0xddc29958, 0x361214b0, 0x1edc1952, 0x3811884c, 0xc01ed535, 0xfc135231, 
-	0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3, 0xc04ee4b9, 0xf9ba1651, 0xdb25f567, 0x34534f40, 
-	0x1d79775b, 0x38cf1669, 0xc0950d1d, 0xf7630799, 0xd9e01007, 0x3367c08f, 0x1cc66e99, 0x392a9642, 
-	0xc0f1360c, 0xf50ef5de, 0xd8a00bae, 0x32744493, 0x1c1249d8, 0x3983e1e7, 0xc1633f8a, 0xf2beafee, 
-	0xd76619b6, 0x317900d6, 0x1b5d1009, 0x39daf5e8, 0xc1eb0209, 0xf0730343, 0xd6326a89, 0x30761c17, 
-	0x1aa6c82b, 0x3a2fcee8, 0xc2884e6f, 0xee2cbbc1, 0xd5052d97, 0x2f6bbe44, 0x19ef7943, 0x3a8269a2, 
-	0xc33aee28, 0xebeca36c, 0xd3de9156, 0x2e5a106f, 0x19372a63, 0x3ad2c2e7, 0xc402a33c, 0xe9b38223, 
-	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xd1a5ef91, 0x2c216eaa, 
-	0x17c3a931, 0x3b6ca4c4, 0xc5d03118, 0xe55937d5, 0xd09441bc, 0x2afad269, 0x17088530, 0x3bb6276d, 
-	0xc6d569be, 0xe3399167, 0xcf89e3e9, 0x29cd9577, 0x164c7ddd, 0x3bfd5cc4, 0xc7ee77b4, 0xe123e6ae, 
-	0xce86ff2a, 0x2899e64a, 0x158f9a75, 0x3c424209, 0xc91af976, 0xdf18f0ce, 0xcd8bbb6d, 0x275ff452, 
-	0x14d1e242, 0x3c84d496, 0xca5a86c4, 0xdd196539, 0xcc983f71, 0x261feff9, 0x14135c94, 0x3cc511d8, 
-	0xcbacb0c0, 0xdb25f567, 0xcbacb0c0, 0x24da0a99, 0x135410c2, 0x3d02f756, 0xcd110217, 0xd93f4e9e, 
-	0xcac933ae, 0x238e7673, 0x1294062e, 0x3d3e82ad, 0xce86ff2a, 0xd76619b6, 0xc9edeb50, 0x223d66a8, 
-	0x11d3443f, 0x3d77b191, 0xd00e263a, 0xd59afadb, 0xc91af976, 0x20e70f32, 0x1111d262, 0x3dae81ce, 
-	0xd1a5ef91, 0xd3de9156, 0xc8507ea8, 0x1f8ba4db, 0x104fb80e, 0x3de2f147, 0xd34dcdb5, 0xd2317757, 
-	0xc78e9a1d, 0x1e2b5d38, 0x0f8cfcbd, 0x3e14fdf7, 0xd5052d97, 0xd09441bc, 0xc6d569be, 0x1cc66e99, 
-	0x0ec9a7f2, 0x3e44a5ee, 0xd6cb76c9, 0xcf077fe1, 0xc6250a18, 0x1b5d1009, 0x0e05c135, 0x3e71e758, 
-	0xd8a00bae, 0xcd8bbb6d, 0xc57d965e, 0x19ef7943, 0x0d415012, 0x3e9cc076, 0xda8249b5, 0xcc217822, 
-	0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae, 0xc449d893, 0x17088530, 
-	0x0bb6ecef, 0x3eeb3347, 0xde6d1f66, 0xc9836583, 0xc3bdbdf7, 0x158f9a75, 0x0af10a22, 0x3f0ec9f4, 
-	0xe0745b25, 0xc8507ea8, 0xc33aee28, 0x14135c94, 0x0a2abb58, 0x3f2ff249, 0xe28688a5, 0xc730e997, 
-	0xc2c17d53, 0x1294062e, 0x09640837, 0x3f4eaafe, 0xe4a2eff7, 0xc6250a18, 0xc2517e32, 0x1111d262, 
-	0x089cf867, 0x3f6af2e3, 0xe6c8d59d, 0xc52d3d19, 0xc1eb0209, 0x0f8cfcbd, 0x07d59395, 0x3f84c8e1, 
-	0xe8f77ad0, 0xc449d893, 0xc18e18a8, 0x0e05c135, 0x070de171, 0x3f9c2bfa, 0xeb2e1dbe, 0xc37b2b6a, 
-	0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47, 0xed6bf9d2, 0xc2c17d53, 0xc0f1360c, 0x0af10a22, 
-	0x057db402, 0x3fc395f9, 0xefb047f2, 0xc21d0eb9, 0xc0b15502, 0x09640837, 0x04b54824, 0x3fd39b5a, 
-	0xf1fa3ecb, 0xc18e18a8, 0xc07b371f, 0x07d59395, 0x03ecadcf, 0x3fe12acb, 0xf4491311, 0xc114ccb9, 
-	0xc04ee4b9, 0x0645e9af, 0x0323ecbe, 0x3fec43c6, 0xf69bf7c9, 0xc0b15502, 0xc02c64a6, 0x04b54824, 
-	0x025b0cae, 0x3ff4e5df, 0xf8f21e8f, 0xc063d406, 0xc013bc3a, 0x0323ecbe, 0x0192155f, 0x3ffb10c1, 
+	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3ffb10c1, 0x0192155f,
+	0x3ffec42d, 0x00c90e8f, 0x3ff4e5df, 0x025b0cae, 0x3fec43c6, 0x0323ecbe, 0x3ffb10c1, 0x0192155f,
+	0x3fd39b5a, 0x04b54824, 0x3fd39b5a, 0x04b54824, 0x3ff4e5df, 0x025b0cae, 0x3f9c2bfa, 0x070de171,
+	0x3fb11b47, 0x0645e9af, 0x3fec43c6, 0x0323ecbe, 0x3f4eaafe, 0x09640837, 0x3f84c8e1, 0x07d59395,
+	0x3fe12acb, 0x03ecadcf, 0x3eeb3347, 0x0bb6ecef, 0x3f4eaafe, 0x09640837, 0x3fd39b5a, 0x04b54824,
+	0x3e71e758, 0x0e05c135, 0x3f0ec9f4, 0x0af10a22, 0x3fc395f9, 0x057db402, 0x3de2f147, 0x104fb80e,
+	0x3ec52f9f, 0x0c7c5c1e, 0x3fb11b47, 0x0645e9af, 0x3d3e82ad, 0x1294062e, 0x3e71e758, 0x0e05c135,
+	0x3f9c2bfa, 0x070de171, 0x3c84d496, 0x14d1e242, 0x3e14fdf7, 0x0f8cfcbd, 0x3f84c8e1, 0x07d59395,
+	0x3bb6276d, 0x17088530, 0x3dae81ce, 0x1111d262, 0x3f6af2e3, 0x089cf867, 0x3ad2c2e7, 0x19372a63,
+	0x3d3e82ad, 0x1294062e, 0x3f4eaafe, 0x09640837, 0x39daf5e8, 0x1b5d1009, 0x3cc511d8, 0x14135c94,
+	0x3f2ff249, 0x0a2abb58, 0x38cf1669, 0x1d79775b, 0x3c424209, 0x158f9a75, 0x3f0ec9f4, 0x0af10a22,
+	0x37af8158, 0x1f8ba4db, 0x3bb6276d, 0x17088530, 0x3eeb3347, 0x0bb6ecef, 0x367c9a7d, 0x2192e09a,
+	0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e, 0x3536cc52, 0x238e7673, 0x3a8269a2, 0x19ef7943,
+	0x3e9cc076, 0x0d415012, 0x33de87de, 0x257db64b, 0x39daf5e8, 0x1b5d1009, 0x3e71e758, 0x0e05c135,
+	0x32744493, 0x275ff452, 0x392a9642, 0x1cc66e99, 0x3e44a5ee, 0x0ec9a7f2, 0x30f8801f, 0x29348937,
+	0x387165e3, 0x1e2b5d38, 0x3e14fdf7, 0x0f8cfcbd, 0x2f6bbe44, 0x2afad269, 0x37af8158, 0x1f8ba4db,
+	0x3de2f147, 0x104fb80e, 0x2dce88a9, 0x2cb2324b, 0x36e5068a, 0x20e70f32, 0x3dae81ce, 0x1111d262,
+	0x2c216eaa, 0x2e5a106f, 0x361214b0, 0x223d66a8, 0x3d77b191, 0x11d3443f, 0x2a650525, 0x2ff1d9c6,
+	0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e, 0x2899e64a, 0x317900d6, 0x34534f40, 0x24da0a99,
+	0x3d02f756, 0x135410c2, 0x26c0b162, 0x32eefde9, 0x3367c08f, 0x261feff9, 0x3cc511d8, 0x14135c94,
+	0x24da0a99, 0x34534f40, 0x32744493, 0x275ff452, 0x3c84d496, 0x14d1e242, 0x22e69ac7, 0x35a5793c,
+	0x317900d6, 0x2899e64a, 0x3c424209, 0x158f9a75, 0x20e70f32, 0x36e5068a, 0x30761c17, 0x29cd9577,
+	0x3bfd5cc4, 0x164c7ddd, 0x1edc1952, 0x3811884c, 0x2f6bbe44, 0x2afad269, 0x3bb6276d, 0x17088530,
+	0x1cc66e99, 0x392a9642, 0x2e5a106f, 0x2c216eaa, 0x3b6ca4c4, 0x17c3a931, 0x1aa6c82b, 0x3a2fcee8,
+	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x2c216eaa, 0x2e5a106f,
+	0x3ad2c2e7, 0x19372a63, 0x164c7ddd, 0x3bfd5cc4, 0x2afad269, 0x2f6bbe44, 0x3a8269a2, 0x19ef7943,
+	0x14135c94, 0x3cc511d8, 0x29cd9577, 0x30761c17, 0x3a2fcee8, 0x1aa6c82b, 0x11d3443f, 0x3d77b191,
+	0x2899e64a, 0x317900d6, 0x39daf5e8, 0x1b5d1009, 0x0f8cfcbd, 0x3e14fdf7, 0x275ff452, 0x32744493,
+	0x3983e1e7, 0x1c1249d8, 0x0d415012, 0x3e9cc076, 0x261feff9, 0x3367c08f, 0x392a9642, 0x1cc66e99,
+	0x0af10a22, 0x3f0ec9f4, 0x24da0a99, 0x34534f40, 0x38cf1669, 0x1d79775b, 0x089cf867, 0x3f6af2e3,
+	0x238e7673, 0x3536cc52, 0x387165e3, 0x1e2b5d38, 0x0645e9af, 0x3fb11b47, 0x223d66a8, 0x361214b0,
+	0x3811884c, 0x1edc1952, 0x03ecadcf, 0x3fe12acb, 0x20e70f32, 0x36e5068a, 0x37af8158, 0x1f8ba4db,
+	0x0192155f, 0x3ffb10c1, 0x1f8ba4db, 0x37af8158, 0x374b54ce, 0x2039f90e, 0xff36f171, 0x3ffec42d,
+	0x1e2b5d38, 0x387165e3, 0x36e5068a, 0x20e70f32, 0xfcdc1342, 0x3fec43c6, 0x1cc66e99, 0x392a9642,
+	0x367c9a7d, 0x2192e09a, 0xfa824bfe, 0x3fc395f9, 0x1b5d1009, 0x39daf5e8, 0x361214b0, 0x223d66a8,
+	0xf82a6c6b, 0x3f84c8e1, 0x19ef7943, 0x3a8269a2, 0x35a5793c, 0x22e69ac7, 0xf5d544a8, 0x3f2ff249,
+	0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 0xf383a3e2, 0x3ec52f9f, 0x17088530, 0x3bb6276d,
+	0x34c61236, 0x2434f332, 0xf136580e, 0x3e44a5ee, 0x158f9a75, 0x3c424209, 0x34534f40, 0x24da0a99,
+	0xeeee2d9e, 0x3dae81ce, 0x14135c94, 0x3cc511d8, 0x33de87de, 0x257db64b, 0xecabef3e, 0x3d02f756,
+	0x1294062e, 0x3d3e82ad, 0x3367c08f, 0x261feff9, 0xea70658b, 0x3c424209, 0x1111d262, 0x3dae81ce,
+	0x32eefde9, 0x26c0b162, 0xe83c56cf, 0x3b6ca4c4, 0x0f8cfcbd, 0x3e14fdf7, 0x32744493, 0x275ff452,
+	0xe61086bd, 0x3a8269a2, 0x0e05c135, 0x3e71e758, 0x31f79947, 0x27fdb2a6, 0xe3edb628, 0x3983e1e7,
+	0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a, 0xe1d4a2c8, 0x387165e3, 0x0af10a22, 0x3f0ec9f4,
+	0x30f8801f, 0x29348937, 0xdfc606f2, 0x374b54ce, 0x09640837, 0x3f4eaafe, 0x30761c17, 0x29cd9577,
+	0xddc29958, 0x361214b0, 0x07d59395, 0x3f84c8e1, 0x2ff1d9c6, 0x2a650525, 0xdbcb0cce, 0x34c61236,
+	0x0645e9af, 0x3fb11b47, 0x2f6bbe44, 0x2afad269, 0xd9e01007, 0x3367c08f, 0x04b54824, 0x3fd39b5a,
+	0x2ee3cebe, 0x2b8ef77c, 0xd8024d5a, 0x31f79947, 0x0323ecbe, 0x3fec43c6, 0x2e5a106f, 0x2c216eaa,
+	0xd6326a89, 0x30761c17, 0x0192155f, 0x3ffb10c1, 0x2dce88a9, 0x2cb2324b, 0xd4710884, 0x2ee3cebe,
+	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xfe6deaa1, 0x3ffb10c1,
+	0x2cb2324b, 0x2dce88a9, 0xd11c3142, 0x2b8ef77c, 0xfcdc1342, 0x3fec43c6, 0x2c216eaa, 0x2e5a106f,
+	0xcf89e3e9, 0x29cd9577, 0xfb4ab7dc, 0x3fd39b5a, 0x2b8ef77c, 0x2ee3cebe, 0xce0866b9, 0x27fdb2a6,
+	0xf9ba1651, 0x3fb11b47, 0x2afad269, 0x2f6bbe44, 0xcc983f71, 0x261feff9, 0xf82a6c6b, 0x3f84c8e1,
+	0x2a650525, 0x2ff1d9c6, 0xcb39edca, 0x2434f332, 0xf69bf7c9, 0x3f4eaafe, 0x29cd9577, 0x30761c17,
+	0xc9edeb50, 0x223d66a8, 0xf50ef5de, 0x3f0ec9f4, 0x29348937, 0x30f8801f, 0xc8b4ab32, 0x2039f90e,
+	0xf383a3e2, 0x3ec52f9f, 0x2899e64a, 0x317900d6, 0xc78e9a1d, 0x1e2b5d38, 0xf1fa3ecb, 0x3e71e758,
+	0x27fdb2a6, 0x31f79947, 0xc67c1e19, 0x1c1249d8, 0xf0730343, 0x3e14fdf7, 0x275ff452, 0x32744493,
+	0xc57d965e, 0x19ef7943, 0xeeee2d9e, 0x3dae81ce, 0x26c0b162, 0x32eefde9, 0xc4935b3c, 0x17c3a931,
+	0xed6bf9d2, 0x3d3e82ad, 0x261feff9, 0x3367c08f, 0xc3bdbdf7, 0x158f9a75, 0xebeca36c, 0x3cc511d8,
+	0x257db64b, 0x33de87de, 0xc2fd08aa, 0x135410c2, 0xea70658b, 0x3c424209, 0x24da0a99, 0x34534f40,
+	0xc2517e32, 0x1111d262, 0xe8f77ad0, 0x3bb6276d, 0x2434f332, 0x34c61236, 0xc1bb5a12, 0x0ec9a7f2,
+	0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52, 0xc13ad061, 0x0c7c5c1e, 0xe61086bd, 0x3a8269a2,
+	0x22e69ac7, 0x35a5793c, 0xc0d00db7, 0x0a2abb58, 0xe4a2eff7, 0x39daf5e8, 0x223d66a8, 0x361214b0,
+	0xc07b371f, 0x07d59395, 0xe3399167, 0x392a9642, 0x2192e09a, 0x367c9a7d, 0xc03c6a07, 0x057db402,
+	0xe1d4a2c8, 0x387165e3, 0x20e70f32, 0x36e5068a, 0xc013bc3a, 0x0323ecbe, 0xe0745b25, 0x37af8158,
+	0x2039f90e, 0x374b54ce, 0xc0013bd3, 0x00c90e8f, 0xdf18f0ce, 0x36e5068a, 0x1f8ba4db, 0x37af8158,
+	0xc004ef3f, 0xfe6deaa1, 0xddc29958, 0x361214b0, 0x1edc1952, 0x3811884c, 0xc01ed535, 0xfc135231,
+	0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3, 0xc04ee4b9, 0xf9ba1651, 0xdb25f567, 0x34534f40,
+	0x1d79775b, 0x38cf1669, 0xc0950d1d, 0xf7630799, 0xd9e01007, 0x3367c08f, 0x1cc66e99, 0x392a9642,
+	0xc0f1360c, 0xf50ef5de, 0xd8a00bae, 0x32744493, 0x1c1249d8, 0x3983e1e7, 0xc1633f8a, 0xf2beafee,
+	0xd76619b6, 0x317900d6, 0x1b5d1009, 0x39daf5e8, 0xc1eb0209, 0xf0730343, 0xd6326a89, 0x30761c17,
+	0x1aa6c82b, 0x3a2fcee8, 0xc2884e6f, 0xee2cbbc1, 0xd5052d97, 0x2f6bbe44, 0x19ef7943, 0x3a8269a2,
+	0xc33aee28, 0xebeca36c, 0xd3de9156, 0x2e5a106f, 0x19372a63, 0x3ad2c2e7, 0xc402a33c, 0xe9b38223,
+	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xd1a5ef91, 0x2c216eaa,
+	0x17c3a931, 0x3b6ca4c4, 0xc5d03118, 0xe55937d5, 0xd09441bc, 0x2afad269, 0x17088530, 0x3bb6276d,
+	0xc6d569be, 0xe3399167, 0xcf89e3e9, 0x29cd9577, 0x164c7ddd, 0x3bfd5cc4, 0xc7ee77b4, 0xe123e6ae,
+	0xce86ff2a, 0x2899e64a, 0x158f9a75, 0x3c424209, 0xc91af976, 0xdf18f0ce, 0xcd8bbb6d, 0x275ff452,
+	0x14d1e242, 0x3c84d496, 0xca5a86c4, 0xdd196539, 0xcc983f71, 0x261feff9, 0x14135c94, 0x3cc511d8,
+	0xcbacb0c0, 0xdb25f567, 0xcbacb0c0, 0x24da0a99, 0x135410c2, 0x3d02f756, 0xcd110217, 0xd93f4e9e,
+	0xcac933ae, 0x238e7673, 0x1294062e, 0x3d3e82ad, 0xce86ff2a, 0xd76619b6, 0xc9edeb50, 0x223d66a8,
+	0x11d3443f, 0x3d77b191, 0xd00e263a, 0xd59afadb, 0xc91af976, 0x20e70f32, 0x1111d262, 0x3dae81ce,
+	0xd1a5ef91, 0xd3de9156, 0xc8507ea8, 0x1f8ba4db, 0x104fb80e, 0x3de2f147, 0xd34dcdb5, 0xd2317757,
+	0xc78e9a1d, 0x1e2b5d38, 0x0f8cfcbd, 0x3e14fdf7, 0xd5052d97, 0xd09441bc, 0xc6d569be, 0x1cc66e99,
+	0x0ec9a7f2, 0x3e44a5ee, 0xd6cb76c9, 0xcf077fe1, 0xc6250a18, 0x1b5d1009, 0x0e05c135, 0x3e71e758,
+	0xd8a00bae, 0xcd8bbb6d, 0xc57d965e, 0x19ef7943, 0x0d415012, 0x3e9cc076, 0xda8249b5, 0xcc217822,
+	0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 0xdc71898d, 0xcac933ae, 0xc449d893, 0x17088530,
+	0x0bb6ecef, 0x3eeb3347, 0xde6d1f66, 0xc9836583, 0xc3bdbdf7, 0x158f9a75, 0x0af10a22, 0x3f0ec9f4,
+	0xe0745b25, 0xc8507ea8, 0xc33aee28, 0x14135c94, 0x0a2abb58, 0x3f2ff249, 0xe28688a5, 0xc730e997,
+	0xc2c17d53, 0x1294062e, 0x09640837, 0x3f4eaafe, 0xe4a2eff7, 0xc6250a18, 0xc2517e32, 0x1111d262,
+	0x089cf867, 0x3f6af2e3, 0xe6c8d59d, 0xc52d3d19, 0xc1eb0209, 0x0f8cfcbd, 0x07d59395, 0x3f84c8e1,
+	0xe8f77ad0, 0xc449d893, 0xc18e18a8, 0x0e05c135, 0x070de171, 0x3f9c2bfa, 0xeb2e1dbe, 0xc37b2b6a,
+	0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47, 0xed6bf9d2, 0xc2c17d53, 0xc0f1360c, 0x0af10a22,
+	0x057db402, 0x3fc395f9, 0xefb047f2, 0xc21d0eb9, 0xc0b15502, 0x09640837, 0x04b54824, 0x3fd39b5a,
+	0xf1fa3ecb, 0xc18e18a8, 0xc07b371f, 0x07d59395, 0x03ecadcf, 0x3fe12acb, 0xf4491311, 0xc114ccb9,
+	0xc04ee4b9, 0x0645e9af, 0x0323ecbe, 0x3fec43c6, 0xf69bf7c9, 0xc0b15502, 0xc02c64a6, 0x04b54824,
+	0x025b0cae, 0x3ff4e5df, 0xf8f21e8f, 0xc063d406, 0xc013bc3a, 0x0323ecbe, 0x0192155f, 0x3ffb10c1,
 	0xfb4ab7dc, 0xc02c64a6, 0xc004ef3f, 0x0192155f, 0x00c90e8f, 0x3ffec42d, 0xfda4f352, 0xc00b1a21
 };
 
 const int twidTab64[4*6 + 16*6] = {
-	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x2d413ccc, 0x2d413ccc, 
-	0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 
-	0xd2bec334, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 
+	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x2d413ccc, 0x2d413ccc,
+	0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc,
+	0xd2bec334, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a,
 
-	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3ec52f9f, 0x0c7c5c1e, 
-	0x3fb11b47, 0x0645e9af, 0x3d3e82ad, 0x1294062e, 0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e, 
-	0x3536cc52, 0x238e7673, 0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e, 0x2899e64a, 0x317900d6, 
-	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x238e7673, 0x3536cc52, 
-	0x387165e3, 0x1e2b5d38, 0x0645e9af, 0x3fb11b47, 0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673, 
-	0xf383a3e2, 0x3ec52f9f, 0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a, 0xe1d4a2c8, 0x387165e3, 
-	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xf383a3e2, 0x3ec52f9f, 
-	0x2899e64a, 0x317900d6, 0xc78e9a1d, 0x1e2b5d38, 0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52, 
-	0xc13ad061, 0x0c7c5c1e, 0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3, 0xc04ee4b9, 0xf9ba1651, 
-	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xcac933ae, 0x238e7673, 
-	0x1294062e, 0x3d3e82ad, 0xce86ff2a, 0xd76619b6, 0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f, 
-	0xdc71898d, 0xcac933ae, 0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47, 0xed6bf9d2, 0xc2c17d53 
+	0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x40000000, 0x00000000, 0x3ec52f9f, 0x0c7c5c1e,
+	0x3fb11b47, 0x0645e9af, 0x3d3e82ad, 0x1294062e, 0x3b20d79e, 0x187de2a6, 0x3ec52f9f, 0x0c7c5c1e,
+	0x3536cc52, 0x238e7673, 0x3536cc52, 0x238e7673, 0x3d3e82ad, 0x1294062e, 0x2899e64a, 0x317900d6,
+	0x2d413ccc, 0x2d413ccc, 0x3b20d79e, 0x187de2a6, 0x187de2a6, 0x3b20d79e, 0x238e7673, 0x3536cc52,
+	0x387165e3, 0x1e2b5d38, 0x0645e9af, 0x3fb11b47, 0x187de2a6, 0x3b20d79e, 0x3536cc52, 0x238e7673,
+	0xf383a3e2, 0x3ec52f9f, 0x0c7c5c1e, 0x3ec52f9f, 0x317900d6, 0x2899e64a, 0xe1d4a2c8, 0x387165e3,
+	0x00000000, 0x40000000, 0x2d413ccc, 0x2d413ccc, 0xd2bec334, 0x2d413ccc, 0xf383a3e2, 0x3ec52f9f,
+	0x2899e64a, 0x317900d6, 0xc78e9a1d, 0x1e2b5d38, 0xe7821d5a, 0x3b20d79e, 0x238e7673, 0x3536cc52,
+	0xc13ad061, 0x0c7c5c1e, 0xdc71898d, 0x3536cc52, 0x1e2b5d38, 0x387165e3, 0xc04ee4b9, 0xf9ba1651,
+	0xd2bec334, 0x2d413ccc, 0x187de2a6, 0x3b20d79e, 0xc4df2862, 0xe7821d5a, 0xcac933ae, 0x238e7673,
+	0x1294062e, 0x3d3e82ad, 0xce86ff2a, 0xd76619b6, 0xc4df2862, 0x187de2a6, 0x0c7c5c1e, 0x3ec52f9f,
+	0xdc71898d, 0xcac933ae, 0xc13ad061, 0x0c7c5c1e, 0x0645e9af, 0x3fb11b47, 0xed6bf9d2, 0xc2c17d53
 };
 #endif  //ARMV5E
 
-const int ShortWindowSine[FRAME_LEN_SHORT/2] ={  
-	0x00c97fff, 0x025b7ffa, 0x03ed7ff1, 0x057f7fe2, 0x07117fce, 0x08a27fb5, 0x0a337f98, 0x0bc47f75, 
-	0x0d547f4e, 0x0ee47f22, 0x10737ef0, 0x12017eba, 0x138f7e7f, 0x151c7e3f, 0x16a87dfb, 0x18337db1, 
-	0x19be7d63, 0x1b477d0f, 0x1cd07cb7, 0x1e577c5a, 0x1fdd7bf9, 0x21627b92, 0x22e57b27, 0x24677ab7, 
-	0x25e87a42, 0x276879c9, 0x28e5794a, 0x2a6278c8, 0x2bdc7840, 0x2d5577b4, 0x2ecc7723, 0x3042768e, 
-	0x31b575f4, 0x33277556, 0x349774b3, 0x3604740b, 0x3770735f, 0x38d972af, 0x3a4071fa, 0x3ba57141, 
-	0x3d087083, 0x3e686fc2, 0x3fc66efb, 0x41216e31, 0x427a6d62, 0x43d16c8f, 0x45246bb8, 0x46756add, 
-	0x47c469fd, 0x490f691a, 0x4a586832, 0x4b9e6747, 0x4ce16657, 0x4e216564, 0x4f5e646c, 0x50986371, 
+const int ShortWindowSine[FRAME_LEN_SHORT/2] ={
+	0x00c97fff, 0x025b7ffa, 0x03ed7ff1, 0x057f7fe2, 0x07117fce, 0x08a27fb5, 0x0a337f98, 0x0bc47f75,
+	0x0d547f4e, 0x0ee47f22, 0x10737ef0, 0x12017eba, 0x138f7e7f, 0x151c7e3f, 0x16a87dfb, 0x18337db1,
+	0x19be7d63, 0x1b477d0f, 0x1cd07cb7, 0x1e577c5a, 0x1fdd7bf9, 0x21627b92, 0x22e57b27, 0x24677ab7,
+	0x25e87a42, 0x276879c9, 0x28e5794a, 0x2a6278c8, 0x2bdc7840, 0x2d5577b4, 0x2ecc7723, 0x3042768e,
+	0x31b575f4, 0x33277556, 0x349774b3, 0x3604740b, 0x3770735f, 0x38d972af, 0x3a4071fa, 0x3ba57141,
+	0x3d087083, 0x3e686fc2, 0x3fc66efb, 0x41216e31, 0x427a6d62, 0x43d16c8f, 0x45246bb8, 0x46756add,
+	0x47c469fd, 0x490f691a, 0x4a586832, 0x4b9e6747, 0x4ce16657, 0x4e216564, 0x4f5e646c, 0x50986371,
 	0x51cf6272, 0x5303616f, 0x54336068, 0x55605f5e, 0x568a5e50, 0x57b15d3e, 0x58d45c29, 0x59f45b10
 };
 
-const int LongWindowKBD[FRAME_LEN_LONG/2]={  
-	0x000a7fff, 0x000e7fff, 0x00127fff, 0x00157fff, 0x00197fff, 0x001c7fff, 0x00207fff, 0x00237fff, 
-	0x00267fff, 0x002a7fff, 0x002d7fff, 0x00307fff, 0x00347fff, 0x00387fff, 0x003b7fff, 0x003f7fff, 
-	0x00437fff, 0x00477fff, 0x004b7fff, 0x004f7fff, 0x00537fff, 0x00577fff, 0x005b7fff, 0x00607fff, 
-	0x00647fff, 0x00697fff, 0x006d7fff, 0x00727fff, 0x00777fff, 0x007c7fff, 0x00817fff, 0x00867fff, 
-	0x008b7fff, 0x00917fff, 0x00967fff, 0x009c7fff, 0x00a17fff, 0x00a77fff, 0x00ad7fff, 0x00b37fff, 
-	0x00b97fff, 0x00bf7fff, 0x00c67fff, 0x00cc7fff, 0x00d37fff, 0x00da7fff, 0x00e07fff, 0x00e77fff, 
-	0x00ee7fff, 0x00f57fff, 0x00fd7fff, 0x01047fff, 0x010c7fff, 0x01137fff, 0x011b7fff, 0x01237fff, 
-	0x012b7fff, 0x01337fff, 0x013c7ffe, 0x01447ffe, 0x014d7ffe, 0x01567ffe, 0x015f7ffe, 0x01687ffe, 
-	0x01717ffe, 0x017a7ffe, 0x01837ffe, 0x018d7ffe, 0x01977ffd, 0x01a17ffd, 0x01ab7ffd, 0x01b57ffd, 
-	0x01bf7ffd, 0x01ca7ffd, 0x01d47ffd, 0x01df7ffc, 0x01ea7ffc, 0x01f57ffc, 0x02007ffc, 0x020c7ffc, 
-	0x02177ffc, 0x02237ffb, 0x022f7ffb, 0x023b7ffb, 0x02477ffb, 0x02537ffb, 0x02607ffa, 0x026d7ffa, 
-	0x027a7ffa, 0x02877ffa, 0x02947ff9, 0x02a17ff9, 0x02af7ff9, 0x02bc7ff9, 0x02ca7ff8, 0x02d87ff8, 
-	0x02e77ff8, 0x02f57ff7, 0x03047ff7, 0x03127ff7, 0x03217ff6, 0x03317ff6, 0x03407ff5, 0x034f7ff5, 
-	0x035f7ff5, 0x036f7ff4, 0x037f7ff4, 0x038f7ff3, 0x03a07ff3, 0x03b07ff2, 0x03c17ff2, 0x03d27ff1, 
-	0x03e37ff1, 0x03f57ff0, 0x04067ff0, 0x04187fef, 0x042a7fef, 0x043c7fee, 0x044f7fed, 0x04617fed, 
-	0x04747fec, 0x04877feb, 0x049a7feb, 0x04ae7fea, 0x04c17fe9, 0x04d57fe9, 0x04e97fe8, 0x04fd7fe7, 
-	0x05127fe6, 0x05277fe5, 0x053b7fe5, 0x05507fe4, 0x05667fe3, 0x057b7fe2, 0x05917fe1, 0x05a77fe0, 
-	0x05bd7fdf, 0x05d37fde, 0x05ea7fdd, 0x06017fdc, 0x06187fdb, 0x062f7fda, 0x06467fd9, 0x065e7fd7, 
-	0x06767fd6, 0x068e7fd5, 0x06a67fd4, 0x06bf7fd2, 0x06d87fd1, 0x06f17fd0, 0x070a7fce, 0x07237fcd, 
-	0x073d7fcc, 0x07577fca, 0x07717fc9, 0x078c7fc7, 0x07a67fc5, 0x07c17fc4, 0x07dc7fc2, 0x07f77fc0, 
-	0x08137fbf, 0x082f7fbd, 0x084b7fbb, 0x08677fb9, 0x08847fb7, 0x08a07fb6, 0x08bd7fb4, 0x08da7fb2, 
-	0x08f87faf, 0x09167fad, 0x09347fab, 0x09527fa9, 0x09707fa7, 0x098f7fa5, 0x09ae7fa2, 0x09cd7fa0, 
-	0x09ec7f9d, 0x0a0c7f9b, 0x0a2c7f98, 0x0a4c7f96, 0x0a6c7f93, 0x0a8d7f91, 0x0aae7f8e, 0x0acf7f8b, 
-	0x0af07f88, 0x0b127f85, 0x0b337f82, 0x0b557f7f, 0x0b787f7c, 0x0b9a7f79, 0x0bbd7f76, 0x0be07f73, 
-	0x0c047f6f, 0x0c277f6c, 0x0c4b7f69, 0x0c6f7f65, 0x0c937f61, 0x0cb87f5e, 0x0cdd7f5a, 0x0d027f56, 
-	0x0d277f53, 0x0d4d7f4f, 0x0d737f4b, 0x0d997f47, 0x0dbf7f43, 0x0de67f3e, 0x0e0c7f3a, 0x0e347f36, 
-	0x0e5b7f31, 0x0e837f2d, 0x0eaa7f28, 0x0ed37f24, 0x0efb7f1f, 0x0f237f1a, 0x0f4c7f15, 0x0f757f10, 
-	0x0f9f7f0b, 0x0fc87f06, 0x0ff27f01, 0x101c7efb, 0x10477ef6, 0x10717ef0, 0x109c7eeb, 0x10c87ee5, 
-	0x10f37edf, 0x111f7eda, 0x114a7ed4, 0x11777ece, 0x11a37ec7, 0x11d07ec1, 0x11fd7ebb, 0x122a7eb4, 
-	0x12577eae, 0x12857ea7, 0x12b37ea0, 0x12e17e9a, 0x130f7e93, 0x133e7e8c, 0x136d7e84, 0x139c7e7d, 
-	0x13cc7e76, 0x13fb7e6e, 0x142b7e67, 0x145b7e5f, 0x148c7e57, 0x14bc7e4f, 0x14ed7e47, 0x151e7e3f, 
-	0x15507e37, 0x15817e2e, 0x15b37e26, 0x15e57e1d, 0x16187e14, 0x164a7e0b, 0x167d7e02, 0x16b07df9, 
-	0x16e47df0, 0x17177de6, 0x174b7ddd, 0x177f7dd3, 0x17b37dc9, 0x17e87dbf, 0x181d7db5, 0x18527dab, 
-	0x18877da1, 0x18bc7d96, 0x18f27d8c, 0x19287d81, 0x195e7d76, 0x19957d6b, 0x19cb7d60, 0x1a027d54, 
-	0x1a397d49, 0x1a717d3d, 0x1aa87d31, 0x1ae07d26, 0x1b187d19, 0x1b507d0d, 0x1b897d01, 0x1bc27cf4, 
-	0x1bfb7ce8, 0x1c347cdb, 0x1c6d7cce, 0x1ca77cc1, 0x1ce17cb3, 0x1d1b7ca6, 0x1d557c98, 0x1d8f7c8a, 
-	0x1dca7c7c, 0x1e057c6e, 0x1e407c60, 0x1e7b7c51, 0x1eb77c43, 0x1ef37c34, 0x1f2f7c25, 0x1f6b7c16, 
-	0x1fa77c06, 0x1fe47bf7, 0x20217be7, 0x205e7bd7, 0x209b7bc7, 0x20d87bb7, 0x21167ba6, 0x21547b96, 
-	0x21927b85, 0x21d07b74, 0x220e7b63, 0x224d7b52, 0x228c7b40, 0x22cb7b2e, 0x230a7b1c, 0x23497b0a, 
-	0x23897af8, 0x23c87ae6, 0x24087ad3, 0x24487ac0, 0x24897aad, 0x24c97a9a, 0x250a7a86, 0x254b7a73, 
-	0x258c7a5f, 0x25cd7a4b, 0x260e7a36, 0x26507a22, 0x26917a0d, 0x26d379f8, 0x271579e3, 0x275779ce, 
-	0x279a79b8, 0x27dc79a3, 0x281f798d, 0x28627977, 0x28a57960, 0x28e8794a, 0x292b7933, 0x296f791c, 
-	0x29b27905, 0x29f678ed, 0x2a3a78d6, 0x2a7e78be, 0x2ac278a6, 0x2b07788d, 0x2b4b7875, 0x2b90785c, 
-	0x2bd47843, 0x2c19782a, 0x2c5e7810, 0x2ca477f7, 0x2ce977dd, 0x2d2e77c3, 0x2d7477a8, 0x2dba778e, 
-	0x2dff7773, 0x2e457758, 0x2e8b773d, 0x2ed27721, 0x2f187706, 0x2f5e76ea, 0x2fa576cd, 0x2fec76b1, 
-	0x30327694, 0x30797677, 0x30c0765a, 0x3107763d, 0x314e761f, 0x31967601, 0x31dd75e3, 0x322575c5, 
-	0x326c75a6, 0x32b47588, 0x32fc7569, 0x33447549, 0x338c752a, 0x33d4750a, 0x341c74ea, 0x346474ca, 
-	0x34ac74a9, 0x34f57488, 0x353d7467, 0x35857446, 0x35ce7424, 0x36177403, 0x365f73e1, 0x36a873be, 
-	0x36f1739c, 0x373a7379, 0x37837356, 0x37cc7333, 0x3815730f, 0x385e72ec, 0x38a772c8, 0x38f172a3, 
-	0x393a727f, 0x3983725a, 0x39cd7235, 0x3a167210, 0x3a6071ea, 0x3aa971c4, 0x3af3719e, 0x3b3c7178, 
-	0x3b867151, 0x3bd0712b, 0x3c197104, 0x3c6370dc, 0x3cad70b5, 0x3cf7708d, 0x3d407065, 0x3d8a703c, 
-	0x3dd47014, 0x3e1e6feb, 0x3e686fc2, 0x3eb16f98, 0x3efb6f6f, 0x3f456f45, 0x3f8f6f1b, 0x3fd96ef0, 
-	0x40236ec6, 0x406d6e9b, 0x40b66e70, 0x41006e44, 0x414a6e19, 0x41946ded, 0x41de6dc1, 0x42286d94, 
-	0x42716d68, 0x42bb6d3b, 0x43056d0d, 0x434f6ce0, 0x43986cb2, 0x43e26c84, 0x442c6c56, 0x44756c28, 
-	0x44bf6bf9, 0x45086bca, 0x45526b9b, 0x459b6b6b, 0x45e56b3c, 0x462e6b0c, 0x46786adb, 0x46c16aab, 
-	0x470a6a7a, 0x47536a49, 0x479c6a18, 0x47e569e7, 0x482e69b5, 0x48776983, 0x48c06951, 0x4909691e, 
-	0x495268ec, 0x499b68b9, 0x49e36885, 0x4a2c6852, 0x4a74681e, 0x4abd67ea, 0x4b0567b6, 0x4b4d6782, 
-	0x4b95674d, 0x4bde6718, 0x4c2666e3, 0x4c6d66ae, 0x4cb56678, 0x4cfd6642, 0x4d45660c, 0x4d8c65d6, 
-	0x4dd4659f, 0x4e1b6568, 0x4e626531, 0x4ea964fa, 0x4ef064c3, 0x4f37648b, 0x4f7e6453, 0x4fc5641b, 
-	0x500b63e2, 0x505263aa, 0x50986371, 0x50df6338, 0x512562fe, 0x516b62c5, 0x51b1628b, 0x51f66251, 
-	0x523c6217, 0x528161dc, 0x52c761a2, 0x530c6167, 0x5351612c, 0x539660f1, 0x53db60b5, 0x54206079, 
-	0x5464603d, 0x54a96001, 0x54ed5fc5, 0x55315f88, 0x55755f4b, 0x55b95f0e, 0x55fc5ed1, 0x56405e94, 
-	0x56835e56, 0x56c75e18, 0x570a5dda, 0x574d5d9c, 0x578f5d5e, 0x57d25d1f, 0x58145ce0, 0x58565ca1, 
+const int LongWindowKBD[FRAME_LEN_LONG/2]={
+	0x000a7fff, 0x000e7fff, 0x00127fff, 0x00157fff, 0x00197fff, 0x001c7fff, 0x00207fff, 0x00237fff,
+	0x00267fff, 0x002a7fff, 0x002d7fff, 0x00307fff, 0x00347fff, 0x00387fff, 0x003b7fff, 0x003f7fff,
+	0x00437fff, 0x00477fff, 0x004b7fff, 0x004f7fff, 0x00537fff, 0x00577fff, 0x005b7fff, 0x00607fff,
+	0x00647fff, 0x00697fff, 0x006d7fff, 0x00727fff, 0x00777fff, 0x007c7fff, 0x00817fff, 0x00867fff,
+	0x008b7fff, 0x00917fff, 0x00967fff, 0x009c7fff, 0x00a17fff, 0x00a77fff, 0x00ad7fff, 0x00b37fff,
+	0x00b97fff, 0x00bf7fff, 0x00c67fff, 0x00cc7fff, 0x00d37fff, 0x00da7fff, 0x00e07fff, 0x00e77fff,
+	0x00ee7fff, 0x00f57fff, 0x00fd7fff, 0x01047fff, 0x010c7fff, 0x01137fff, 0x011b7fff, 0x01237fff,
+	0x012b7fff, 0x01337fff, 0x013c7ffe, 0x01447ffe, 0x014d7ffe, 0x01567ffe, 0x015f7ffe, 0x01687ffe,
+	0x01717ffe, 0x017a7ffe, 0x01837ffe, 0x018d7ffe, 0x01977ffd, 0x01a17ffd, 0x01ab7ffd, 0x01b57ffd,
+	0x01bf7ffd, 0x01ca7ffd, 0x01d47ffd, 0x01df7ffc, 0x01ea7ffc, 0x01f57ffc, 0x02007ffc, 0x020c7ffc,
+	0x02177ffc, 0x02237ffb, 0x022f7ffb, 0x023b7ffb, 0x02477ffb, 0x02537ffb, 0x02607ffa, 0x026d7ffa,
+	0x027a7ffa, 0x02877ffa, 0x02947ff9, 0x02a17ff9, 0x02af7ff9, 0x02bc7ff9, 0x02ca7ff8, 0x02d87ff8,
+	0x02e77ff8, 0x02f57ff7, 0x03047ff7, 0x03127ff7, 0x03217ff6, 0x03317ff6, 0x03407ff5, 0x034f7ff5,
+	0x035f7ff5, 0x036f7ff4, 0x037f7ff4, 0x038f7ff3, 0x03a07ff3, 0x03b07ff2, 0x03c17ff2, 0x03d27ff1,
+	0x03e37ff1, 0x03f57ff0, 0x04067ff0, 0x04187fef, 0x042a7fef, 0x043c7fee, 0x044f7fed, 0x04617fed,
+	0x04747fec, 0x04877feb, 0x049a7feb, 0x04ae7fea, 0x04c17fe9, 0x04d57fe9, 0x04e97fe8, 0x04fd7fe7,
+	0x05127fe6, 0x05277fe5, 0x053b7fe5, 0x05507fe4, 0x05667fe3, 0x057b7fe2, 0x05917fe1, 0x05a77fe0,
+	0x05bd7fdf, 0x05d37fde, 0x05ea7fdd, 0x06017fdc, 0x06187fdb, 0x062f7fda, 0x06467fd9, 0x065e7fd7,
+	0x06767fd6, 0x068e7fd5, 0x06a67fd4, 0x06bf7fd2, 0x06d87fd1, 0x06f17fd0, 0x070a7fce, 0x07237fcd,
+	0x073d7fcc, 0x07577fca, 0x07717fc9, 0x078c7fc7, 0x07a67fc5, 0x07c17fc4, 0x07dc7fc2, 0x07f77fc0,
+	0x08137fbf, 0x082f7fbd, 0x084b7fbb, 0x08677fb9, 0x08847fb7, 0x08a07fb6, 0x08bd7fb4, 0x08da7fb2,
+	0x08f87faf, 0x09167fad, 0x09347fab, 0x09527fa9, 0x09707fa7, 0x098f7fa5, 0x09ae7fa2, 0x09cd7fa0,
+	0x09ec7f9d, 0x0a0c7f9b, 0x0a2c7f98, 0x0a4c7f96, 0x0a6c7f93, 0x0a8d7f91, 0x0aae7f8e, 0x0acf7f8b,
+	0x0af07f88, 0x0b127f85, 0x0b337f82, 0x0b557f7f, 0x0b787f7c, 0x0b9a7f79, 0x0bbd7f76, 0x0be07f73,
+	0x0c047f6f, 0x0c277f6c, 0x0c4b7f69, 0x0c6f7f65, 0x0c937f61, 0x0cb87f5e, 0x0cdd7f5a, 0x0d027f56,
+	0x0d277f53, 0x0d4d7f4f, 0x0d737f4b, 0x0d997f47, 0x0dbf7f43, 0x0de67f3e, 0x0e0c7f3a, 0x0e347f36,
+	0x0e5b7f31, 0x0e837f2d, 0x0eaa7f28, 0x0ed37f24, 0x0efb7f1f, 0x0f237f1a, 0x0f4c7f15, 0x0f757f10,
+	0x0f9f7f0b, 0x0fc87f06, 0x0ff27f01, 0x101c7efb, 0x10477ef6, 0x10717ef0, 0x109c7eeb, 0x10c87ee5,
+	0x10f37edf, 0x111f7eda, 0x114a7ed4, 0x11777ece, 0x11a37ec7, 0x11d07ec1, 0x11fd7ebb, 0x122a7eb4,
+	0x12577eae, 0x12857ea7, 0x12b37ea0, 0x12e17e9a, 0x130f7e93, 0x133e7e8c, 0x136d7e84, 0x139c7e7d,
+	0x13cc7e76, 0x13fb7e6e, 0x142b7e67, 0x145b7e5f, 0x148c7e57, 0x14bc7e4f, 0x14ed7e47, 0x151e7e3f,
+	0x15507e37, 0x15817e2e, 0x15b37e26, 0x15e57e1d, 0x16187e14, 0x164a7e0b, 0x167d7e02, 0x16b07df9,
+	0x16e47df0, 0x17177de6, 0x174b7ddd, 0x177f7dd3, 0x17b37dc9, 0x17e87dbf, 0x181d7db5, 0x18527dab,
+	0x18877da1, 0x18bc7d96, 0x18f27d8c, 0x19287d81, 0x195e7d76, 0x19957d6b, 0x19cb7d60, 0x1a027d54,
+	0x1a397d49, 0x1a717d3d, 0x1aa87d31, 0x1ae07d26, 0x1b187d19, 0x1b507d0d, 0x1b897d01, 0x1bc27cf4,
+	0x1bfb7ce8, 0x1c347cdb, 0x1c6d7cce, 0x1ca77cc1, 0x1ce17cb3, 0x1d1b7ca6, 0x1d557c98, 0x1d8f7c8a,
+	0x1dca7c7c, 0x1e057c6e, 0x1e407c60, 0x1e7b7c51, 0x1eb77c43, 0x1ef37c34, 0x1f2f7c25, 0x1f6b7c16,
+	0x1fa77c06, 0x1fe47bf7, 0x20217be7, 0x205e7bd7, 0x209b7bc7, 0x20d87bb7, 0x21167ba6, 0x21547b96,
+	0x21927b85, 0x21d07b74, 0x220e7b63, 0x224d7b52, 0x228c7b40, 0x22cb7b2e, 0x230a7b1c, 0x23497b0a,
+	0x23897af8, 0x23c87ae6, 0x24087ad3, 0x24487ac0, 0x24897aad, 0x24c97a9a, 0x250a7a86, 0x254b7a73,
+	0x258c7a5f, 0x25cd7a4b, 0x260e7a36, 0x26507a22, 0x26917a0d, 0x26d379f8, 0x271579e3, 0x275779ce,
+	0x279a79b8, 0x27dc79a3, 0x281f798d, 0x28627977, 0x28a57960, 0x28e8794a, 0x292b7933, 0x296f791c,
+	0x29b27905, 0x29f678ed, 0x2a3a78d6, 0x2a7e78be, 0x2ac278a6, 0x2b07788d, 0x2b4b7875, 0x2b90785c,
+	0x2bd47843, 0x2c19782a, 0x2c5e7810, 0x2ca477f7, 0x2ce977dd, 0x2d2e77c3, 0x2d7477a8, 0x2dba778e,
+	0x2dff7773, 0x2e457758, 0x2e8b773d, 0x2ed27721, 0x2f187706, 0x2f5e76ea, 0x2fa576cd, 0x2fec76b1,
+	0x30327694, 0x30797677, 0x30c0765a, 0x3107763d, 0x314e761f, 0x31967601, 0x31dd75e3, 0x322575c5,
+	0x326c75a6, 0x32b47588, 0x32fc7569, 0x33447549, 0x338c752a, 0x33d4750a, 0x341c74ea, 0x346474ca,
+	0x34ac74a9, 0x34f57488, 0x353d7467, 0x35857446, 0x35ce7424, 0x36177403, 0x365f73e1, 0x36a873be,
+	0x36f1739c, 0x373a7379, 0x37837356, 0x37cc7333, 0x3815730f, 0x385e72ec, 0x38a772c8, 0x38f172a3,
+	0x393a727f, 0x3983725a, 0x39cd7235, 0x3a167210, 0x3a6071ea, 0x3aa971c4, 0x3af3719e, 0x3b3c7178,
+	0x3b867151, 0x3bd0712b, 0x3c197104, 0x3c6370dc, 0x3cad70b5, 0x3cf7708d, 0x3d407065, 0x3d8a703c,
+	0x3dd47014, 0x3e1e6feb, 0x3e686fc2, 0x3eb16f98, 0x3efb6f6f, 0x3f456f45, 0x3f8f6f1b, 0x3fd96ef0,
+	0x40236ec6, 0x406d6e9b, 0x40b66e70, 0x41006e44, 0x414a6e19, 0x41946ded, 0x41de6dc1, 0x42286d94,
+	0x42716d68, 0x42bb6d3b, 0x43056d0d, 0x434f6ce0, 0x43986cb2, 0x43e26c84, 0x442c6c56, 0x44756c28,
+	0x44bf6bf9, 0x45086bca, 0x45526b9b, 0x459b6b6b, 0x45e56b3c, 0x462e6b0c, 0x46786adb, 0x46c16aab,
+	0x470a6a7a, 0x47536a49, 0x479c6a18, 0x47e569e7, 0x482e69b5, 0x48776983, 0x48c06951, 0x4909691e,
+	0x495268ec, 0x499b68b9, 0x49e36885, 0x4a2c6852, 0x4a74681e, 0x4abd67ea, 0x4b0567b6, 0x4b4d6782,
+	0x4b95674d, 0x4bde6718, 0x4c2666e3, 0x4c6d66ae, 0x4cb56678, 0x4cfd6642, 0x4d45660c, 0x4d8c65d6,
+	0x4dd4659f, 0x4e1b6568, 0x4e626531, 0x4ea964fa, 0x4ef064c3, 0x4f37648b, 0x4f7e6453, 0x4fc5641b,
+	0x500b63e2, 0x505263aa, 0x50986371, 0x50df6338, 0x512562fe, 0x516b62c5, 0x51b1628b, 0x51f66251,
+	0x523c6217, 0x528161dc, 0x52c761a2, 0x530c6167, 0x5351612c, 0x539660f1, 0x53db60b5, 0x54206079,
+	0x5464603d, 0x54a96001, 0x54ed5fc5, 0x55315f88, 0x55755f4b, 0x55b95f0e, 0x55fc5ed1, 0x56405e94,
+	0x56835e56, 0x56c75e18, 0x570a5dda, 0x574d5d9c, 0x578f5d5e, 0x57d25d1f, 0x58145ce0, 0x58565ca1,
 	0x58995c62, 0x58da5c23, 0x591c5be3, 0x595e5ba4, 0x599f5b64, 0x59e05b24, 0x5a215ae3, 0x5a625aa3
 };
 
@@ -1070,277 +1070,277 @@
 
   \brief   these tables are used for the non
            linear quantizer and inverse quantizer
-           
+
 */
 const Word32 mTab_3_4[512] = {
-	0x4c1bf829, 0x4c3880de, 0x4c550603, 0x4c71879c, 
-	0x4c8e05aa, 0x4caa8030, 0x4cc6f72f, 0x4ce36aab, 
-	0x4cffdaa4, 0x4d1c471d, 0x4d38b019, 0x4d55159a, 
-	0x4d7177a1, 0x4d8dd631, 0x4daa314b, 0x4dc688f3, 
-	0x4de2dd2a, 0x4dff2df2, 0x4e1b7b4d, 0x4e37c53d, 
-	0x4e540bc5, 0x4e704ee6, 0x4e8c8ea3, 0x4ea8cafd, 
-	0x4ec503f7, 0x4ee13992, 0x4efd6bd0, 0x4f199ab4, 
-	0x4f35c640, 0x4f51ee75, 0x4f6e1356, 0x4f8a34e4, 
-	0x4fa65321, 0x4fc26e10, 0x4fde85b2, 0x4ffa9a0a, 
-	0x5016ab18, 0x5032b8e0, 0x504ec362, 0x506acaa1, 
-	0x5086cea0, 0x50a2cf5e, 0x50becce0, 0x50dac725, 
-	0x50f6be31, 0x5112b205, 0x512ea2a3, 0x514a900d, 
-	0x51667a45, 0x5182614c, 0x519e4524, 0x51ba25cf, 
-	0x51d60350, 0x51f1dda7, 0x520db4d6, 0x522988e0, 
-	0x524559c6, 0x52612789, 0x527cf22d, 0x5298b9b1, 
-	0x52b47e19, 0x52d03f65, 0x52ebfd98, 0x5307b8b4, 
-	0x532370b9, 0x533f25aa, 0x535ad789, 0x53768656, 
-	0x53923215, 0x53addac6, 0x53c9806b, 0x53e52306, 
-	0x5400c298, 0x541c5f24, 0x5437f8ab, 0x54538f2e, 
-	0x546f22af, 0x548ab330, 0x54a640b3, 0x54c1cb38, 
-	0x54dd52c2, 0x54f8d753, 0x551458eb, 0x552fd78d, 
-	0x554b5339, 0x5566cbf3, 0x558241bb, 0x559db492, 
-	0x55b9247b, 0x55d49177, 0x55effb87, 0x560b62ad, 
-	0x5626c6eb, 0x56422842, 0x565d86b4, 0x5678e242, 
-	0x56943aee, 0x56af90b9, 0x56cae3a4, 0x56e633b2, 
-	0x570180e4, 0x571ccb3b, 0x573812b8, 0x5753575e, 
-	0x576e992e, 0x5789d829, 0x57a51450, 0x57c04da6, 
-	0x57db842b, 0x57f6b7e1, 0x5811e8c9, 0x582d16e6, 
-	0x58484238, 0x58636ac0, 0x587e9081, 0x5899b37c, 
-	0x58b4d3b1, 0x58cff123, 0x58eb0bd3, 0x590623c2, 
-	0x592138f2, 0x593c4b63, 0x59575b19, 0x59726812, 
-	0x598d7253, 0x59a879da, 0x59c37eab, 0x59de80c6, 
-	0x59f9802d, 0x5a147ce0, 0x5a2f76e2, 0x5a4a6e34, 
-	0x5a6562d6, 0x5a8054cb, 0x5a9b4414, 0x5ab630b2, 
-	0x5ad11aa6, 0x5aec01f1, 0x5b06e696, 0x5b21c895, 
-	0x5b3ca7ef, 0x5b5784a6, 0x5b725ebc, 0x5b8d3631, 
-	0x5ba80b06, 0x5bc2dd3e, 0x5bddacd9, 0x5bf879d8, 
-	0x5c13443d, 0x5c2e0c09, 0x5c48d13e, 0x5c6393dc, 
-	0x5c7e53e5, 0x5c99115a, 0x5cb3cc3c, 0x5cce848d, 
-	0x5ce93a4e, 0x5d03ed80, 0x5d1e9e24, 0x5d394c3b, 
-	0x5d53f7c7, 0x5d6ea0c9, 0x5d894742, 0x5da3eb33, 
-	0x5dbe8c9e, 0x5dd92b84, 0x5df3c7e5, 0x5e0e61c3, 
-	0x5e28f920, 0x5e438dfc, 0x5e5e2059, 0x5e78b037, 
-	0x5e933d99, 0x5eadc87e, 0x5ec850e9, 0x5ee2d6da, 
-	0x5efd5a53, 0x5f17db54, 0x5f3259e0, 0x5f4cd5f6, 
-	0x5f674f99, 0x5f81c6c8, 0x5f9c3b87, 0x5fb6add4, 
-	0x5fd11db3, 0x5feb8b23, 0x6005f626, 0x60205ebd, 
-	0x603ac4e9, 0x605528ac, 0x606f8a05, 0x6089e8f7, 
-	0x60a44583, 0x60be9fa9, 0x60d8f76b, 0x60f34cca, 
-	0x610d9fc7, 0x6127f062, 0x61423e9e, 0x615c8a7a, 
-	0x6176d3f9, 0x61911b1b, 0x61ab5fe1, 0x61c5a24d, 
-	0x61dfe25f, 0x61fa2018, 0x62145b7a, 0x622e9485, 
-	0x6248cb3b, 0x6262ff9d, 0x627d31ab, 0x62976167, 
-	0x62b18ed1, 0x62cbb9eb, 0x62e5e2b6, 0x63000933, 
-	0x631a2d62, 0x63344f45, 0x634e6edd, 0x63688c2b, 
-	0x6382a730, 0x639cbfec, 0x63b6d661, 0x63d0ea90, 
-	0x63eafc7a, 0x64050c1f, 0x641f1982, 0x643924a2, 
-	0x64532d80, 0x646d341f, 0x6487387e, 0x64a13a9e, 
-	0x64bb3a81, 0x64d53828, 0x64ef3393, 0x65092cc4, 
-	0x652323bb, 0x653d1879, 0x65570b00, 0x6570fb50, 
-	0x658ae96b, 0x65a4d550, 0x65bebf01, 0x65d8a680, 
-	0x65f28bcc, 0x660c6ee8, 0x66264fd3, 0x66402e8f, 
-	0x665a0b1c, 0x6673e57d, 0x668dbdb0, 0x66a793b8, 
-	0x66c16795, 0x66db3949, 0x66f508d4, 0x670ed636, 
-	0x6728a172, 0x67426a87, 0x675c3177, 0x6775f643, 
-	0x678fb8eb, 0x67a97971, 0x67c337d5, 0x67dcf418, 
-	0x67f6ae3b, 0x6810663f, 0x682a1c25, 0x6843cfed, 
-	0x685d8199, 0x68773129, 0x6890de9f, 0x68aa89fa, 
-	0x68c4333d, 0x68ddda67, 0x68f77f7a, 0x69112277, 
-	0x692ac35e, 0x69446230, 0x695dfeee, 0x6977999a, 
-	0x69913232, 0x69aac8ba, 0x69c45d31, 0x69ddef98, 
-	0x69f77ff0, 0x6a110e3a, 0x6a2a9a77, 0x6a4424a8, 
-	0x6a5daccc, 0x6a7732e6, 0x6a90b6f6, 0x6aaa38fd, 
-	0x6ac3b8fb, 0x6add36f2, 0x6af6b2e2, 0x6b102ccd, 
-	0x6b29a4b2, 0x6b431a92, 0x6b5c8e6f, 0x6b76004a, 
-	0x6b8f7022, 0x6ba8ddf9, 0x6bc249d0, 0x6bdbb3a7, 
-	0x6bf51b80, 0x6c0e815a, 0x6c27e537, 0x6c414718, 
-	0x6c5aa6fd, 0x6c7404e7, 0x6c8d60d7, 0x6ca6bace, 
-	0x6cc012cc, 0x6cd968d2, 0x6cf2bce1, 0x6d0c0ef9, 
-	0x6d255f1d, 0x6d3ead4b, 0x6d57f985, 0x6d7143cc, 
-	0x6d8a8c21, 0x6da3d283, 0x6dbd16f5, 0x6dd65976, 
-	0x6def9a08, 0x6e08d8ab, 0x6e221560, 0x6e3b5027, 
-	0x6e548902, 0x6e6dbff1, 0x6e86f4f5, 0x6ea0280e, 
-	0x6eb9593e, 0x6ed28885, 0x6eebb5e3, 0x6f04e15a, 
-	0x6f1e0aea, 0x6f373294, 0x6f505859, 0x6f697c39, 
-	0x6f829e35, 0x6f9bbe4e, 0x6fb4dc85, 0x6fcdf8d9, 
-	0x6fe7134d, 0x70002be0, 0x70194293, 0x70325767, 
-	0x704b6a5d, 0x70647b76, 0x707d8ab1, 0x70969811, 
-	0x70afa394, 0x70c8ad3d, 0x70e1b50c, 0x70fabb01, 
-	0x7113bf1d, 0x712cc161, 0x7145c1ce, 0x715ec064, 
-	0x7177bd24, 0x7190b80f, 0x71a9b124, 0x71c2a866, 
-	0x71db9dd4, 0x71f49170, 0x720d8339, 0x72267331, 
-	0x723f6159, 0x72584db0, 0x72713838, 0x728a20f1, 
-	0x72a307db, 0x72bbecf9, 0x72d4d049, 0x72edb1ce, 
-	0x73069187, 0x731f6f75, 0x73384b98, 0x735125f3, 
-	0x7369fe84, 0x7382d54d, 0x739baa4e, 0x73b47d89, 
-	0x73cd4efd, 0x73e61eab, 0x73feec94, 0x7417b8b8, 
-	0x74308319, 0x74494bb6, 0x74621291, 0x747ad7aa, 
-	0x74939b02, 0x74ac5c98, 0x74c51c6f, 0x74ddda86, 
-	0x74f696de, 0x750f5178, 0x75280a54, 0x7540c174, 
-	0x755976d7, 0x75722a7e, 0x758adc69, 0x75a38c9b, 
-	0x75bc3b12, 0x75d4e7cf, 0x75ed92d4, 0x76063c21, 
-	0x761ee3b6, 0x76378994, 0x76502dbc, 0x7668d02e, 
-	0x768170eb, 0x769a0ff3, 0x76b2ad47, 0x76cb48e7, 
-	0x76e3e2d5, 0x76fc7b10, 0x7715119a, 0x772da673, 
-	0x7746399b, 0x775ecb13, 0x77775adc, 0x778fe8f6, 
-	0x77a87561, 0x77c1001f, 0x77d98930, 0x77f21095, 
-	0x780a964d, 0x78231a5b, 0x783b9cbd, 0x78541d75, 
-	0x786c9c84, 0x788519e9, 0x789d95a6, 0x78b60fbb, 
-	0x78ce8828, 0x78e6feef, 0x78ff740f, 0x7917e78a, 
-	0x7930595f, 0x7948c990, 0x7961381d, 0x7979a506, 
-	0x7992104c, 0x79aa79f0, 0x79c2e1f1, 0x79db4852, 
-	0x79f3ad11, 0x7a0c1031, 0x7a2471b0, 0x7a3cd191, 
-	0x7a552fd3, 0x7a6d8c76, 0x7a85e77d, 0x7a9e40e6, 
-	0x7ab698b2, 0x7aceeee3, 0x7ae74378, 0x7aff9673, 
-	0x7b17e7d2, 0x7b303799, 0x7b4885c5, 0x7b60d259, 
-	0x7b791d55, 0x7b9166b9, 0x7ba9ae86, 0x7bc1f4bc, 
-	0x7bda395c, 0x7bf27c66, 0x7c0abddb, 0x7c22fdbb, 
-	0x7c3b3c07, 0x7c5378c0, 0x7c6bb3e5, 0x7c83ed78, 
-	0x7c9c2579, 0x7cb45be9, 0x7ccc90c7, 0x7ce4c414, 
-	0x7cfcf5d2, 0x7d152600, 0x7d2d549f, 0x7d4581b0, 
-	0x7d5dad32, 0x7d75d727, 0x7d8dff8f, 0x7da6266a, 
-	0x7dbe4bba, 0x7dd66f7d, 0x7dee91b6, 0x7e06b264, 
-	0x7e1ed188, 0x7e36ef22, 0x7e4f0b34, 0x7e6725bd, 
-	0x7e7f3ebd, 0x7e975636, 0x7eaf6c28, 0x7ec78093, 
-	0x7edf9378, 0x7ef7a4d7, 0x7f0fb4b1, 0x7f27c307, 
-	0x7f3fcfd8, 0x7f57db25, 0x7f6fe4ef, 0x7f87ed36, 
+	0x4c1bf829, 0x4c3880de, 0x4c550603, 0x4c71879c,
+	0x4c8e05aa, 0x4caa8030, 0x4cc6f72f, 0x4ce36aab,
+	0x4cffdaa4, 0x4d1c471d, 0x4d38b019, 0x4d55159a,
+	0x4d7177a1, 0x4d8dd631, 0x4daa314b, 0x4dc688f3,
+	0x4de2dd2a, 0x4dff2df2, 0x4e1b7b4d, 0x4e37c53d,
+	0x4e540bc5, 0x4e704ee6, 0x4e8c8ea3, 0x4ea8cafd,
+	0x4ec503f7, 0x4ee13992, 0x4efd6bd0, 0x4f199ab4,
+	0x4f35c640, 0x4f51ee75, 0x4f6e1356, 0x4f8a34e4,
+	0x4fa65321, 0x4fc26e10, 0x4fde85b2, 0x4ffa9a0a,
+	0x5016ab18, 0x5032b8e0, 0x504ec362, 0x506acaa1,
+	0x5086cea0, 0x50a2cf5e, 0x50becce0, 0x50dac725,
+	0x50f6be31, 0x5112b205, 0x512ea2a3, 0x514a900d,
+	0x51667a45, 0x5182614c, 0x519e4524, 0x51ba25cf,
+	0x51d60350, 0x51f1dda7, 0x520db4d6, 0x522988e0,
+	0x524559c6, 0x52612789, 0x527cf22d, 0x5298b9b1,
+	0x52b47e19, 0x52d03f65, 0x52ebfd98, 0x5307b8b4,
+	0x532370b9, 0x533f25aa, 0x535ad789, 0x53768656,
+	0x53923215, 0x53addac6, 0x53c9806b, 0x53e52306,
+	0x5400c298, 0x541c5f24, 0x5437f8ab, 0x54538f2e,
+	0x546f22af, 0x548ab330, 0x54a640b3, 0x54c1cb38,
+	0x54dd52c2, 0x54f8d753, 0x551458eb, 0x552fd78d,
+	0x554b5339, 0x5566cbf3, 0x558241bb, 0x559db492,
+	0x55b9247b, 0x55d49177, 0x55effb87, 0x560b62ad,
+	0x5626c6eb, 0x56422842, 0x565d86b4, 0x5678e242,
+	0x56943aee, 0x56af90b9, 0x56cae3a4, 0x56e633b2,
+	0x570180e4, 0x571ccb3b, 0x573812b8, 0x5753575e,
+	0x576e992e, 0x5789d829, 0x57a51450, 0x57c04da6,
+	0x57db842b, 0x57f6b7e1, 0x5811e8c9, 0x582d16e6,
+	0x58484238, 0x58636ac0, 0x587e9081, 0x5899b37c,
+	0x58b4d3b1, 0x58cff123, 0x58eb0bd3, 0x590623c2,
+	0x592138f2, 0x593c4b63, 0x59575b19, 0x59726812,
+	0x598d7253, 0x59a879da, 0x59c37eab, 0x59de80c6,
+	0x59f9802d, 0x5a147ce0, 0x5a2f76e2, 0x5a4a6e34,
+	0x5a6562d6, 0x5a8054cb, 0x5a9b4414, 0x5ab630b2,
+	0x5ad11aa6, 0x5aec01f1, 0x5b06e696, 0x5b21c895,
+	0x5b3ca7ef, 0x5b5784a6, 0x5b725ebc, 0x5b8d3631,
+	0x5ba80b06, 0x5bc2dd3e, 0x5bddacd9, 0x5bf879d8,
+	0x5c13443d, 0x5c2e0c09, 0x5c48d13e, 0x5c6393dc,
+	0x5c7e53e5, 0x5c99115a, 0x5cb3cc3c, 0x5cce848d,
+	0x5ce93a4e, 0x5d03ed80, 0x5d1e9e24, 0x5d394c3b,
+	0x5d53f7c7, 0x5d6ea0c9, 0x5d894742, 0x5da3eb33,
+	0x5dbe8c9e, 0x5dd92b84, 0x5df3c7e5, 0x5e0e61c3,
+	0x5e28f920, 0x5e438dfc, 0x5e5e2059, 0x5e78b037,
+	0x5e933d99, 0x5eadc87e, 0x5ec850e9, 0x5ee2d6da,
+	0x5efd5a53, 0x5f17db54, 0x5f3259e0, 0x5f4cd5f6,
+	0x5f674f99, 0x5f81c6c8, 0x5f9c3b87, 0x5fb6add4,
+	0x5fd11db3, 0x5feb8b23, 0x6005f626, 0x60205ebd,
+	0x603ac4e9, 0x605528ac, 0x606f8a05, 0x6089e8f7,
+	0x60a44583, 0x60be9fa9, 0x60d8f76b, 0x60f34cca,
+	0x610d9fc7, 0x6127f062, 0x61423e9e, 0x615c8a7a,
+	0x6176d3f9, 0x61911b1b, 0x61ab5fe1, 0x61c5a24d,
+	0x61dfe25f, 0x61fa2018, 0x62145b7a, 0x622e9485,
+	0x6248cb3b, 0x6262ff9d, 0x627d31ab, 0x62976167,
+	0x62b18ed1, 0x62cbb9eb, 0x62e5e2b6, 0x63000933,
+	0x631a2d62, 0x63344f45, 0x634e6edd, 0x63688c2b,
+	0x6382a730, 0x639cbfec, 0x63b6d661, 0x63d0ea90,
+	0x63eafc7a, 0x64050c1f, 0x641f1982, 0x643924a2,
+	0x64532d80, 0x646d341f, 0x6487387e, 0x64a13a9e,
+	0x64bb3a81, 0x64d53828, 0x64ef3393, 0x65092cc4,
+	0x652323bb, 0x653d1879, 0x65570b00, 0x6570fb50,
+	0x658ae96b, 0x65a4d550, 0x65bebf01, 0x65d8a680,
+	0x65f28bcc, 0x660c6ee8, 0x66264fd3, 0x66402e8f,
+	0x665a0b1c, 0x6673e57d, 0x668dbdb0, 0x66a793b8,
+	0x66c16795, 0x66db3949, 0x66f508d4, 0x670ed636,
+	0x6728a172, 0x67426a87, 0x675c3177, 0x6775f643,
+	0x678fb8eb, 0x67a97971, 0x67c337d5, 0x67dcf418,
+	0x67f6ae3b, 0x6810663f, 0x682a1c25, 0x6843cfed,
+	0x685d8199, 0x68773129, 0x6890de9f, 0x68aa89fa,
+	0x68c4333d, 0x68ddda67, 0x68f77f7a, 0x69112277,
+	0x692ac35e, 0x69446230, 0x695dfeee, 0x6977999a,
+	0x69913232, 0x69aac8ba, 0x69c45d31, 0x69ddef98,
+	0x69f77ff0, 0x6a110e3a, 0x6a2a9a77, 0x6a4424a8,
+	0x6a5daccc, 0x6a7732e6, 0x6a90b6f6, 0x6aaa38fd,
+	0x6ac3b8fb, 0x6add36f2, 0x6af6b2e2, 0x6b102ccd,
+	0x6b29a4b2, 0x6b431a92, 0x6b5c8e6f, 0x6b76004a,
+	0x6b8f7022, 0x6ba8ddf9, 0x6bc249d0, 0x6bdbb3a7,
+	0x6bf51b80, 0x6c0e815a, 0x6c27e537, 0x6c414718,
+	0x6c5aa6fd, 0x6c7404e7, 0x6c8d60d7, 0x6ca6bace,
+	0x6cc012cc, 0x6cd968d2, 0x6cf2bce1, 0x6d0c0ef9,
+	0x6d255f1d, 0x6d3ead4b, 0x6d57f985, 0x6d7143cc,
+	0x6d8a8c21, 0x6da3d283, 0x6dbd16f5, 0x6dd65976,
+	0x6def9a08, 0x6e08d8ab, 0x6e221560, 0x6e3b5027,
+	0x6e548902, 0x6e6dbff1, 0x6e86f4f5, 0x6ea0280e,
+	0x6eb9593e, 0x6ed28885, 0x6eebb5e3, 0x6f04e15a,
+	0x6f1e0aea, 0x6f373294, 0x6f505859, 0x6f697c39,
+	0x6f829e35, 0x6f9bbe4e, 0x6fb4dc85, 0x6fcdf8d9,
+	0x6fe7134d, 0x70002be0, 0x70194293, 0x70325767,
+	0x704b6a5d, 0x70647b76, 0x707d8ab1, 0x70969811,
+	0x70afa394, 0x70c8ad3d, 0x70e1b50c, 0x70fabb01,
+	0x7113bf1d, 0x712cc161, 0x7145c1ce, 0x715ec064,
+	0x7177bd24, 0x7190b80f, 0x71a9b124, 0x71c2a866,
+	0x71db9dd4, 0x71f49170, 0x720d8339, 0x72267331,
+	0x723f6159, 0x72584db0, 0x72713838, 0x728a20f1,
+	0x72a307db, 0x72bbecf9, 0x72d4d049, 0x72edb1ce,
+	0x73069187, 0x731f6f75, 0x73384b98, 0x735125f3,
+	0x7369fe84, 0x7382d54d, 0x739baa4e, 0x73b47d89,
+	0x73cd4efd, 0x73e61eab, 0x73feec94, 0x7417b8b8,
+	0x74308319, 0x74494bb6, 0x74621291, 0x747ad7aa,
+	0x74939b02, 0x74ac5c98, 0x74c51c6f, 0x74ddda86,
+	0x74f696de, 0x750f5178, 0x75280a54, 0x7540c174,
+	0x755976d7, 0x75722a7e, 0x758adc69, 0x75a38c9b,
+	0x75bc3b12, 0x75d4e7cf, 0x75ed92d4, 0x76063c21,
+	0x761ee3b6, 0x76378994, 0x76502dbc, 0x7668d02e,
+	0x768170eb, 0x769a0ff3, 0x76b2ad47, 0x76cb48e7,
+	0x76e3e2d5, 0x76fc7b10, 0x7715119a, 0x772da673,
+	0x7746399b, 0x775ecb13, 0x77775adc, 0x778fe8f6,
+	0x77a87561, 0x77c1001f, 0x77d98930, 0x77f21095,
+	0x780a964d, 0x78231a5b, 0x783b9cbd, 0x78541d75,
+	0x786c9c84, 0x788519e9, 0x789d95a6, 0x78b60fbb,
+	0x78ce8828, 0x78e6feef, 0x78ff740f, 0x7917e78a,
+	0x7930595f, 0x7948c990, 0x7961381d, 0x7979a506,
+	0x7992104c, 0x79aa79f0, 0x79c2e1f1, 0x79db4852,
+	0x79f3ad11, 0x7a0c1031, 0x7a2471b0, 0x7a3cd191,
+	0x7a552fd3, 0x7a6d8c76, 0x7a85e77d, 0x7a9e40e6,
+	0x7ab698b2, 0x7aceeee3, 0x7ae74378, 0x7aff9673,
+	0x7b17e7d2, 0x7b303799, 0x7b4885c5, 0x7b60d259,
+	0x7b791d55, 0x7b9166b9, 0x7ba9ae86, 0x7bc1f4bc,
+	0x7bda395c, 0x7bf27c66, 0x7c0abddb, 0x7c22fdbb,
+	0x7c3b3c07, 0x7c5378c0, 0x7c6bb3e5, 0x7c83ed78,
+	0x7c9c2579, 0x7cb45be9, 0x7ccc90c7, 0x7ce4c414,
+	0x7cfcf5d2, 0x7d152600, 0x7d2d549f, 0x7d4581b0,
+	0x7d5dad32, 0x7d75d727, 0x7d8dff8f, 0x7da6266a,
+	0x7dbe4bba, 0x7dd66f7d, 0x7dee91b6, 0x7e06b264,
+	0x7e1ed188, 0x7e36ef22, 0x7e4f0b34, 0x7e6725bd,
+	0x7e7f3ebd, 0x7e975636, 0x7eaf6c28, 0x7ec78093,
+	0x7edf9378, 0x7ef7a4d7, 0x7f0fb4b1, 0x7f27c307,
+	0x7f3fcfd8, 0x7f57db25, 0x7f6fe4ef, 0x7f87ed36,
 	0x7f9ff3fb, 0x7fb7f93e, 0x7fcffcff, 0x7fe7ff40
 };
 
 const Word32 mTab_4_3[512]={
-	0x32cbfd4a, 0x32eddd70, 0x330fc339, 0x3331aea3, 
-	0x33539fac, 0x33759652, 0x33979294, 0x33b99470, 
-	0x33db9be4, 0x33fda8ed, 0x341fbb8b, 0x3441d3bb, 
-	0x3463f17c, 0x348614cc, 0x34a83da8, 0x34ca6c10, 
-	0x34eca001, 0x350ed979, 0x35311877, 0x35535cfa, 
-	0x3575a6fe, 0x3597f683, 0x35ba4b87, 0x35dca607, 
-	0x35ff0603, 0x36216b78, 0x3643d665, 0x366646c7, 
-	0x3688bc9e, 0x36ab37e8, 0x36cdb8a2, 0x36f03ecb, 
-	0x3712ca62, 0x37355b64, 0x3757f1d1, 0x377a8da5, 
-	0x379d2ee0, 0x37bfd580, 0x37e28184, 0x380532e8, 
-	0x3827e9ad, 0x384aa5d0, 0x386d674f, 0x38902e2a, 
-	0x38b2fa5d, 0x38d5cbe9, 0x38f8a2ca, 0x391b7eff, 
-	0x393e6088, 0x39614761, 0x3984338a, 0x39a72501, 
-	0x39ca1bc4, 0x39ed17d1, 0x3a101928, 0x3a331fc6, 
-	0x3a562baa, 0x3a793cd2, 0x3a9c533d, 0x3abf6ee9, 
-	0x3ae28fd5, 0x3b05b5ff, 0x3b28e165, 0x3b4c1206, 
-	0x3b6f47e0, 0x3b9282f2, 0x3bb5c33a, 0x3bd908b7, 
-	0x3bfc5368, 0x3c1fa349, 0x3c42f85b, 0x3c66529c, 
-	0x3c89b209, 0x3cad16a2, 0x3cd08065, 0x3cf3ef51, 
-	0x3d176364, 0x3d3adc9c, 0x3d5e5af8, 0x3d81de77, 
-	0x3da56717, 0x3dc8f4d6, 0x3dec87b4, 0x3e101fae, 
-	0x3e33bcc3, 0x3e575ef2, 0x3e7b063a, 0x3e9eb298, 
-	0x3ec2640c, 0x3ee61a93, 0x3f09d62d, 0x3f2d96d8, 
-	0x3f515c93, 0x3f75275b, 0x3f98f731, 0x3fbccc11, 
-	0x3fe0a5fc, 0x400484ef, 0x402868ea, 0x404c51e9, 
-	0x40703fee, 0x409432f5, 0x40b82afd, 0x40dc2806, 
-	0x41002a0d, 0x41243111, 0x41483d12, 0x416c4e0d, 
-	0x41906401, 0x41b47eed, 0x41d89ecf, 0x41fcc3a7, 
-	0x4220ed72, 0x42451c30, 0x42694fde, 0x428d887d, 
-	0x42b1c609, 0x42d60883, 0x42fa4fe8, 0x431e9c37, 
-	0x4342ed70, 0x43674390, 0x438b9e96, 0x43affe82, 
-	0x43d46351, 0x43f8cd03, 0x441d3b95, 0x4441af08, 
-	0x44662758, 0x448aa487, 0x44af2690, 0x44d3ad75, 
-	0x44f83933, 0x451cc9c8, 0x45415f35, 0x4565f977, 
-	0x458a988d, 0x45af3c76, 0x45d3e531, 0x45f892bc, 
-	0x461d4516, 0x4641fc3e, 0x4666b832, 0x468b78f2, 
-	0x46b03e7c, 0x46d508cf, 0x46f9d7e9, 0x471eabca, 
-	0x47438470, 0x476861d9, 0x478d4406, 0x47b22af3, 
-	0x47d716a1, 0x47fc070e, 0x4820fc39, 0x4845f620, 
-	0x486af4c3, 0x488ff820, 0x48b50035, 0x48da0d03, 
-	0x48ff1e87, 0x492434c0, 0x49494fad, 0x496e6f4d, 
-	0x4993939f, 0x49b8bca2, 0x49ddea54, 0x4a031cb4, 
-	0x4a2853c1, 0x4a4d8f7a, 0x4a72cfde, 0x4a9814eb, 
-	0x4abd5ea1, 0x4ae2acfd, 0x4b080000, 0x4b2d57a8, 
-	0x4b52b3f3, 0x4b7814e1, 0x4b9d7a70, 0x4bc2e49f, 
-	0x4be8536e, 0x4c0dc6db, 0x4c333ee4, 0x4c58bb89, 
-	0x4c7e3cc9, 0x4ca3c2a2, 0x4cc94d14, 0x4ceedc1c, 
-	0x4d146fbb, 0x4d3a07ef, 0x4d5fa4b6, 0x4d854611, 
-	0x4daaebfd, 0x4dd09679, 0x4df64585, 0x4e1bf91f, 
-	0x4e41b146, 0x4e676dfa, 0x4e8d2f38, 0x4eb2f501, 
-	0x4ed8bf52, 0x4efe8e2b, 0x4f24618a, 0x4f4a3970, 
-	0x4f7015d9, 0x4f95f6c6, 0x4fbbdc36, 0x4fe1c626, 
-	0x5007b497, 0x502da787, 0x50539ef5, 0x50799ae1, 
-	0x509f9b48, 0x50c5a02a, 0x50eba985, 0x5111b75a, 
-	0x5137c9a6, 0x515de069, 0x5183fba2, 0x51aa1b4f, 
-	0x51d03f70, 0x51f66803, 0x521c9508, 0x5242c67d, 
-	0x5268fc62, 0x528f36b5, 0x52b57575, 0x52dbb8a2, 
-	0x5302003a, 0x53284c3c, 0x534e9ca8, 0x5374f17c, 
-	0x539b4ab7, 0x53c1a858, 0x53e80a5f, 0x540e70ca, 
-	0x5434db98, 0x545b4ac8, 0x5481be5a, 0x54a8364b, 
-	0x54ceb29c, 0x54f5334c, 0x551bb858, 0x554241c1, 
-	0x5568cf85, 0x558f61a3, 0x55b5f81b, 0x55dc92eb, 
-	0x56033212, 0x5629d590, 0x56507d63, 0x5677298a, 
-	0x569dda05, 0x56c48ed3, 0x56eb47f2, 0x57120562, 
-	0x5738c721, 0x575f8d2f, 0x5786578a, 0x57ad2633, 
-	0x57d3f927, 0x57fad066, 0x5821abef, 0x58488bc0, 
-	0x586f6fda, 0x5896583b, 0x58bd44e2, 0x58e435ce, 
-	0x590b2aff, 0x59322473, 0x59592229, 0x59802420, 
-	0x59a72a59, 0x59ce34d0, 0x59f54387, 0x5a1c567b, 
-	0x5a436dac, 0x5a6a8919, 0x5a91a8c1, 0x5ab8cca3, 
-	0x5adff4be, 0x5b072111, 0x5b2e519c, 0x5b55865e, 
-	0x5b7cbf54, 0x5ba3fc80, 0x5bcb3ddf, 0x5bf28371, 
-	0x5c19cd35, 0x5c411b2a, 0x5c686d4f, 0x5c8fc3a4, 
-	0x5cb71e27, 0x5cde7cd7, 0x5d05dfb4, 0x5d2d46bd, 
-	0x5d54b1f0, 0x5d7c214e, 0x5da394d4, 0x5dcb0c83, 
-	0x5df28859, 0x5e1a0856, 0x5e418c78, 0x5e6914be, 
-	0x5e90a129, 0x5eb831b7, 0x5edfc667, 0x5f075f38, 
-	0x5f2efc29, 0x5f569d3a, 0x5f7e426a, 0x5fa5ebb7, 
-	0x5fcd9921, 0x5ff54aa8, 0x601d004a, 0x6044ba06, 
-	0x606c77dc, 0x609439ca, 0x60bbffd0, 0x60e3c9ee, 
-	0x610b9821, 0x61336a6a, 0x615b40c8, 0x61831b39, 
-	0x61aaf9bd, 0x61d2dc53, 0x61fac2fa, 0x6222adb2, 
-	0x624a9c79, 0x62728f4f, 0x629a8633, 0x62c28123, 
-	0x62ea8020, 0x63128329, 0x633a8a3c, 0x63629559, 
-	0x638aa47f, 0x63b2b7ad, 0x63dacee2, 0x6402ea1e, 
-	0x642b0960, 0x64532ca6, 0x647b53f1, 0x64a37f3f, 
-	0x64cbae8f, 0x64f3e1e2, 0x651c1935, 0x65445488, 
-	0x656c93db, 0x6594d72c, 0x65bd1e7b, 0x65e569c7, 
-	0x660db90f, 0x66360c53, 0x665e6391, 0x6686bec9, 
-	0x66af1dfa, 0x66d78123, 0x66ffe844, 0x6728535b, 
-	0x6750c268, 0x6779356b, 0x67a1ac62, 0x67ca274c, 
-	0x67f2a629, 0x681b28f9, 0x6843afb9, 0x686c3a6a, 
-	0x6894c90b, 0x68bd5b9b, 0x68e5f219, 0x690e8c84, 
-	0x69372add, 0x695fcd21, 0x69887350, 0x69b11d6a, 
-	0x69d9cb6d, 0x6a027d5a, 0x6a2b332f, 0x6a53eceb, 
-	0x6a7caa8d, 0x6aa56c16, 0x6ace3184, 0x6af6fad6, 
-	0x6b1fc80c, 0x6b489925, 0x6b716e20, 0x6b9a46fd, 
-	0x6bc323bb, 0x6bec0458, 0x6c14e8d5, 0x6c3dd130, 
-	0x6c66bd69, 0x6c8fad80, 0x6cb8a172, 0x6ce19940, 
-	0x6d0a94e9, 0x6d33946d, 0x6d5c97ca, 0x6d859eff, 
-	0x6daeaa0d, 0x6dd7b8f1, 0x6e00cbad, 0x6e29e23e, 
-	0x6e52fca4, 0x6e7c1adf, 0x6ea53cee, 0x6ece62cf, 
-	0x6ef78c83, 0x6f20ba09, 0x6f49eb5f, 0x6f732085, 
-	0x6f9c597b, 0x6fc59640, 0x6feed6d3, 0x70181b33, 
-	0x70416360, 0x706aaf59, 0x7093ff1d, 0x70bd52ab, 
-	0x70e6aa04, 0x71100525, 0x7139640f, 0x7162c6c1, 
-	0x718c2d3a, 0x71b5977a, 0x71df057f, 0x72087749, 
-	0x7231ecd8, 0x725b662a, 0x7284e33f, 0x72ae6417, 
-	0x72d7e8b0, 0x7301710a, 0x732afd24, 0x73548cfe, 
-	0x737e2097, 0x73a7b7ee, 0x73d15303, 0x73faf1d5, 
-	0x74249462, 0x744e3aac, 0x7477e4b0, 0x74a1926e, 
-	0x74cb43e6, 0x74f4f917, 0x751eb201, 0x75486ea1, 
-	0x75722ef9, 0x759bf307, 0x75c5baca, 0x75ef8642, 
-	0x7619556f, 0x7643284f, 0x766cfee2, 0x7696d928, 
-	0x76c0b71f, 0x76ea98c7, 0x77147e20, 0x773e6728, 
-	0x776853df, 0x77924445, 0x77bc3858, 0x77e63019, 
-	0x78102b85, 0x783a2a9e, 0x78642d62, 0x788e33d1, 
-	0x78b83de9, 0x78e24bab, 0x790c5d15, 0x79367228, 
-	0x79608ae1, 0x798aa742, 0x79b4c748, 0x79deeaf4, 
-	0x7a091245, 0x7a333d3a, 0x7a5d6bd2, 0x7a879e0e, 
-	0x7ab1d3ec, 0x7adc0d6b, 0x7b064a8c, 0x7b308b4d, 
-	0x7b5acfae, 0x7b8517ae, 0x7baf634c, 0x7bd9b289, 
-	0x7c040563, 0x7c2e5bda, 0x7c58b5ec, 0x7c83139b, 
-	0x7cad74e4, 0x7cd7d9c7, 0x7d024244, 0x7d2cae5a, 
-	0x7d571e09, 0x7d81914f, 0x7dac082d, 0x7dd682a1, 
-	0x7e0100ac, 0x7e2b824b, 0x7e560780, 0x7e809048, 
-	0x7eab1ca5, 0x7ed5ac94, 0x7f004015, 0x7f2ad729, 
+	0x32cbfd4a, 0x32eddd70, 0x330fc339, 0x3331aea3,
+	0x33539fac, 0x33759652, 0x33979294, 0x33b99470,
+	0x33db9be4, 0x33fda8ed, 0x341fbb8b, 0x3441d3bb,
+	0x3463f17c, 0x348614cc, 0x34a83da8, 0x34ca6c10,
+	0x34eca001, 0x350ed979, 0x35311877, 0x35535cfa,
+	0x3575a6fe, 0x3597f683, 0x35ba4b87, 0x35dca607,
+	0x35ff0603, 0x36216b78, 0x3643d665, 0x366646c7,
+	0x3688bc9e, 0x36ab37e8, 0x36cdb8a2, 0x36f03ecb,
+	0x3712ca62, 0x37355b64, 0x3757f1d1, 0x377a8da5,
+	0x379d2ee0, 0x37bfd580, 0x37e28184, 0x380532e8,
+	0x3827e9ad, 0x384aa5d0, 0x386d674f, 0x38902e2a,
+	0x38b2fa5d, 0x38d5cbe9, 0x38f8a2ca, 0x391b7eff,
+	0x393e6088, 0x39614761, 0x3984338a, 0x39a72501,
+	0x39ca1bc4, 0x39ed17d1, 0x3a101928, 0x3a331fc6,
+	0x3a562baa, 0x3a793cd2, 0x3a9c533d, 0x3abf6ee9,
+	0x3ae28fd5, 0x3b05b5ff, 0x3b28e165, 0x3b4c1206,
+	0x3b6f47e0, 0x3b9282f2, 0x3bb5c33a, 0x3bd908b7,
+	0x3bfc5368, 0x3c1fa349, 0x3c42f85b, 0x3c66529c,
+	0x3c89b209, 0x3cad16a2, 0x3cd08065, 0x3cf3ef51,
+	0x3d176364, 0x3d3adc9c, 0x3d5e5af8, 0x3d81de77,
+	0x3da56717, 0x3dc8f4d6, 0x3dec87b4, 0x3e101fae,
+	0x3e33bcc3, 0x3e575ef2, 0x3e7b063a, 0x3e9eb298,
+	0x3ec2640c, 0x3ee61a93, 0x3f09d62d, 0x3f2d96d8,
+	0x3f515c93, 0x3f75275b, 0x3f98f731, 0x3fbccc11,
+	0x3fe0a5fc, 0x400484ef, 0x402868ea, 0x404c51e9,
+	0x40703fee, 0x409432f5, 0x40b82afd, 0x40dc2806,
+	0x41002a0d, 0x41243111, 0x41483d12, 0x416c4e0d,
+	0x41906401, 0x41b47eed, 0x41d89ecf, 0x41fcc3a7,
+	0x4220ed72, 0x42451c30, 0x42694fde, 0x428d887d,
+	0x42b1c609, 0x42d60883, 0x42fa4fe8, 0x431e9c37,
+	0x4342ed70, 0x43674390, 0x438b9e96, 0x43affe82,
+	0x43d46351, 0x43f8cd03, 0x441d3b95, 0x4441af08,
+	0x44662758, 0x448aa487, 0x44af2690, 0x44d3ad75,
+	0x44f83933, 0x451cc9c8, 0x45415f35, 0x4565f977,
+	0x458a988d, 0x45af3c76, 0x45d3e531, 0x45f892bc,
+	0x461d4516, 0x4641fc3e, 0x4666b832, 0x468b78f2,
+	0x46b03e7c, 0x46d508cf, 0x46f9d7e9, 0x471eabca,
+	0x47438470, 0x476861d9, 0x478d4406, 0x47b22af3,
+	0x47d716a1, 0x47fc070e, 0x4820fc39, 0x4845f620,
+	0x486af4c3, 0x488ff820, 0x48b50035, 0x48da0d03,
+	0x48ff1e87, 0x492434c0, 0x49494fad, 0x496e6f4d,
+	0x4993939f, 0x49b8bca2, 0x49ddea54, 0x4a031cb4,
+	0x4a2853c1, 0x4a4d8f7a, 0x4a72cfde, 0x4a9814eb,
+	0x4abd5ea1, 0x4ae2acfd, 0x4b080000, 0x4b2d57a8,
+	0x4b52b3f3, 0x4b7814e1, 0x4b9d7a70, 0x4bc2e49f,
+	0x4be8536e, 0x4c0dc6db, 0x4c333ee4, 0x4c58bb89,
+	0x4c7e3cc9, 0x4ca3c2a2, 0x4cc94d14, 0x4ceedc1c,
+	0x4d146fbb, 0x4d3a07ef, 0x4d5fa4b6, 0x4d854611,
+	0x4daaebfd, 0x4dd09679, 0x4df64585, 0x4e1bf91f,
+	0x4e41b146, 0x4e676dfa, 0x4e8d2f38, 0x4eb2f501,
+	0x4ed8bf52, 0x4efe8e2b, 0x4f24618a, 0x4f4a3970,
+	0x4f7015d9, 0x4f95f6c6, 0x4fbbdc36, 0x4fe1c626,
+	0x5007b497, 0x502da787, 0x50539ef5, 0x50799ae1,
+	0x509f9b48, 0x50c5a02a, 0x50eba985, 0x5111b75a,
+	0x5137c9a6, 0x515de069, 0x5183fba2, 0x51aa1b4f,
+	0x51d03f70, 0x51f66803, 0x521c9508, 0x5242c67d,
+	0x5268fc62, 0x528f36b5, 0x52b57575, 0x52dbb8a2,
+	0x5302003a, 0x53284c3c, 0x534e9ca8, 0x5374f17c,
+	0x539b4ab7, 0x53c1a858, 0x53e80a5f, 0x540e70ca,
+	0x5434db98, 0x545b4ac8, 0x5481be5a, 0x54a8364b,
+	0x54ceb29c, 0x54f5334c, 0x551bb858, 0x554241c1,
+	0x5568cf85, 0x558f61a3, 0x55b5f81b, 0x55dc92eb,
+	0x56033212, 0x5629d590, 0x56507d63, 0x5677298a,
+	0x569dda05, 0x56c48ed3, 0x56eb47f2, 0x57120562,
+	0x5738c721, 0x575f8d2f, 0x5786578a, 0x57ad2633,
+	0x57d3f927, 0x57fad066, 0x5821abef, 0x58488bc0,
+	0x586f6fda, 0x5896583b, 0x58bd44e2, 0x58e435ce,
+	0x590b2aff, 0x59322473, 0x59592229, 0x59802420,
+	0x59a72a59, 0x59ce34d0, 0x59f54387, 0x5a1c567b,
+	0x5a436dac, 0x5a6a8919, 0x5a91a8c1, 0x5ab8cca3,
+	0x5adff4be, 0x5b072111, 0x5b2e519c, 0x5b55865e,
+	0x5b7cbf54, 0x5ba3fc80, 0x5bcb3ddf, 0x5bf28371,
+	0x5c19cd35, 0x5c411b2a, 0x5c686d4f, 0x5c8fc3a4,
+	0x5cb71e27, 0x5cde7cd7, 0x5d05dfb4, 0x5d2d46bd,
+	0x5d54b1f0, 0x5d7c214e, 0x5da394d4, 0x5dcb0c83,
+	0x5df28859, 0x5e1a0856, 0x5e418c78, 0x5e6914be,
+	0x5e90a129, 0x5eb831b7, 0x5edfc667, 0x5f075f38,
+	0x5f2efc29, 0x5f569d3a, 0x5f7e426a, 0x5fa5ebb7,
+	0x5fcd9921, 0x5ff54aa8, 0x601d004a, 0x6044ba06,
+	0x606c77dc, 0x609439ca, 0x60bbffd0, 0x60e3c9ee,
+	0x610b9821, 0x61336a6a, 0x615b40c8, 0x61831b39,
+	0x61aaf9bd, 0x61d2dc53, 0x61fac2fa, 0x6222adb2,
+	0x624a9c79, 0x62728f4f, 0x629a8633, 0x62c28123,
+	0x62ea8020, 0x63128329, 0x633a8a3c, 0x63629559,
+	0x638aa47f, 0x63b2b7ad, 0x63dacee2, 0x6402ea1e,
+	0x642b0960, 0x64532ca6, 0x647b53f1, 0x64a37f3f,
+	0x64cbae8f, 0x64f3e1e2, 0x651c1935, 0x65445488,
+	0x656c93db, 0x6594d72c, 0x65bd1e7b, 0x65e569c7,
+	0x660db90f, 0x66360c53, 0x665e6391, 0x6686bec9,
+	0x66af1dfa, 0x66d78123, 0x66ffe844, 0x6728535b,
+	0x6750c268, 0x6779356b, 0x67a1ac62, 0x67ca274c,
+	0x67f2a629, 0x681b28f9, 0x6843afb9, 0x686c3a6a,
+	0x6894c90b, 0x68bd5b9b, 0x68e5f219, 0x690e8c84,
+	0x69372add, 0x695fcd21, 0x69887350, 0x69b11d6a,
+	0x69d9cb6d, 0x6a027d5a, 0x6a2b332f, 0x6a53eceb,
+	0x6a7caa8d, 0x6aa56c16, 0x6ace3184, 0x6af6fad6,
+	0x6b1fc80c, 0x6b489925, 0x6b716e20, 0x6b9a46fd,
+	0x6bc323bb, 0x6bec0458, 0x6c14e8d5, 0x6c3dd130,
+	0x6c66bd69, 0x6c8fad80, 0x6cb8a172, 0x6ce19940,
+	0x6d0a94e9, 0x6d33946d, 0x6d5c97ca, 0x6d859eff,
+	0x6daeaa0d, 0x6dd7b8f1, 0x6e00cbad, 0x6e29e23e,
+	0x6e52fca4, 0x6e7c1adf, 0x6ea53cee, 0x6ece62cf,
+	0x6ef78c83, 0x6f20ba09, 0x6f49eb5f, 0x6f732085,
+	0x6f9c597b, 0x6fc59640, 0x6feed6d3, 0x70181b33,
+	0x70416360, 0x706aaf59, 0x7093ff1d, 0x70bd52ab,
+	0x70e6aa04, 0x71100525, 0x7139640f, 0x7162c6c1,
+	0x718c2d3a, 0x71b5977a, 0x71df057f, 0x72087749,
+	0x7231ecd8, 0x725b662a, 0x7284e33f, 0x72ae6417,
+	0x72d7e8b0, 0x7301710a, 0x732afd24, 0x73548cfe,
+	0x737e2097, 0x73a7b7ee, 0x73d15303, 0x73faf1d5,
+	0x74249462, 0x744e3aac, 0x7477e4b0, 0x74a1926e,
+	0x74cb43e6, 0x74f4f917, 0x751eb201, 0x75486ea1,
+	0x75722ef9, 0x759bf307, 0x75c5baca, 0x75ef8642,
+	0x7619556f, 0x7643284f, 0x766cfee2, 0x7696d928,
+	0x76c0b71f, 0x76ea98c7, 0x77147e20, 0x773e6728,
+	0x776853df, 0x77924445, 0x77bc3858, 0x77e63019,
+	0x78102b85, 0x783a2a9e, 0x78642d62, 0x788e33d1,
+	0x78b83de9, 0x78e24bab, 0x790c5d15, 0x79367228,
+	0x79608ae1, 0x798aa742, 0x79b4c748, 0x79deeaf4,
+	0x7a091245, 0x7a333d3a, 0x7a5d6bd2, 0x7a879e0e,
+	0x7ab1d3ec, 0x7adc0d6b, 0x7b064a8c, 0x7b308b4d,
+	0x7b5acfae, 0x7b8517ae, 0x7baf634c, 0x7bd9b289,
+	0x7c040563, 0x7c2e5bda, 0x7c58b5ec, 0x7c83139b,
+	0x7cad74e4, 0x7cd7d9c7, 0x7d024244, 0x7d2cae5a,
+	0x7d571e09, 0x7d81914f, 0x7dac082d, 0x7dd682a1,
+	0x7e0100ac, 0x7e2b824b, 0x7e560780, 0x7e809048,
+	0x7eab1ca5, 0x7ed5ac94, 0x7f004015, 0x7f2ad729,
 	0x7f5571cd, 0x7f801003, 0x7faab1c8, 0x7fd5571d
 };
 
 
 const Word32 invSBF[24] = {
-  0x3FFD34FC, 0x2D3F8000, 0x24F18C7E, 0x1FFE9A7E, 
-  0x1C9DF10C, 0x1A1F851A, 0x182FE994, 0x169FC000, 
-  0x15542AAA, 0x143C31C2, 0x134B1B6C, 0x127920BE, 
-  0x11BF2FCC, 0x111A749E, 0x1085FC42, 0x0FFFA7BE, 
-  0x0F855818, 0x0F14EE56, 0x0EAE6A78, 0x0E4EF886, 
+  0x3FFD34FC, 0x2D3F8000, 0x24F18C7E, 0x1FFE9A7E,
+  0x1C9DF10C, 0x1A1F851A, 0x182FE994, 0x169FC000,
+  0x15542AAA, 0x143C31C2, 0x134B1B6C, 0x127920BE,
+  0x11BF2FCC, 0x111A749E, 0x1085FC42, 0x0FFFA7BE,
+  0x0F855818, 0x0F14EE56, 0x0EAE6A78, 0x0E4EF886,
   0x0DF69880, 0x0DA49568, 0x0D578542, 0x0D101D0C
 };
 
@@ -1353,40 +1353,40 @@
 };
 
 const Word16 sideInfoTabLong[MAX_SFB_LONG + 1] = {
-  9, 9, 9, 9, 9, 9, 9, 9, 9, 
-  9, 9, 9, 9, 9, 9, 9, 9, 9, 
-  9, 9, 9, 9, 9, 9, 9, 9, 9, 
-  9, 9, 9, 9, 14, 14, 14, 14, 
-  14, 14, 14, 14, 14, 14, 14, 
-  14, 14, 14, 14, 14, 14, 14, 
+  9, 9, 9, 9, 9, 9, 9, 9, 9,
+  9, 9, 9, 9, 9, 9, 9, 9, 9,
+  9, 9, 9, 9, 9, 9, 9, 9, 9,
+  9, 9, 9, 9, 14, 14, 14, 14,
+  14, 14, 14, 14, 14, 14, 14,
+  14, 14, 14, 14, 14, 14, 14,
   14, 14, 14
 };
 
 const Word16 sideInfoTabShort[MAX_SFB_SHORT + 1] = {
-  7, 7, 7, 7, 7, 7, 7, 10, 10, 
+  7, 7, 7, 7, 7, 7, 7, 10, 10,
   10, 10, 10, 10, 10, 13, 13
 };
 
 Word32 specExpMantTableComb_enc[4][14] =
 {
-  {0x40000000,  0x50a28be6,  0x6597fa95,  0x40000000, 
-   0x50a28be6,  0x6597fa95,  0x40000000,  0x50a28be6, 
-   0x6597fa95,  0x40000000,  0x50a28be6,  0x6597fa95, 
-   0x40000000,  0x50a28be6}, 
+  {0x40000000,  0x50a28be6,  0x6597fa95,  0x40000000,
+   0x50a28be6,  0x6597fa95,  0x40000000,  0x50a28be6,
+   0x6597fa95,  0x40000000,  0x50a28be6,  0x6597fa95,
+   0x40000000,  0x50a28be6},
 
-  {0x4c1bf829,  0x5fe4435e,  0x78d0df9c,  0x4c1bf829, 
-   0x5fe4435e,  0x78d0df9c,  0x4c1bf829,  0x5fe4435e, 
-   0x78d0df9c,  0x4c1bf829,  0x5fe4435e,  0x78d0df9c, 
-   0x4c1bf829,  0x5fe4435e}, 
+  {0x4c1bf829,  0x5fe4435e,  0x78d0df9c,  0x4c1bf829,
+   0x5fe4435e,  0x78d0df9c,  0x4c1bf829,  0x5fe4435e,
+   0x78d0df9c,  0x4c1bf829,  0x5fe4435e,  0x78d0df9c,
+   0x4c1bf829,  0x5fe4435e},
 
-  {0x5a82799a,  0x7208f81d,  0x47d66b0f,  0x5a82799a, 
-   0x7208f81d,  0x47d66b0f,  0x5a82799a,  0x7208f81d, 
-   0x47d66b0f,  0x5a82799a,  0x7208f81d,  0x47d66b0f, 
-   0x5a82799a,  0x7208f81d}, 
+  {0x5a82799a,  0x7208f81d,  0x47d66b0f,  0x5a82799a,
+   0x7208f81d,  0x47d66b0f,  0x5a82799a,  0x7208f81d,
+   0x47d66b0f,  0x5a82799a,  0x7208f81d,  0x47d66b0f,
+   0x5a82799a,  0x7208f81d},
 
-  {0x6ba27e65,  0x43ce3e4b,  0x556e0424,  0x6ba27e65, 
-   0x43ce3e4b,  0x556e0424,  0x6ba27e65,  0x43ce3e4b, 
-   0x556e0424,  0x6ba27e65,  0x43ce3e4b,  0x556e0424, 
+  {0x6ba27e65,  0x43ce3e4b,  0x556e0424,  0x6ba27e65,
+   0x43ce3e4b,  0x556e0424,  0x6ba27e65,  0x43ce3e4b,
+   0x556e0424,  0x6ba27e65,  0x43ce3e4b,  0x556e0424,
    0x6ba27e65,  0x43ce3e4b}
 };
 
@@ -1417,12 +1417,12 @@
 };
 
 const int sampRateTab[NUM_SAMPLE_RATES] = {
-    96000, 88200, 64000, 48000, 44100, 32000, 
+    96000, 88200, 64000, 48000, 44100, 32000,
 	24000, 22050, 16000, 12000, 11025,  8000
 };
 
 
-const int	rates[8] = {		
+const int	rates[8] = {
 	160, 240, 320, 400, 480, 560, 640, 0
 };
 
@@ -1507,7 +1507,7 @@
 };
 
 /*
-  these tables are used only for counting and 
+  these tables are used only for counting and
   are stored in packed format
 */
 const UWord16 huff_ltab1_2[3][3][3][3]=
@@ -2260,12 +2260,12 @@
 };
 
 const Word32 m_log2_table[INT_BITS] = {
-  0x00000000,0x4ae00d00,0x2934f080,0x15c01a3f, 
-  0x0b31fb80,0x05aeb4e0,0x02dcf2d0,0x016fe50c, 
+  0x00000000,0x4ae00d00,0x2934f080,0x15c01a3f,
+  0x0b31fb80,0x05aeb4e0,0x02dcf2d0,0x016fe50c,
   0x00b84e23,0x005c3e10,0x002e24ca,0x001713d6,
   0x000b8a47,0x0005c53b,0x0002e2a3,0x00017153,
   0x0000b8aa,0x00005c55,0x00002e2b,0x00001715,
-  0x00000b8b,0x000005c5,0x000002e3,0x00000171, 
+  0x00000b8b,0x000005c5,0x000002e3,0x00000171,
   0x000000b9,0x0000005c,0x0000002e,0x00000017,
   0x0000000c,0x00000006,0x00000003,0x00000001
 };
@@ -2344,7 +2344,7 @@
 };
 
 
-const unsigned char bitrevTab[17 + 129] = 
+const unsigned char bitrevTab[17 + 129] =
 {
 /* 64 */
 0x01, 0x08, 0x02, 0x04, 0x03, 0x0c, 0x05, 0x0a, 0x07, 0x0e, 0x0b, 0x0d, 0x00, 0x06, 0x09, 0x0f,
diff --git a/media/libstagefright/codecs/aacenc/src/aacenc.c b/media/libstagefright/codecs/aacenc/src/aacenc.c
index 975f598..b5e8a9c 100644
--- a/media/libstagefright/codecs/aacenc/src/aacenc.c
+++ b/media/libstagefright/codecs/aacenc/src/aacenc.c
@@ -48,7 +48,7 @@
 
 	interMem = 0;
 	error = 0;
-	
+
 	/* init the memory operator */
 	if(pUserData == NULL || pUserData->memflag != VO_IMF_USERMEMOPERATOR || pUserData->memData == NULL )
 	{
@@ -113,7 +113,7 @@
 		{
 			mem_free(pMemOP, hAacEnc, VO_INDEX_ENC_AAC);
 			hAacEnc = NULL;
-		}		
+		}
 		*phCodec = NULL;
 		return VO_ERR_OUTOF_MEMORY;
 	}
@@ -168,9 +168,9 @@
 	{
 		return VO_ERR_INVALID_ARG;
 	}
-	
+
 	hAacEnc = (AAC_ENCODER *)hCodec;
-	
+
 	/* init input pcm buffer and length*/
 	hAacEnc->inbuf = (short *)pInput->Buffer;
 	hAacEnc->inlen = pInput->Length / sizeof(short);
@@ -178,12 +178,12 @@
 
 	hAacEnc->encbuf = hAacEnc->inbuf;
 	hAacEnc->enclen = hAacEnc->inlen;
-	
+
 	/* rebuild intra pcm buffer and length*/
 	if(hAacEnc->intlen)
 	{
 		length = min(hAacEnc->config.nChannelsIn*AACENC_BLOCKSIZE - hAacEnc->intlen, hAacEnc->inlen);
-		hAacEnc->voMemop->Copy(VO_INDEX_ENC_AAC, hAacEnc->intbuf + hAacEnc->intlen, 
+		hAacEnc->voMemop->Copy(VO_INDEX_ENC_AAC, hAacEnc->intbuf + hAacEnc->intlen,
 			hAacEnc->inbuf, length*sizeof(short));
 
 		hAacEnc->encbuf = hAacEnc->intbuf;
@@ -192,7 +192,7 @@
 		hAacEnc->inbuf += length;
 		hAacEnc->inlen -= length;
 	}
-	
+
 	return VO_ERR_NONE;
 }
 
@@ -219,11 +219,11 @@
 	 /* check the input pcm buffer and length*/
 	 if(NULL == hAacEnc->encbuf || hAacEnc->enclen < inbuflen)
 	 {
-		length = hAacEnc->enclen;		
+		length = hAacEnc->enclen;
 		if(hAacEnc->intlen == 0)
-		{	
-			hAacEnc->voMemop->Copy(VO_INDEX_ENC_AAC, hAacEnc->intbuf, 
-				hAacEnc->encbuf, length*sizeof(short));		
+		{
+			hAacEnc->voMemop->Copy(VO_INDEX_ENC_AAC, hAacEnc->intbuf,
+				hAacEnc->encbuf, length*sizeof(short));
 			hAacEnc->uselength += length*sizeof(short);
 		}
 		else
@@ -236,7 +236,7 @@
 		pOutput->Length = 0;
 		if(pOutInfo)
 			pOutInfo->InputUsed = hAacEnc->uselength;
-		return VO_ERR_INPUT_BUFFER_SMALL;	
+		return VO_ERR_INPUT_BUFFER_SMALL;
 	 }
 
 	 /* check the output aac buffer and length*/
@@ -254,7 +254,7 @@
 	 /* update the input pcm buffer and length*/
 	 if(hAacEnc->intlen)
 	 {
-		length = inbuflen - hAacEnc->intlen;		
+		length = inbuflen - hAacEnc->intlen;
 		hAacEnc->encbuf = hAacEnc->inbuf;
 		hAacEnc->enclen = hAacEnc->inlen;
 		hAacEnc->uselength += length*sizeof(short);
@@ -265,7 +265,7 @@
 		 hAacEnc->encbuf = hAacEnc->encbuf + inbuflen;
 		 hAacEnc->enclen = hAacEnc->enclen - inbuflen;
 		 hAacEnc->uselength += inbuflen*sizeof(short);
-	 }	 
+	 }
 
 	 /* update the output aac information */
 	if(pOutInfo)
@@ -287,7 +287,7 @@
 VO_U32 VO_API voAACEncUninit(VO_HANDLE hCodec)
 {
 	AAC_ENCODER* hAacEnc = (AAC_ENCODER*)hCodec;
-	
+
 	if(NULL != hAacEnc)
 	{
 		/* close the aac encoder */
@@ -296,7 +296,7 @@
 		/* free the aac encoder handle*/
 		mem_free(hAacEnc->voMemop, hAacEnc, VO_INDEX_ENC_AAC);
 		hAacEnc = NULL;
-	}	
+	}
 
 	return VO_ERR_NONE;
 }
@@ -319,7 +319,7 @@
 
 	if(NULL == hAacEnc)
 		return VO_ERR_INVALID_ARG;
-	
+
 	switch(uParamID)
 	{
 	case VO_PID_AAC_ENCPARAM:  /* init aac encoder parameter*/
@@ -354,11 +354,11 @@
 		SampleRateIdx = i;
 
 		tmp = 441;
-		if(config.sampleRate%8000 == 0) 
+		if(config.sampleRate%8000 == 0)
 			tmp =480;
 		/* check the bitrate */
 		if(config.bitRate!=0 && (config.bitRate/config.nChannelsOut < 4000) ||
-           (config.bitRate/config.nChannelsOut > 160000) || 
+           (config.bitRate/config.nChannelsOut > 160000) ||
 		   (config.bitRate > config.sampleRate*6*config.nChannelsOut))
 		{
 			config.bitRate = 640*config.sampleRate/tmp*config.nChannelsOut;
@@ -385,7 +385,7 @@
 
 		/* init aac encoder core */
 		ret = AacEncOpen(hAacEnc, config);
-		if(ret) 
+		if(ret)
 			return VO_ERR_AUDIO_UNSFEATURE;
 		break;
 	case VO_PID_AUDIO_FORMAT:	/* init pcm channel and samplerate*/
@@ -426,7 +426,7 @@
 
 		/* update the bitrates */
 		tmp = 441;
-		if(config.sampleRate%8000 == 0) 
+		if(config.sampleRate%8000 == 0)
 			tmp =480;
 
 		config.bitRate = 640*config.sampleRate/tmp*config.nChannelsOut;
@@ -449,10 +449,10 @@
 		}
 
 		config.bandWidth = BandwithCoefTab[i][SampleRateIdx];
-		
+
 		/* init aac encoder core */
 		ret = AacEncOpen(hAacEnc, config);
-		if(ret) 
+		if(ret)
 			return VO_ERR_AUDIO_UNSFEATURE;
 		break;
 	default:
@@ -483,7 +483,7 @@
 {
 	if(pDecHandle == NULL)
 		return VO_ERR_INVALID_ARG;
-		
+
 	pDecHandle->Init = voAACEncInit;
 	pDecHandle->SetInputData = voAACEncSetInputData;
 	pDecHandle->GetOutputData = voAACEncGetOutputData;
diff --git a/media/libstagefright/codecs/aacenc/src/aacenc_core.c b/media/libstagefright/codecs/aacenc/src/aacenc_core.c
index b69a017..2b3bd48 100644
--- a/media/libstagefright/codecs/aacenc/src/aacenc_core.c
+++ b/media/libstagefright/codecs/aacenc/src/aacenc_core.c
@@ -43,8 +43,8 @@
   config->adtsUsed        = 1;
   config->nChannelsIn     = 2;
   config->nChannelsOut    = 2;
-  config->bitRate         = 128000;                      
-  config->bandWidth       = 0;                           
+  config->bitRate         = 128000;
+  config->bandWidth       = 0;
 }
 
 /********************************************************************************
@@ -63,11 +63,11 @@
   Word16 profile = 1;
 
   ELEMENT_INFO *elInfo = NULL;
-   
+
   if (hAacEnc==0) {
-    error=1;                                  
+    error=1;
   }
-   
+
   if (!error) {
     hAacEnc->config = config;
   }
@@ -83,7 +83,7 @@
 
   if (!error) {
     /* use or not tns tool for long and short block */
-	 Word16 tnsMask=3;      
+	 Word16 tnsMask=3;
 
 	/* init encoder psychoacoustic */
     error = psyMainInit(&hAacEnc->psyKernel,
@@ -107,10 +107,10 @@
     qcInit.elInfo = &hAacEnc->elInfo;
 
     qcInit.maxBits = (Word16) (MAXBITS_COEF*elInfo->nChannelsInEl);
-    qcInit.bitRes = qcInit.maxBits;                                      
+    qcInit.bitRes = qcInit.maxBits;
     qcInit.averageBits = (Word16) ((config.bitRate * FRAME_LEN_LONG) / config.sampleRate);
 
-    qcInit.padding.paddingRest = config.sampleRate;                          
+    qcInit.padding.paddingRest = config.sampleRate;
 
     qcInit.meanPe = (Word16) ((10 * FRAME_LEN_LONG * hAacEnc->config.bandWidth) /
                                               (config.sampleRate>>1));
@@ -118,17 +118,17 @@
     qcInit.maxBitFac = (Word16) ((100 * (MAXBITS_COEF-MINBITS_COEF)* elInfo->nChannelsInEl)/
                                                  (qcInit.averageBits?qcInit.averageBits:1));
 
-    qcInit.bitrate = config.bitRate;                                     
+    qcInit.bitrate = config.bitRate;
 
     error = QCInit(&hAacEnc->qcKernel, &qcInit);
   }
 
   /* init bitstream encoder */
   if (!error) {
-    hAacEnc->bseInit.nChannels   = elInfo->nChannelsInEl;                
-    hAacEnc->bseInit.bitrate     = config.bitRate;                       
-    hAacEnc->bseInit.sampleRate  = config.sampleRate;                    
-    hAacEnc->bseInit.profile     = profile;                              
+    hAacEnc->bseInit.nChannels   = elInfo->nChannelsInEl;
+    hAacEnc->bseInit.bitrate     = config.bitRate;
+    hAacEnc->bseInit.sampleRate  = config.sampleRate;
+    hAacEnc->bseInit.profile     = profile;
   }
 
   return error;
@@ -152,14 +152,14 @@
   ELEMENT_INFO *elInfo = &aacEnc->elInfo;
   Word16 globUsedBits;
   Word16 ancDataBytes, ancDataBytesLeft;
-  
-  ancDataBytes = ancDataBytesLeft = *numAncBytes;                          
+
+  ancDataBytes = ancDataBytesLeft = *numAncBytes;
 
   /* init output aac data buffer and length */
   aacEnc->hBitStream = CreateBitBuffer(&aacEnc->bitStream, outBytes, *numOutBytes);
 
   /* psychoacoustic process */
-  psyMain(aacEnc->config.nChannelsOut,    
+  psyMain(aacEnc->config.nChannelsOut,
           elInfo,
           timeSignal,
           &aacEnc->psyKernel.psyData[elInfo->ChannelIndex[0]],
@@ -175,9 +175,9 @@
   AdjustBitrate(&aacEnc->qcKernel,
                 aacEnc->config.bitRate,
                 aacEnc->config.sampleRate);
-    
+
   /* quantization and coding process */
-  QCMain(&aacEnc->qcKernel,         
+  QCMain(&aacEnc->qcKernel,
          &aacEnc->qcKernel.elementBits,
          &aacEnc->qcKernel.adjThr.adjThrStateElem,
          &aacEnc->psyOut.psyOutChannel[elInfo->ChannelIndex[0]],
@@ -193,11 +193,11 @@
                          &aacEnc->qcOut);
 
   /* write bitstream process */
-  WriteBitstream(aacEnc->hBitStream,				 
+  WriteBitstream(aacEnc->hBitStream,
                  *elInfo,
                  &aacEnc->qcOut,
                  &aacEnc->psyOut,
-                 &globUsedBits,				 
+                 &globUsedBits,
                  ancBytes,
 				 aacEnc->psyKernel.sampleRateIdx);
 
@@ -219,7 +219,7 @@
 **********************************************************************************/
 void AacEncClose (AAC_ENCODER* hAacEnc, VO_MEM_OPERATOR *pMemOP)
 {
-  if (hAacEnc) {  
+  if (hAacEnc) {
     QCDelete(&hAacEnc->qcKernel, pMemOP);
 
     QCOutDelete(&hAacEnc->qcOut, pMemOP);
diff --git a/media/libstagefright/codecs/aacenc/src/adj_thr.c b/media/libstagefright/codecs/aacenc/src/adj_thr.c
index 83b43a1..c656f65 100644
--- a/media/libstagefright/codecs/aacenc/src/adj_thr.c
+++ b/media/libstagefright/codecs/aacenc/src/adj_thr.c
@@ -71,7 +71,7 @@
   Word32 *pthrExp, *psfbThre;
   for (ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
-	 for(sfbGrp = 0; sfbGrp < psyOutChan->sfbCnt; sfbGrp+= psyOutChan->sfbPerGroup)	 
+	 for(sfbGrp = 0; sfbGrp < psyOutChan->sfbCnt; sfbGrp+= psyOutChan->sfbPerGroup)
 	  pthrExp = &(thrExp[ch][sfbGrp]);
 	  psfbThre = psyOutChan->sfbThreshold + sfbGrp;
 	  for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
@@ -96,21 +96,21 @@
   Word32 nSfb, avgEn;
   Word16 log_avgEn = 0;
   Word32 startRatio_x_avgEn = 0;
-                                                                           
+
 
   for (ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL* psyOutChan = &psyOutChannel[ch];
 
     /* calc average energy per scalefactor band */
-    avgEn = 0;                                                           
-    nSfb = 0;                                                            
+    avgEn = 0;
+    nSfb = 0;
     for (sfbOffs=0; sfbOffs<psyOutChan->sfbCnt; sfbOffs+=psyOutChan->sfbPerGroup) {
       for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
         avgEn = L_add(avgEn, psyOutChan->sfbEnergy[sfbOffs+sfb]);
         nSfb = nSfb + 1;
       }
     }
-     
+
     if (nSfb > 0) {
 	  avgEn = avgEn / nSfb;
 
@@ -118,7 +118,7 @@
       startRatio_x_avgEn = fixmul(msaParam->startRatio, avgEn);
     }
 
-    
+
     /* reduce minSnr requirement by minSnr^minSnrRed dependent on avgEn/sfbEn */
     for (sfbOffs=0; sfbOffs<psyOutChan->sfbCnt; sfbOffs+=psyOutChan->sfbPerGroup) {
       for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
@@ -126,22 +126,22 @@
           Word16 dbRatio, minSnrRed;
           Word32 snrRed;
           Word16 newMinSnr;
-          
+
           dbRatio = log_avgEn - logSfbEnergy[ch][sfbOffs+sfb];
           dbRatio = dbRatio + (dbRatio << 1);
 
           minSnrRed = 110 - ((dbRatio + (dbRatio << 1)) >> 2);
-          minSnrRed = max(minSnrRed, 20); /* 110: (0.375(redOffs)+1)*80,  
+          minSnrRed = max(minSnrRed, 20); /* 110: (0.375(redOffs)+1)*80,
                                                3: 0.00375(redRatioFac)*80
                                                20: 0.25(maxRed) * 80 */
 
-          snrRed = minSnrRed * iLog4((psyOutChan->sfbMinSnr[sfbOffs+sfb] << 16)); 
-          /* 
+          snrRed = minSnrRed * iLog4((psyOutChan->sfbMinSnr[sfbOffs+sfb] << 16));
+          /*
              snrRedI si now scaled by 80 (minSnrRed) and 4 (ffr_iLog4)
           */
-        
+
           newMinSnr = round16(pow2_xy(snrRed,80*4));
-         
+
           psyOutChan->sfbMinSnr[sfbOffs+sfb] = min(newMinSnr, minSnrLimit);
         }
       }
@@ -169,7 +169,7 @@
 
   for (ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
-     
+
     if (psyOutChan->windowSequence != SHORT_WINDOW) {
       for(sfbGrp = 0;sfbGrp < psyOutChan->sfbCnt;sfbGrp+= psyOutChan->sfbPerGroup){
          psfbSpreadEn = psyOutChan->sfbSpreadedEnergy + sfbGrp;
@@ -194,7 +194,7 @@
   if (ahParam->modifyMinSnr) {
     for(ch=0; ch<nChannels; ch++) {
       PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
-         
+
       if (psyOutChan->windowSequence != SHORT_WINDOW)
         threshold = HOLE_THR_LONG;
       else
@@ -204,39 +204,39 @@
         Word16 *psfbMinSnr = psyOutChan->sfbMinSnr + sfbGrp;
 		for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
           Word32 sfbEn, sfbEnm1, sfbEnp1, avgEn;
-             
+
           if (sfb > 0)
             sfbEnm1 = psyOutChan->sfbEnergy[sfbGrp+sfb-1];
           else
             sfbEnm1 = psyOutChan->sfbEnergy[sfbGrp];
-             
+
           if (sfb < (psyOutChan->maxSfbPerGroup-1))
             sfbEnp1 = psyOutChan->sfbEnergy[sfbGrp+sfb+1];
           else
             sfbEnp1 = psyOutChan->sfbEnergy[sfbGrp+sfb];
           avgEn = (sfbEnm1 + sfbEnp1) >> 1;
-          sfbEn = psyOutChan->sfbEnergy[sfbGrp+sfb];                             
-             
+          sfbEn = psyOutChan->sfbEnergy[sfbGrp+sfb];
+
           if (sfbEn > avgEn && avgEn > 0) {
             Word32 tmpMinSnr;
             shift = norm_l(sfbEn);
 			tmpMinSnr = Div_32(L_mpy_ls(avgEn, minSnrLimit) << shift, sfbEn << shift );
-            tmpMinSnr = max(tmpMinSnr, HOLE_THR_LONG);                  
+            tmpMinSnr = max(tmpMinSnr, HOLE_THR_LONG);
             tmpMinSnr = max(tmpMinSnr, threshold);
             *psfbMinSnr = min(*psfbMinSnr, tmpMinSnr);
           }
           /* valley ? */
-             
+
           if ((sfbEn < (avgEn >> 1)) && (sfbEn > 0)) {
             Word32 tmpMinSnr;
-            Word32 minSnrEn = L_mpy_wx(avgEn, *psfbMinSnr);                 
-             
+            Word32 minSnrEn = L_mpy_wx(avgEn, *psfbMinSnr);
+
             if(minSnrEn < sfbEn) {
 			  shift = norm_l(sfbEn);
               tmpMinSnr = Div_32( minSnrEn << shift, sfbEn<<shift);
             }
             else {
-              tmpMinSnr = MAX_16;                                             
+              tmpMinSnr = MAX_16;
             }
             tmpMinSnr = min(minSnrLimit, tmpMinSnr);
 
@@ -251,7 +251,7 @@
 
   /* stereo: adapt the minimum requirements sfbMinSnr of mid and
      side channels */
-   
+
   if (nChannels == 2) {
     PSY_OUT_CHANNEL *psyOutChanM = &psyOutChannel[0];
     PSY_OUT_CHANNEL *psyOutChanS = &psyOutChannel[1];
@@ -260,30 +260,30 @@
         Word32 sfbEnM = psyOutChanM->sfbEnergy[sfb];
         Word32 sfbEnS = psyOutChanS->sfbEnergy[sfb];
         Word32 maxSfbEn = max(sfbEnM, sfbEnS);
-        Word32 maxThr = L_mpy_wx(maxSfbEn, psyOutChanM->sfbMinSnr[sfb]) >> 1;        
-         
+        Word32 maxThr = L_mpy_wx(maxSfbEn, psyOutChanM->sfbMinSnr[sfb]) >> 1;
+
         if(maxThr >= sfbEnM) {
-          psyOutChanM->sfbMinSnr[sfb] = MAX_16;                                          
+          psyOutChanM->sfbMinSnr[sfb] = MAX_16;
         }
         else {
-          shift = norm_l(sfbEnM); 
-		  psyOutChanM->sfbMinSnr[sfb] = min(max(psyOutChanM->sfbMinSnr[sfb], 
+          shift = norm_l(sfbEnM);
+		  psyOutChanM->sfbMinSnr[sfb] = min(max(psyOutChanM->sfbMinSnr[sfb],
 			  round16(Div_32(maxThr<<shift, sfbEnM << shift))), minSnrLimit);
         }
-         
+
         if(maxThr >= sfbEnS) {
           psyOutChanS->sfbMinSnr[sfb] = MAX_16;
         }
         else {
 		  shift = norm_l(sfbEnS);
-          psyOutChanS->sfbMinSnr[sfb] = min(max(psyOutChanS->sfbMinSnr[sfb], 
+          psyOutChanS->sfbMinSnr[sfb] = min(max(psyOutChanS->sfbMinSnr[sfb],
 			  round16(Div_32(maxThr << shift, sfbEnS << shift))), minSnrLimit);
         }
 
-         
+
         if (sfbEnM > psyOutChanM->sfbSpreadedEnergy[sfb])
           psyOutChanS->sfbSpreadedEnergy[sfb] = L_mpy_ls(sfbEnS, MS_THRSPREAD_COEF);
-         
+
         if (sfbEnS > psyOutChanS->sfbSpreadedEnergy[sfb])
           psyOutChanM->sfbSpreadedEnergy[sfb] = L_mpy_ls(sfbEnM, MS_THRSPREAD_COEF);
       }
@@ -297,7 +297,7 @@
     for(sfbGrp = 0;sfbGrp < psyOutChan->sfbCnt;sfbGrp+= psyOutChan->sfbPerGroup){
       Word16 *pahFlag = ahFlag[ch] + sfbGrp;
 	  for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-               
+
         if ((psyOutChan->sfbSpreadedEnergy[sfbGrp+sfb] > psyOutChan->sfbEnergy[sfbGrp+sfb]) ||
             (psyOutChan->sfbEnergy[sfbGrp+sfb] <= psyOutChan->sfbThreshold[sfbGrp+sfb]) ||
             (psyOutChan->sfbMinSnr[sfbGrp+sfb] == MAX_16)) {
@@ -308,7 +308,7 @@
         }
       }
       for (sfb=psyOutChan->maxSfbPerGroup; sfb<psyOutChan->sfbPerGroup; sfb++) {
-        *pahFlag++ = NO_AH;                                                          
+        *pahFlag++ = NO_AH;
       }
     }
   }
@@ -331,15 +331,15 @@
   Word16 ch, sfb, sfbGrp;
   int ipe, iconstPart, inActiveLines;
 
-  ipe = 0;                                                       
-  iconstPart = 0;                                                
-  inActiveLines = 0;                                             
+  ipe = 0;
+  iconstPart = 0;
+  inActiveLines = 0;
   for(ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
     PE_CHANNEL_DATA *peChanData = &peData->peChannelData[ch];
     for(sfbGrp = 0;sfbGrp < psyOutChan->sfbCnt;sfbGrp+= psyOutChan->sfbPerGroup){
       for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-         
+
         if (ahFlag[ch][sfbGrp+sfb] < AH_ACTIVE) {
           ipe = ipe + peChanData->sfbPe[sfbGrp+sfb];
           iconstPart = iconstPart + peChanData->sfbConstPart[sfbGrp+sfb];
@@ -349,9 +349,9 @@
     }
   }
 
-  *pe = saturate(ipe);                                                       
-  *constPart = saturate(iconstPart);                                                
-  *nActiveLines = saturate(inActiveLines);  
+  *pe = saturate(ipe);
+  *constPart = saturate(iconstPart);
+  *nActiveLines = saturate(inActiveLines);
 }
 
 /********************************************************************************
@@ -367,16 +367,16 @@
                              const Word32     redVal)
 {
   Word32 sfbThrReduced;
-  Word32 *psfbEn, *psfbThr;     
+  Word32 *psfbEn, *psfbThr;
   Word16 ch, sfb, sfbGrp;
 
   for(ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
     for(sfbGrp=0; sfbGrp<psyOutChan->sfbCnt; sfbGrp+=psyOutChan->sfbPerGroup) {
- 	  psfbEn  = psyOutChan->sfbEnergy + sfbGrp;                                      
+ 	  psfbEn  = psyOutChan->sfbEnergy + sfbGrp;
       psfbThr = psyOutChan->sfbThreshold + sfbGrp;
 	  for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-         
+
         if (*psfbEn > *psfbThr) {
           /* threshold reduction formula */
           Word32 tmp = thrExp[ch][sfbGrp+sfb] + redVal;
@@ -384,11 +384,11 @@
           sfbThrReduced = fixmul(tmp, tmp);
           /* avoid holes */
           tmp = L_mpy_ls(*psfbEn, psyOutChan->sfbMinSnr[sfbGrp+sfb]);
-             
-          if ((sfbThrReduced > tmp) && 
+
+          if ((sfbThrReduced > tmp) &&
               (ahFlag[ch][sfbGrp+sfb] != NO_AH)){
             sfbThrReduced = max(tmp, *psfbThr);
-            ahFlag[ch][sfbGrp+sfb] = AH_ACTIVE;                                          
+            ahFlag[ch][sfbGrp+sfb] = AH_ACTIVE;
           }
 		  *psfbThr = sfbThrReduced;
         }
@@ -426,7 +426,7 @@
   Word32 sfbThrReduced;
 
   /* for each sfb calc relative factors for pe changes */
-  normFactor = 1;                                                                        
+  normFactor = 1;
   for(ch=0; ch<nChannels; ch++) {
     psyOutChan = &psyOutChannel[ch];
     peChanData = &peData->peChannelData[ch];
@@ -436,22 +436,22 @@
 	  pahFlag = ahFlag[ch] + sfbGrp;
 	  for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
         Word32 redThrExp = thrExp[ch][sfbGrp+sfb] + redVal;
-             
+
         if (((*pahFlag < AH_ACTIVE) || (deltaPe > 0)) && (redThrExp > 0) ) {
-            
+
           *psfbPeFactors = (*psfbNActiveLines) * (0x7fffffff / redThrExp);
           normFactor = L_add(normFactor, *psfbPeFactors);
         }
         else {
-          *psfbPeFactors = 0;                                              
+          *psfbPeFactors = 0;
         }
-		psfbPeFactors++; 
+		psfbPeFactors++;
 		pahFlag++; psfbNActiveLines++;
       }
     }
   }
 
- 
+
   /* calculate new thresholds */
   for(ch=0; ch<nChannels; ch++) {
     psyOutChan = &psyOutChannel[ch];
@@ -464,7 +464,7 @@
         /* pe difference for this sfb */
         deltaSfbPe = *psfbPeFactors * deltaPe;
 
-		/* thr3(n) = thr2(n)*2^deltaSfbPe/b(n) */         
+		/* thr3(n) = thr2(n)*2^deltaSfbPe/b(n) */
         if (*psfbNActiveLines > 0) {
           /* new threshold */
           Word32 thrFactor;
@@ -476,7 +476,7 @@
               reduce threshold
             */
             thrFactor = pow2_xy(L_negate(deltaSfbPe), (normFactor* (*psfbNActiveLines)));
-              
+
             sfbThrReduced = L_mpy_ls(sfbThr, round16(thrFactor));
           }
           else {
@@ -484,28 +484,28 @@
               increase threshold
             */
             thrFactor = pow2_xy(deltaSfbPe, (normFactor * (*psfbNActiveLines)));
-              
-             
+
+
             if(thrFactor > sfbThr) {
               shift = norm_l(thrFactor);
 			  sfbThrReduced = Div_32( sfbThr << shift, thrFactor<<shift );
             }
             else {
-              sfbThrReduced = MAX_32;                                                                            
+              sfbThrReduced = MAX_32;
             }
 
           }
-            
+
           /* avoid hole */
           sfbEn = L_mpy_ls(sfbEn, psyOutChan->sfbMinSnr[sfbGrp+sfb]);
-             
+
           if ((sfbThrReduced > sfbEn) &&
               (*pahFlag == AH_INACTIVE)) {
             sfbThrReduced = max(sfbEn, sfbThr);
-            *pahFlag = AH_ACTIVE;                                                                  
+            *pahFlag = AH_ACTIVE;
           }
 
-          psyOutChan->sfbThreshold[sfbGrp+sfb] = sfbThrReduced;  
+          psyOutChan->sfbThreshold[sfbGrp+sfb] = sfbThrReduced;
         }
 
 		pahFlag++; psfbNActiveLines++; psfbPeFactors++;
@@ -521,8 +521,8 @@
 * description: if the desired pe can not be reached, reduce pe by reducing minSnr
 *
 **********************************************************************************/
-static void reduceMinSnr(PSY_OUT_CHANNEL  psyOutChannel[MAX_CHANNELS], 
-                         PE_DATA         *peData, 
+static void reduceMinSnr(PSY_OUT_CHANNEL  psyOutChannel[MAX_CHANNELS],
+                         PE_DATA         *peData,
                          Word16           ahFlag[MAX_CHANNELS][MAX_GROUPED_SFB],
                          const Word16     nChannels,
                          const Word16     desiredPe)
@@ -531,9 +531,9 @@
   Word16 deltaPe;
 
   /* start at highest freq down to 0 */
-  sfbSubWin = psyOutChannel[0].maxSfbPerGroup;                                                 
+  sfbSubWin = psyOutChannel[0].maxSfbPerGroup;
   while (peData->pe > desiredPe && sfbSubWin > 0) {
-       
+
     sfbSubWin = sfbSubWin - 1;
     /* loop over all subwindows */
     for (sfb=sfbSubWin; sfb<psyOutChannel[0].sfbCnt;
@@ -541,10 +541,10 @@
       /* loop over all channels */
 		PE_CHANNEL_DATA* peChan = peData->peChannelData;
 		PSY_OUT_CHANNEL* psyOutCh = psyOutChannel;
-		for (ch=0; ch<nChannels; ch++) {           
+		for (ch=0; ch<nChannels; ch++) {
         if (ahFlag[ch][sfb] != NO_AH &&
             psyOutCh->sfbMinSnr[sfb] < minSnrLimit) {
-          psyOutCh->sfbMinSnr[sfb] = minSnrLimit;                                      
+          psyOutCh->sfbMinSnr[sfb] = minSnrLimit;
           psyOutCh->sfbThreshold[sfb] =
             L_mpy_ls(psyOutCh->sfbEnergy[sfb], psyOutCh->sfbMinSnr[sfb]);
 
@@ -552,12 +552,12 @@
           deltaPe = ((peChan->sfbNLines4[sfb] + (peChan->sfbNLines4[sfb] >> 1)) >> 2) -
               peChan->sfbPe[sfb];
           peData->pe = peData->pe + deltaPe;
-          peChan->pe = peChan->pe + deltaPe;		  
+          peChan->pe = peChan->pe + deltaPe;
         }
 		peChan += 1; psyOutCh += 1;
       }
       /* stop if enough has been saved */
-       
+
       if (peData->pe <= desiredPe)
         break;
     }
@@ -567,13 +567,13 @@
 /********************************************************************************
 *
 * function name:allowMoreHoles
-* description: if the desired pe can not be reached, some more scalefactor bands  
+* description: if the desired pe can not be reached, some more scalefactor bands
 *              have to be quantized to zero
 *
 **********************************************************************************/
-static void allowMoreHoles(PSY_OUT_CHANNEL  psyOutChannel[MAX_CHANNELS], 
+static void allowMoreHoles(PSY_OUT_CHANNEL  psyOutChannel[MAX_CHANNELS],
                            PSY_OUT_ELEMENT *psyOutElement,
-                           PE_DATA         *peData, 
+                           PE_DATA         *peData,
                            Word16           ahFlag[MAX_CHANNELS][MAX_GROUPED_SFB],
                            const AH_PARAM  *ahParam,
                            const Word16     nChannels,
@@ -582,46 +582,46 @@
   Word16 ch, sfb;
   Word16 actPe, shift;
 
-  actPe = peData->pe;                                                                    
+  actPe = peData->pe;
 
   /* for MS allow hole in the channel with less energy */
-     
+
   if (nChannels==2 &&
       psyOutChannel[0].windowSequence==psyOutChannel[1].windowSequence) {
     PSY_OUT_CHANNEL *psyOutChanL = &psyOutChannel[0];
     PSY_OUT_CHANNEL *psyOutChanR = &psyOutChannel[1];
     for (sfb=0; sfb<psyOutChanL->sfbCnt; sfb++) {
       Word32 minEn;
-       
+
       if (psyOutElement->toolsInfo.msMask[sfb]) {
         /* allow hole in side channel ? */
         minEn = L_mpy_ls(psyOutChanL->sfbEnergy[sfb], (minSnrLimit * psyOutChanL->sfbMinSnr[sfb]) >> 16);
-           
+
         if (ahFlag[1][sfb] != NO_AH &&
             minEn > psyOutChanR->sfbEnergy[sfb]) {
-          ahFlag[1][sfb] = NO_AH;                                                                
+          ahFlag[1][sfb] = NO_AH;
           psyOutChanR->sfbThreshold[sfb] = L_add(psyOutChanR->sfbEnergy[sfb], psyOutChanR->sfbEnergy[sfb]);
           actPe = actPe - peData->peChannelData[1].sfbPe[sfb];
         }
         /* allow hole in mid channel ? */
         else {
         minEn = L_mpy_ls(psyOutChanR->sfbEnergy[sfb], (minSnrLimit * psyOutChanR->sfbMinSnr[sfb]) >> 16);
-             
+
           if (ahFlag[0][sfb]!= NO_AH &&
               minEn > psyOutChanL->sfbEnergy[sfb]) {
-            ahFlag[0][sfb] = NO_AH;                                                              
+            ahFlag[0][sfb] = NO_AH;
             psyOutChanL->sfbThreshold[sfb] = L_add(psyOutChanL->sfbEnergy[sfb], psyOutChanL->sfbEnergy[sfb]);
             actPe = actPe - peData->peChannelData[0].sfbPe[sfb];
           }
         }
-         
+
         if (actPe < desiredPe)
           break;
       }
     }
   }
 
-  /* subsequently erase bands */   
+  /* subsequently erase bands */
   if (actPe > desiredPe) {
     Word16 startSfb[2];
     Word32 avgEn, minEn;
@@ -634,20 +634,20 @@
 
     /* do not go below startSfb */
     for (ch=0; ch<nChannels; ch++) {
-         
+
       if (psyOutChannel[ch].windowSequence != SHORT_WINDOW)
         startSfb[ch] = ahParam->startSfbL;
       else
         startSfb[ch] = ahParam->startSfbS;
     }
 
-    avgEn = 0;                                                           
-    minEn = MAX_32;                                                      
-    ahCnt = 0;                                                           
+    avgEn = 0;
+    minEn = MAX_32;
+    ahCnt = 0;
     for (ch=0; ch<nChannels; ch++) {
       PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
       for (sfb=startSfb[ch]; sfb<psyOutChan->sfbCnt; sfb++) {
-           
+
         if ((ahFlag[ch][sfb] != NO_AH) &&
             (psyOutChan->sfbEnergy[sfb] > psyOutChan->sfbThreshold[sfb])) {
           minEn = min(minEn, psyOutChan->sfbEnergy[sfb]);
@@ -656,7 +656,7 @@
         }
       }
     }
-     
+
     if(ahCnt) {
       Word32 iahCnt;
       shift = norm_l(ahCnt);
@@ -674,46 +674,46 @@
 
     /* start with lowest energy border at highest sfb */
     maxSfb = psyOutChannel[0].sfbCnt - 1;
-    minSfb = startSfb[0];                                                                
-     
+    minSfb = startSfb[0];
+
     if (nChannels == 2) {
       maxSfb = max(maxSfb, (psyOutChannel[1].sfbCnt - 1));
       minSfb = min(minSfb, startSfb[1]);
     }
 
-    sfb = maxSfb;                                                                        
-    enIdx = 0;                                                                           
-    done = 0;                                                                            
+    sfb = maxSfb;
+    enIdx = 0;
+    done = 0;
     while (!done) {
-       
+
       for (ch=0; ch<nChannels; ch++) {
         PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
-           
+
         if (sfb>=startSfb[ch] && sfb<psyOutChan->sfbCnt) {
           /* sfb energy below border ? */
-             
+
           if (ahFlag[ch][sfb] != NO_AH && psyOutChan->sfbEnergy[sfb] < en[enIdx]){
             /* allow hole */
-            ahFlag[ch][sfb] = NO_AH;                                                     
+            ahFlag[ch][sfb] = NO_AH;
             psyOutChan->sfbThreshold[sfb] = L_add(psyOutChan->sfbEnergy[sfb], psyOutChan->sfbEnergy[sfb]);
             actPe = actPe - peData->peChannelData[ch].sfbPe[sfb];
           }
-           
+
           if (actPe < desiredPe) {
-            done = 1;                                                                    
+            done = 1;
             break;
           }
         }
       }
       sfb = sfb - 1;
-       
+
       if (sfb < minSfb) {
         /* restart with next energy border */
-        sfb = maxSfb;                                                                    
+        sfb = maxSfb;
         enIdx = enIdx + 1;
-         
+
         if (enIdx - 4 >= 0)
-          done = 1;                                                                      
+          done = 1;
       }
     }
   }
@@ -748,13 +748,13 @@
 
   initAvoidHoleFlag(peData->ahFlag, psyOutChannel, psyOutElement, nChannels, ahParam);
 
-  noRedPe = peData->pe;                                                          
-  constPart = peData->constPart;                                                 
-  nActiveLines = peData->nActiveLines;       
+  noRedPe = peData->pe;
+  constPart = peData->constPart;
+  nActiveLines = peData->nActiveLines;
 
   /* first guess of reduction value t^0.25 = 2^((a-pen)/4*b) */
   avgThrExp = pow2_xy((constPart - noRedPe), (nActiveLines << 2));
-  
+
   /* r1 = 2^((a-per)/4*b) - t^0.25 */
   redVal = pow2_xy((constPart - desiredPe), (nActiveLines << 2)) - avgThrExp;
 
@@ -763,40 +763,40 @@
 
   /* pe after first guess */
   calcSfbPe(peData, psyOutChannel, nChannels);
-  redPe = peData->pe;                                                            
+  redPe = peData->pe;
 
-  iter = 0;                                                                      
+  iter = 0;
   do {
     /* pe for bands where avoid hole is inactive */
     calcPeNoAH(&redPeNoAH, &constPartNoAH, &nActiveLinesNoAH,
                peData, peData->ahFlag, psyOutChannel, nChannels);
 
     desiredPeNoAH = desiredPe -(redPe - redPeNoAH);
-     
+
     if (desiredPeNoAH < 0) {
-      desiredPeNoAH = 0;                                                         
+      desiredPeNoAH = 0;
     }
 
     /* second guess */
-     
+
     if (nActiveLinesNoAH > 0) {
-		
+
 		avgThrExp = pow2_xy((constPartNoAH - redPeNoAH), (nActiveLinesNoAH << 2));
-		
+
 		redVal = (redVal + pow2_xy((constPartNoAH - desiredPeNoAH), (nActiveLinesNoAH << 2))) - avgThrExp;
-		
+
 		/* reduce thresholds */
 		reduceThresholds(psyOutChannel, peData->ahFlag, peData->thrExp, nChannels, redVal);
     }
 
     calcSfbPe(peData, psyOutChannel, nChannels);
-    redPe = peData->pe;                                                          
+    redPe = peData->pe;
 
     iter = iter+1;
-       
+
   } while ((20 * abs_s(redPe - desiredPe) > desiredPe) && (iter < 2));
 
-   
+
   if ((100 * redPe < 115 * desiredPe)) {
     correctThresh(psyOutChannel, peData->ahFlag, peData, peData->thrExp, redVal,
                   nChannels, desiredPe - redPe);
@@ -863,7 +863,7 @@
   if(clipHigh-clipLow)
   bitspend = (minBitSpend + ((maxBitSpend - minBitSpend)*(fillLevel - clipLow) /
                                 (clipHigh-clipLow)));
-                            
+
   return (bitspend);
 }
 
@@ -884,19 +884,19 @@
   Word16 minFacHi, maxFacHi, minFacLo, maxFacLo;
   Word16 diff;
   Word16 minDiff = extract_l(currPe / 6);
-  minFacHi = 30;                                                         
-  maxFacHi = 100;                                                        
-  minFacLo = 14;                                                         
-  maxFacLo = 7;                                                          
+  minFacHi = 30;
+  maxFacHi = 100;
+  minFacLo = 14;
+  maxFacLo = 7;
 
   diff = currPe - *peMax ;
-   
+
   if (diff > 0) {
     *peMin = *peMin + ((diff * minFacHi) / 100);
     *peMax = *peMax + ((diff * maxFacHi) / 100);
   } else {
     diff = *peMin - currPe;
-     
+
     if (diff > 0) {
       *peMin = *peMin - ((diff * minFacLo) / 100);
       *peMax = *peMax - ((diff * maxFacLo) / 100);
@@ -906,7 +906,7 @@
     }
   }
 
-   
+
   if ((*peMax - *peMin) < minDiff) {
     Word16 partLo, partHi;
 
@@ -969,7 +969,7 @@
                     (adjThrChan->peMax - adjThrChan->peMin));
   else
 	bitresFac = 0x7fff;
-               
+
   bitresFac = min(bitresFac,
                     (100-30 + extract_l((100 * bitresBits) / avgBits)));
 
@@ -995,23 +995,23 @@
 
   /* common for all elements: */
   /* parameters for bitres control */
-  hAdjThr->bresParamLong.clipSaveLow   =  20;                    
-  hAdjThr->bresParamLong.clipSaveHigh  =  95;                    
-  hAdjThr->bresParamLong.minBitSave    =  -5;                    
-  hAdjThr->bresParamLong.maxBitSave    =  30;                    
-  hAdjThr->bresParamLong.clipSpendLow  =  20;                    
-  hAdjThr->bresParamLong.clipSpendHigh =  95;                    
-  hAdjThr->bresParamLong.minBitSpend   = -10;                    
-  hAdjThr->bresParamLong.maxBitSpend   =  40;                    
+  hAdjThr->bresParamLong.clipSaveLow   =  20;
+  hAdjThr->bresParamLong.clipSaveHigh  =  95;
+  hAdjThr->bresParamLong.minBitSave    =  -5;
+  hAdjThr->bresParamLong.maxBitSave    =  30;
+  hAdjThr->bresParamLong.clipSpendLow  =  20;
+  hAdjThr->bresParamLong.clipSpendHigh =  95;
+  hAdjThr->bresParamLong.minBitSpend   = -10;
+  hAdjThr->bresParamLong.maxBitSpend   =  40;
 
-  hAdjThr->bresParamShort.clipSaveLow   =  20;                   
-  hAdjThr->bresParamShort.clipSaveHigh  =  75;                   
-  hAdjThr->bresParamShort.minBitSave    =   0;                   
-  hAdjThr->bresParamShort.maxBitSave    =  20;                   
-  hAdjThr->bresParamShort.clipSpendLow  =  20;                   
-  hAdjThr->bresParamShort.clipSpendHigh =  75;                   
-  hAdjThr->bresParamShort.minBitSpend   = -5;                    
-  hAdjThr->bresParamShort.maxBitSpend   =  50;                   
+  hAdjThr->bresParamShort.clipSaveLow   =  20;
+  hAdjThr->bresParamShort.clipSaveHigh  =  75;
+  hAdjThr->bresParamShort.minBitSave    =   0;
+  hAdjThr->bresParamShort.maxBitSave    =  20;
+  hAdjThr->bresParamShort.clipSpendLow  =  20;
+  hAdjThr->bresParamShort.clipSpendHigh =  75;
+  hAdjThr->bresParamShort.minBitSpend   = -5;
+  hAdjThr->bresParamShort.maxBitSpend   =  50;
 
   /* specific for each element: */
 
@@ -1020,7 +1020,7 @@
   atsElem->peMax = extract_l(((120*meanPe) / 100));
 
   /* additional pe offset to correct pe2bits for low bitrates */
-  atsElem->peOffset = 0;                             
+  atsElem->peOffset = 0;
   if (chBitrate < 32000) {
     atsElem->peOffset = max(50, (100 - extract_l((100 * chBitrate) / 32000)));
   }
@@ -1039,24 +1039,24 @@
 
   /* minSnr adaptation */
   /* maximum reduction of minSnr goes down to minSnr^maxRed */
-  msaParam->maxRed = 0x20000000;     /* *0.25f /                        
+  msaParam->maxRed = 0x20000000;     /* *0.25f /
   /* start adaptation of minSnr for avgEn/sfbEn > startRatio */
-  msaParam->startRatio = 0x0ccccccd; /* 10 */                        
+  msaParam->startRatio = 0x0ccccccd; /* 10 */
   /* maximum minSnr reduction to minSnr^maxRed is reached for
      avgEn/sfbEn >= maxRatio */
-  msaParam->maxRatio =  0x0020c49c; /* 1000 */                         
+  msaParam->maxRatio =  0x0020c49c; /* 1000 */
   /* helper variables to interpolate minSnr reduction for
      avgEn/sfbEn between startRatio and maxRatio */
 
-  msaParam->redRatioFac = 0xfb333333; /* -0.75/20 */         
+  msaParam->redRatioFac = 0xfb333333; /* -0.75/20 */
 
-  msaParam->redOffs = 0x30000000;  /* msaParam->redRatioFac * 10*log10(msaParam->startRatio) */  
+  msaParam->redOffs = 0x30000000;  /* msaParam->redRatioFac * 10*log10(msaParam->startRatio) */
 
-       
+
   /* pe correction */
-  atsElem->peLast = 0;                                                 
-  atsElem->dynBitsLast = 0;                                            
-  atsElem->peCorrectionFactor = 100; /* 1.0 */                         
+  atsElem->peLast = 0;
+  atsElem->dynBitsLast = 0;
+  atsElem->peCorrectionFactor = 100; /* 1.0 */
 
 }
 
@@ -1069,20 +1069,20 @@
 *****************************************************************************/
 static void calcPeCorrection(Word16 *correctionFac,
                              const Word16 peAct,
-                             const Word16 peLast, 
-                             const Word16 bitsLast) 
+                             const Word16 peLast,
+                             const Word16 bitsLast)
 {
   Word32 peAct100 = 100 * peAct;
   Word32 peLast100 = 100 * peLast;
   Word16 peBitsLast = bits2pe(bitsLast);
-           
+
   if ((bitsLast > 0) &&
       (peAct100 < (150 * peLast)) &&  (peAct100 > (70 * peLast)) &&
       ((120 * peBitsLast) > peLast100 ) && (( 65 * peBitsLast) < peLast100))
     {
       Word16 newFac = (100 * peLast) / peBitsLast;
       /* dead zone */
-       
+
       if (newFac < 100) {
         newFac = min(((110 * newFac) / 100), 100);
         newFac = max(newFac, 85);
@@ -1091,13 +1091,13 @@
         newFac = max(((90 * newFac) / 100), 100);
         newFac = min(newFac, 115);
       }
-         
+
       if ((newFac > 100 && *correctionFac < 100) ||
           (newFac < 100 && *correctionFac > 100)) {
-        *correctionFac = 100;                                                    
+        *correctionFac = 100;
       }
       /* faster adaptation towards 1.0, slower in the other direction */
-             
+
       if ((*correctionFac < 100 && newFac < *correctionFac) ||
           (*correctionFac > 100 && newFac > *correctionFac))
         *correctionFac = (85 * *correctionFac + 15 * newFac) / 100;
@@ -1107,7 +1107,7 @@
       *correctionFac = max(*correctionFac, 85);
     }
   else {
-    *correctionFac = 100;                                                        
+    *correctionFac = 100;
   }
 }
 
@@ -1123,40 +1123,40 @@
                       PSY_OUT_ELEMENT *psyOutElement,
                       Word16          *chBitDistribution,
                       Word16           logSfbEnergy[MAX_CHANNELS][MAX_GROUPED_SFB],
-                      Word16           sfbNRelevantLines[MAX_CHANNELS][MAX_GROUPED_SFB],                      
+                      Word16           sfbNRelevantLines[MAX_CHANNELS][MAX_GROUPED_SFB],
                       QC_OUT_ELEMENT  *qcOE,
 					  ELEMENT_BITS	  *elBits,
 					  const Word16     nChannels,
                       const Word16     maxBitFac)
 {
-  PE_DATA peData;  
+  PE_DATA peData;
   Word16 noRedPe, grantedPe, grantedPeCorr;
   Word16 curWindowSequence;
   Word16 bitFactor;
   Word16 avgBits = (elBits->averageBits - (qcOE->staticBitsUsed + qcOE->ancBitsUsed));
-  Word16 bitresBits = elBits->bitResLevel; 
+  Word16 bitresBits = elBits->bitResLevel;
   Word16 maxBitresBits = elBits->maxBits;
   Word16 sideInfoBits = (qcOE->staticBitsUsed + qcOE->ancBitsUsed);
   Word16 ch;
-   
+
   prepareSfbPe(&peData, psyOutChannel, logSfbEnergy, sfbNRelevantLines, nChannels, AdjThrStateElement->peOffset);
-   
+
   /* pe without reduction */
   calcSfbPe(&peData, psyOutChannel, nChannels);
-  noRedPe = peData.pe;                                                   
+  noRedPe = peData.pe;
 
 
-  curWindowSequence = LONG_WINDOW;                                       
-   
+  curWindowSequence = LONG_WINDOW;
+
   if (nChannels == 2) {
-       
+
     if ((psyOutChannel[0].windowSequence == SHORT_WINDOW) ||
         (psyOutChannel[1].windowSequence == SHORT_WINDOW)) {
-      curWindowSequence = SHORT_WINDOW;                                  
+      curWindowSequence = SHORT_WINDOW;
     }
   }
   else {
-    curWindowSequence = psyOutChannel[0].windowSequence;                 
+    curWindowSequence = psyOutChannel[0].windowSequence;
   }
 
 
@@ -1170,13 +1170,13 @@
   grantedPe = ((bitFactor * bits2pe(avgBits)) / 100);
 
   /* correction of pe value */
-  calcPeCorrection(&(AdjThrStateElement->peCorrectionFactor), 
+  calcPeCorrection(&(AdjThrStateElement->peCorrectionFactor),
                    min(grantedPe, noRedPe),
-                   AdjThrStateElement->peLast, 
+                   AdjThrStateElement->peLast,
                    AdjThrStateElement->dynBitsLast);
   grantedPeCorr = (grantedPe * AdjThrStateElement->peCorrectionFactor) / 100;
 
-     
+
   if (grantedPeCorr < noRedPe && noRedPe > peData.offset) {
     /* calc threshold necessary for desired pe */
     adaptThresholdsToPe(psyOutChannel,
@@ -1192,8 +1192,8 @@
   /* calculate relative distribution */
   for (ch=0; ch<nChannels; ch++) {
     Word16 peOffsDiff = peData.pe - peData.offset;
-    chBitDistribution[ch] = 200;                                                 
-     
+    chBitDistribution[ch] = 200;
+
     if (peOffsDiff > 0) {
       Word32 temp = 1000 - (nChannels * 200);
       chBitDistribution[ch] = chBitDistribution[ch] +
@@ -1202,10 +1202,10 @@
   }
 
   /* store pe */
-  qcOE->pe = noRedPe;                                                            
+  qcOE->pe = noRedPe;
 
   /* update last pe */
-  AdjThrStateElement->peLast = grantedPe;                                        
+  AdjThrStateElement->peLast = grantedPe;
 }
 
 /********************************************************************************
@@ -1217,7 +1217,7 @@
 void AdjThrUpdate(ATS_ELEMENT *AdjThrStateElement,
                   const Word16 dynBitsUsed)
 {
-  AdjThrStateElement->dynBitsLast = dynBitsUsed;                                 
+  AdjThrStateElement->dynBitsLast = dynBitsUsed;
 }
 
 
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/AutoCorrelation_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/AutoCorrelation_v5.s
index e0885f1..e705197 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/AutoCorrelation_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/AutoCorrelation_v5.s
@@ -22,34 +22,34 @@
 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
 
 
-	.section .text	
+	.section .text
 	.global	AutoCorrelation
 
 AutoCorrelation:
 	stmdb     sp!, {r4 - r11, lr}
 
-  sub     r13, r13, #20                     
+  sub     r13, r13, #20
 
-  mov     r5, r0                            
-  mov     r7, r1                            
-  mov     r9, r3                            
-  mov     r2, r2, lsl #16                      
-  mov     r0, #0          
-  mov     r4, r2, asr #16                   
-  mov     r8, #0                            
-  cmp     r4, #0                            
-  ble     L136        
-	
-	cmp     r4, #8 
-	mov		  r2, #0 
-  blt     L133   
+  mov     r5, r0
+  mov     r7, r1
+  mov     r9, r3
+  mov     r2, r2, lsl #16
+  mov     r0, #0
+  mov     r4, r2, asr #16
+  mov     r8, #0
+  cmp     r4, #0
+  ble     L136
 
-	sub     r12, r4, #8                
-L132:  
-  ldr     r6, [r5, r2]  
+	cmp     r4, #8
+	mov		  r2, #0
+  blt     L133
+
+	sub     r12, r4, #8
+L132:
+  ldr     r6, [r5, r2]
 	add		  r2, r2, #4
 	smulbb  r3, r6, r6
-	ldr     r1, [r5, r2] 
+	ldr     r1, [r5, r2]
 	smultt	r10, r6, r6
 	mov		  r3, r3, asr #9
 	smulbb	r6, r1, r1
@@ -72,95 +72,95 @@
 	add     r8, r8, #6
 
 	qadd	  r0, r0, r6
-	cmp     r8, r12                            
-  blt     L132	                  
-L133:                         
-  ldrsh   r6, [r5, r2]                      
-  mul     r10, r6, r6   
-	add     r2, r2, #2                     
-  mov     r1, r10, asr #9                    
+	cmp     r8, r12
+  blt     L132
+L133:
+  ldrsh   r6, [r5, r2]
+  mul     r10, r6, r6
+	add     r2, r2, #2
+  mov     r1, r10, asr #9
   qadd    r0, r0, r1
-L134:                         
-  add     r8, r8, #1                        
-  cmp     r8, r4                            
-  blt     L133                            
-L135:                        
-L136:                         
-  str     r0, [r7, #0]                      
-  cmp     r0, #0                            
-  beq     L1320                           
-L137:                         
-  mov     r2, r9, lsl #16                   
-	mov     r8, #1                                
-  mov     r2, r2, asr #16                   
-  cmp     r2, #1                            
-  ble     L1319                           
-L138:                        
-L139:                         
-  sub     r4, r4, #1                        
-  mov     r14, #0                           
-  mov     r3, #0                            
-  cmp     r4, #0                            
-  ble     L1317                           
-L1310:                       
-  cmp     r4, #6                            
-  addlt   r6, r5, r8, lsl #1                
-  blt     L1314                           
-L1311:                        
-  add     r6, r5, r8, lsl #1                
-  sub     r12, r4, #6                       
-  str     r8, [r13, #8]                     
-  str     r7, [r13, #4]                     
-L1312:                        
-  mov     r1, r3, lsl #1                    
-  ldrsh   r7, [r6, r1]                      
-  ldrsh   r10, [r5, r1]  
-  add     r8, r1, r6 
-	add     r9, r5, r1                       
+L134:
+  add     r8, r8, #1
+  cmp     r8, r4
+  blt     L133
+L135:
+L136:
+  str     r0, [r7, #0]
+  cmp     r0, #0
+  beq     L1320
+L137:
+  mov     r2, r9, lsl #16
+	mov     r8, #1
+  mov     r2, r2, asr #16
+  cmp     r2, #1
+  ble     L1319
+L138:
+L139:
+  sub     r4, r4, #1
+  mov     r14, #0
+  mov     r3, #0
+  cmp     r4, #0
+  ble     L1317
+L1310:
+  cmp     r4, #6
+  addlt   r6, r5, r8, lsl #1
+  blt     L1314
+L1311:
+  add     r6, r5, r8, lsl #1
+  sub     r12, r4, #6
+  str     r8, [r13, #8]
+  str     r7, [r13, #4]
+L1312:
+  mov     r1, r3, lsl #1
+  ldrsh   r7, [r6, r1]
+  ldrsh   r10, [r5, r1]
+  add     r8, r1, r6
+	add     r9, r5, r1
 	mul     r7, r10, r7
-  ldrsh   r1, [r8, #2] 
-	ldrsh   r10, [r8, #4]   
-  add     r7, r14, r7, asr #9  	                                             
-  ldrsh   r0, [r9, #2]                          
-  ldrsh   r11, [r9, #4]                   
-  mul     r1, r0, r1                        
-  ldrsh   r14, [r8, #6]                     
-  mul     r10, r11, r10          
-	add     r7, r7, r1, asr #9            
-  ldrsh   r8, [r8, #8] 
+  ldrsh   r1, [r8, #2]
+	ldrsh   r10, [r8, #4]
+  add     r7, r14, r7, asr #9
+  ldrsh   r0, [r9, #2]
+  ldrsh   r11, [r9, #4]
+  mul     r1, r0, r1
+  ldrsh   r14, [r8, #6]
+  mul     r10, r11, r10
+	add     r7, r7, r1, asr #9
+  ldrsh   r8, [r8, #8]
 	add     r3, r3, #5
-	ldrsh   r11, [r9, #6]                  
-  ldrsh   r1, [r9, #8]                      
-  mul     r14, r11, r14                     
-  add     r7, r7, r10, asr #9       
-  mul     r1, r1, r8                             
-  add     r14, r7, r14, asr #9              
-	cmp     r3, r12 
-  add     r14, r14, r1, asr #9              
-  ble     L1312                           
-L1313:                        
-  ldr     r8, [r13, #8]                     
-  ldr     r7, [r13, #4]                     
-L1314:                        
-L1315:                        
-  mov     r12, r3, lsl #1                   
-  ldrsh   r9, [r6, r12]                     
-  ldrsh   r12, [r5, r12]                    
-  add     r3, r3, #1                        
-  cmp     r3, r4                            
-  mul     r12, r12, r9                      
-  add     r14, r14, r12, asr #9             
-  blt     L1315                           
-L1316:                        
-L1317:                        
-  str     r14, [r7, +r8, lsl #2]            
-  add     r8, r8, #1                        
-  cmp     r8, r2                            
-  blt     L139   
-	                         
+	ldrsh   r11, [r9, #6]
+  ldrsh   r1, [r9, #8]
+  mul     r14, r11, r14
+  add     r7, r7, r10, asr #9
+  mul     r1, r1, r8
+  add     r14, r7, r14, asr #9
+	cmp     r3, r12
+  add     r14, r14, r1, asr #9
+  ble     L1312
+L1313:
+  ldr     r8, [r13, #8]
+  ldr     r7, [r13, #4]
+L1314:
+L1315:
+  mov     r12, r3, lsl #1
+  ldrsh   r9, [r6, r12]
+  ldrsh   r12, [r5, r12]
+  add     r3, r3, #1
+  cmp     r3, r4
+  mul     r12, r12, r9
+  add     r14, r14, r12, asr #9
+  blt     L1315
+L1316:
+L1317:
+  str     r14, [r7, +r8, lsl #2]
+  add     r8, r8, #1
+  cmp     r8, r2
+  blt     L139
+
 L1319:
 L1320:
-	add     r13, r13, #20                    
+	add     r13, r13, #20
 	ldmia   sp!, {r4 - r11, pc}
 
 	@ENDP  @ |AutoCorrelation|
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/CalcWindowEnergy_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/CalcWindowEnergy_v5.s
index 75b916c..b30e8cb 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/CalcWindowEnergy_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/CalcWindowEnergy_v5.s
@@ -22,91 +22,91 @@
 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
 
 	.section .text
-	
+
 	.global	CalcWindowEnergy
 
 CalcWindowEnergy:
 	stmdb   sp!, {r4 - r11, lr}
-	sub     r13, r13, #20 
+	sub     r13, r13, #20
 
-  mov     r3, r3, lsl #16                         
+  mov     r3, r3, lsl #16
 	ldr     r10, [r0, #168]                    @ states0 = blockSwitchingControl->iirStates[0];
-  mov     r3, r3, asr #16 
+  mov     r3, r3, asr #16
 	ldr     r11, [r0, #172]                    @ states1 = blockSwitchingControl->iirStates[1];
 
 	mov     r2, r2, lsl #16
-	ldr     r12, hiPassCoeff                   @ Coeff0 = hiPassCoeff[0];      
+	ldr     r12, hiPassCoeff                   @ Coeff0 = hiPassCoeff[0];
   mov     r2, r2, asr #16
 	ldr     r14, hiPassCoeff + 4			         @ Coeff1 = hiPassCoeff[1];
-	
+
 	mov			r8, #0							               @ w=0
 	mov			r5, #0							               @ wOffset = 0;
-	
+
 BLOCK_BEGIN:
-	mov			r6, #0                             @ accuUE = 0; 
-	mov			r7, #0								             @ accuFE = 0; 
+	mov			r6, #0                             @ accuUE = 0;
+	mov			r7, #0								             @ accuFE = 0;
 	mov			r4, #0							               @ i=0
-		                   
-	str			r8, [r13, #4]	
-	str			r0, [r13, #8]	
+
+	str			r8, [r13, #4]
+	str			r0, [r13, #8]
 	str			r3, [r13, #12]
-	
-ENERGY_BEG:	
-	mov     r9, r5, lsl #1  
+
+ENERGY_BEG:
+	mov     r9, r5, lsl #1
 	ldrsh   r9, [r1, r9]											@ tempUnfiltered = timeSignal[tidx];
 
 	add			r5, r5, r2												@ tidx = tidx + chIncrement;
-	
-	smulwb	r3, r14, r9												@ accu1 = L_mpy_ls(Coeff1, tempUnfiltered);	
+
+	smulwb	r3, r14, r9												@ accu1 = L_mpy_ls(Coeff1, tempUnfiltered);
 	smull		r0, r8, r12, r11									@ accu2 = fixmul( Coeff0, states1 );
-	
+
 	mov			r3, r3, lsl #1
 	mov			r8, r8, lsl #1
 
-	sub			r0, r3, r10												@ accu3 = accu1 - states0;	
+	sub			r0, r3, r10												@ accu3 = accu1 - states0;
 	sub			r8,	r0, r8												@ out = accu3 - accu2;
 
 	mov		  r10, r3														@ states0 = accu1;
-	mov		  r11, r8														@ states1 = out;  
-	
-	mul		  r3, r9, r9	
+	mov		  r11, r8														@ states1 = out;
+
+	mul		  r3, r9, r9
 	mov     r8, r8, asr #16
-	
+
 	add		  r4, r4, #1
 	add     r6, r6, r3, asr #7
 
-	mul		  r9, r8, r8	
+	mul		  r9, r8, r8
 	ldr		  r3, [r13, #12]
 
 	add		  r7, r7, r9, asr #7
-		
-	cmp     r4, r3                            
-  blt     ENERGY_BEG       
-	
+
+	cmp     r4, r3
+  blt     ENERGY_BEG
+
 	ldr		  r0, [r13, #8]
 	ldr		  r8, [r13, #4]
-	
+
 ENERGY_END:
 	add		  r4, r0, r8, lsl #2
 
-	str     r6, [r4, #72]         
-	add		  r8, r8, #1	           
-  str     r7, [r4, #136]                   
+	str     r6, [r4, #72]
+	add		  r8, r8, #1
+  str     r7, [r4, #136]
 
 	cmp		  r8, #8
-	blt		  BLOCK_BEGIN                  	                        
+	blt		  BLOCK_BEGIN
 
 BLOCK_END:
-	str     r10, [r0, #168]                    
-  str     r11, [r0, #172]                    
-  mov     r0, #1            
-	                
-  add     r13, r13, #20   
-	ldmia   sp!, {r4 - r11, pc}                  
+	str     r10, [r0, #168]
+  str     r11, [r0, #172]
+  mov     r0, #1
+
+  add     r13, r13, #20
+	ldmia   sp!, {r4 - r11, pc}
 
 hiPassCoeff:
 	.word 0xbec8b439
 	.word	0x609d4952
-		
+
 	@ENDP
 	.end
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/PrePostMDCT_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/PrePostMDCT_v5.s
index 38fe092..103cc91 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/PrePostMDCT_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/PrePostMDCT_v5.s
@@ -26,46 +26,46 @@
 
 PreMDCT:
 	stmdb       sp!, {r4 - r11, lr}
-	
+
 	add         r9, r0, r1, lsl #2
 	sub         r3, r9, #8
 
 	movs        r1, r1, asr #2
 	beq         PreMDCT_END
-	
+
 PreMDCT_LOOP:
 	ldr					r8, [r2], #4
 	ldr					r9, [r2], #4
-	
+
 	ldrd				r4, [r0]
 	ldrd				r6, [r3]
-	
+
 	smull				r14, r11, r4, r8					@ MULHIGH(tr1, cosa)
 	smull    			r10, r12, r7, r8					@ MULHIGH(ti1, cosa)
-		
+
 	smull				r14, r8, r7, r9						@ MULHIGH(ti1, sina)
-	smull				r7, r10, r4, r9						@ MULHIGH(tr1, sina)	
-		
-	add					r11, r11, r8						@ MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@	
+	smull				r7, r10, r4, r9						@ MULHIGH(tr1, sina)
+
+	add					r11, r11, r8						@ MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@
 	sub					r7, r12, r10						@ MULHIGH(ti1, cosa) - MULHIGH(tr1, sina)
-	
+
 	ldr					r8, [r2], #4
 	ldr					r9, [r2], #4
-	
+
 	smull				r14, r4, r6, r8						@ MULHIGH(tr2, cosa)
 	smull    			r10, r12, r5, r8					@ MULHIGH(ti2, cosa)
-		
+
 	smull				r14, r8, r5, r9						@ MULHIGH(ti2, sina)
 	smull				r5, r10, r6, r9						@ MULHIGH(tr2, sina)
-	
+
 	add					r8, r8, r4
 	sub					r9, r12, r10
-	
-	mov					r6, r11		
 
-	strd				r6, [r0]	
+	mov					r6, r11
+
+	strd				r6, [r0]
 	strd				r8, [r3]
-	
+
 	subs				r1, r1, #1
 	sub					r3, r3, #8
 	add 				r0, r0, #8
@@ -74,52 +74,52 @@
 PreMDCT_END:
 	ldmia       sp!, {r4 - r11, pc}
 	@ENDP  @ |PreMDCT|
-	
+
 	.section .text
 	.global	PostMDCT
 
 PostMDCT:
 	stmdb       sp!, {r4 - r11, lr}
-	
+
 	add         r9, r0, r1, lsl #2
 	sub         r3, r9, #8
 
 	movs        r1, r1, asr #2
 	beq         PostMDCT_END
-	
+
 PostMDCT_LOOP:
-	ldr					r8, [r2], #4					
+	ldr					r8, [r2], #4
 	ldr					r9, [r2], #4
-	
+
 	ldrd				r4, [r0]
 	ldrd				r6, [r3]
-	
+
 	smull				r14, r11, r4, r8					@ MULHIGH(tr1, cosa)
 	smull    			r10, r12, r5, r8					@ MULHIGH(ti1, cosa)
-		
+
 	smull				r14, r8, r5, r9						@ MULHIGH(ti1, sina)
-	smull				r5, r10, r4, r9						@ MULHIGH(tr1, sina)	
-		
-	add					r4, r11, r8							@ MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@	
+	smull				r5, r10, r4, r9						@ MULHIGH(tr1, sina)
+
+	add					r4, r11, r8							@ MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@
 	sub					r11, r10, r12						@ MULHIGH(ti1, cosa) - MULHIGH(tr1, sina)@
-	
+
 	ldr					r8, [r2], #4						@
 	ldr					r9, [r2], #4
-	
+
 	smull				r14, r5, r6, r8						@ MULHIGH(tr2, cosa)
 	smull    			r10, r12, r7, r8					@ MULHIGH(ti2, cosa)
-		
+
 	smull				r14, r8, r7, r9						@ MULHIGH(ti2, sina)
 	smull				r7, r10, r6, r9						@ MULHIGH(tr2, sina)
-	
+
 	add					r6, r8, r5							@ MULHIGH(cosb, tr2) + MULHIGH(sinb, ti2)@
 	sub					r5, r10, r12						@ MULHIGH(sinb, tr2) - MULHIGH(cosb, ti2)@
-	
-	mov					r7, r11				
+
+	mov					r7, r11
 
 	strd				r4, [r0]
 	strd				r6, [r3]
-	
+
 	subs				r1, r1, #1
 	sub					r3, r3, #8
 	add 				r0, r0, #8
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/R4R8First_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/R4R8First_v5.s
index b30881a..72cb9a3 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/R4R8First_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/R4R8First_v5.s
@@ -26,46 +26,46 @@
 
 Radix4First:
 	stmdb       sp!, {r4 - r11, lr}
-	
+
 	movs				r10, r1
 	mov					r11, r0
 	beq					Radix4First_END
-		
+
 Radix4First_LOOP:
 	ldrd				r0, [r11]
 	ldrd				r2, [r11, #8]
 	ldrd				r4, [r11, #16]
 	ldrd				r6, [r11, #24]
-	
+
 	add					r8, r0, r2
 	add					r9, r1, r3
-	
+
 	sub					r0, r0, r2
 	sub					r1, r1, r3
-	
+
 	add					r2, r4, r6
 	add					r3, r5, r7
-	
+
 	sub					r4, r4, r6
 	sub					r5, r5, r7
-	
+
 	add					r6, r8, r2
 	add					r7, r9, r3
-	
+
 	sub					r8, r8, r2
 	sub					r9, r9, r3
-	
+
 	add					r2, r0, r5
 	sub					r3, r1, r4
-	
+
 	sub					r0, r0, r5
 	add					r1, r1, r4
-	
+
 	strd				r6, [r11]
 	strd				r2, [r11, #8]
 	strd				r8, [r11, #16]
 	strd				r0, [r11, #24]
-	
+
 	subs				r10, r10, #1
 	add					r11, r11, #32
 	bne					Radix4First_LOOP
@@ -73,180 +73,180 @@
 Radix4First_END:
 	ldmia       sp!, {r4 - r11, pc}
 	@ENDP  @ |Radix4First|
-	
+
 	.section .text
 	.global	Radix8First
 
 Radix8First:
 	stmdb       sp!, {r4 - r11, lr}
 	sub         sp, sp, #0x24
-	
+
 	mov				  r12, r1
 	mov					r14, r0
 	cmp					r12, #0
 	beq					Radix8First_END
-	
+
 Radix8First_LOOP:
-	ldrd				r0, [r14]		
+	ldrd				r0, [r14]
 	ldrd				r2, [r14, #8]
 	ldrd				r4, [r14, #16]
 	ldrd				r6, [r14, #24]
-	
+
 	add					r8, r0, r2					@ r0 = buf[0] + buf[2]@
 	add					r9, r1, r3					@ i0 = buf[1] + buf[3]@
-	
+
 	sub					r0, r0, r2					@ r1 = buf[0] - buf[2]@
 	sub					r1, r1, r3					@ i1 = buf[1] - buf[3]@
-	
+
 	add					r2, r4, r6					@	r2 = buf[4] + buf[6]@
 	add					r3, r5, r7					@ i2 = buf[5] + buf[7]@
-	
+
 	sub					r4, r4, r6					@	r3 = buf[4] - buf[6]@
 	sub					r5, r5, r7					@ i3 = buf[5] - buf[7]@
-	
+
 	add					r6, r8, r2					@ r4 = (r0 + r2) >> 1@
 	add					r7, r9, r3					@ i4 = (i0 + i2) >> 1@
-	
+
 	sub					r8, r8, r2					@	r5 = (r0 - r2) >> 1@
 	sub					r9, r9, r3					@ i5 = (i0 - i2) >> 1@
-	
+
 	sub					r2, r0, r5					@ r6 = (r1 - i3) >> 1@
 	add					r3, r1, r4					@ i6 = (i1 + r3) >> 1@
-	
+
 	add					r0, r0, r5					@ r7 = (r1 + i3) >> 1@
 	sub					r1, r1, r4					@ i7 = (i1 - r3) >> 1@
-	
+
 	mov					r6, r6, asr #1			@
 	mov					r7, r7, asr #1			@
-	
+
 	mov					r8, r8, asr #1
 	mov					r9, r9, asr #1
-	
+
 	mov					r2, r2, asr #1
 	mov					r3, r3, asr #1
-	
+
 	mov					r0, r0, asr #1
-	mov					r1, r1, asr #1	
-	
+	mov					r1, r1, asr #1
+
 	str					r6, [sp]
 	str					r7, [sp, #4]
-	
+
 	str					r8, [sp, #8]
 	str					r9, [sp, #12]
-	
+
 	str					r2, [sp, #16]
-	str					r3, [sp, #20]	
-	
+	str					r3, [sp, #20]
+
 	str					r0, [sp, #24]
-	str					r1, [sp, #28]	
-	
-	ldrd				r2, [r14, #32]		
+	str					r1, [sp, #28]
+
+	ldrd				r2, [r14, #32]
 	ldrd				r4, [r14, #40]
 	ldrd				r6, [r14, #48]
 	ldrd				r8, [r14, #56]
-	
+
 	add					r0, r2, r4					@ r0 = buf[ 8] + buf[10]@
 	add					r1, r3, r5					@ i0 = buf[ 9] + buf[11]@
-	
+
 	sub					r2, r2, r4					@ r1 = buf[ 8] - buf[10]@
 	sub					r3, r3, r5					@ i1 = buf[ 9] - buf[11]@
-	
+
 	add					r4, r6, r8					@ r2 = buf[12] + buf[14]@
 	add					r5, r7, r9					@ i2 = buf[13] + buf[15]@
-	
+
 	sub					r6, r6, r8					@ r3 = buf[12] - buf[14]@
 	sub					r7, r7, r9					@	i3 = buf[13] - buf[15]@
-	
+
 	add					r8, r0, r4					@ t0 = (r0 + r2)
 	add					r9, r1, r5					@ t1 = (i0 + i2)
-	
+
 	sub					r0, r0, r4					@ t2 = (r0 - r2)
 	sub					r1, r1, r5					@ t3 = (i0 - i2)
-	
+
 	mov					r8, r8, asr #1
 	ldr					r4, [sp]
-	
+
 	mov					r9, r9, asr #1
 	ldr					r5, [sp, #4]
-	
-	mov					r0, r0, asr #1		
+
+	mov					r0, r0, asr #1
 	mov					r1, r1, asr #1
-	
+
 	add					r10, r4, r8					@ buf[ 0] = r4 + t0@
 	add					r11, r5, r9					@ buf[ 1] = i4 + t1@
-	
+
 	sub					r4,  r4, r8					@ buf[ 8] = r4 - t0@
 	sub					r5,  r5, r9					@	buf[ 9] = i4 - t1@
-	
+
  	strd				r10, [r14]
  	strd				r4,  [r14, #32]
- 	
+
  	ldr					r10, [sp, #8]
  	ldr					r11, [sp, #12]
- 	
+
  	add					r4, r10, r1					@ buf[ 4] = r5 + t3@
  	sub					r5, r11, r0					@	buf[ 5] = i5 - t2@
- 	
+
  	sub					r10, r10, r1				@ buf[12] = r5 - t3@
  	add					r11, r11, r0				@ buf[13] = i5 + t2@
- 	
+
  	strd				r4,  [r14, #16]
  	strd				r10, [r14, #48]
- 	
+
  	sub					r0, r2, r7					@ r0 = r1 - i3@
  	add					r1, r3, r6					@ i0 = i1 + r3@
- 
+
   ldr					r11, DATATab
- 	
+
  	add					r2, r2, r7					@ r2 = r1 + i3@
  	sub					r3, r3, r6					@ i2 = i1 - r3@
- 	
+
 	sub					r4, r0, r1					@ r0 - i0
 	add					r5, r0, r1					@ r0 + i0
-	
+
 	sub					r0, r2, r3					@ r2 - i2
 	add					r1, r2, r3					@ r2 + i2
-	
-	smull				r8, r6, r4, r11								
-	smull				r9, r7, r5, r11								
-	
+
+	smull				r8, r6, r4, r11
+	smull				r9, r7, r5, r11
+
 	ldr					r2, [sp, #16]
 	ldr					r3, [sp, #20]
-	
-	smull				r8, r4, r0, r11								
-	smull				r9, r5, r1, r11								
-	
+
+	smull				r8, r4, r0, r11
+	smull				r9, r5, r1, r11
+
 	ldr					r10, [sp, #24]
 	ldr					r11, [sp, #28]
-	
+
 	sub					r8, r2, r6
 	sub					r9, r3, r7
-	
+
 	add					r2, r2, r6
 	add					r3, r3, r7
-	
+
 	add					r6, r10, r5
 	sub					r7, r11, r4
-	
+
 	sub					r0, r10, r5
 	add					r1, r11, r4
-	
+
 	strd				r6, [r14, #8]
 	strd				r8, [r14, #24]
 	strd				r0, [r14, #40]
 	strd				r2, [r14, #56]
-	
+
 	subs				r12, r12, #1
 	add					r14, r14, #64
-	
+
 	bne					Radix8First_LOOP
-	
+
 Radix8First_END:
 	add         sp, sp, #0x24
 	ldmia       sp!, {r4 - r11, pc}
-	
+
 DATATab:
 	.word       0x5a82799a
-	
+
 	@ENDP  @ |Radix8First|
 	.end
\ No newline at end of file
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/Radix4FFT_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/Radix4FFT_v5.s
index bc069b4..e81c82e 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/Radix4FFT_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/Radix4FFT_v5.s
@@ -25,145 +25,145 @@
 
 Radix4FFT:
 	stmdb     sp!, {r4 - r11, lr}
-	sub       sp, sp, #32                     
+	sub       sp, sp, #32
 
 	mov			r1, r1, asr #2
-	cmp     r1, #0       
-	beq     Radix4FFT_END                            
-                       
-Radix4FFT_LOOP1:          
-	mov     r14, r0          							@ xptr = buf@          
+	cmp     r1, #0
+	beq     Radix4FFT_END
+
+Radix4FFT_LOOP1:
+	mov     r14, r0          							@ xptr = buf@
 	mov		r10, r1 												@ i = num@
 	mov     r9, r2, lsl #3  							@ step = 2*bgn@
-	cmp     r10, #0  
-	str		r0, [sp] 
-	str		r1, [sp, #4]      
+	cmp     r10, #0
+	str		r0, [sp]
+	str		r1, [sp, #4]
 	str		r2, [sp, #8]
-	str		r3, [sp, #12]  
-	beq     Radix4FFT_LOOP1_END                            	    
-     
-Radix4FFT_LOOP2:                       
+	str		r3, [sp, #12]
+	beq     Radix4FFT_LOOP1_END
+
+Radix4FFT_LOOP2:
 	mov     r12, r3				        				@ csptr = twidTab@
 	mov		r11, r2												@ j = bgn
-	cmp     r11, #0        
+	cmp     r11, #0
 	str		r10, [sp, #16]
-	beq     Radix4FFT_LOOP2_END                         
-	 
-Radix4FFT_LOOP3:                          
-	str			r11, [sp, #20]	 
-	
+	beq     Radix4FFT_LOOP2_END
+
+Radix4FFT_LOOP3:
+	str			r11, [sp, #20]
+
 	ldrd		r0, [r14, #0]									@ r0 = xptr[0]@ r1 = xptr[1]@
 	add			r14, r14, r9 	 								@ xptr += step@
-	
-	ldrd		r10,	[r14, #0]  					 			@ r2 = xptr[0]@ r3 = xptr[1]@	
+
+	ldrd		r10,	[r14, #0]  					 			@ r2 = xptr[0]@ r3 = xptr[1]@
 	ldr			r8, [r12], #4									@ cosxsinx = csptr[0]@
-	
+
 	smulwt	r4, r10, r8										@ L_mpy_wx(cosx, t0)
 	smulwt	r3, r11, r8										@ L_mpy_wx(cosx, t1)
-	
+
 	smlawb	r2, r11, r8, r4								@ r2 = L_mpy_wx(cosx, t0) + L_mpy_wx(sinx, t1)@
 	smulwb	r5, r10, r8										@ L_mpy_wx(sinx, t0)
-	
+
 	mov			r10, r0, asr #2								@ t0 = r0 >> 2@
 	mov			r11, r1, asr #2								@	t1 = r1 >> 2@
-		
+
 	sub			r3, r3, r5										@ r3 = L_mpy_wx(cosx, t1) - L_mpy_wx(sinx, t0)@
 	add     r14, r14, r9 	 								@ xptr += step@
-	
+
 	sub			r0, r10, r2										@ r0 = t0 - r2@
 	sub			r1, r11, r3									  @ r1 = t1 - r3@
-	
+
 	add			r2, r10, r2										@ r2 = t0 + r2@
 	add			r3, r11, r3										@ r3 = t1 + r3@
-	
+
 	str			r2, [sp, #24]
 	str			r3, [sp, #28]
-	
+
 	ldrd		r10, [r14, #0]								@ r4 = xptr[0]@ r5 = xptr[1]@
 	ldr			r8, [r12], #4									@ cosxsinx = csptr[1]@
-	
+
 	smulwt	r6, r10, r8										@ L_mpy_wx(cosx, t0)
 	smulwt	r5, r11, r8										@ L_mpy_wx(cosx, t1)
-	
+
 	smlawb	r4, r11, r8, r6								@ r4 = L_mpy_wx(cosx, t0) + L_mpy_wx(sinx, t1)@
 	smulwb	r7, r10, r8										@ L_mpy_wx(sinx, t0)
-	
+
 	add			r14, r14, r9									@ xptr += step@
 	sub			r5, r5, r7										@ r5 = L_mpy_wx(cosx, t1) - L_mpy_wx(sinx, t0)@
-		
+
 	ldrd		r10, [r14]										@ r6 = xptr[0]@ r7 = xptr[1]@
 	ldr			r8, [r12], #4									@ cosxsinx = csptr[1]@
-	
+
 	smulwt	r2, r10, r8										@ L_mpy_wx(cosx, t0)
 	smulwt	r7, r11, r8										@ L_mpy_wx(cosx, t1)
-	
+
 	smlawb	r6, r11, r8, r2								@ r4 = L_mpy_wx(cosx, t0) + L_mpy_wx(sinx, t1)@
 	smulwb	r3, r10, r8										@ L_mpy_wx(sinx, t0)
-	
-	mov			r10, r4												@ t0 = r4@
-	mov			r11, r5												@ t1 = r5@	
-	
-	sub			r7, r7, r3										@ r5 = L_mpy_wx(cosx, t1) - L_mpy_wx(sinx, t0)@
-	
 
-	add			r4,  r10, r6									@	r4 = t0 + r6@	
+	mov			r10, r4												@ t0 = r4@
+	mov			r11, r5												@ t1 = r5@
+
+	sub			r7, r7, r3										@ r5 = L_mpy_wx(cosx, t1) - L_mpy_wx(sinx, t0)@
+
+
+	add			r4,  r10, r6									@	r4 = t0 + r6@
 	sub			r5, r7, r11										@ r5 = r7 - t1@
-	
+
 	sub			r6, r10, r6										@ r6 = t0 - r6@
 	add			r7, r7, r11										@ r7 = r7 + t1@
-	
+
 	ldr			r2, [sp, #24]
 	ldr			r3, [sp, #28]
-	
+
 	add			r10, r0, r5										@ xptr[0] = r0 + r5@
 	add			r11, r1, r6										@ xptr[0] = r1 + r6
-	
-	strd		r10, [r14]										
+
+	strd		r10, [r14]
 	sub			r14, r14, r9									@ xptr -= step@
-	
+
 	sub			r10, r2, r4										@	xptr[0] = r2 - r4@
 	sub			r11, r3, r7										@ xptr[1] = r3 - r7@
-	
-	strd		r10, [r14]				
+
+	strd		r10, [r14]
 	sub			r14, r14, r9									@ xptr -= step@
-	
+
 	sub			r10, r0, r5										@ xptr[0] = r0 - r5@
 	sub			r11, r1, r6										@ xptr[0] = r1 - r6
-	
-	strd		r10, [r14]										
+
+	strd		r10, [r14]
 	sub			r14, r14, r9									@ xptr -= step@
-	
+
 	add			r10, r2, r4										@	xptr[0] = r2 - r4@
 	add			r11, r3, r7										@ xptr[1] = r3 - r7@
-	
-	strd		r10, [r14]				
+
+	strd		r10, [r14]
 	add			r14, r14, #8									@ xptr += 2@
-	
+
 	ldr			r11, [sp, #20]
 	subs		r11, r11, #1
-	bne			Radix4FFT_LOOP3	
-	 
-Radix4FFT_LOOP2_END:           
+	bne			Radix4FFT_LOOP3
+
+Radix4FFT_LOOP2_END:
 	ldr			r10, [sp, #16]
 	ldr			r3, [sp, #12]
 	ldr			r2, [sp, #8]
-	rsb			r8, r9, r9, lsl #2   
+	rsb			r8, r9, r9, lsl #2
 	sub			r10, r10, #1
-	add			r14, r14, r8		      
-	cmp			r10, #0  
-	bhi     Radix4FFT_LOOP2           
-                        
-Radix4FFT_LOOP1_END:               
-	ldr     r0, [sp]    
+	add			r14, r14, r8
+	cmp			r10, #0
+	bhi     Radix4FFT_LOOP2
+
+Radix4FFT_LOOP1_END:
+	ldr     r0, [sp]
 	ldr		r1, [sp, #4]
 	add     r3, r3, r8, asr #1
-	mov     r2, r2, lsl #2 
-	movs    r1, r1, asr #2 
-	bne     Radix4FFT_LOOP1          
-                        
-Radix4FFT_END:                        
-	add     sp, sp, #32                  
+	mov     r2, r2, lsl #2
+	movs    r1, r1, asr #2
+	bne     Radix4FFT_LOOP1
+
+Radix4FFT_END:
+	add     sp, sp, #32
 	ldmia   sp!, {r4 - r11, pc}
-		
+
 	@ENDP  @ |Radix4FFT|
 	.end
\ No newline at end of file
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/band_nrg_v5.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/band_nrg_v5.s
index 3b88810..4789f6d 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/band_nrg_v5.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV5E/band_nrg_v5.s
@@ -26,31 +26,31 @@
 	.global	CalcBandEnergy
 
 CalcBandEnergy:
-	stmdb   sp!, {r4 - r11, lr}	
-                   
-  mov     r2, r2, lsl #16                   
+	stmdb   sp!, {r4 - r11, lr}
+
+  mov     r2, r2, lsl #16
 	ldr     r12, [r13, #36]
 	mov			r9, #0
-  mov     r5, r2, asr #16    
-	mov			r4, #0               
-  cmp     r5, #0	
-	ble     L212 
+  mov     r5, r2, asr #16
+	mov			r4, #0
+  cmp     r5, #0
+	ble     L212
 
 L22:
-  mov     r2, r4, lsl #1                    
-  ldrsh   r10, [r1, r2]                     
-  add     r11, r1, r2                       
-  ldrsh   r2, [r11, #2]    
-	mov     r14, #0                 
-  cmp     r10, r2                           
-  bge     L28 
-	
+  mov     r2, r4, lsl #1
+  ldrsh   r10, [r1, r2]
+  add     r11, r1, r2
+  ldrsh   r2, [r11, #2]
+	mov     r14, #0
+  cmp     r10, r2
+  bge     L28
+
 L23:
-	ldr     r11, [r0, +r10, lsl #2]	
-  add     r10, r10, #1    
-	ldr     r6, [r0, +r10, lsl #2]	
+	ldr     r11, [r0, +r10, lsl #2]
+  add     r10, r10, #1
+	ldr     r6, [r0, +r10, lsl #2]
 	smull   r11, r7, r11, r11
-	add     r10, r10, #1 
+	add     r10, r10, #1
 	smull	  r6, r8, r6, r6
 	ldr     r11, [r0, +r10, lsl #2]
 	qadd	  r14, r14, r7
@@ -59,71 +59,71 @@
 	ldr     r6, [r0, +r10, lsl #2]
 	qadd	  r14, r14, r8
 	smull	  r6, r8, r6, r6
-  add     r10, r10, #1 
+  add     r10, r10, #1
 	qadd	  r14, r14, r7
 	cmp     r10, r2
 	qadd	  r14, r14, r8
-	blt     L23   
+	blt     L23
 
-L28:	
+L28:
 	qadd	  r14, r14, r14
 	str     r14, [r3, +r4, lsl #2]
-	add     r4, r4, #1 
+	add     r4, r4, #1
 	qadd	  r9, r9, r14
-	cmp     r4, r5                          
+	cmp     r4, r5
 
-  blt     L22       	
+  blt     L22
 
-L212:	
-	str     r9, [r12, #0]                     
+L212:
+	str     r9, [r12, #0]
 	ldmia   sp!, {r4 - r11, pc}
-	
+
 	@ENDP  ; |CalcBandEnergy|
-	
+
 	.global	CalcBandEnergyMS
 
 CalcBandEnergyMS:
 	stmdb   sp!, {r4 - r11, lr}
 	sub     r13, r13, #24
-	
-	mov     r12, #0 
-  mov     r3, r3, lsl #16  
-  mov     r14, #0 
-	mov     r3, r3, asr #16      
-	cmp     r3, #0          
-	mov		  r4, #0                  
-  ble     L315    
-	
-L32:	
+
+	mov     r12, #0
+  mov     r3, r3, lsl #16
+  mov     r14, #0
+	mov     r3, r3, asr #16
+	cmp     r3, #0
+	mov		  r4, #0
+  ble     L315
+
+L32:
 	mov		  r5, r4, lsl #1
 	mov		  r6, #0
 	ldrsh   r10, [r2, r5]
 	add     r5, r2, r5
 	mov		  r7, #0
-	ldrsh	  r11, [r5, #2]                        
-	cmp     r10, r11                          
-  bge     L39    
+	ldrsh	  r11, [r5, #2]
+	cmp     r10, r11
+  bge     L39
 
 	str		  r3, [r13, #4]
 	str		  r4, [r13, #8]
 	str		  r12, [r13, #12]
 	str		  r14, [r13, #16]
 
-L33:	
-	ldr     r8, [r0, +r10, lsl #2]                    
+L33:
+	ldr     r8, [r0, +r10, lsl #2]
 	ldr     r9, [r1, +r10, lsl #2]
 	mov		  r8, r8, asr #1
 	add		  r10, r10, #1
 	mov		  r9, r9, asr #1
 
-	ldr     r12, [r0, +r10, lsl #2]          
-	add		  r5, r8, r9	          
+	ldr     r12, [r0, +r10, lsl #2]
+	add		  r5, r8, r9
 	ldr     r14, [r1, +r10, lsl #2]
 	sub		  r8, r8, r9
 
-	smull   r5, r3, r5, r5 
+	smull   r5, r3, r5, r5
 	mov		  r12, r12, asr #1
-	smull   r8, r4, r8, r8 
+	smull   r8, r4, r8, r8
 	mov		  r14, r14, asr #1
 
 	qadd	  r6, r6, r3
@@ -131,27 +131,27 @@
 	qadd	  r7, r7, r4
 	sub		  r8, r12, r14
 
-	smull   r5, r3, r5, r5 
+	smull   r5, r3, r5, r5
 	add		  r10, r10, #1
-	smull   r8, r4, r8, r8 
-		
+	smull   r8, r4, r8, r8
+
 	qadd	  r6, r6, r3
 	qadd	  r7, r7, r4
 
-	ldr     r8, [r0, +r10, lsl #2]                    
+	ldr     r8, [r0, +r10, lsl #2]
 	ldr     r9, [r1, +r10, lsl #2]
 	mov		  r8, r8, asr #1
 	add		  r10, r10, #1
 	mov		  r9, r9, asr #1
 
-	ldr     r12, [r0, +r10, lsl #2]          
-	add		  r5, r8, r9	          
+	ldr     r12, [r0, +r10, lsl #2]
+	add		  r5, r8, r9
 	ldr     r14, [r1, +r10, lsl #2]
 	sub		  r8, r8, r9
 
-	smull   r5, r3, r5, r5 
+	smull   r5, r3, r5, r5
 	mov		  r12, r12, asr #1
-	smull   r8, r4, r8, r8 
+	smull   r8, r4, r8, r8
 	mov		  r14, r14, asr #1
 
 	qadd	  r6, r6, r3
@@ -159,37 +159,37 @@
 	qadd	  r7, r7, r4
 	sub		  r8, r12, r14
 
-	smull   r5, r3, r5, r5 
+	smull   r5, r3, r5, r5
 	add		  r10, r10, #1
-	smull   r8, r4, r8, r8 
-		
+	smull   r8, r4, r8, r8
+
 	qadd	  r6, r6, r3
 	qadd	  r7, r7, r4
 
 	cmp     r10, r11
-	
+
 	blt		  L33
 
 	ldr		  r3, [r13, #4]
-	ldr		  r4, [r13, #8]	
+	ldr		  r4, [r13, #8]
 	ldr		  r12, [r13, #12]
 	ldr		  r14, [r13, #16]
-L39:	
+L39:
 	qadd	  r6, r6, r6
-	qadd	  r7, r7, r7	
-	
+	qadd	  r7, r7, r7
+
 	ldr		  r8, [r13, #60]
 	ldr		  r9, [r13, #68]
 
 	qadd	  r12, r12, r6
 	qadd	  r14, r14, r7
-	
-	str		  r6, [r8, +r4, lsl #2]       
-	str     r7, [r9, +r4, lsl #2]    
-	
+
+	str		  r6, [r8, +r4, lsl #2]
+	str     r7, [r9, +r4, lsl #2]
+
 	add		  r4, r4, #1
 	cmp		  r4, r3
-	blt     L32            
+	blt     L32
 
 L315:
 	ldr		  r8, [r13, #64]
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/PrePostMDCT_v7.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/PrePostMDCT_v7.s
index a04c105..64d767a 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/PrePostMDCT_v7.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/PrePostMDCT_v7.s
@@ -26,53 +26,53 @@
 
 PreMDCT:
 	stmdb     sp!, {r4 - r11, lr}
-	
+
 	add         r9, r0, r1, lsl #2
 	sub         r3, r9, #32
 
 	movs        r1, r1, asr #2
-	beq         PreMDCT_END	
-	
+	beq         PreMDCT_END
+
 PreMDCT_LOOP:
 	VLD4.I32			{d0, d2, d4, d6}, [r2]!				@ cosa = *csptr++@ sina = *csptr++@
 	VLD4.I32			{d1, d3, d5, d7}, [r2]!				@ cosb = *csptr++@ sinb = *csptr++@
 	VLD2.I32			{d8, d9, d10, d11}, [r0]			@ tr1 = *(buf0 + 0)@ ti2 = *(buf0 + 1)@
 	VLD2.I32			{d13, d15}, [r3]!					@ tr2 = *(buf1 - 1)@ ti1 = *(buf1 + 0)@
 	VLD2.I32			{d12, d14}, [r3]!					@ tr2 = *(buf1 - 1)@ ti1 = *(buf1 + 0)@
-		
-	VREV64.32			Q8, Q7	
+
+	VREV64.32			Q8, Q7
 	VREV64.32			Q9, Q6
 
-	
+
 	VQDMULH.S32		Q10, Q0, Q4								@ MULHIGH(cosa, tr1)
 	VQDMULH.S32		Q11, Q1, Q8								@ MULHIGH(sina, ti1)
 	VQDMULH.S32		Q12, Q0, Q8								@ MULHIGH(cosa, ti1)
 	VQDMULH.S32		Q13, Q1, Q4								@ MULHIGH(sina, tr1)
-		
+
 	VADD.S32			Q0, Q10, Q11						@ *buf0++ = MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@
 	VSUB.S32			Q1, Q12, Q13						@ *buf0++ = MULHIGH(cosa, ti1) - MULHIGH(sina, tr1)@
-	
+
 	VST2.I32			{d0, d1, d2, d3}, [r0]!
 	sub						r3, r3, #32
-	
+
 	VQDMULH.S32		Q10, Q2, Q9										@ MULHIGH(cosb, tr2)
 	VQDMULH.S32		Q11, Q3, Q5										@ MULHIGH(sinb, ti2)
 	VQDMULH.S32		Q12, Q2, Q5										@ MULHIGH(cosb, ti2)
 	VQDMULH.S32		Q13, Q3, Q9										@ MULHIGH(sinb, tr2)
-		
+
 	VADD.S32			Q0, Q10, Q11									@ MULHIGH(cosa, tr2) + MULHIGH(sina, ti2)@
 	VSUB.S32			Q1, Q12, Q13									@ MULHIGH(cosa, ti2) - MULHIGH(sina, tr2)@
-	
+
 	VREV64.32			Q3, Q1
 	VREV64.32			Q2, Q0
-		
-	VST2.I32		{d5, d7}, [r3]!	
-	VST2.I32		{d4, d6}, [r3]! 
-	
+
+	VST2.I32		{d5, d7}, [r3]!
+	VST2.I32		{d4, d6}, [r3]!
+
 	subs     		r1, r1, #4
-	sub		  		r3, r3, #64	
+	sub		  		r3, r3, #64
 	bne       	PreMDCT_LOOP
-	
+
 PreMDCT_END:
 	ldmia     sp!, {r4 - r11, pc}
 	@ENDP  @ |PreMDCT|
@@ -82,50 +82,50 @@
 
 PostMDCT:
 	stmdb     sp!, {r4 - r11, lr}
-	
+
 	add         r9, r0, r1, lsl #2
 	sub         r3, r9, #32
 
 	movs        r1, r1, asr #2
 	beq         PostMDCT_END
-	
+
 PostMDCT_LOOP:
 	VLD4.I32			{d0, d2, d4, d6}, [r2]!				@ cosa = *csptr++@ sina = *csptr++@
 	VLD4.I32			{d1, d3, d5, d7}, [r2]!				@ cosb = *csptr++@ sinb = *csptr++@
 	VLD2.I32			{d8, d9, d10, d11}, [r0]			@ tr1 = *(zbuf1 + 0)@ ti1 = *(zbuf1 + 1)@
 	VLD2.I32			{d13, d15}, [r3]!							@ tr2 = *(zbuf2 - 1)@ ti2 = *(zbuf2 + 0)@
-	VLD2.I32			{d12, d14}, [r3]!							@ tr2 = *(zbuf2 - 1)@ ti2 = *(zbuf2 + 0)@	
+	VLD2.I32			{d12, d14}, [r3]!							@ tr2 = *(zbuf2 - 1)@ ti2 = *(zbuf2 + 0)@
 
-	VREV64.32			Q8, Q6	
-	VREV64.32			Q9, Q7			
-	
+	VREV64.32			Q8, Q6
+	VREV64.32			Q9, Q7
+
 	VQDMULH.S32		Q10, Q0, Q4										@ MULHIGH(cosa, tr1)
 	VQDMULH.S32		Q11, Q1, Q5										@ MULHIGH(sina, ti1)
 	VQDMULH.S32		Q12, Q0, Q5										@ MULHIGH(cosa, ti1)
 	VQDMULH.S32		Q13, Q1, Q4										@ MULHIGH(sina, tr1)
-		
+
 	VADD.S32			Q0, Q10, Q11									@ *buf0++ = MULHIGH(cosa, tr1) + MULHIGH(sina, ti1)@
 	VSUB.S32			Q5, Q13, Q12									@ *buf1-- = MULHIGH(sina, tr1) - MULHIGH(cosa, ti1)@
-	
+
 	VQDMULH.S32		Q10, Q2, Q8										@ MULHIGH(cosb, tr2)
 	VQDMULH.S32		Q11, Q3, Q9										@ MULHIGH(sinb, ti2)
 	VQDMULH.S32		Q12, Q2, Q9										@ MULHIGH(cosb, ti2)
 	VQDMULH.S32		Q13, Q3, Q8										@ MULHIGH(sinb, tr2)
-		
+
 	VADD.S32			Q4, Q10, Q11									@ *buf1-- = MULHIGH(cosa, tr2) + MULHIGH(sina, ti2)@
-	VSUB.S32			Q1, Q13, Q12									@ *buf0++ = MULHIGH(sina, tr2) - MULHIGH(cosa, ti2)@	
-	
+	VSUB.S32			Q1, Q13, Q12									@ *buf0++ = MULHIGH(sina, tr2) - MULHIGH(cosa, ti2)@
+
 	VREV64.32			Q2, Q4
-	VREV64.32			Q3, Q5	
-	
-	sub						r3, r3, #32	
+	VREV64.32			Q3, Q5
+
+	sub						r3, r3, #32
 	VST2.I32			{d0, d1, d2, d3}, [r0]!
-		
-	VST2.I32			{d5, d7}, [r3]!	
-	VST2.I32			{d4, d6}, [r3]! 
-	
+
+	VST2.I32			{d5, d7}, [r3]!
+	VST2.I32			{d4, d6}, [r3]!
+
 	subs     			r1, r1, #4
-	sub		  			r3, r3, #64		
+	sub		  			r3, r3, #64
 	bne       	PostMDCT_LOOP
 
 PostMDCT_END:
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/R4R8First_v7.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/R4R8First_v7.s
index defd45d..7fc5520 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/R4R8First_v7.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/R4R8First_v7.s
@@ -29,86 +29,86 @@
 
 	ldr       		r3, SQRT1_2
 	cmp       		r1, #0
-	
-	VDUP.I32  		Q15, r3	
+
+	VDUP.I32  		Q15, r3
 	beq       		Radix8First_END
-	
+
 Radix8First_LOOP:
 	VLD1.I32			{d0, d1, d2, d3},	[r0]!
 	VLD1.I32			{d8, d9, d10, d11},	[r0]!
-		
+
 	VADD.S32			d4, d0, d1		@ r0 = buf[0] + buf[2]@i0 = buf[1] + buf[3]@
-	VSUB.S32			d5, d0, d1		@ r1 = buf[0] - buf[2]@i1 = buf[1] - buf[3]@	
-	VSUB.S32			d7, d2, d3		@ r2 = buf[4] - buf[6]@i2 = buf[5] - buf[7]@	
+	VSUB.S32			d5, d0, d1		@ r1 = buf[0] - buf[2]@i1 = buf[1] - buf[3]@
+	VSUB.S32			d7, d2, d3		@ r2 = buf[4] - buf[6]@i2 = buf[5] - buf[7]@
 	VADD.S32			d6, d2, d3		@ r3 = buf[4] + buf[6]@i3 = buf[5] + buf[7]@
-	VREV64.I32			d7, d7	
-	
+	VREV64.I32			d7, d7
+
 	VADD.S32			Q0, Q2, Q3		@ r4 = (r0 + r2)@i4 = (i0 + i2)@i6 = (i1 + r3)@r7 = (r1 + i3)
 	VSUB.S32			Q1, Q2, Q3		@ r5 = (r0 - r2)@i5 = (i0 - i2)@r6 = (r1 - i3)@i7 = (i1 - r3)@
 
-	VREV64.I32			d3, d3	
+	VREV64.I32			d3, d3
 
 	VADD.S32			d4, d8, d9		@ r0 = buf[ 8] + buf[10]@i0 = buf[ 9] + buf[11]@
-	VSUB.S32			d7, d10, d11	@ r1 = buf[12] - buf[14]@i1 = buf[13] - buf[15]@	
+	VSUB.S32			d7, d10, d11	@ r1 = buf[12] - buf[14]@i1 = buf[13] - buf[15]@
 	VADD.S32			d6, d10, d11	@ r2 = buf[12] + buf[14]@i2 = buf[13] + buf[15]@
-	VREV64.I32			d7, d7	
+	VREV64.I32			d7, d7
 	VSUB.S32			d5, d8, d9		@ r3 = buf[ 8] - buf[10]@i3 = buf[ 9] - buf[11]@
-	
-	VTRN.32				d1, d3	
-	
+
+	VTRN.32				d1, d3
+
 	VADD.S32			Q4, Q2, Q3		@ t0 = (r0 + r2) >> 1@t1 = (i0 + i2) >> 1@i0 = i1 + r3@r2 = r1 + i3@
 	VSUB.S32			Q5, Q2, Q3		@ t2 = (r0 - r2) >> 1@t3 = (i0 - i2) >> 1@r0 = r1 - i3@i2 = i1 - r3@
-	
+
 	VREV64.I32			d3, d3
-	
-	VSHR.S32			d8, d8, #1		 
+
+	VSHR.S32			d8, d8, #1
 	VSHR.S32			Q0, Q0, #1
 	VREV64.I32			d10, d10
 	VTRN.32				d11, d9
 	VSHR.S32			Q1, Q1, #1
 	VSHR.S32			d10, d10, #1
 	VREV64.I32			d9, d9
-	
+
 	sub       			r0, r0, #0x40
-	
+
 	VADD.S32			d12, d0, d8
-	VSUB.S32			d16, d0, d8	
+	VSUB.S32			d16, d0, d8
 	VADD.S32			d14, d2, d10
 	VSUB.S32			d18, d2, d10
-	
+
 	VSUB.S32			d4, d11, d9
 	VADD.S32			d5, d11, d9
-	
+
 	VREV64.I32			d18, d18
-	
+
 	VQDMULH.S32			Q3, Q2, Q15
 	VTRN.32				d14, d18
 	VTRN.32				d6, d7
-	VREV64.I32			d18, d18	
-	
+	VREV64.I32			d18, d18
+
 	VSUB.S32			d15, d3, d6
 	VREV64.I32			d7, d7
 	VADD.S32			d19, d3, d6
 	VADD.S32			d13, d1, d7
 	VSUB.S32			d17, d1, d7
-	
+
 	VREV64.I32			d17, d17
 	VTRN.32				d13, d17
 	VREV64.I32			d17, d17
-	
-	subs       			r1, r1, #1	
-	
+
+	subs       			r1, r1, #1
+
 	VST1.I32			{d12, d13, d14, d15}, [r0]!
-	VST1.I32			{d16, d17, d18, d19}, [r0]!	
+	VST1.I32			{d16, d17, d18, d19}, [r0]!
 	bne       			Radix8First_LOOP
-	
+
 Radix8First_END:
-	ldmia     sp!, {r4 - r11, pc}	
+	ldmia     sp!, {r4 - r11, pc}
 SQRT1_2:
 	.word      0x2d413ccd
-	
+
 	@ENDP  @ |Radix8First|
-	
+
 	.section .text
 	.global	Radix4First
 
@@ -117,28 +117,28 @@
 
 	cmp       	r1, #0
 	beq       	Radix4First_END
-	
+
 Radix4First_LOOP:
-	VLD1.I32			{d0, d1, d2, d3}, [r0]					
-	
-	VADD.S32			d4, d0, d1							@ r0 = buf[0] + buf[2]@ r1 = buf[1] + buf[3]@		
+	VLD1.I32			{d0, d1, d2, d3}, [r0]
+
+	VADD.S32			d4, d0, d1							@ r0 = buf[0] + buf[2]@ r1 = buf[1] + buf[3]@
 	VSUB.S32			d5, d0, d1							@ r2 = buf[0] - buf[2]@ r3 = buf[1] - buf[3]@
 	VSUB.S32			d7, d2, d3							@ r4 = buf[4] + buf[6]@ r5 = buf[5] + buf[7]@
 	VADD.S32			d6, d2, d3							@ r6 = buf[4] - buf[6]@ r7 = buf[5] - buf[7]@
-	
-	VREV64.I32		d7, d7									@ 
-	
+
+	VREV64.I32		d7, d7									@
+
 	VADD.S32			Q4, Q2, Q3
 	VSUB.S32			Q5, Q2, Q3
-	
+
 	VREV64.I32		d11, d11
 	VTRN.32				d9, d11
-	subs       		r1, r1, #1	
+	subs       		r1, r1, #1
 	VREV64.I32		d11, d11
 	VST1.I32			{d8, d9, d10, d11}, [r0]!
 
 	bne       		Radix4First_LOOP
-	
+
 Radix4First_END:
 	ldmia    		sp!, {r4 - r11, pc}
 
diff --git a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/Radix4FFT_v7.s b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/Radix4FFT_v7.s
index 84a4a80..b8655ae 100644
--- a/media/libstagefright/codecs/aacenc/src/asm/ARMV7/Radix4FFT_v7.s
+++ b/media/libstagefright/codecs/aacenc/src/asm/ARMV7/Radix4FFT_v7.s
@@ -28,116 +28,116 @@
 	stmdb    sp!, {r4 - r11, lr}
 
 	mov			r1, r1, asr #2
-	cmp     	r1, #0                            
-	beq     	Radix4FFT_END                            
-                        
-Radix4FFT_LOOP1:                         
-	mov     	r5, r2, lsl #1  
-	mov     	r8, r0          
-	mov     	r7, r1  
-	mov     	r5, r5, lsl #2   
-	cmp     	r1, #0          
-	rsbeq   	r12, r5, r5, lsl #2 
-	beq     	Radix4FFT_LOOP1_END              
-                         
-	rsb     	r12, r5, r5, lsl #2   
-	 
-Radix4FFT_LOOP2:                        
-	mov     	r6, r3 
-	mov     	r4, r2  
-	cmp     	r2, #0        
-	beq     	Radix4FFT_LOOP2_END         
-  
-Radix4FFT_LOOP3:                          
+	cmp     	r1, #0
+	beq     	Radix4FFT_END
+
+Radix4FFT_LOOP1:
+	mov     	r5, r2, lsl #1
+	mov     	r8, r0
+	mov     	r7, r1
+	mov     	r5, r5, lsl #2
+	cmp     	r1, #0
+	rsbeq   	r12, r5, r5, lsl #2
+	beq     	Radix4FFT_LOOP1_END
+
+	rsb     	r12, r5, r5, lsl #2
+
+Radix4FFT_LOOP2:
+	mov     	r6, r3
+	mov     	r4, r2
+	cmp     	r2, #0
+	beq     	Radix4FFT_LOOP2_END
+
+Radix4FFT_LOOP3:
 	@r0 = xptr[0]@
 	@r1 = xptr[1]@
-	VLD2.I32			{D0, D1, D2, D3}, [r8]				
+	VLD2.I32			{D0, D1, D2, D3}, [r8]
 	VLD2.I32			{D28, D29, D30, D31}, [r6]!		@ cosx = csptr[0]@ sinx = csptr[1]@
-	
-	add					r8, r8, r5										@ xptr += step@	
+
+	add					r8, r8, r5										@ xptr += step@
 	VLD2.I32			{D4, D5, D6,D7}, [r8]					@ r2 = xptr[0]@ r3 = xptr[1]@
-	
+
 	VQDMULH.S32		Q10, Q2, Q14									@ MULHIGH(cosx, t0)
 	VQDMULH.S32		Q11, Q3, Q15									@ MULHIGH(sinx, t1)
 	VQDMULH.S32		Q12, Q3, Q14									@ MULHIGH(cosx, t1)
 	VQDMULH.S32		Q13, Q2, Q15									@ MULHIGH(sinx, t0)
-		
+
 	VADD.S32			Q2, Q10, Q11									@ MULHIGH(cosx, t0) + MULHIGH(sinx, t1)
 	VSUB.S32			Q3, Q12, Q13									@ MULHIGH(cosx, t1) - MULHIGH(sinx, t0)
-	
+
 	add					r8, r8, r5										@ xptr += step@
 	VSHR.S32			Q10, Q0, #2										@ t0 = r0 >> 2@
 	VSHR.S32			Q11, Q1, #2										@ t1 = r1 >> 2@
-	
+
 	VSUB.S32			Q0,	Q10, Q2										@ r0 = t0 - r2@
 	VSUB.S32			Q1,	Q11, Q3										@ r1 = t1 - r3@
 	VADD.S32			Q2, Q10, Q2										@ r2 = t0 + r2@
 	VADD.S32			Q3, Q11, Q3										@ r3 = t1 + r3@
-		
-	VLD2.I32			{D8, D9, D10, D11}, [r8]	
-	VLD2.I32			{D28, D29, D30, D31}, [r6]!	
+
+	VLD2.I32			{D8, D9, D10, D11}, [r8]
+	VLD2.I32			{D28, D29, D30, D31}, [r6]!
 	add						r8, r8, r5
 
 	VQDMULH.S32		Q10, Q4, Q14									@ MULHIGH(cosx, t0)
 	VQDMULH.S32		Q11, Q5, Q15									@ MULHIGH(sinx, t1)
 	VQDMULH.S32		Q12, Q5, Q14									@ MULHIGH(cosx, t1)
 	VQDMULH.S32		Q13, Q4, Q15									@ MULHIGH(sinx, t0)
-		
+
 	VADD.S32			Q8, Q10, Q11									@ MULHIGH(cosx, t0) + MULHIGH(sinx, t1)
-	VSUB.S32			Q9, Q12, Q13									@ MULHIGH(cosx, t1) - MULHIGH(sinx, t0)	
-	
-	VLD2.I32		{D12, D13, D14, D15}, [r8]	
+	VSUB.S32			Q9, Q12, Q13									@ MULHIGH(cosx, t1) - MULHIGH(sinx, t0)
+
+	VLD2.I32		{D12, D13, D14, D15}, [r8]
 	VLD2.I32		{D28, D29, D30, D31}, [r6]!
-	
+
 	VQDMULH.S32		Q10, Q6, Q14									@ MULHIGH(cosx, t0)
 	VQDMULH.S32		Q11, Q7, Q15									@ MULHIGH(sinx, t1)
 	VQDMULH.S32		Q12, Q7, Q14									@ MULHIGH(cosx, t1)
 	VQDMULH.S32		Q13, Q6, Q15									@ MULHIGH(sinx, t0)
-		
+
 	VADD.S32			Q6, Q10, Q11									@ MULHIGH(cosx, t0) + MULHIGH(sinx, t1)
-	VSUB.S32			Q7, Q12, Q13									@ MULHIGH(cosx, t1) - MULHIGH(sinx, t0)		
-	
+	VSUB.S32			Q7, Q12, Q13									@ MULHIGH(cosx, t1) - MULHIGH(sinx, t0)
+
 	VADD.S32			Q4, Q8, Q6										@ r4 = t0 + r6@
 	VSUB.S32			Q5, Q7, Q9										@ r5 = r7 - t1@
 	VSUB.S32			Q6, Q8, Q6										@ r6 = t0 - r6@
 	VADD.S32			Q7, Q7, Q9										@ r7 = r7 + t1@
-	
+
 	VADD.S32			Q8, Q0, Q5										@ xptr[0] = r0 + r5@
 	VADD.S32			Q9, Q1, Q6										@ xptr[1] = r1 + r6@
 	VST2.I32			{D16, D17, D18, D19}, [r8]
-	
+
 	VSUB.S32			Q10, Q2, Q4										@ xptr[0] = r2 - r4@
 	sub					r8, r8, r5										@ xptr -= step@
 	VSUB.S32			Q11, Q3, Q7										@ xptr[1] = r3 - r7@
 	VST2.I32			{D20, D21, D22, D23}, [r8]
-		
+
 	VSUB.S32			Q8, Q0, Q5										@ xptr[0] = r0 - r5@
 	sub					r8, r8, r5										@ xptr -= step@
 	VSUB.S32			Q9, Q1, Q6										@ xptr[1] = r1 - r6@
 	VST2.I32			{D16, D17, D18, D19}, [r8]
-		
+
 	VADD.S32			Q10, Q2, Q4										@ xptr[0] = r2 + r4@
 	sub					r8, r8, r5										@ xptr -= step@
 	VADD.S32			Q11, Q3, Q7										@ xptr[1] = r3 + r7@
 	VST2.I32			{D20, D21, D22, D23}, [r8]!
-		
-	subs    			r4, r4, #4 
-	bne     			Radix4FFT_LOOP3 
-	                         
-Radix4FFT_LOOP2_END:                         
-	add     			r8, r8, r12    
-	sub    				r7, r7, #1     
+
+	subs    			r4, r4, #4
+	bne     			Radix4FFT_LOOP3
+
+Radix4FFT_LOOP2_END:
+	add     			r8, r8, r12
+	sub    				r7, r7, #1
 	cmp					r7, #0
-	bhi     			Radix4FFT_LOOP2           
-                        
-Radix4FFT_LOOP1_END:                        
-	add     			r3, r12, r3    
-	mov     			r2, r2, lsl #2 
-	movs    			r1, r1, asr #2 
-	bne     			Radix4FFT_LOOP1          
-                        
-Radix4FFT_END:        
+	bhi     			Radix4FFT_LOOP2
+
+Radix4FFT_LOOP1_END:
+	add     			r3, r12, r3
+	mov     			r2, r2, lsl #2
+	movs    			r1, r1, asr #2
+	bne     			Radix4FFT_LOOP1
+
+Radix4FFT_END:
 	ldmia   			sp!, {r4 - r11, pc}
-		
+
 	@ENDP  @ |Radix4FFT|
 	.end
\ No newline at end of file
diff --git a/media/libstagefright/codecs/aacenc/src/band_nrg.c b/media/libstagefright/codecs/aacenc/src/band_nrg.c
index 89c39b6..7501af1 100644
--- a/media/libstagefright/codecs/aacenc/src/band_nrg.c
+++ b/media/libstagefright/codecs/aacenc/src/band_nrg.c
@@ -37,18 +37,18 @@
                     Word32       *bandEnergySum)
 {
   Word32 i, j;
-  Word32 accuSum = 0;                                            
+  Word32 accuSum = 0;
 
   for (i=0; i<numBands; i++) {
-    Word32 accu = 0;                                             
+    Word32 accu = 0;
     for (j=bandOffset[i]; j<bandOffset[i+1]; j++)
       accu = L_add(accu, MULHIGH(mdctSpectrum[j], mdctSpectrum[j]));
 
 	accu = L_add(accu, accu);
     accuSum = L_add(accuSum, accu);
-    bandEnergy[i] = accu;                                        
+    bandEnergy[i] = accu;
   }
-  *bandEnergySum = accuSum;                                      
+  *bandEnergySum = accuSum;
 }
 
 /********************************************************************************
@@ -68,15 +68,15 @@
 {
 
   Word32 i, j;
-  Word32 accuMidSum = 0;        
-  Word32 accuSideSum = 0;                                          
- 
+  Word32 accuMidSum = 0;
+  Word32 accuSideSum = 0;
+
 
   for(i=0; i<numBands; i++) {
     Word32 accuMid = 0;
-    Word32 accuSide = 0;                                           
+    Word32 accuSide = 0;
     for (j=bandOffset[i]; j<bandOffset[i+1]; j++) {
-      Word32 specm, specs; 
+      Word32 specm, specs;
       Word32 l, r;
 
       l = mdctSpectrumLeft[j] >> 1;
@@ -86,17 +86,17 @@
       accuMid = L_add(accuMid, MULHIGH(specm, specm));
       accuSide = L_add(accuSide, MULHIGH(specs, specs));
     }
-    
+
 	accuMid = L_add(accuMid, accuMid);
 	accuSide = L_add(accuSide, accuSide);
-	bandEnergyMid[i] = accuMid;                                  
+	bandEnergyMid[i] = accuMid;
     accuMidSum = L_add(accuMidSum, accuMid);
-    bandEnergySide[i] = accuSide;                                
+    bandEnergySide[i] = accuSide;
     accuSideSum = L_add(accuSideSum, accuSide);
-    
+
   }
-  *bandEnergyMidSum = accuMidSum;                                
-  *bandEnergySideSum = accuSideSum;                              
+  *bandEnergyMidSum = accuMidSum;
+  *bandEnergySideSum = accuSideSum;
 }
 
 #endif
\ No newline at end of file
diff --git a/media/libstagefright/codecs/aacenc/src/bit_cnt.c b/media/libstagefright/codecs/aacenc/src/bit_cnt.c
index 8853efc..9fe511cd 100644
--- a/media/libstagefright/codecs/aacenc/src/bit_cnt.c
+++ b/media/libstagefright/codecs/aacenc/src/bit_cnt.c
@@ -26,14 +26,14 @@
 #define HI_LTAB(a) (a>>8)
 #define LO_LTAB(a) (a & 0xff)
 
-#define EXPAND(a)  ((((Word32)(a&0xff00)) << 8)|(Word32)(a&0xff)) 
+#define EXPAND(a)  ((((Word32)(a&0xff00)) << 8)|(Word32)(a&0xff))
 
 
 /*****************************************************************************
 *
 * function name: count1_2_3_4_5_6_7_8_9_10_11
-* description:  counts tables 1-11 
-* returns:      
+* description:  counts tables 1-11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 1-11
 *
@@ -46,51 +46,51 @@
   Word32 t0,t1,t2,t3,i;
   Word32 bc1_2,bc3_4,bc5_6,bc7_8,bc9_10;
   Word16 bc11,sc;
-  
-  bc1_2=0;                               
-  bc3_4=0;                               
-  bc5_6=0;                               
-  bc7_8=0;                               
-  bc9_10=0;                              
-  bc11=0;                                
-  sc=0;                                  
+
+  bc1_2=0;
+  bc3_4=0;
+  bc5_6=0;
+  bc7_8=0;
+  bc9_10=0;
+  bc11=0;
+  sc=0;
 
   for(i=0;i<width;i+=4){
-    
-    t0= values[i+0];                     
-    t1= values[i+1];                     
-    t2= values[i+2];                     
-    t3= values[i+3];                     
-  
+
+    t0= values[i+0];
+    t1= values[i+1];
+    t2= values[i+2];
+    t3= values[i+3];
+
     /* 1,2 */
 
-    bc1_2 = bc1_2 + EXPAND(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);              
+    bc1_2 = bc1_2 + EXPAND(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);
 
     /* 5,6 */
-    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);                          
-    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t2+4][t3+4]);                          
+    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);
+    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t2+4][t3+4]);
 
     t0=ABS(t0);
     t1=ABS(t1);
     t2=ABS(t2);
     t3=ABS(t3);
 
-    
-    bc3_4 = bc3_4 + EXPAND(huff_ltab3_4[t0][t1][t2][t3]);                      
-    
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);                              
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t2][t3]);                              
-    
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);                           
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t2][t3]);                           
-    
+
+    bc3_4 = bc3_4 + EXPAND(huff_ltab3_4[t0][t1][t2][t3]);
+
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t2][t3]);
+
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t2][t3]);
+
     bc11 = bc11 + huff_ltab11[t0][t1];
     bc11 = bc11 + huff_ltab11[t2][t3];
-   
-           
+
+
     sc = sc + (t0>0) + (t1>0) + (t2>0) + (t3>0);
   }
-  
+
   bitCount[1]=extract_h(bc1_2);
   bitCount[2]=extract_l(bc1_2);
   bitCount[3]=extract_h(bc3_4) + sc;
@@ -108,8 +108,8 @@
 /*****************************************************************************
 *
 * function name: count3_4_5_6_7_8_9_10_11
-* description:  counts tables 3-11 
-* returns:      
+* description:  counts tables 3-11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 3-11
 *
@@ -122,26 +122,26 @@
   Word32 t0,t1,t2,t3, i;
   Word32 bc3_4,bc5_6,bc7_8,bc9_10;
   Word16 bc11,sc;
-    
-  bc3_4=0;                               
-  bc5_6=0;                               
-  bc7_8=0;                               
-  bc9_10=0;                              
-  bc11=0;                                
-  sc=0;                                  
+
+  bc3_4=0;
+  bc5_6=0;
+  bc7_8=0;
+  bc9_10=0;
+  bc11=0;
+  sc=0;
 
   for(i=0;i<width;i+=4){
 
-    t0= values[i+0];                     
-    t1= values[i+1];                     
-    t2= values[i+2];                     
-    t3= values[i+3];                     
-    
+    t0= values[i+0];
+    t1= values[i+1];
+    t2= values[i+2];
+    t3= values[i+3];
+
     /*
       5,6
     */
-    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);                          
-    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t2+4][t3+4]);                          
+    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);
+    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t2+4][t3+4]);
 
     t0=ABS(t0);
     t1=ABS(t1);
@@ -149,23 +149,23 @@
     t3=ABS(t3);
 
 
-    bc3_4 = bc3_4 + EXPAND(huff_ltab3_4[t0][t1][t2][t3]);                      
-                                                                                                                
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);                              
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t2][t3]);                              
-    
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);                           
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t2][t3]);                           
-                                                                                                                
+    bc3_4 = bc3_4 + EXPAND(huff_ltab3_4[t0][t1][t2][t3]);
+
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t2][t3]);
+
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t2][t3]);
+
     bc11 = bc11 + huff_ltab11[t0][t1];
     bc11 = bc11 + huff_ltab11[t2][t3];
 
-           
-    sc = sc + (t0>0) + (t1>0) + (t2>0) + (t3>0);   
+
+    sc = sc + (t0>0) + (t1>0) + (t2>0) + (t3>0);
   }
-  
-  bitCount[1]=INVALID_BITCOUNT;                          
-  bitCount[2]=INVALID_BITCOUNT;                          
+
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
   bitCount[3]=extract_h(bc3_4) + sc;
   bitCount[4]=extract_l(bc3_4) + sc;
   bitCount[5]=extract_h(bc5_6);
@@ -175,7 +175,7 @@
   bitCount[9]=extract_h(bc9_10) + sc;
   bitCount[10]=extract_l(bc9_10) + sc;
   bitCount[11]=bc11 + sc;
-  
+
 }
 
 
@@ -183,8 +183,8 @@
 /*****************************************************************************
 *
 * function name: count5_6_7_8_9_10_11
-* description:  counts tables 5-11 
-* returns:      
+* description:  counts tables 5-11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 5-11
 *
@@ -198,33 +198,33 @@
   Word32 bc5_6,bc7_8,bc9_10;
   Word16 bc11,sc;
 
-  bc5_6=0;                               
-  bc7_8=0;                               
-  bc9_10=0;                              
-  bc11=0;                                
-  sc=0;                                  
+  bc5_6=0;
+  bc7_8=0;
+  bc9_10=0;
+  bc11=0;
+  sc=0;
 
   for(i=0;i<width;i+=2){
 
-    t0 = values[i+0];                    
-    t1 = values[i+1];                    
+    t0 = values[i+0];
+    t1 = values[i+1];
 
-    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);                  
+    bc5_6 = bc5_6 + EXPAND(huff_ltab5_6[t0+4][t1+4]);
 
     t0=ABS(t0);
     t1=ABS(t1);
-     
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);                      
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);                   
+
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);
     bc11 = bc11 + huff_ltab11[t0][t1];
-    
-       
+
+
     sc = sc + (t0>0) + (t1>0);
   }
-  bitCount[1]=INVALID_BITCOUNT;                          
-  bitCount[2]=INVALID_BITCOUNT;                          
-  bitCount[3]=INVALID_BITCOUNT;                          
-  bitCount[4]=INVALID_BITCOUNT;                          
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
+  bitCount[3]=INVALID_BITCOUNT;
+  bitCount[4]=INVALID_BITCOUNT;
   bitCount[5]=extract_h(bc5_6);
   bitCount[6]=extract_l(bc5_6);
   bitCount[7]=extract_h(bc7_8) + sc;
@@ -232,15 +232,15 @@
   bitCount[9]=extract_h(bc9_10) + sc;
   bitCount[10]=extract_l(bc9_10) + sc;
   bitCount[11]=bc11 + sc;
-  
+
 }
 
 
 /*****************************************************************************
 *
 * function name: count7_8_9_10_11
-* description:  counts tables 7-11 
-* returns:      
+* description:  counts tables 7-11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 7-11
 *
@@ -253,43 +253,43 @@
   Word32 t0,t1, i;
   Word32 bc7_8,bc9_10;
   Word16 bc11,sc;
-    
-  bc7_8=0;                       
-  bc9_10=0;                      
-  bc11=0;                        
-  sc=0;                          
+
+  bc7_8=0;
+  bc9_10=0;
+  bc11=0;
+  sc=0;
 
   for(i=0;i<width;i+=2){
 
     t0=ABS(values[i+0]);
     t1=ABS(values[i+1]);
 
-    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);                      
-    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);                   
+    bc7_8 = bc7_8 + EXPAND(huff_ltab7_8[t0][t1]);
+    bc9_10 = bc9_10 + EXPAND(huff_ltab9_10[t0][t1]);
     bc11 = bc11 + huff_ltab11[t0][t1];
-   
-       
+
+
     sc = sc + (t0>0) + (t1>0);
   }
-  bitCount[1]=INVALID_BITCOUNT;                  
-  bitCount[2]=INVALID_BITCOUNT;                  
-  bitCount[3]=INVALID_BITCOUNT;                  
-  bitCount[4]=INVALID_BITCOUNT;                  
-  bitCount[5]=INVALID_BITCOUNT;                  
-  bitCount[6]=INVALID_BITCOUNT;                  
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
+  bitCount[3]=INVALID_BITCOUNT;
+  bitCount[4]=INVALID_BITCOUNT;
+  bitCount[5]=INVALID_BITCOUNT;
+  bitCount[6]=INVALID_BITCOUNT;
   bitCount[7]=extract_h(bc7_8) + sc;
   bitCount[8]=extract_l(bc7_8) + sc;
   bitCount[9]=extract_h(bc9_10) + sc;
   bitCount[10]=extract_l(bc9_10) + sc;
   bitCount[11]=bc11 + sc;
-  
+
 }
 
 /*****************************************************************************
 *
 * function name: count9_10_11
-* description:  counts tables 9-11 
-* returns:      
+* description:  counts tables 9-11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 9-11
 *
@@ -299,45 +299,45 @@
                          Word16       *bitCount)
 {
 
-  Word32 t0,t1,i;  
+  Word32 t0,t1,i;
   Word32 bc9_10;
   Word16 bc11,sc;
 
-  bc9_10=0;                              
-  bc11=0;                                
-  sc=0;                                  
+  bc9_10=0;
+  bc11=0;
+  sc=0;
 
   for(i=0;i<width;i+=2){
 
     t0=ABS(values[i+0]);
     t1=ABS(values[i+1]);
-    
 
-    bc9_10 += EXPAND(huff_ltab9_10[t0][t1]);           
+
+    bc9_10 += EXPAND(huff_ltab9_10[t0][t1]);
     bc11 = bc11 + huff_ltab11[t0][t1];
 
-       
+
     sc = sc + (t0>0) + (t1>0);
   }
-  bitCount[1]=INVALID_BITCOUNT;          
-  bitCount[2]=INVALID_BITCOUNT;          
-  bitCount[3]=INVALID_BITCOUNT;          
-  bitCount[4]=INVALID_BITCOUNT;          
-  bitCount[5]=INVALID_BITCOUNT;          
-  bitCount[6]=INVALID_BITCOUNT;          
-  bitCount[7]=INVALID_BITCOUNT;          
-  bitCount[8]=INVALID_BITCOUNT;          
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
+  bitCount[3]=INVALID_BITCOUNT;
+  bitCount[4]=INVALID_BITCOUNT;
+  bitCount[5]=INVALID_BITCOUNT;
+  bitCount[6]=INVALID_BITCOUNT;
+  bitCount[7]=INVALID_BITCOUNT;
+  bitCount[8]=INVALID_BITCOUNT;
   bitCount[9]=extract_h(bc9_10) + sc;
   bitCount[10]=extract_l(bc9_10) + sc;
   bitCount[11]=bc11 + sc;
-  
+
 }
- 
+
 /*****************************************************************************
 *
 * function name: count11
-* description:  counts table 11 
-* returns:      
+* description:  counts table 11
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for table 11
 *
@@ -347,37 +347,37 @@
                     Word16        *bitCount)
 {
   Word32 t0,t1,i;
-  Word16 bc11,sc;  
+  Word16 bc11,sc;
 
-  bc11=0;                        
-  sc=0;                          
+  bc11=0;
+  sc=0;
   for(i=0;i<width;i+=2){
     t0=ABS(values[i+0]);
     t1=ABS(values[i+1]);
     bc11 = bc11 + huff_ltab11[t0][t1];
 
-       
+
     sc = sc + (t0>0) + (t1>0);
   }
 
-  bitCount[1]=INVALID_BITCOUNT;                  
-  bitCount[2]=INVALID_BITCOUNT;                  
-  bitCount[3]=INVALID_BITCOUNT;                  
-  bitCount[4]=INVALID_BITCOUNT;                  
-  bitCount[5]=INVALID_BITCOUNT;                  
-  bitCount[6]=INVALID_BITCOUNT;                  
-  bitCount[7]=INVALID_BITCOUNT;                  
-  bitCount[8]=INVALID_BITCOUNT;                  
-  bitCount[9]=INVALID_BITCOUNT;                  
-  bitCount[10]=INVALID_BITCOUNT;                 
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
+  bitCount[3]=INVALID_BITCOUNT;
+  bitCount[4]=INVALID_BITCOUNT;
+  bitCount[5]=INVALID_BITCOUNT;
+  bitCount[6]=INVALID_BITCOUNT;
+  bitCount[7]=INVALID_BITCOUNT;
+  bitCount[8]=INVALID_BITCOUNT;
+  bitCount[9]=INVALID_BITCOUNT;
+  bitCount[10]=INVALID_BITCOUNT;
   bitCount[11]=bc11 + sc;
 }
 
 /*****************************************************************************
 *
 * function name: countEsc
-* description:  counts table 11 (with Esc) 
-* returns:      
+* description:  counts table 11 (with Esc)
+* returns:
 * input:        quantized spectrum
 * output:       bitCount for tables 11 (with Esc)
 *
@@ -388,31 +388,31 @@
                      Word16       *bitCount)
 {
   Word32 t0,t1,t00,t01,i;
-  Word16 bc11,ec,sc;  
+  Word16 bc11,ec,sc;
 
-  bc11=0;                                
-  sc=0;                                  
-  ec=0;                                  
+  bc11=0;
+  sc=0;
+  ec=0;
   for(i=0;i<width;i+=2){
     t0=ABS(values[i+0]);
     t1=ABS(values[i+1]);
-    
-       
+
+
     sc = sc + (t0>0) + (t1>0);
 
     t00 = min(t0,16);
     t01 = min(t1,16);
     bc11 = bc11 + huff_ltab11[t00][t01];
-    
-     
+
+
     if(t0 >= 16){
       ec = ec + 5;
       while(sub(t0=(t0 >> 1), 16) >= 0) {
         ec = ec + 2;
       }
     }
-    
-     
+
+
     if(t1 >= 16){
       ec = ec + 5;
       while(sub(t1=(t1 >> 1), 16) >= 0) {
@@ -420,16 +420,16 @@
       }
     }
   }
-  bitCount[1]=INVALID_BITCOUNT;          
-  bitCount[2]=INVALID_BITCOUNT;          
-  bitCount[3]=INVALID_BITCOUNT;          
-  bitCount[4]=INVALID_BITCOUNT;          
-  bitCount[5]=INVALID_BITCOUNT;          
-  bitCount[6]=INVALID_BITCOUNT;          
-  bitCount[7]=INVALID_BITCOUNT;          
-  bitCount[8]=INVALID_BITCOUNT;          
-  bitCount[9]=INVALID_BITCOUNT;          
-  bitCount[10]=INVALID_BITCOUNT;         
+  bitCount[1]=INVALID_BITCOUNT;
+  bitCount[2]=INVALID_BITCOUNT;
+  bitCount[3]=INVALID_BITCOUNT;
+  bitCount[4]=INVALID_BITCOUNT;
+  bitCount[5]=INVALID_BITCOUNT;
+  bitCount[6]=INVALID_BITCOUNT;
+  bitCount[7]=INVALID_BITCOUNT;
+  bitCount[8]=INVALID_BITCOUNT;
+  bitCount[9]=INVALID_BITCOUNT;
+  bitCount[10]=INVALID_BITCOUNT;
   bitCount[11]=bc11 + sc + ec;
 }
 
@@ -463,7 +463,7 @@
 /*****************************************************************************
 *
 * function name: bitCount
-* description:  count bits 
+* description:  count bits
 *
 *****************************************************************************/
 Word16 bitCount(const Word16 *values,
@@ -474,7 +474,7 @@
   /*
     check if we can use codebook 0
   */
-     
+
   if(maxVal == 0)
     bitCount[0] = 0;
   else
@@ -489,7 +489,7 @@
 /*****************************************************************************
 *
 * function name: codeValues
-* description:  write huffum bits 
+* description:  write huffum bits
 *
 *****************************************************************************/
 Word16 codeValues(Word16 *values, Word16 width, Word16 codeBook, HANDLE_BIT_BUF hBitstream)
@@ -499,85 +499,85 @@
   UWord16 codeWord, codeLength;
   Word16 sign, signLength;
 
-   
+
   switch (codeBook) {
     case CODE_BOOK_ZERO_NO:
       break;
 
     case CODE_BOOK_1_NO:
       for(i=0; i<width; i+=4) {
-        t0         = values[i+0];                                        
-        t1         = values[i+1];                                        
-        t2         = values[i+2];                                        
-        t3         = values[i+3];                                        
-        codeWord   = huff_ctab1[t0+1][t1+1][t2+1][t3+1];                 
-        codeLength = HI_LTAB(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);      
-        WriteBits(hBitstream, codeWord, codeLength);        
+        t0         = values[i+0];
+        t1         = values[i+1];
+        t2         = values[i+2];
+        t3         = values[i+3];
+        codeWord   = huff_ctab1[t0+1][t1+1][t2+1][t3+1];
+        codeLength = HI_LTAB(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);
+        WriteBits(hBitstream, codeWord, codeLength);
       }
       break;
 
     case CODE_BOOK_2_NO:
       for(i=0; i<width; i+=4) {
-        t0         = values[i+0];                                        
-        t1         = values[i+1];                                        
-        t2         = values[i+2];                                        
-        t3         = values[i+3];                                        
-        codeWord   = huff_ctab2[t0+1][t1+1][t2+1][t3+1];                 
-        codeLength = LO_LTAB(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);      
+        t0         = values[i+0];
+        t1         = values[i+1];
+        t2         = values[i+2];
+        t3         = values[i+3];
+        codeWord   = huff_ctab2[t0+1][t1+1][t2+1][t3+1];
+        codeLength = LO_LTAB(huff_ltab1_2[t0+1][t1+1][t2+1][t3+1]);
         WriteBits(hBitstream,codeWord,codeLength);
       }
       break;
 
     case CODE_BOOK_3_NO:
       for(i=0; i<width; i+=4) {
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-         
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
         if(t0 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t0 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t0=-t0;
           }
         }
-        t1 = values[i+1];                                                
-         
+        t1 = values[i+1];
+
         if(t1 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t1 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t1=-t1;
           }
         }
-        t2 = values[i+2];                                                
-         
+        t2 = values[i+2];
+
         if(t2 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t2 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t2=-t2;
           }
         }
-        t3 = values[i+3];                                                
+        t3 = values[i+3];
         if(t3 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t3 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t3=-t3;
           }
         }
 
-        codeWord   = huff_ctab3[t0][t1][t2][t3];                         
-        codeLength = HI_LTAB(huff_ltab3_4[t0][t1][t2][t3]);              
+        codeWord   = huff_ctab3[t0][t1][t2][t3];
+        codeLength = HI_LTAB(huff_ltab3_4[t0][t1][t2][t3]);
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
       }
@@ -585,107 +585,107 @@
 
     case CODE_BOOK_4_NO:
       for(i=0; i<width; i+=4) {
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-         
-        if(t0 != 0){                                                             
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
+        if(t0 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-          if(t0 < 0){                                                            
-            sign|=1;                                                     
-            t0=-t0;                                                          
+          sign = sign << 1;
+          if(t0 < 0){
+            sign|=1;
+            t0=-t0;
           }
-        }                                                                        
-        t1 = values[i+1];                                                
-         
-        if(t1 != 0){                                                             
+        }
+        t1 = values[i+1];
+
+        if(t1 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
-          if(t1 < 0){                                                            
-            sign|=1;                                                     
-            t1=-t1;                                                          
-          }                                                                      
-        }                                                                        
-        t2 = values[i+2];                                                
-         
-        if(t2 != 0){                                                    
+          sign = sign << 1;
+
+          if(t1 < 0){
+            sign|=1;
+            t1=-t1;
+          }
+        }
+        t2 = values[i+2];
+
+        if(t2 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
-          if(t2 < 0){                                                   
-            sign|=1;                                                     
-            t2=-t2;                                                 
-          }                                                             
-        }                                                               
-        t3 = values[i+3];                                                
-         
-        if(t3 != 0){                                                    
+          sign = sign << 1;
+
+          if(t2 < 0){
+            sign|=1;
+            t2=-t2;
+          }
+        }
+        t3 = values[i+3];
+
+        if(t3 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
-          if(t3 < 0){                                                   
-            sign|=1;                                                     
-            t3=-t3;                                                 
-          }                                                             
-        }                                                               
-        codeWord   = huff_ctab4[t0][t1][t2][t3];                         
-        codeLength = LO_LTAB(huff_ltab3_4[t0][t1][t2][t3]);              
-        WriteBits(hBitstream,codeWord,codeLength);                      
-        WriteBits(hBitstream,sign,signLength);                          
-      }                                                                 
-      break;                                                            
-                                                                        
-    case CODE_BOOK_5_NO:                                                
-      for(i=0; i<width; i+=2) {                                         
-        t0         = values[i+0];                                         
-        t1         = values[i+1];                                        
-        codeWord   = huff_ctab5[t0+4][t1+4];                             
-        codeLength = HI_LTAB(huff_ltab5_6[t0+4][t1+4]);                  
+          sign = sign << 1;
+
+          if(t3 < 0){
+            sign|=1;
+            t3=-t3;
+          }
+        }
+        codeWord   = huff_ctab4[t0][t1][t2][t3];
+        codeLength = LO_LTAB(huff_ltab3_4[t0][t1][t2][t3]);
+        WriteBits(hBitstream,codeWord,codeLength);
+        WriteBits(hBitstream,sign,signLength);
+      }
+      break;
+
+    case CODE_BOOK_5_NO:
+      for(i=0; i<width; i+=2) {
+        t0         = values[i+0];
+        t1         = values[i+1];
+        codeWord   = huff_ctab5[t0+4][t1+4];
+        codeLength = HI_LTAB(huff_ltab5_6[t0+4][t1+4]);
         WriteBits(hBitstream,codeWord,codeLength);
       }
       break;
 
     case CODE_BOOK_6_NO:
       for(i=0; i<width; i+=2) {
-        t0         = values[i+0];                                        
-        t1         = values[i+1];                                        
-        codeWord   = huff_ctab6[t0+4][t1+4];                             
-        codeLength = LO_LTAB(huff_ltab5_6[t0+4][t1+4]);                  
+        t0         = values[i+0];
+        t1         = values[i+1];
+        codeWord   = huff_ctab6[t0+4][t1+4];
+        codeLength = LO_LTAB(huff_ltab5_6[t0+4][t1+4]);
         WriteBits(hBitstream,codeWord,codeLength);
       }
       break;
 
     case CODE_BOOK_7_NO:
       for(i=0; i<width; i+=2){
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-         
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
         if(t0 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t0 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t0=-t0;
           }
         }
 
-        t1 = values[i+1];                                                
-         
+        t1 = values[i+1];
+
         if(t1 != 0){
           signLength = signLength + 1;
-          sign = sign << 1; 
-           
+          sign = sign << 1;
+
           if(t1 < 0){
-            sign|=1;                                                     
+            sign|=1;
             t1=-t1;
           }
         }
-        codeWord   = huff_ctab7[t0][t1];                                 
-        codeLength = HI_LTAB(huff_ltab7_8[t0][t1]);                      
+        codeWord   = huff_ctab7[t0][t1];
+        codeLength = HI_LTAB(huff_ltab7_8[t0][t1]);
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
       }
@@ -693,33 +693,33 @@
 
     case CODE_BOOK_8_NO:
       for(i=0; i<width; i+=2) {
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-                                                                           
-        if(t0 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t0 < 0){                                                            
-            sign|=1;                                                     
-            t0=-t0;                                                        
-          }                                                                      
-        }                                                                        
-                                                                                 
-        t1 = values[i+1];                                                
-                                                                           
-        if(t1 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t1 < 0){                                                            
-            sign|=1;                                                     
-            t1=-t1;                                                        
-          }                                                                      
-        }                                                                        
-        codeWord   = huff_ctab8[t0][t1];                                 
-        codeLength = LO_LTAB(huff_ltab7_8[t0][t1]);                      
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
+        if(t0 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t0 < 0){
+            sign|=1;
+            t0=-t0;
+          }
+        }
+
+        t1 = values[i+1];
+
+        if(t1 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t1 < 0){
+            sign|=1;
+            t1=-t1;
+          }
+        }
+        codeWord   = huff_ctab8[t0][t1];
+        codeLength = LO_LTAB(huff_ltab7_8[t0][t1]);
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
       }
@@ -727,33 +727,33 @@
 
     case CODE_BOOK_9_NO:
       for(i=0; i<width; i+=2) {
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-                                                                           
-        if(t0 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t0 < 0){                                                            
-            sign|=1;                                                     
-            t0=-t0;                                                        
-          }                                                                      
-        }                                                                        
-                                                                                 
-        t1 = values[i+1];                                                
-                                                                           
-        if(t1 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t1 < 0){                                                            
-            sign|=1;                                                     
-            t1=-t1;                                                        
-          }                                                                      
-        }                                                                        
-        codeWord   = huff_ctab9[t0][t1];                                 
-        codeLength = HI_LTAB(huff_ltab9_10[t0][t1]);                     
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
+        if(t0 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t0 < 0){
+            sign|=1;
+            t0=-t0;
+          }
+        }
+
+        t1 = values[i+1];
+
+        if(t1 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t1 < 0){
+            sign|=1;
+            t1=-t1;
+          }
+        }
+        codeWord   = huff_ctab9[t0][t1];
+        codeLength = HI_LTAB(huff_ltab9_10[t0][t1]);
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
       }
@@ -761,33 +761,33 @@
 
     case CODE_BOOK_10_NO:
       for(i=0; i<width; i+=2) {
-        sign=0;                                                          
-        signLength=0;                                                    
-        t0 = values[i+0];                                                
-                                                                           
-        if(t0 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t0 < 0){                                                            
-            sign|=1;                                                     
-            t0=-t0;                                                        
-          }                                                                      
-        }                                                                        
-                                                                                 
-        t1 = values[i+1];                                                
-                                                                           
-        if(t1 != 0){                                                             
-          signLength = signLength + 1;                                       
-          sign = sign << 1;                                                   
-                                                                           
-          if(t1 < 0){                                                            
-            sign|=1;                                                     
-            t1=-t1;                                                        
-          }                                                                      
-        }                                                                        
-        codeWord   = huff_ctab10[t0][t1];                                
-        codeLength = LO_LTAB(huff_ltab9_10[t0][t1]);                     
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
+        if(t0 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t0 < 0){
+            sign|=1;
+            t0=-t0;
+          }
+        }
+
+        t1 = values[i+1];
+
+        if(t1 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t1 < 0){
+            sign|=1;
+            t1=-t1;
+          }
+        }
+        codeWord   = huff_ctab10[t0][t1];
+        codeLength = LO_LTAB(huff_ltab9_10[t0][t1]);
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
       }
@@ -795,45 +795,45 @@
 
     case CODE_BOOK_ESC_NO:
       for(i=0; i<width; i+=2) {
-        sign=0;                                                  
-        signLength=0;                                            
-        t0 = values[i+0];                                        
-                                                                   
-        if(t0 != 0){                                                     
-          signLength = signLength + 1;                               
-          sign = sign << 1;                                           
-                                                                   
-          if(t0 < 0){                                                    
-            sign|=1;                                             
-            t0=-t0;                                                
-          }                                                              
-        }                                                                
-                                                                         
-        t1 = values[i+1];                                        
-                                                                   
-        if(t1 != 0){                                                     
-          signLength = signLength + 1;                               
-          sign = sign << 1;                                           
-                                                                   
-          if(t1 < 0){                                                    
-            sign|=1;                                             
-            t1=-t1;                                                
-          }                                                              
-        }                                                                
+        sign=0;
+        signLength=0;
+        t0 = values[i+0];
+
+        if(t0 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t0 < 0){
+            sign|=1;
+            t0=-t0;
+          }
+        }
+
+        t1 = values[i+1];
+
+        if(t1 != 0){
+          signLength = signLength + 1;
+          sign = sign << 1;
+
+          if(t1 < 0){
+            sign|=1;
+            t1=-t1;
+          }
+        }
         t00 = min(t0,16);
         t01 = min(t1,16);
 
-        codeWord   = huff_ctab11[t00][t01];                      
-        codeLength = huff_ltab11[t00][t01];                      
+        codeWord   = huff_ctab11[t00][t01];
+        codeLength = huff_ltab11[t00][t01];
         WriteBits(hBitstream,codeWord,codeLength);
         WriteBits(hBitstream,sign,signLength);
-         
+
         if(t0 >= 16){
           Word16 n, p;
-          n=0;                                                   
-          p=t0;                                                  
+          n=0;
+          p=t0;
           while(sub(p=(p >> 1), 16) >= 0){
-             
+
             WriteBits(hBitstream,1,1);
             n = n + 1;
           }
@@ -841,13 +841,13 @@
           n = n + 4;
           WriteBits(hBitstream,(t0 - (1 << n)),n);
         }
-         
+
         if(t1 >= 16){
           Word16 n, p;
-          n=0;                                                   
-          p=t1;                                                  
+          n=0;
+          p=t1;
           while(sub(p=(p >> 1), 16) >= 0){
-             
+
             WriteBits(hBitstream,1,1);
             n = n + 1;
           }
@@ -871,15 +871,15 @@
 
 Word16 codeScalefactorDelta(Word16 delta, HANDLE_BIT_BUF hBitstream)
 {
-  Word32 codeWord; 
+  Word32 codeWord;
   Word16 codeLength;
-  
-   
+
+
   if(delta > CODE_BOOK_SCF_LAV || delta < -CODE_BOOK_SCF_LAV)
     return(1);
-  
-  codeWord   = huff_ctabscf[delta + CODE_BOOK_SCF_LAV];            
-  codeLength = huff_ltabscf[delta + CODE_BOOK_SCF_LAV];            
+
+  codeWord   = huff_ctabscf[delta + CODE_BOOK_SCF_LAV];
+  codeLength = huff_ltabscf[delta + CODE_BOOK_SCF_LAV];
   WriteBits(hBitstream,codeWord,codeLength);
   return(0);
 }
diff --git a/media/libstagefright/codecs/aacenc/src/bitbuffer.c b/media/libstagefright/codecs/aacenc/src/bitbuffer.c
index ef13c13..5615ac3 100644
--- a/media/libstagefright/codecs/aacenc/src/bitbuffer.c
+++ b/media/libstagefright/codecs/aacenc/src/bitbuffer.c
@@ -32,15 +32,15 @@
                                 UWord8 **pBitBufWord,
                                 Word16   cnt)
 {
-  *pBitBufWord += cnt;                                                                  
+  *pBitBufWord += cnt;
 
-                                                                                        
+
   if(*pBitBufWord > hBitBuf->pBitBufEnd) {
-    *pBitBufWord -= (hBitBuf->pBitBufEnd - hBitBuf->pBitBufBase + 1);                   
+    *pBitBufWord -= (hBitBuf->pBitBufEnd - hBitBuf->pBitBufBase + 1);
   }
-                                                                                        
+
   if(*pBitBufWord < hBitBuf->pBitBufBase) {
-    *pBitBufWord += (hBitBuf->pBitBufEnd - hBitBuf->pBitBufBase + 1);                   
+    *pBitBufWord += (hBitBuf->pBitBufEnd - hBitBuf->pBitBufBase + 1);
   }
 }
 
@@ -57,18 +57,18 @@
 {
   assert(bitBufSize*8 <= 32768);
 
-  hBitBuf->pBitBufBase = pBitBufBase;                                                    
-  hBitBuf->pBitBufEnd  = pBitBufBase + bitBufSize - 1;                                  
+  hBitBuf->pBitBufBase = pBitBufBase;
+  hBitBuf->pBitBufEnd  = pBitBufBase + bitBufSize - 1;
 
-  hBitBuf->pWriteNext  = pBitBufBase;                                                    
+  hBitBuf->pWriteNext  = pBitBufBase;
 
   hBitBuf->cache       = 0;
-  
-  hBitBuf->wBitPos     = 0;                                                              
-  hBitBuf->cntBits     = 0;   
-  
-  hBitBuf->size        = (bitBufSize << 3);                                             
-  hBitBuf->isValid     = 1;                                                              
+
+  hBitBuf->wBitPos     = 0;
+  hBitBuf->cntBits     = 0;
+
+  hBitBuf->size        = (bitBufSize << 3);
+  hBitBuf->isValid     = 1;
 
   return hBitBuf;
 }
@@ -82,8 +82,8 @@
 void DeleteBitBuffer(HANDLE_BIT_BUF *hBitBuf)
 {
   if(*hBitBuf)
-	(*hBitBuf)->isValid = 0;                                                               
-  *hBitBuf = NULL;                                                                       
+	(*hBitBuf)->isValid = 0;
+  *hBitBuf = NULL;
 }
 
 /*****************************************************************************
@@ -96,15 +96,15 @@
                  UWord8 *pBitBufBase,
                  Word16  bitBufSize)
 {
-  hBitBuf->pBitBufBase = pBitBufBase;                                                    
-  hBitBuf->pBitBufEnd  = pBitBufBase + bitBufSize - 1;                                  
+  hBitBuf->pBitBufBase = pBitBufBase;
+  hBitBuf->pBitBufEnd  = pBitBufBase + bitBufSize - 1;
 
-                                                 
-  hBitBuf->pWriteNext  = pBitBufBase;                                                    
 
-  hBitBuf->wBitPos     = 0;    
-  hBitBuf->cntBits     = 0;    
-  
+  hBitBuf->pWriteNext  = pBitBufBase;
+
+  hBitBuf->wBitPos     = 0;
+  hBitBuf->cntBits     = 0;
+
   hBitBuf->cache	   = 0;
 }
 
@@ -117,7 +117,7 @@
 void CopyBitBuf(HANDLE_BIT_BUF hBitBufSrc,
                 HANDLE_BIT_BUF hBitBufDst)
 {
-  *hBitBufDst = *hBitBufSrc;                                                             
+  *hBitBufDst = *hBitBufSrc;
 }
 
 /*****************************************************************************
@@ -148,25 +148,25 @@
   if(noBitsToWrite == 0)
 	  return noBitsToWrite;
 
-  hBitBuf->cntBits += noBitsToWrite;   
+  hBitBuf->cntBits += noBitsToWrite;
 
   wBitPos = hBitBuf->wBitPos;
   wBitPos += noBitsToWrite;
-  writeValue <<= 32 - wBitPos;	
+  writeValue <<= 32 - wBitPos;
   writeValue |= hBitBuf->cache;
-  
-  while (wBitPos >= 8) 
+
+  while (wBitPos >= 8)
   {
 	  UWord8 tmp;
 	  tmp = (UWord8)((writeValue >> 24) & 0xFF);
-	  
-	  *hBitBuf->pWriteNext++ = tmp;		
+
+	  *hBitBuf->pWriteNext++ = tmp;
 	  writeValue <<= 8;
 	  wBitPos -= 8;
   }
-  
+
   hBitBuf->wBitPos = wBitPos;
   hBitBuf->cache = writeValue;
-                                                                                     
+
   return noBitsToWrite;
 }
diff --git a/media/libstagefright/codecs/aacenc/src/bitenc.c b/media/libstagefright/codecs/aacenc/src/bitenc.c
index ea34407..fcc12dd 100644
--- a/media/libstagefright/codecs/aacenc/src/bitenc.c
+++ b/media/libstagefright/codecs/aacenc/src/bitenc.c
@@ -46,7 +46,7 @@
   Word16 i,sfb;
   Word16 dbgVal;
   SECTION_INFO* psectioninfo;
-  dbgVal = GetBitsAvail(hBitStream);                                     
+  dbgVal = GetBitsAvail(hBitStream);
 
   for(i=0; i<sectionData->noOfSections; i++) {
     psectioninfo = &(sectionData->sectionInfo[i]);
@@ -100,7 +100,7 @@
   WriteBits(hBitStream,blockType,2);
   WriteBits(hBitStream,windowShape,1);
 
-   
+
   switch(blockType){
     case LONG_WINDOW:
     case START_WINDOW:
@@ -137,30 +137,30 @@
   Word16 sectLen;
   Word16 i;
   Word16 dbgVal=GetBitsAvail(hBitStream);
-       
 
-   
+
+
   switch(sectionData->blockType)
   {
     case LONG_WINDOW:
     case START_WINDOW:
     case STOP_WINDOW:
-      sectEscapeVal = SECT_ESC_VAL_LONG;                 
-      sectLenBits   = SECT_BITS_LONG;                    
+      sectEscapeVal = SECT_ESC_VAL_LONG;
+      sectLenBits   = SECT_BITS_LONG;
       break;
 
     case SHORT_WINDOW:
-      sectEscapeVal = SECT_ESC_VAL_SHORT;                
-      sectLenBits   = SECT_BITS_SHORT;                   
+      sectEscapeVal = SECT_ESC_VAL_SHORT;
+      sectLenBits   = SECT_BITS_SHORT;
       break;
   }
 
   for(i=0;i<sectionData->noOfSections;i++) {
     WriteBits(hBitStream,sectionData->sectionInfo[i].codeBook,4);
-    sectLen = sectionData->sectionInfo[i].sfbCnt;        
+    sectLen = sectionData->sectionInfo[i].sfbCnt;
 
     while(sectLen >= sectEscapeVal) {
-       
+
       WriteBits(hBitStream,sectEscapeVal,sectLenBits);
       sectLen = sectLen - sectEscapeVal;
     }
@@ -183,24 +183,24 @@
 {
   Word16 i,j,lastValScf,deltaScf;
   Word16 dbgVal = GetBitsAvail(hBitStream);
-  SECTION_INFO* psectioninfo; 
+  SECTION_INFO* psectioninfo;
 
-  lastValScf=scalefac[sectionData->firstScf];                    
+  lastValScf=scalefac[sectionData->firstScf];
 
   for(i=0;i<sectionData->noOfSections;i++){
-    psectioninfo = &(sectionData->sectionInfo[i]); 
+    psectioninfo = &(sectionData->sectionInfo[i]);
     if (psectioninfo->codeBook != CODE_BOOK_ZERO_NO){
       for (j=psectioninfo->sfbStart;
            j<psectioninfo->sfbStart+psectioninfo->sfbCnt; j++){
-         
+
         if(maxValueInSfb[j] == 0) {
-          deltaScf = 0;                                          
+          deltaScf = 0;
         }
         else {
           deltaScf = lastValScf - scalefac[j];
-          lastValScf = scalefac[j];                              
+          lastValScf = scalefac[j];
         }
-         
+
         if(codeScalefactorDelta(deltaScf,hBitStream)){
           return(1);
         }
@@ -227,7 +227,7 @@
 {
   Word16 sfb, sfbOff;
 
-   
+
   switch(msDigest)
   {
     case MS_NONE:
@@ -242,7 +242,7 @@
       WriteBits(hBitStream,SI_MS_MASK_SOME,2);
       for(sfbOff = 0; sfbOff < sfbCnt; sfbOff+=grpSfb) {
         for(sfb=0; sfb<maxSfb; sfb++) {
-             
+
           if(jsFlags[sfbOff+sfb] & MS_ON) {
             WriteBits(hBitStream,1,1);
           }
@@ -272,7 +272,7 @@
   Word16 coefBits;
   Flag isShort;
 
-       
+
   if (blockType==2) {
     isShort = 1;
     numOfWindows = TRANS_FAC;
@@ -282,52 +282,52 @@
     numOfWindows = 1;
   }
 
-  tnsPresent=0;                                                  
+  tnsPresent=0;
   for (i=0; i<numOfWindows; i++) {
-     
+
     if (tnsInfo.tnsActive[i]) {
-      tnsPresent=1;                                              
+      tnsPresent=1;
     }
   }
-   
+
   if (tnsPresent==0) {
     WriteBits(hBitStream,0,1);
   }
   else{ /* there is data to be written*/
     WriteBits(hBitStream,1,1); /*data_present */
     for (i=0; i<numOfWindows; i++) {
-       
+
       WriteBits(hBitStream,tnsInfo.tnsActive[i],(isShort?1:2));
-       
+
       if (tnsInfo.tnsActive[i]) {
-         
+
         WriteBits(hBitStream,((tnsInfo.coefRes[i] - 4)==0?1:0),1);
-         
+
         WriteBits(hBitStream,tnsInfo.length[i],(isShort?4:6));
-         
+
         WriteBits(hBitStream,tnsInfo.order[i],(isShort?3:5));
-         
+
         if (tnsInfo.order[i]){
           WriteBits(hBitStream, FILTER_DIRECTION, 1);
-           
+
           if(tnsInfo.coefRes[i] == 4) {
-            coefBits = 3;                                                
+            coefBits = 3;
             for(k=0; k<tnsInfo.order[i]; k++) {
-                 
+
               if (tnsInfo.coef[i*TNS_MAX_ORDER_SHORT+k] > 3 ||
                   tnsInfo.coef[i*TNS_MAX_ORDER_SHORT+k] < -4) {
-                coefBits = 4;                                            
+                coefBits = 4;
                 break;
               }
             }
           }
           else {
-            coefBits = 2;                                                
+            coefBits = 2;
             for(k=0; k<tnsInfo.order[i]; k++) {
-                 
+
               if (tnsInfo.coef[i*TNS_MAX_ORDER_SHORT+k] > 1 ||
                   tnsInfo.coef[i*TNS_MAX_ORDER_SHORT+k] < -2) {
-                coefBits = 3;                                            
+                coefBits = 3;
                 break;
               }
             }
@@ -335,7 +335,7 @@
           WriteBits(hBitStream, tnsInfo.coefRes[i] - coefBits, 1); /*coef_compres*/
           for (k=0; k<tnsInfo.order[i]; k++ ) {
             static const Word16 rmask[] = {0,1,3,7,15};
-             
+
             WriteBits(hBitStream,tnsInfo.coef[i*TNS_MAX_ORDER_SHORT+k] & rmask[coefBits],coefBits);
           }
         }
@@ -397,7 +397,7 @@
 
   encodeGlobalGain(globalGain, logNorm,scf[sectionData->firstScf], hBitStream);
 
-   
+
   if(!commonWindow) {
     encodeIcsInfo(sectionData->blockType, windowShape, groupingMask, sectionData, hBitStream);
   }
@@ -536,7 +536,7 @@
     Write fill Element(s):
     amount of a fill element can be 7+X*8 Bits, X element of [0..270]
   */
-    
+
   while(totFillBits >= (3+4)) {
     cnt = min(((totFillBits - (3+4)) >> 3), ((1<<4)-1));
 
@@ -545,7 +545,7 @@
 
     totFillBits = totFillBits - (3+4);
 
-     
+
     if ((cnt == (1<<4)-1)) {
 
       esc_count = min( ((totFillBits >> 3) - ((1<<4)-1)), (1<<8)-1);
@@ -555,7 +555,7 @@
     }
 
     for(i=0;i<cnt;i++) {
-       
+
       if(ancBytes)
         WriteBits(hBitStream, *ancBytes++,8);
       else
@@ -576,7 +576,7 @@
                        ELEMENT_INFO elInfo,
                        QC_OUT *qcOut,
                        PSY_OUT *psyOut,
-                       Word16 *globUsedBits,					   
+                       Word16 *globUsedBits,
                        const UWord8 *ancBytes,
 					   Word16 sampindex
                        ) /* returns error code */
@@ -586,7 +586,7 @@
   Word16 frameBits=0;
 
   /*   struct bitbuffer bsWriteCopy; */
-  bitMarkUp = GetBitsAvail(hBitStream); 
+  bitMarkUp = GetBitsAvail(hBitStream);
   if(qcOut->qcElement.adtsUsed)  /*  write adts header*/
   {
 	  WriteBits(hBitStream, 0xFFF, 12); /* 12 bit Syncword */
@@ -601,23 +601,23 @@
 									6 channels or less, else a channel
 									configuration should be written */
 	  WriteBits(hBitStream, 0, 1); /* original/copy */
-	  WriteBits(hBitStream, 0, 1); /* home */	  
-	  
+	  WriteBits(hBitStream, 0, 1); /* home */
+
 	  /* Variable ADTS header */
 	  WriteBits(hBitStream, 0, 1); /* copyr. id. bit */
 	  WriteBits(hBitStream, 0, 1); /* copyr. id. start */
 	  WriteBits(hBitStream, *globUsedBits >> 3, 13);
 	  WriteBits(hBitStream, 0x7FF, 11); /* buffer fullness (0x7FF for VBR) */
-	  WriteBits(hBitStream, 0, 2); /* raw data blocks (0+1=1) */  
+	  WriteBits(hBitStream, 0, 2); /* raw data blocks (0+1=1) */
   }
 
-  *globUsedBits=0;                                               
+  *globUsedBits=0;
 
   {
 
     Word16 *sfbOffset[2];
     TNS_INFO tnsInfo[2];
-    elementUsedBits = 0;                                         
+    elementUsedBits = 0;
 
     switch (elInfo.elType) {
 
@@ -636,7 +636,7 @@
         {
           Word16 msDigest;
           Word16 *msFlags = psyOut->psyOutElement.toolsInfo.msMask;
-          msDigest = psyOut->psyOutElement.toolsInfo.msDigest;                        
+          msDigest = psyOut->psyOutElement.toolsInfo.msDigest;
           sfbOffset[0] =
             psyOut->psyOutChannel[elInfo.ChannelIndex[0]].sfbOffsets;
           sfbOffset[1] =
@@ -668,20 +668,20 @@
   }
 
   writeFillElement(NULL,
-                   qcOut->totFillBits, 
+                   qcOut->totFillBits,
                    hBitStream);
 
   WriteBits(hBitStream,ID_END,3);
 
   /* byte alignement */
-  WriteBits(hBitStream,0, (8 - (hBitStream->cntBits & 7)) & 7);          
-  
+  WriteBits(hBitStream,0, (8 - (hBitStream->cntBits & 7)) & 7);
+
   *globUsedBits = *globUsedBits- bitMarkUp;
-  bitMarkUp = GetBitsAvail(hBitStream);                                  
+  bitMarkUp = GetBitsAvail(hBitStream);
   *globUsedBits = *globUsedBits + bitMarkUp;
   frameBits = frameBits + *globUsedBits;
 
-   
+
   if (frameBits !=  (qcOut->totStaticBitsUsed+qcOut->totDynBitsUsed + qcOut->totAncBitsUsed +
                      qcOut->totFillBits + qcOut->alignBits)) {
     return(-1);
diff --git a/media/libstagefright/codecs/aacenc/src/block_switch.c b/media/libstagefright/codecs/aacenc/src/block_switch.c
index d54e32f..47fd15e 100644
--- a/media/libstagefright/codecs/aacenc/src/block_switch.c
+++ b/media/libstagefright/codecs/aacenc/src/block_switch.c
@@ -52,7 +52,7 @@
   IIR high pass coeffs
 */
 Word32 hiPassCoeff[BLOCK_SWITCHING_IIR_LEN] = {
-  0xbec8b439, 0x609d4952  /* -0.5095f, 0.7548f */ 
+  0xbec8b439, 0x609d4952  /* -0.5095f, 0.7548f */
 };
 
 static const Word32 accWindowNrgFac = 0x26666666;                   /* factor for accumulating filtered window energies 0.3 */
@@ -76,8 +76,8 @@
                           const Word32 bitRate, const Word16 nChannels)
 {
   /* select attackRatio */
-           
-  if ((sub(nChannels,1)==0 && L_sub(bitRate, 24000) > 0) || 
+
+  if ((sub(nChannels,1)==0 && L_sub(bitRate, 24000) > 0) ||
       (sub(nChannels,1)>0 && bitRate > (nChannels * 16000))) {
     blockSwitchingControl->invAttackRatio = invAttackRatioHighBr;
   }
@@ -116,7 +116,7 @@
 
   /* Reset grouping info */
   for (i=0; i<TRANS_FAC; i++) {
-    blockSwitchingControl->groupLen[i] = 0;                                      
+    blockSwitchingControl->groupLen[i] = 0;
   }
 
 
@@ -125,21 +125,21 @@
                                                           &blockSwitchingControl->attackIndex,
                                                           BLOCK_SWITCH_WINDOWS);
 
-  blockSwitchingControl->attackIndex = blockSwitchingControl->lastAttackIndex;   
+  blockSwitchingControl->attackIndex = blockSwitchingControl->lastAttackIndex;
 
   /* Set grouping info */
-  blockSwitchingControl->noOfGroups = MAX_NO_OF_GROUPS;                          
+  blockSwitchingControl->noOfGroups = MAX_NO_OF_GROUPS;
 
   for (i=0; i<MAX_NO_OF_GROUPS; i++) {
-    blockSwitchingControl->groupLen[i] = suggestedGroupingTable[blockSwitchingControl->attackIndex][i];  
+    blockSwitchingControl->groupLen[i] = suggestedGroupingTable[blockSwitchingControl->attackIndex][i];
   }
-	
+
   /* if the samplerate is less than 16000, it should be all the short block, avoid pre&post echo */
   if(sampleRate >= 16000) {
 	  /* Save current window energy as last window energy */
 	  for (w=0; w<BLOCK_SWITCH_WINDOWS; w++) {
-		  blockSwitchingControl->windowNrg[0][w] = blockSwitchingControl->windowNrg[1][w];             
-		  blockSwitchingControl->windowNrgF[0][w] = blockSwitchingControl->windowNrgF[1][w];           
+		  blockSwitchingControl->windowNrg[0][w] = blockSwitchingControl->windowNrg[1][w];
+		  blockSwitchingControl->windowNrgF[0][w] = blockSwitchingControl->windowNrgF[1][w];
 	  }
 
 
@@ -147,10 +147,10 @@
 	  CalcWindowEnergy(blockSwitchingControl, timeSignal, chIncrement, BLOCK_SWITCH_WINDOW_LEN);
 
 	  /* reset attack */
-	  blockSwitchingControl->attack = FALSE;                                         
+	  blockSwitchingControl->attack = FALSE;
 
-	  enMax = 0;                                                                     
-	  enM1 = blockSwitchingControl->windowNrgF[0][BLOCK_SWITCH_WINDOWS-1];           
+	  enMax = 0;
+	  enM1 = blockSwitchingControl->windowNrgF[0][BLOCK_SWITCH_WINDOWS-1];
 
 	  for (w=0; w<BLOCK_SWITCH_WINDOWS; w++) {
 		  Word32 enM1_Tmp, accWindowNrg_Tmp, windowNrgF_Tmp;
@@ -172,15 +172,15 @@
 		  /* if the energy with the ratio is bigger than the average, and the attack and short block  */
 		  if ((fixmul(windowNrgF_Tmp, blockSwitchingControl->invAttackRatio) >> windowNrgF_Shf) >
 			  blockSwitchingControl->accWindowNrg ) {
-				  blockSwitchingControl->attack = TRUE;                                      
-				  blockSwitchingControl->lastAttackIndex = w;                                
+				  blockSwitchingControl->attack = TRUE;
+				  blockSwitchingControl->lastAttackIndex = w;
 		  }
-		  enM1 = blockSwitchingControl->windowNrgF[1][w];                              
+		  enM1 = blockSwitchingControl->windowNrgF[1][w];
 		  enMax = max(enMax, enM1);
 	  }
 
 	  if (enMax < minAttackNrg) {
-		  blockSwitchingControl->attack = FALSE;                                       
+		  blockSwitchingControl->attack = FALSE;
 	  }
   }
   else
@@ -188,22 +188,22 @@
 	  blockSwitchingControl->attack = TRUE;
   }
 
-  /* Check if attack spreads over frame border */     
+  /* Check if attack spreads over frame border */
   if ((!blockSwitchingControl->attack) && (blockSwitchingControl->lastattack)) {
-     
+
     if (blockSwitchingControl->attackIndex == TRANS_FAC-1) {
-      blockSwitchingControl->attack = TRUE;                                      
+      blockSwitchingControl->attack = TRUE;
     }
 
-    blockSwitchingControl->lastattack = FALSE;                                   
+    blockSwitchingControl->lastattack = FALSE;
   }
   else {
-    blockSwitchingControl->lastattack = blockSwitchingControl->attack;           
+    blockSwitchingControl->lastattack = blockSwitchingControl->attack;
   }
 
-  blockSwitchingControl->windowSequence =  blockSwitchingControl->nextwindowSequence;    
+  blockSwitchingControl->windowSequence =  blockSwitchingControl->nextwindowSequence;
 
-     
+
   if (blockSwitchingControl->attack) {
     blockSwitchingControl->nextwindowSequence = SHORT_WINDOW;
   }
@@ -211,27 +211,27 @@
     blockSwitchingControl->nextwindowSequence = LONG_WINDOW;
   }
 
-  /* update short block group */ 
+  /* update short block group */
   if (blockSwitchingControl->nextwindowSequence == SHORT_WINDOW) {
-     
+
     if (blockSwitchingControl->windowSequence== LONG_WINDOW) {
-      blockSwitchingControl->windowSequence = START_WINDOW;                      
+      blockSwitchingControl->windowSequence = START_WINDOW;
     }
-     
+
     if (blockSwitchingControl->windowSequence == STOP_WINDOW) {
-      blockSwitchingControl->windowSequence = SHORT_WINDOW;                      
-      blockSwitchingControl->noOfGroups = 3;                                     
-      blockSwitchingControl->groupLen[0] = 3;                                    
-      blockSwitchingControl->groupLen[1] = 3;                                    
-      blockSwitchingControl->groupLen[2] = 2;                                    
+      blockSwitchingControl->windowSequence = SHORT_WINDOW;
+      blockSwitchingControl->noOfGroups = 3;
+      blockSwitchingControl->groupLen[0] = 3;
+      blockSwitchingControl->groupLen[1] = 3;
+      blockSwitchingControl->groupLen[2] = 2;
     }
   }
 
-  /* update block type */  
+  /* update block type */
   if (blockSwitchingControl->nextwindowSequence == LONG_WINDOW) {
-     
+
     if (blockSwitchingControl->windowSequence == SHORT_WINDOW) {
-      blockSwitchingControl->nextwindowSequence = STOP_WINDOW;                   
+      blockSwitchingControl->nextwindowSequence = STOP_WINDOW;
     }
   }
 
@@ -252,17 +252,17 @@
   Word32 i, idx;
 
   /* Search maximum value in array and return index and value */
-  max = 0;                                                       
-  idx = 0;                                                       
+  max = 0;
+  idx = 0;
 
   for (i = 0; i < n; i++) {
-     
+
     if (in[i+1]  > max) {
-      max = in[i+1];                                             
-      idx = i;                                                   
+      max = in[i+1];
+      idx = i;
     }
   }
-  *index = idx;                                                  
+  *index = idx;
 
   return(max);
 }
@@ -292,11 +292,11 @@
   states1 = blockSwitchingControl->iirStates[1];
   Coeff0 = hiPassCoeff[0];
   Coeff1 = hiPassCoeff[1];
-  tidx = 0;                                                   
+  tidx = 0;
   for (w=0; w < BLOCK_SWITCH_WINDOWS; w++) {
 
-    accuUE = 0;                                                  
-    accuFE = 0;                                                  
+    accuUE = 0;
+    accuFE = 0;
 
     for(i=0; i<windowLen; i++) {
 	  Word32 accu1, accu2, accu3;
@@ -309,16 +309,16 @@
 	  accu3 = accu1 - states0;
 	  out = accu3 - accu2;
 
-	  states0 = accu1;             
-	  states1 = out;               
+	  states0 = accu1;
+	  states1 = out;
 
-      tempFiltered = extract_h(out);	  
+      tempFiltered = extract_h(out);
       accuUE += (tempUnfiltered * tempUnfiltered) >> ENERGY_SHIFT;
       accuFE += (tempFiltered * tempFiltered) >> ENERGY_SHIFT;
     }
 
-    blockSwitchingControl->windowNrg[1][w] = accuUE;             
-    blockSwitchingControl->windowNrgF[1][w] = accuFE;            
+    blockSwitchingControl->windowNrg[1][w] = accuUE;
+    blockSwitchingControl->windowNrgF[1][w] = accuFE;
 
   }
 
@@ -346,8 +346,8 @@
   accu2 = fixmul( coeff[0], states[1] );
   out = accu3 - accu2;
 
-  states[0] = accu1;             
-  states[1] = out;               
+  states[0] = accu1;
+  states[1] = out;
 
   return round16(out);
 }
@@ -374,54 +374,54 @@
                           const Word16 nChannels)
 {
   Word16 i;
-  Word16 patchType = LONG_WINDOW;                
+  Word16 patchType = LONG_WINDOW;
 
-   
+
   if (nChannels == 1) { /* Mono */
     if (blockSwitchingControlLeft->windowSequence != SHORT_WINDOW) {
-      blockSwitchingControlLeft->noOfGroups = 1;                         
-      blockSwitchingControlLeft->groupLen[0] = 1;                        
+      blockSwitchingControlLeft->noOfGroups = 1;
+      blockSwitchingControlLeft->groupLen[0] = 1;
 
       for (i=1; i<TRANS_FAC; i++) {
-        blockSwitchingControlLeft->groupLen[i] = 0;                      
+        blockSwitchingControlLeft->groupLen[i] = 0;
       }
     }
   }
   else { /* Stereo common Window */
-    patchType = synchronizedBlockTypeTable[patchType][blockSwitchingControlLeft->windowSequence];        
-    patchType = synchronizedBlockTypeTable[patchType][blockSwitchingControlRight->windowSequence];       
+    patchType = synchronizedBlockTypeTable[patchType][blockSwitchingControlLeft->windowSequence];
+    patchType = synchronizedBlockTypeTable[patchType][blockSwitchingControlRight->windowSequence];
 
     /* Set synchronized Blocktype */
-    blockSwitchingControlLeft->windowSequence = patchType;               
-    blockSwitchingControlRight->windowSequence = patchType;              
+    blockSwitchingControlLeft->windowSequence = patchType;
+    blockSwitchingControlRight->windowSequence = patchType;
 
-    /* Synchronize grouping info */     
+    /* Synchronize grouping info */
     if(patchType != SHORT_WINDOW) { /* Long Blocks */
       /* Set grouping info */
-      blockSwitchingControlLeft->noOfGroups = 1;                         
-      blockSwitchingControlRight->noOfGroups = 1;                        
-      blockSwitchingControlLeft->groupLen[0] = 1;                        
-      blockSwitchingControlRight->groupLen[0] = 1;                       
+      blockSwitchingControlLeft->noOfGroups = 1;
+      blockSwitchingControlRight->noOfGroups = 1;
+      blockSwitchingControlLeft->groupLen[0] = 1;
+      blockSwitchingControlRight->groupLen[0] = 1;
 
       for (i=1; i<TRANS_FAC; i++) {
-        blockSwitchingControlLeft->groupLen[i] = 0;                      
-        blockSwitchingControlRight->groupLen[i] = 0;                     
+        blockSwitchingControlLeft->groupLen[i] = 0;
+        blockSwitchingControlRight->groupLen[i] = 0;
       }
     }
     else {
-       
+
       if (blockSwitchingControlLeft->maxWindowNrg > blockSwitchingControlRight->maxWindowNrg) {
         /* Left Channel wins */
-        blockSwitchingControlRight->noOfGroups = blockSwitchingControlLeft->noOfGroups;          
+        blockSwitchingControlRight->noOfGroups = blockSwitchingControlLeft->noOfGroups;
         for (i=0; i<TRANS_FAC; i++) {
-          blockSwitchingControlRight->groupLen[i] = blockSwitchingControlLeft->groupLen[i];      
+          blockSwitchingControlRight->groupLen[i] = blockSwitchingControlLeft->groupLen[i];
         }
       }
       else {
         /* Right Channel wins */
-        blockSwitchingControlLeft->noOfGroups = blockSwitchingControlRight->noOfGroups;          
+        blockSwitchingControlLeft->noOfGroups = blockSwitchingControlRight->noOfGroups;
         for (i=0; i<TRANS_FAC; i++) {
-          blockSwitchingControlLeft->groupLen[i] = blockSwitchingControlRight->groupLen[i];      
+          blockSwitchingControlLeft->groupLen[i] = blockSwitchingControlRight->groupLen[i];
         }
       }
     }
diff --git a/media/libstagefright/codecs/aacenc/src/channel_map.c b/media/libstagefright/codecs/aacenc/src/channel_map.c
index 2d41f8c..f6552ed 100644
--- a/media/libstagefright/codecs/aacenc/src/channel_map.c
+++ b/media/libstagefright/codecs/aacenc/src/channel_map.c
@@ -29,32 +29,32 @@
 
 static Word16 initElement(ELEMENT_INFO* elInfo, ELEMENT_TYPE elType)
 {
-  Word16 error=0;                                    
+  Word16 error=0;
 
-  elInfo->elType=elType;                             
+  elInfo->elType=elType;
 
   switch(elInfo->elType) {
 
     case ID_SCE:
-      elInfo->nChannelsInEl=1;                       
+      elInfo->nChannelsInEl=1;
 
-      elInfo->ChannelIndex[0]=0;                     
+      elInfo->ChannelIndex[0]=0;
 
-      elInfo->instanceTag=0;                         
+      elInfo->instanceTag=0;
       break;
 
     case ID_CPE:
 
-      elInfo->nChannelsInEl=2;                        
+      elInfo->nChannelsInEl=2;
 
-      elInfo->ChannelIndex[0]=0;                      
-      elInfo->ChannelIndex[1]=1;                      
+      elInfo->ChannelIndex[0]=0;
+      elInfo->ChannelIndex[1]=1;
 
-      elInfo->instanceTag=0;                    
+      elInfo->instanceTag=0;
       break;
 
     default:
-      error=1;                                  
+      error=1;
   }
 
   return error;
@@ -64,11 +64,11 @@
 Word16 InitElementInfo (Word16 nChannels, ELEMENT_INFO* elInfo)
 {
   Word16 error;
-  error = 0;                                        
+  error = 0;
 
   switch(nChannels) {
 
-    case 1: 
+    case 1:
       initElement(elInfo, ID_SCE);
       break;
 
@@ -77,7 +77,7 @@
       break;
 
     default:
-      error=4;                                         
+      error=4;
   }
 
   return error;
@@ -91,18 +91,18 @@
                        Word16 staticBitsTot)
 {
   Word16 error;
-  error = 0;                                    
+  error = 0;
 
    switch(elInfo.nChannelsInEl) {
     case 1:
-      elementBits->chBitrate = bitrateTot;                     
+      elementBits->chBitrate = bitrateTot;
       elementBits->averageBits = averageBitsTot - staticBitsTot;
-      elementBits->maxBits = maxChannelBits;                   
+      elementBits->maxBits = maxChannelBits;
 
       elementBits->maxBitResBits = maxChannelBits - averageBitsTot;
-      elementBits->maxBitResBits = elementBits->maxBitResBits - (elementBits->maxBitResBits & 7); 
-      elementBits->bitResLevel = elementBits->maxBitResBits;   
-      elementBits->relativeBits  = 0x4000; /* 1.0f/2 */        
+      elementBits->maxBitResBits = elementBits->maxBitResBits - (elementBits->maxBitResBits & 7);
+      elementBits->bitResLevel = elementBits->maxBitResBits;
+      elementBits->relativeBits  = 0x4000; /* 1.0f/2 */
       break;
 
     case 2:
@@ -111,13 +111,13 @@
       elementBits->maxBits     = maxChannelBits << 1;
 
       elementBits->maxBitResBits = (maxChannelBits << 1) - averageBitsTot;
-      elementBits->maxBitResBits = elementBits->maxBitResBits - (elementBits->maxBitResBits & 7);   
-      elementBits->bitResLevel = elementBits->maxBitResBits;     
-      elementBits->relativeBits = 0x4000; /* 1.0f/2 */           
+      elementBits->maxBitResBits = elementBits->maxBitResBits - (elementBits->maxBitResBits & 7);
+      elementBits->bitResLevel = elementBits->maxBitResBits;
+      elementBits->relativeBits = 0x4000; /* 1.0f/2 */
       break;
 
     default:
-      error = 1;                                                 
+      error = 1;
   }
   return error;
 }
diff --git a/media/libstagefright/codecs/aacenc/src/dyn_bits.c b/media/libstagefright/codecs/aacenc/src/dyn_bits.c
index f3b3e02..3d2efdc 100644
--- a/media/libstagefright/codecs/aacenc/src/dyn_bits.c
+++ b/media/libstagefright/codecs/aacenc/src/dyn_bits.c
@@ -45,12 +45,12 @@
   for (i=0; i<maxSfb; i++) {
     Word16 sfbWidth, maxVal;
 
-    sectionInfo[i].sfbCnt = 1;                                   
-    sectionInfo[i].sfbStart = i;                                 
-    sectionInfo[i].sectionBits = INVALID_BITCOUNT;               
-    sectionInfo[i].codeBook = -1;                                
-    sfbWidth = sfbOffset[i + 1] - sfbOffset[i];              
-    maxVal = sfbMax[i];                                          
+    sectionInfo[i].sfbCnt = 1;
+    sectionInfo[i].sfbStart = i;
+    sectionInfo[i].sectionBits = INVALID_BITCOUNT;
+    sectionInfo[i].codeBook = -1;
+    sfbWidth = sfbOffset[i + 1] - sfbOffset[i];
+    maxVal = sfbMax[i];
     bitCount(quantSpectrum + sfbOffset[i], sfbWidth, maxVal, bitLookUp[i]);
   }
 }
@@ -66,13 +66,13 @@
 findBestBook(const Word16 *bc, Word16 *book)
 {
   Word32 minBits, j;
-  minBits = INVALID_BITCOUNT;                                    
+  minBits = INVALID_BITCOUNT;
 
   for (j=0; j<=CODE_BOOK_ESC_NDX; j++) {
-     
+
     if (bc[j] < minBits) {
-      minBits = bc[j];                                           
-      *book = j;                                                 
+      minBits = bc[j];
+      *book = j;
     }
   }
   return extract_l(minBits);
@@ -82,12 +82,12 @@
 findMinMergeBits(const Word16 *bc1, const Word16 *bc2)
 {
   Word32 minBits, j, sum;
-  minBits = INVALID_BITCOUNT;                                    
+  minBits = INVALID_BITCOUNT;
 
   for (j=0; j<=CODE_BOOK_ESC_NDX; j++) {
     sum = bc1[j] + bc2[j];
     if (sum < minBits) {
-      minBits = sum;                                             
+      minBits = sum;
     }
   }
   return extract_l(minBits);
@@ -109,13 +109,13 @@
              const Word16 maxSfb, Word16 *maxNdx)
 {
   Word32 i, maxMergeGain;
-  maxMergeGain = 0;                                              
+  maxMergeGain = 0;
 
   for (i=0; i+sectionInfo[i].sfbCnt < maxSfb; i += sectionInfo[i].sfbCnt) {
-     
+
     if (mergeGainLookUp[i] > maxMergeGain) {
-      maxMergeGain = mergeGainLookUp[i];                         
-      *maxNdx = i;                                               
+      maxMergeGain = mergeGainLookUp[i];
+      *maxNdx = i;
     }
   }
   return extract_l(maxMergeGain);
@@ -159,7 +159,7 @@
 
   for (i=0; i<maxSfb; i++) {
     /* Side-Info bits will be calculated in Stage 1!  */
-     
+
     if (sectionInfo[i].sectionBits == INVALID_BITCOUNT) {
       sectionInfo[i].sectionBits = findBestBook(bitLookUp[i], &(sectionInfo[i].codeBook));
     }
@@ -180,13 +180,13 @@
   SECTION_INFO * sectionInfo_s;
   SECTION_INFO * sectionInfo_e;
   Word32 mergeStart, mergeEnd;
-  mergeStart = 0;                                                        
+  mergeStart = 0;
 
   do {
 
     sectionInfo_s = sectionInfo + mergeStart;
 	for (mergeEnd=mergeStart+1; mergeEnd<maxSfb; mergeEnd++) {
-      sectionInfo_e = sectionInfo + mergeEnd; 
+      sectionInfo_e = sectionInfo + mergeEnd;
       if (sectionInfo_s->codeBook != sectionInfo_e->codeBook)
         break;
       sectionInfo_s->sfbCnt += 1;
@@ -196,11 +196,11 @@
     }
 
     sectionInfo_s->sectionBits += sideInfoTab[sectionInfo_s->sfbCnt];
-    sectionInfo[mergeEnd - 1].sfbStart = sectionInfo_s->sfbStart;      /* speed up prev search */  
+    sectionInfo[mergeEnd - 1].sfbStart = sectionInfo_s->sfbStart;      /* speed up prev search */
 
-    mergeStart = mergeEnd;                                               
+    mergeStart = mergeEnd;
 
-     
+
   } while (mergeStart - maxSfb < 0);
 }
 
@@ -230,7 +230,7 @@
 
     maxMergeGain = findMaxMerge(mergeGainLookUp, sectionInfo, maxSfb, &maxNdx);
 
-     
+
     if (maxMergeGain <= 0)
       break;
 
@@ -244,7 +244,7 @@
 
     mergeBitLookUp(bitLookUp[maxNdx], bitLookUp[maxNdxNext]);
 
-     
+
     if (maxNdx != 0) {
       maxNdxLast = sectionInfo[maxNdx - 1].sfbStart;
       mergeGainLookUp[maxNdxLast] = CalcMergeGain(sectionInfo,
@@ -255,9 +255,9 @@
     }
     maxNdxNext = maxNdx + sectionInfo[maxNdx].sfbCnt;
 
-    sectionInfo[maxNdxNext - 1].sfbStart = sectionInfo[maxNdx].sfbStart;             
+    sectionInfo[maxNdxNext - 1].sfbStart = sectionInfo[maxNdx].sfbStart;
 
-     
+
     if (maxNdxNext - maxSfb < 0) {
       mergeGainLookUp[maxNdx] = CalcMergeGain(sectionInfo,
                                               bitLookUp,
@@ -286,7 +286,7 @@
 
   /*
     use appropriate side info table
-  */   
+  */
   switch (blockType)
   {
     case LONG_WINDOW:
@@ -300,11 +300,11 @@
   }
 
 
-  sectionData->noOfSections = 0;                                         
-  sectionData->huffmanBits = 0;                                          
-  sectionData->sideInfoBits = 0;                                         
+  sectionData->noOfSections = 0;
+  sectionData->huffmanBits = 0;
+  sectionData->sideInfoBits = 0;
 
-   
+
   if (sectionData->maxSfbPerGroup == 0)
     return;
 
@@ -353,7 +353,7 @@
       sectionData->huffmanBits = (sectionData->huffmanBits +
                                      (sectionInfo[i].sectionBits - sideInfoTab[sectionInfo[i].sfbCnt]));
       sectionData->sideInfoBits = (sectionData->sideInfoBits + sideInfoTab[sectionInfo[i].sfbCnt]);
-      sectionData->sectionInfo[sectionData->noOfSections] = sectionInfo[i];             
+      sectionData->sectionInfo[sectionData->noOfSections] = sectionInfo[i];
       sectionData->noOfSections = sectionData->noOfSections + 1;
     }
   }
@@ -386,25 +386,25 @@
   Word32 lastValScf     = 0;
   Word32 deltaScf       = 0;
   Flag found            = 0;
-  Word32 scfSkipCounter = 0;           
-         
+  Word32 scfSkipCounter = 0;
 
-  sectionData->scalefacBits = 0;                                 
 
-   
+  sectionData->scalefacBits = 0;
+
+
   if (scalefacGain == NULL) {
     return;
   }
 
-  lastValScf = 0;                                                
-  sectionData->firstScf = 0;        
-  
+  lastValScf = 0;
+  sectionData->firstScf = 0;
+
   psectionInfo = sectionData->sectionInfo;
   for (i=0; i<sectionData->noOfSections; i++) {
-     
+
     if (psectionInfo->codeBook != CODE_BOOK_ZERO_NO) {
-      sectionData->firstScf = psectionInfo->sfbStart;      
-      lastValScf = scalefacGain[sectionData->firstScf];                  
+      sectionData->firstScf = psectionInfo->sfbStart;
+      lastValScf = scalefacGain[sectionData->firstScf];
       break;
     }
 	psectionInfo += 1;
@@ -412,38 +412,38 @@
 
   psectionInfo = sectionData->sectionInfo;
   for (i=0; i<sectionData->noOfSections; i++, psectionInfo += 1) {
-       
+
     if (psectionInfo->codeBook != CODE_BOOK_ZERO_NO
         && psectionInfo->codeBook != CODE_BOOK_PNS_NO) {
       for (j = psectionInfo->sfbStart;
            j < (psectionInfo->sfbStart + psectionInfo->sfbCnt); j++) {
         /* check if we can repeat the last value to save bits */
-         
+
         if (maxValueInSfb[j] == 0) {
-          found = 0;                                                     
-           
+          found = 0;
+
           if (scfSkipCounter == 0) {
             /* end of section */
-             
+
             if (j - ((psectionInfo->sfbStart + psectionInfo->sfbCnt) - 1) == 0) {
-              found = 0;                                                 
+              found = 0;
             }
             else {
               for (k = j + 1; k < psectionInfo->sfbStart + psectionInfo->sfbCnt; k++) {
-                 
+
                 if (maxValueInSfb[k] != 0) {
                   int tmp = L_abs(scalefacGain[k] - lastValScf);
-				  found = 1;                                             
-                   
+				  found = 1;
+
                   if ( tmp < CODE_BOOK_SCF_LAV) {
                     /* save bits */
-                    deltaScf = 0;                                        
+                    deltaScf = 0;
                   }
                   else {
                     /* do not save bits */
                     deltaScf = lastValScf - scalefacGain[j];
-                    lastValScf = scalefacGain[j];                        
-                    scfSkipCounter = 0;                                  
+                    lastValScf = scalefacGain[j];
+                    scfSkipCounter = 0;
                   }
                   break;
                 }
@@ -451,26 +451,26 @@
                 scfSkipCounter = scfSkipCounter + 1;
               }
             }
-			
+
 			psectionInfom = psectionInfo + 1;
             /* search for the next maxValueInSfb[] != 0 in all other sections */
             for (m = i + 1; (m < sectionData->noOfSections) && (found == 0); m++) {
-                 
+
               if ((psectionInfom->codeBook != CODE_BOOK_ZERO_NO) &&
                   (psectionInfom->codeBook != CODE_BOOK_PNS_NO)) {
                 for (n = psectionInfom->sfbStart;
                      n < (psectionInfom->sfbStart + psectionInfom->sfbCnt); n++) {
-                   
+
                   if (maxValueInSfb[n] != 0) {
-                    found = 1;                                           
-                     
+                    found = 1;
+
                     if ( (abs_s(scalefacGain[n] - lastValScf) < CODE_BOOK_SCF_LAV)) {
-                      deltaScf = 0;                                      
+                      deltaScf = 0;
                     }
                     else {
                       deltaScf = (lastValScf - scalefacGain[j]);
-                      lastValScf = scalefacGain[j];                      
-                      scfSkipCounter = 0;                                
+                      lastValScf = scalefacGain[j];
+                      scfSkipCounter = 0;
                     }
                     break;
                   }
@@ -481,20 +481,20 @@
 
 			  psectionInfom += 1;
             }
-             
+
             if (found == 0) {
-              deltaScf = 0;                                              
-              scfSkipCounter = 0;                                        
+              deltaScf = 0;
+              scfSkipCounter = 0;
             }
           }
           else {
-            deltaScf = 0;                                                
+            deltaScf = 0;
             scfSkipCounter = scfSkipCounter - 1;
           }
         }
         else {
           deltaScf = lastValScf - scalefacGain[j];
-          lastValScf = scalefacGain[j];                                  
+          lastValScf = scalefacGain[j];
         }
         sectionData->scalefacBits += bitCountScalefactorDelta(deltaScf);
       }
@@ -517,14 +517,14 @@
             const Word16  *sfbOffset,
             SECTION_DATA  *sectionData)
 {
-  sectionData->blockType      = blockType;                       
-  sectionData->sfbCnt         = sfbCnt;                          
-  sectionData->sfbPerGroup    = sfbPerGroup;           
+  sectionData->blockType      = blockType;
+  sectionData->sfbCnt         = sfbCnt;
+  sectionData->sfbPerGroup    = sfbPerGroup;
   if(sfbPerGroup)
-	sectionData->noOfGroups   = sfbCnt/sfbPerGroup; 
+	sectionData->noOfGroups   = sfbCnt/sfbPerGroup;
   else
 	sectionData->noOfGroups   = 0x7fff;
-  sectionData->maxSfbPerGroup = maxSfbPerGroup;                  
+  sectionData->maxSfbPerGroup = maxSfbPerGroup;
 
   noiselessCounter(sectionData,
                    sectionData->mergeGainLookUp,
@@ -539,7 +539,7 @@
            sectionData);
 
 
-  return (sectionData->huffmanBits + sectionData->sideInfoBits + 
+  return (sectionData->huffmanBits + sectionData->sideInfoBits +
 	      sectionData->scalefacBits);
 }
 
diff --git a/media/libstagefright/codecs/aacenc/src/grp_data.c b/media/libstagefright/codecs/aacenc/src/grp_data.c
index fb88654..7861e1c 100644
--- a/media/libstagefright/codecs/aacenc/src/grp_data.c
+++ b/media/libstagefright/codecs/aacenc/src/grp_data.c
@@ -57,29 +57,29 @@
 
   /* for short: regroup and  */
   /* cumulate energies und thresholds group-wise . */
-  
+
   /* calculate sfbCnt */
-  highestSfb = 0;                                        
+  highestSfb = 0;
   for (wnd=0; wnd<TRANS_FAC; wnd++) {
     for (sfb=sfbCnt - 1; sfb>=highestSfb; sfb--) {
       for (line=(sfbOffset[sfb + 1] - 1); line>=sfbOffset[sfb]; line--) {
-        
-        if (mdctSpectrum[wnd*FRAME_LEN_SHORT+line] != 0) break; 
+
+        if (mdctSpectrum[wnd*FRAME_LEN_SHORT+line] != 0) break;
       }
-      
+
       if (line >= sfbOffset[sfb]) break;
     }
     highestSfb = max(highestSfb, sfb);
   }
-  
+
   if (highestSfb < 0) {
-    highestSfb = 0;                                      
+    highestSfb = 0;
   }
   *maxSfbPerGroup = highestSfb + 1;
 
   /* calculate sfbOffset */
-  i = 0;                                                 
-  offset = 0;                                            
+  i = 0;
+  offset = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
       groupedSfbOffset[i] = offset + sfbOffset[sfb] * groupLen[grp];
@@ -87,15 +87,15 @@
     }
     offset += groupLen[grp] * FRAME_LEN_SHORT;
   }
-  groupedSfbOffset[i] = FRAME_LEN_LONG;                  
+  groupedSfbOffset[i] = FRAME_LEN_LONG;
   i += 1;
 
   /* calculate minSnr */
-  i = 0;                                                 
-  offset = 0;                                            
+  i = 0;
+  offset = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
-      groupedSfbMinSnr[i] = sfbMinSnr[sfb];              
+      groupedSfbMinSnr[i] = sfbMinSnr[sfb];
       i += 1;
     }
     offset += groupLen[grp] * FRAME_LEN_SHORT;
@@ -103,74 +103,74 @@
 
 
   /* sum up sfbThresholds */
-  wnd = 0;                                                       
-  i = 0;                                                         
+  wnd = 0;
+  i = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
-      Word32 thresh = sfbThreshold->sfbShort[wnd][sfb];          
+      Word32 thresh = sfbThreshold->sfbShort[wnd][sfb];
       for (j=1; j<groupLen[grp]; j++) {
         thresh = L_add(thresh, sfbThreshold->sfbShort[wnd+j][sfb]);
       }
-      sfbThreshold->sfbLong[i] = thresh;                         
+      sfbThreshold->sfbLong[i] = thresh;
       i += 1;
     }
     wnd += groupLen[grp];
   }
 
   /* sum up sfbEnergies left/right */
-  wnd = 0;                                                       
-  i = 0;                                                         
+  wnd = 0;
+  i = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
-      Word32 energy = sfbEnergy->sfbShort[wnd][sfb];             
+      Word32 energy = sfbEnergy->sfbShort[wnd][sfb];
       for (j=1; j<groupLen[grp]; j++) {
         energy = L_add(energy, sfbEnergy->sfbShort[wnd+j][sfb]);
       }
-      sfbEnergy->sfbLong[i] = energy;                            
+      sfbEnergy->sfbLong[i] = energy;
       i += 1;
     }
     wnd += groupLen[grp];
   }
 
   /* sum up sfbEnergies mid/side */
-  wnd = 0;                                                       
-  i = 0;                                                         
+  wnd = 0;
+  i = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
-      Word32 energy = sfbEnergyMS->sfbShort[wnd][sfb];           
+      Word32 energy = sfbEnergyMS->sfbShort[wnd][sfb];
       for (j=1; j<groupLen[grp]; j++) {
         energy = L_add(energy, sfbEnergyMS->sfbShort[wnd+j][sfb]);
       }
-      sfbEnergyMS->sfbLong[i] = energy;                          
+      sfbEnergyMS->sfbLong[i] = energy;
       i += 1;
     }
     wnd += groupLen[grp];
   }
 
   /* sum up sfbSpreadedEnergies */
-  wnd = 0;                                                       
-  i = 0;                                                         
+  wnd = 0;
+  i = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
-      Word32 energy = sfbSpreadedEnergy->sfbShort[wnd][sfb];     
+      Word32 energy = sfbSpreadedEnergy->sfbShort[wnd][sfb];
       for (j=1; j<groupLen[grp]; j++) {
         energy = L_add(energy, sfbSpreadedEnergy->sfbShort[wnd+j][sfb]);
       }
-      sfbSpreadedEnergy->sfbLong[i] = energy;                    
+      sfbSpreadedEnergy->sfbLong[i] = energy;
       i += 1;
     }
     wnd += groupLen[grp];
   }
 
   /* re-group spectrum */
-  wnd = 0;                                                       
-  i = 0;                                                         
+  wnd = 0;
+  i = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     for (sfb = 0; sfb < sfbCnt; sfb++) {
       for (j = 0; j < groupLen[grp]; j++) {
         Word16 lineOffset = FRAME_LEN_SHORT * (wnd + j);
         for (line = lineOffset + sfbOffset[sfb]; line < lineOffset + sfbOffset[sfb+1]; line++) {
-          tmpSpectrum[i] = mdctSpectrum[line];                   
+          tmpSpectrum[i] = mdctSpectrum[line];
           i = i + 1;
         }
       }
@@ -179,10 +179,10 @@
   }
 
   for(i=0;i<FRAME_LEN_LONG;i+=4) {
-    mdctSpectrum[i] = tmpSpectrum[i];  
-	mdctSpectrum[i+1] = tmpSpectrum[i+1];  
-	mdctSpectrum[i+2] = tmpSpectrum[i+2];  
-	mdctSpectrum[i+3] = tmpSpectrum[i+3];  	
+    mdctSpectrum[i] = tmpSpectrum[i];
+	mdctSpectrum[i+1] = tmpSpectrum[i+1];
+	mdctSpectrum[i+2] = tmpSpectrum[i+2];
+	mdctSpectrum[i+3] = tmpSpectrum[i+3];
   }
 }
 
diff --git a/media/libstagefright/codecs/aacenc/src/interface.c b/media/libstagefright/codecs/aacenc/src/interface.c
index 34fee00..f2472d8 100644
--- a/media/libstagefright/codecs/aacenc/src/interface.c
+++ b/media/libstagefright/codecs/aacenc/src/interface.c
@@ -49,56 +49,56 @@
                     PSY_OUT_CHANNEL         *psyOutCh)
 {
   Word32 j;
-  Word32 grp; 
+  Word32 grp;
   Word32 mask;
   Word16 *tmpV;
 
   /*
   copy values to psyOut
   */
-  psyOutCh->maxSfbPerGroup    = maxSfbPerGroup;                             
-  psyOutCh->sfbCnt            = groupedSfbCnt;   
+  psyOutCh->maxSfbPerGroup    = maxSfbPerGroup;
+  psyOutCh->sfbCnt            = groupedSfbCnt;
   if(noOfGroups)
 	psyOutCh->sfbPerGroup     = groupedSfbCnt/ noOfGroups;
   else
 	psyOutCh->sfbPerGroup     = 0x7fff;
-  psyOutCh->windowSequence    = windowSequence;                             
-  psyOutCh->windowShape       = windowShape;                                
-  psyOutCh->mdctScale         = mdctScale;                                  
+  psyOutCh->windowSequence    = windowSequence;
+  psyOutCh->windowShape       = windowShape;
+  psyOutCh->mdctScale         = mdctScale;
   psyOutCh->mdctSpectrum      = groupedMdctSpectrum;
   psyOutCh->sfbEnergy         = groupedSfbEnergy->sfbLong;
   psyOutCh->sfbThreshold      = groupedSfbThreshold->sfbLong;
   psyOutCh->sfbSpreadedEnergy = groupedSfbSpreadedEnergy->sfbLong;
-  
+
   tmpV = psyOutCh->sfbOffsets;
   for(j=0; j<groupedSfbCnt + 1; j++) {
       *tmpV++ = groupedSfbOffset[j];
   }
-  
+
   tmpV = psyOutCh->sfbMinSnr;
   for(j=0;j<groupedSfbCnt; j++) {
 	  *tmpV++ =   groupedSfbMinSnr[j];
   }
-  
+
   /* generate grouping mask */
-  mask = 0;                                                                      
+  mask = 0;
   for (grp = 0; grp < noOfGroups; grp++) {
     mask = mask << 1;
     for (j=1; j<groupLen[grp]; j++) {
       mask = mask << 1;
-      mask |= 1;                                                                 
+      mask |= 1;
     }
   }
-  psyOutCh->groupingMask = mask; 
-  
+  psyOutCh->groupingMask = mask;
+
   if (windowSequence != SHORT_WINDOW) {
-    psyOutCh->sfbEnSumLR =  sfbEnergySumLR.sfbLong;                              
-    psyOutCh->sfbEnSumMS =  sfbEnergySumMS.sfbLong;                              
+    psyOutCh->sfbEnSumLR =  sfbEnergySumLR.sfbLong;
+    psyOutCh->sfbEnSumMS =  sfbEnergySumMS.sfbLong;
   }
   else {
     Word32 i;
     Word32 accuSumMS=0;
-    Word32 accuSumLR=0;        
+    Word32 accuSumLR=0;
 	Word32 *pSumMS = sfbEnergySumMS.sfbShort;
 	Word32 *pSumLR = sfbEnergySumLR.sfbShort;
 
@@ -106,7 +106,7 @@
       accuSumLR = L_add(accuSumLR, *pSumLR); pSumLR++;
       accuSumMS = L_add(accuSumMS, *pSumMS); pSumMS++;
     }
-    psyOutCh->sfbEnSumMS = accuSumMS;                                            
-    psyOutCh->sfbEnSumLR = accuSumLR;                                            
+    psyOutCh->sfbEnSumMS = accuSumMS;
+    psyOutCh->sfbEnSumLR = accuSumLR;
   }
 }
diff --git a/media/libstagefright/codecs/aacenc/src/line_pe.c b/media/libstagefright/codecs/aacenc/src/line_pe.c
index 5e93cd0..480dc28 100644
--- a/media/libstagefright/codecs/aacenc/src/line_pe.c
+++ b/media/libstagefright/codecs/aacenc/src/line_pe.c
@@ -45,20 +45,20 @@
                   const Word16 peOffset)
 {
   Word32 sfbGrp, sfb;
-  Word32 ch;     
+  Word32 ch;
 
   for(ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
     PE_CHANNEL_DATA *peChanData=&peData->peChannelData[ch];
     for(sfbGrp=0;sfbGrp<psyOutChan->sfbCnt; sfbGrp+=psyOutChan->sfbPerGroup){
       for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-	    peChanData->sfbNLines4[sfbGrp+sfb] = sfbNRelevantLines[ch][sfbGrp+sfb];          
-        sfbNRelevantLines[ch][sfbGrp+sfb] = sfbNRelevantLines[ch][sfbGrp+sfb] >> 2;    
-	    peChanData->sfbLdEnergy[sfbGrp+sfb] = logSfbEnergy[ch][sfbGrp+sfb];              
+	    peChanData->sfbNLines4[sfbGrp+sfb] = sfbNRelevantLines[ch][sfbGrp+sfb];
+        sfbNRelevantLines[ch][sfbGrp+sfb] = sfbNRelevantLines[ch][sfbGrp+sfb] >> 2;
+	    peChanData->sfbLdEnergy[sfbGrp+sfb] = logSfbEnergy[ch][sfbGrp+sfb];
       }
     }
   }
-  peData->offset = peOffset;                                                             
+  peData->offset = peOffset;
 }
 
 
@@ -78,23 +78,23 @@
   Word32 ldThr, ldRatio;
   Word32 pe, constPart, nActiveLines;
 
-  peData->pe = peData->offset;                                           
-  peData->constPart = 0;                                                 
-  peData->nActiveLines = 0;                                              
+  peData->pe = peData->offset;
+  peData->constPart = 0;
+  peData->nActiveLines = 0;
   for(ch=0; ch<nChannels; ch++) {
     PSY_OUT_CHANNEL *psyOutChan = &psyOutChannel[ch];
     PE_CHANNEL_DATA *peChanData = &peData->peChannelData[ch];
     const Word32 *sfbEnergy = psyOutChan->sfbEnergy;
     const Word32 *sfbThreshold = psyOutChan->sfbThreshold;
 
-    pe = 0;                                                  
-    constPart = 0;                                           
-    nActiveLines = 0;                                        
+    pe = 0;
+    constPart = 0;
+    nActiveLines = 0;
 
     for(sfbGrp=0; sfbGrp<psyOutChan->sfbCnt; sfbGrp+=psyOutChan->sfbPerGroup) {
       for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-        Word32 nrg = sfbEnergy[sfbGrp+sfb];                             
-        Word32 thres = sfbThreshold[sfbGrp+sfb];                           
+        Word32 nrg = sfbEnergy[sfbGrp+sfb];
+        Word32 thres = sfbThreshold[sfbGrp+sfb];
         Word32 sfbLDEn = peChanData->sfbLdEnergy[sfbGrp+sfb];
 
         if (nrg > thres) {
@@ -102,8 +102,8 @@
 
           ldRatio = sfbLDEn - ldThr;
 
-          nLines4 = peChanData->sfbNLines4[sfbGrp+sfb];                    
-           
+          nLines4 = peChanData->sfbNLines4[sfbGrp+sfb];
+
           /* sfbPe = nl*log2(en/thr)*/
 		  if (ldRatio >= C1_I) {
             peChanData->sfbPe[sfbGrp+sfb] = (nLines4*ldRatio + 8) >> 4;
@@ -120,26 +120,26 @@
           peChanData->sfbNActiveLines[sfbGrp+sfb] = nLines4 >> 2;
         }
         else {
-          peChanData->sfbPe[sfbGrp+sfb] = 0;                             
-          peChanData->sfbConstPart[sfbGrp+sfb] = 0;                      
-          peChanData->sfbNActiveLines[sfbGrp+sfb] = 0;                   
+          peChanData->sfbPe[sfbGrp+sfb] = 0;
+          peChanData->sfbConstPart[sfbGrp+sfb] = 0;
+          peChanData->sfbNActiveLines[sfbGrp+sfb] = 0;
         }
         pe = pe + peChanData->sfbPe[sfbGrp+sfb];
         constPart = constPart + peChanData->sfbConstPart[sfbGrp+sfb];
         nActiveLines = nActiveLines + peChanData->sfbNActiveLines[sfbGrp+sfb];
       }
     }
-	
-	peChanData->pe = saturate(pe);                                                  
-    peChanData->constPart = saturate(constPart);                                           
-    peChanData->nActiveLines = saturate(nActiveLines);                                        
 
-    
+	peChanData->pe = saturate(pe);
+    peChanData->constPart = saturate(constPart);
+    peChanData->nActiveLines = saturate(nActiveLines);
+
+
 	pe += peData->pe;
-	peData->pe = saturate(pe); 
+	peData->pe = saturate(pe);
     constPart += peData->constPart;
-	peData->constPart = saturate(constPart); 
+	peData->constPart = saturate(constPart);
     nActiveLines += peData->nActiveLines;
 	peData->nActiveLines = saturate(nActiveLines);
-  } 
+  }
 }
diff --git a/media/libstagefright/codecs/aacenc/src/memalign.c b/media/libstagefright/codecs/aacenc/src/memalign.c
index 44dd4ba..bb266dc 100644
--- a/media/libstagefright/codecs/aacenc/src/memalign.c
+++ b/media/libstagefright/codecs/aacenc/src/memalign.c
@@ -32,7 +32,7 @@
 /*****************************************************************************
 *
 * function name: mem_malloc
-* description:  malloc the alignments memory 
+* description:  malloc the alignments memory
 * returns:      the point of the memory
 *
 **********************************************************************************/
diff --git a/media/libstagefright/codecs/aacenc/src/ms_stereo.c b/media/libstagefright/codecs/aacenc/src/ms_stereo.c
index 44d45cc..2e34f14 100644
--- a/media/libstagefright/codecs/aacenc/src/ms_stereo.c
+++ b/media/libstagefright/codecs/aacenc/src/ms_stereo.c
@@ -30,7 +30,7 @@
 *
 * function name: MsStereoProcessing
 * description:  detect use ms stereo or not
-*				if ((min(thrLn, thrRn)*min(thrLn, thrRn))/(enMn*enSn)) 
+*				if ((min(thrLn, thrRn)*min(thrLn, thrRn))/(enMn*enSn))
 *				>= ((thrLn *thrRn)/(enLn*enRn)) then ms stereo
 *
 **********************************************************************************/
@@ -51,7 +51,7 @@
                         const Word16  maxSfbPerGroup,
                         const Word16 *sfbOffset) {
   Word32 temp;
-  Word32 sfb,sfboffs, j; 
+  Word32 sfb,sfboffs, j;
   Word32 msMaskTrueSomewhere = 0;
   Word32 msMaskFalseSomewhere = 0;
 
@@ -64,12 +64,12 @@
       Word32 thrL, thrR, nrgL, nrgR;
       Word32 idx, shift;
 
-      idx = sfb + sfboffs;                                                                       
+      idx = sfb + sfboffs;
 
-      thrL = sfbThresholdLeft[idx];                                                                 
-      thrR = sfbThresholdRight[idx];                                                                
-      nrgL = sfbEnergyLeft[idx];                                                                    
-      nrgR = sfbEnergyRight[idx];                                                                   
+      thrL = sfbThresholdLeft[idx];
+      thrR = sfbThresholdRight[idx];
+      nrgL = sfbEnergyLeft[idx];
+      nrgR = sfbEnergyRight[idx];
 
       minThreshold = min(thrL, thrR);
 
@@ -82,8 +82,8 @@
 
 	  pnlr = fixmul(nrgL, nrgR);
 
-      nrgL = sfbEnergyMid[idx];                                                                     
-      nrgR = sfbEnergySide[idx];                                                                    
+      nrgL = sfbEnergyMid[idx];
+      nrgR = sfbEnergySide[idx];
 
       nrgL = max(nrgL,minThreshold) + 1;
       shift = norm_l(nrgL);
@@ -97,42 +97,42 @@
 
       temp = (pnlr + 1) / ((pnms >> 8) + 1);
 
-      temp = pnms - pnlr;                                                                     
+      temp = pnms - pnlr;
       if( temp > 0 ){
 
-        msMask[idx] = 1;                                                                            
-        msMaskTrueSomewhere = 1;                                                                    
+        msMask[idx] = 1;
+        msMaskTrueSomewhere = 1;
 
         for (j=sfbOffset[idx]; j<sfbOffset[idx+1]; j++) {
           Word32 left, right;
           left  = (mdctSpectrumLeft[j] >>  1);
           right = (mdctSpectrumRight[j] >> 1);
-          mdctSpectrumLeft[j] =  left + right;                                               
-          mdctSpectrumRight[j] =  left - right;                                              
+          mdctSpectrumLeft[j] =  left + right;
+          mdctSpectrumRight[j] =  left - right;
         }
-        
-        sfbThresholdLeft[idx] = minThreshold;                                                       
-        sfbThresholdRight[idx] = minThreshold;                                                      
-        sfbEnergyLeft[idx] = sfbEnergyMid[idx];                                                     
-        sfbEnergyRight[idx] = sfbEnergySide[idx];                                                   
 
-        sfbSpreadedEnRight[idx] = min(sfbSpreadedEnLeft[idx],sfbSpreadedEnRight[idx]) >> 1;  
-        sfbSpreadedEnLeft[idx] = sfbSpreadedEnRight[idx];                                           
-        
+        sfbThresholdLeft[idx] = minThreshold;
+        sfbThresholdRight[idx] = minThreshold;
+        sfbEnergyLeft[idx] = sfbEnergyMid[idx];
+        sfbEnergyRight[idx] = sfbEnergySide[idx];
+
+        sfbSpreadedEnRight[idx] = min(sfbSpreadedEnLeft[idx],sfbSpreadedEnRight[idx]) >> 1;
+        sfbSpreadedEnLeft[idx] = sfbSpreadedEnRight[idx];
+
       }
       else {
-        msMask[idx]  = 0;                                                                           
-        msMaskFalseSomewhere = 1;                                                                   
+        msMask[idx]  = 0;
+        msMaskFalseSomewhere = 1;
       }
-    }                                                                                               
-    if ( msMaskTrueSomewhere ) {                                                                    
+    }
+    if ( msMaskTrueSomewhere ) {
       if(msMaskFalseSomewhere ) {
-        *msDigest = SI_MS_MASK_SOME;                                                                
+        *msDigest = SI_MS_MASK_SOME;
       } else {
-        *msDigest = SI_MS_MASK_ALL;                                                                 
+        *msDigest = SI_MS_MASK_ALL;
       }
     } else {
-      *msDigest = SI_MS_MASK_NONE;                                                                  
+      *msDigest = SI_MS_MASK_NONE;
     }
   }
 
diff --git a/media/libstagefright/codecs/aacenc/src/pre_echo_control.c b/media/libstagefright/codecs/aacenc/src/pre_echo_control.c
index 1e818a2..1406e11 100644
--- a/media/libstagefright/codecs/aacenc/src/pre_echo_control.c
+++ b/media/libstagefright/codecs/aacenc/src/pre_echo_control.c
@@ -29,7 +29,7 @@
 
 /*****************************************************************************
 *
-* function name:InitPreEchoControl 
+* function name:InitPreEchoControl
 * description: init pre echo control parameter
 *
 *****************************************************************************/
@@ -40,13 +40,13 @@
   Word16 pb;
 
   for(pb=0; pb<numPb; pb++) {
-    pbThresholdNm1[pb] = pbThresholdQuiet[pb];                                   
+    pbThresholdNm1[pb] = pbThresholdQuiet[pb];
   }
 }
 
 /*****************************************************************************
 *
-* function name:PreEchoControl 
+* function name:PreEchoControl
 * description: update shreshold to avoid pre echo
 *			   thr(n) = max(rpmin*thrq(n), min(thrq(n), rpelev*thrq1(n)))
 *
@@ -68,22 +68,22 @@
   (void)maxAllowedIncreaseFactor;
 
   scaling = ((mdctScale - mdctScalenm1) << 1);
-   
+
   if ( scaling > 0 ) {
     for(i = 0; i < numPb; i++) {
       tmpThreshold1 = pbThresholdNm1[i] >> (scaling-1);
       tmpThreshold2 = L_mpy_ls(pbThreshold[i], minRemainingThresholdFactor);
 
       /* copy thresholds to internal memory */
-      pbThresholdNm1[i] = pbThreshold[i];                                        
+      pbThresholdNm1[i] = pbThreshold[i];
 
-       
+
       if(pbThreshold[i] > tmpThreshold1) {
-        pbThreshold[i] = tmpThreshold1;                                          
+        pbThreshold[i] = tmpThreshold1;
       }
-       
+
       if(tmpThreshold2 > pbThreshold[i]) {
-        pbThreshold[i] = tmpThreshold2;                                          
+        pbThreshold[i] = tmpThreshold2;
       }
 
     }
@@ -96,15 +96,15 @@
       tmpThreshold2 = L_mpy_ls(pbThreshold[i], minRemainingThresholdFactor);
 
       /* copy thresholds to internal memory */
-      pbThresholdNm1[i] = pbThreshold[i];                                        
+      pbThresholdNm1[i] = pbThreshold[i];
 
-       
+
       if(((pbThreshold[i] >> scaling) > tmpThreshold1)) {
         pbThreshold[i] = tmpThreshold1 << scaling;
       }
-       
+
       if(tmpThreshold2 > pbThreshold[i]) {
-        pbThreshold[i] = tmpThreshold2;                                          
+        pbThreshold[i] = tmpThreshold2;
       }
 
     }
diff --git a/media/libstagefright/codecs/aacenc/src/psy_configuration.c b/media/libstagefright/codecs/aacenc/src/psy_configuration.c
index 8e599b0..02d92ab 100644
--- a/media/libstagefright/codecs/aacenc/src/psy_configuration.c
+++ b/media/libstagefright/codecs/aacenc/src/psy_configuration.c
@@ -88,17 +88,17 @@
 *
 * function name: atan_1000
 * description:  calculates 1000*atan(x/1000)
-*               based on atan approx for x > 0				
+*               based on atan approx for x > 0
 *				atan(x) = x/((float)1.0f+(float)0.280872f*x*x)  if x < 1
 *						= pi/2 - x/((float)0.280872f +x*x)	    if x >= 1
 * return:       1000*atan(x/1000)
 *
 **********************************************************************************/
-static Word16 atan_1000(Word32 val) 
+static Word16 atan_1000(Word32 val)
 {
   Word32 y;
 
-   
+
   if(L_sub(val, 1000) < 0) {
     y = extract_l(((1000 * val) / (1000 + ((val * val) / ATAN_COEF1))));
   }
@@ -126,9 +126,9 @@
   /* center frequency of fft line */
   center_freq = (fftLine * samplingFreq) / (noOfLines << 1);
   temp =  atan_1000((center_freq << 2) / (3*10));
-  bvalFFTLine = 
+  bvalFFTLine =
     (26600 * atan_1000((center_freq*76) / 100) + 7*temp*temp) / (2*1000*1000 / BARC_SCALE);
-  
+
   return saturate(bvalFFTLine);
 }
 
@@ -148,17 +148,17 @@
   for(i=0; i<numPb; i++) {
     Word16 bv1, bv2;
 
-     
+
     if (i>0)
       bv1 = (pbBarcVal[i] + pbBarcVal[i-1]) >> 1;
     else
       bv1 = pbBarcVal[i] >> 1;
 
-     
+
     if (i < (numPb - 1))
       bv2 = (pbBarcVal[i] + pbBarcVal[i+1]) >> 1;
     else {
-      bv2 = pbBarcVal[i];                                        
+      bv2 = pbBarcVal[i];
     }
 
     bv1 = min((bv1 / BARC_SCALE), max_bark);
@@ -166,9 +166,9 @@
 
     barcThrQuiet = min(BARC_THR_QUIET[bv1], BARC_THR_QUIET[bv2]);
 
-    
+
     /*
-      we calculate 
+      we calculate
       pow(10.0f,(float)(barcThrQuiet - ABS_LEV)*0.1)*(float)ABS_LOW*(pbOffset[i+1] - pbOffset[i]);
     */
 
@@ -196,47 +196,47 @@
   Word16 i;
   Word16 maskLowSprEn, maskHighSprEn;
 
-   
+
   if (sub(blockType, SHORT_WINDOW) != 0) {
-    maskLowSprEn = maskLowSprEnLong;                                     
-       
+    maskLowSprEn = maskLowSprEnLong;
+
     if (bitrate > 22000)
       maskHighSprEn = maskHighSprEnLong;
     else
       maskHighSprEn = maskHighSprEnLongLowBr;
   }
   else {
-    maskLowSprEn = maskLowSprEnShort;            
-    maskHighSprEn = maskHighSprEnShort;          
+    maskLowSprEn = maskLowSprEnShort;
+    maskHighSprEn = maskHighSprEnShort;
   }
 
   for(i=0; i<numPb; i++) {
-     
+
     if (i > 0) {
       Word32 dbVal;
       Word16 dbark = pbBarcValue[i] - pbBarcValue[i-1];
 
       /*
-        we calulate pow(10.0f, -0.1*dbVal/BARC_SCALE) 
+        we calulate pow(10.0f, -0.1*dbVal/BARC_SCALE)
       */
       dbVal = (maskHigh * dbark);
       pbMaskHiFactor[i] = round16(pow2_xy(L_negate(dbVal), (Word32)LOG2_1000));             /* 0.301 log10(2) */
-       
+
       dbVal = (maskLow * dbark);
-      pbMaskLoFactor[i-1] = round16(pow2_xy(L_negate(dbVal),(Word32)LOG2_1000)); 
-       
-      
+      pbMaskLoFactor[i-1] = round16(pow2_xy(L_negate(dbVal),(Word32)LOG2_1000));
+
+
       dbVal = (maskHighSprEn * dbark);
-      pbMaskHiFactorSprEn[i] =  round16(pow2_xy(L_negate(dbVal),(Word32)LOG2_1000)); 
+      pbMaskHiFactorSprEn[i] =  round16(pow2_xy(L_negate(dbVal),(Word32)LOG2_1000));
       dbVal = (maskLowSprEn * dbark);
       pbMaskLoFactorSprEn[i-1] = round16(pow2_xy(L_negate(dbVal),(Word32)LOG2_1000));
     }
     else {
-      pbMaskHiFactor[i] = 0;                     
-      pbMaskLoFactor[numPb-1] = 0;               
+      pbMaskHiFactor[i] = 0;
+      pbMaskLoFactor[numPb-1] = 0;
 
-      pbMaskHiFactorSprEn[i] = 0;                
-      pbMaskLoFactorSprEn[numPb-1] = 0;          
+      pbMaskHiFactorSprEn[i] = 0;
+      pbMaskLoFactorSprEn[numPb-1] = 0;
     }
   }
 
@@ -258,12 +258,12 @@
   Word16 i;
   Word16 pbBval0, pbBval1;
 
-  pbBval0 = 0;                                       
+  pbBval0 = 0;
 
   for(i=0; i<numPb; i++){
     pbBval1 = BarcLineValue(numLines, pbOffset[i+1], samplingFrequency);
     pbBval[i] = (pbBval0 + pbBval1) >> 1;
-    pbBval0 = pbBval1;                              
+    pbBval0 = pbBval1;
   }
 }
 
@@ -295,38 +295,38 @@
 
   pePerWindow = bits2pe(extract_l((bitrate * numLines) / samplerate));
 
-  pbVal0 = 0;                                                    
+  pbVal0 = 0;
 
   for (sfb=0; sfb<sfbActive; sfb++) {
 
     pbVal1 = (pbBarcVal[sfb] << 1) - pbVal0;
     barcWidth = pbVal1 - pbVal0;
-    pbVal0 = pbVal1;                                             
+    pbVal0 = pbVal1;
 
     /* allow at least 2.4% of pe for each active barc */
 	pePart = ((pePerWindow * 24) * (max_bark * barcWidth)) /
         (pbBarcVal[sfbActive-1] * (sfbOffset[sfb+1] - sfbOffset[sfb]));
-   
-      
-    pePart = min(pePart, 8400); 
+
+
+    pePart = min(pePart, 8400);
     pePart = max(pePart, 1400);
 
     /* minSnr(n) = 1/(2^sfbPemin(n)/w(n) - 1.5)*/
 	/* we add an offset of 2^16 to the pow functions */
 	/* 0xc000 = 1.5*(1 << 15)*/
-      
+
     snr = pow2_xy((pePart - 16*1000),1000) - 0x0000c000;
-      
+
     if(snr > 0x00008000)
 	{
 		shift = norm_l(snr);
-		snr = Div_32(0x00008000 << shift, snr << shift);  
+		snr = Div_32(0x00008000 << shift, snr << shift);
 	}
 	else
 	{
 		snr = 0x7fffffff;
 	}
-      
+
     /* upper limit is -1 dB */
     snr = min(snr, c_maxsnr);
     /* lower limit is -25 dB */
@@ -354,7 +354,7 @@
   /*
     init sfb table
   */
-  samplerateindex = GetSRIndex(samplerate);  
+  samplerateindex = GetSRIndex(samplerate);
   psyConf->sfbCnt = sfBandTotalLong[samplerateindex];
   psyConf->sfbOffset = sfBandTabLong + sfBandTabLongOffset[samplerateindex];
   psyConf->sampRateIdx = samplerateindex;
@@ -391,19 +391,19 @@
   /*
     init ratio
   */
-  psyConf->ratio = c_ratio;      
+  psyConf->ratio = c_ratio;
 
-  psyConf->maxAllowedIncreaseFactor = 2;              
-  psyConf->minRemainingThresholdFactor = c_minRemainingThresholdFactor;    /* 0.01 *(1 << 15)*/  
+  psyConf->maxAllowedIncreaseFactor = 2;
+  psyConf->minRemainingThresholdFactor = c_minRemainingThresholdFactor;    /* 0.01 *(1 << 15)*/
 
-  psyConf->clipEnergy = c_maxClipEnergyLong;                   
+  psyConf->clipEnergy = c_maxClipEnergyLong;
   psyConf->lowpassLine = extract_l((bandwidth<<1) * FRAME_LEN_LONG / samplerate);
 
   for (sfb = 0; sfb < psyConf->sfbCnt; sfb++) {
     if (sub(psyConf->sfbOffset[sfb], psyConf->lowpassLine) >= 0)
       break;
   }
-  psyConf->sfbActive = sfb;                 
+  psyConf->sfbActive = sfb;
 
   /*
     calculate minSnr
@@ -429,7 +429,7 @@
 Word16 InitPsyConfigurationShort(Word32 bitrate,
                                  Word32 samplerate,
                                  Word16 bandwidth,
-                                 PSY_CONFIGURATION_SHORT *psyConf) 
+                                 PSY_CONFIGURATION_SHORT *psyConf)
 {
   Word32 samplerateindex;
   Word16 sfbBarcVal[MAX_SFB_SHORT];
@@ -437,7 +437,7 @@
   /*
     init sfb table
   */
-  samplerateindex = GetSRIndex(samplerate);  
+  samplerateindex = GetSRIndex(samplerate);
   psyConf->sfbCnt = sfBandTotalShort[samplerateindex];
   psyConf->sfbOffset = sfBandTabShort + sfBandTabShortOffset[samplerateindex];
   psyConf->sampRateIdx = samplerateindex;
@@ -473,21 +473,21 @@
   /*
     init ratio
   */
-  psyConf->ratio = c_ratio;                                                      
+  psyConf->ratio = c_ratio;
 
-  psyConf->maxAllowedIncreaseFactor = 2;                                         
-  psyConf->minRemainingThresholdFactor = c_minRemainingThresholdFactor;                            	 
+  psyConf->maxAllowedIncreaseFactor = 2;
+  psyConf->minRemainingThresholdFactor = c_minRemainingThresholdFactor;
 
-  psyConf->clipEnergy = c_maxClipEnergyShort;                                    
+  psyConf->clipEnergy = c_maxClipEnergyShort;
 
   psyConf->lowpassLine = extract_l(((bandwidth << 1) * FRAME_LEN_SHORT) / samplerate);
- 
+
   for (sfb = 0; sfb < psyConf->sfbCnt; sfb++) {
-     
+
     if (psyConf->sfbOffset[sfb] >= psyConf->lowpassLine)
       break;
   }
-  psyConf->sfbActive = sfb;                                                      
+  psyConf->sfbActive = sfb;
 
   /*
     calculate minSnr
diff --git a/media/libstagefright/codecs/aacenc/src/psy_main.c b/media/libstagefright/codecs/aacenc/src/psy_main.c
index 3d0a355..085acb8 100644
--- a/media/libstagefright/codecs/aacenc/src/psy_main.c
+++ b/media/libstagefright/codecs/aacenc/src/psy_main.c
@@ -81,7 +81,7 @@
   Word32 *mdctSpectrum;
   Word32 *scratchTNS;
   Word16 *mdctDelayBuffer;
-  
+
   mdctSpectrum = (Word32 *)mem_malloc(pMemOP, nChan * FRAME_LEN_LONG * sizeof(Word32), 32, VO_INDEX_ENC_AAC);
   if(NULL == mdctSpectrum)
 	  return 1;
@@ -99,7 +99,7 @@
   }
 
   for (i=0; i<nChan; i++){
-    hPsy->psyData[i].mdctDelayBuffer = mdctDelayBuffer + i*BLOCK_SWITCHING_OFFSET;      
+    hPsy->psyData[i].mdctDelayBuffer = mdctDelayBuffer + i*BLOCK_SWITCHING_OFFSET;
     hPsy->psyData[i].mdctSpectrum = mdctSpectrum + i*FRAME_LEN_LONG;
   }
 
@@ -124,12 +124,12 @@
   {
 	if(hPsy->psyData[0].mdctDelayBuffer)
 		mem_free(pMemOP, hPsy->psyData[0].mdctDelayBuffer, VO_INDEX_ENC_AAC);
-      
+
     if(hPsy->psyData[0].mdctSpectrum)
 		mem_free(pMemOP, hPsy->psyData[0].mdctSpectrum, VO_INDEX_ENC_AAC);
 
     for (nch=0; nch<MAX_CHANNELS; nch++){
-	  hPsy->psyData[nch].mdctDelayBuffer = NULL;      
+	  hPsy->psyData[nch].mdctDelayBuffer = NULL;
 	  hPsy->psyData[nch].mdctSpectrum = NULL;
 	}
 
@@ -216,14 +216,14 @@
 
   if (!err)
     for(ch=0;ch < channels;ch++){
-  
+
       InitBlockSwitching(&hPsy->psyData[ch].blockSwitchingControl,
                          bitRate, channels);
 
       InitPreEchoControl(hPsy->psyData[ch].sfbThresholdnm1,
                          hPsy->psyConfLong.sfbCnt,
                          hPsy->psyConfLong.sfbThresholdQuiet);
-      hPsy->psyData[ch].mdctScalenm1 = 0;                                
+      hPsy->psyData[ch].mdctScalenm1 = 0;
     }
 
 	return(err);
@@ -241,7 +241,7 @@
 
 Word16 psyMain(Word16                   nChannels,
                ELEMENT_INFO            *elemInfo,
-               Word16                  *timeSignal, 
+               Word16                  *timeSignal,
                PSY_DATA                 psyData[MAX_CHANNELS],
                TNS_DATA                 tnsData[MAX_CHANNELS],
                PSY_CONFIGURATION_LONG  *hPsyConfLong,
@@ -260,8 +260,8 @@
   Word16 channels;
   Word16 maxScale;
 
-  channels = elemInfo->nChannelsInEl;                            
-  maxScale = 0;                                                  
+  channels = elemInfo->nChannelsInEl;
+  maxScale = 0;
 
   /* block switching */
   for(ch = 0; ch < channels; ch++) {
@@ -291,7 +291,7 @@
   /* common scaling for all channels */
   for (ch=0; ch<channels; ch++) {
     Word16 scaleDiff = maxScale - mdctScalingArray[ch];
-     
+
     if (scaleDiff > 0) {
       Word32 *Spectrum = psyData[ch].mdctSpectrum;
 	  for(line=0; line<FRAME_LEN_LONG; line++) {
@@ -299,11 +299,11 @@
 		Spectrum++;
       }
     }
-    psyData[ch].mdctScale = maxScale;                                    
+    psyData[ch].mdctScale = maxScale;
   }
 
   for (ch=0; ch<channels; ch++) {
-     
+
     if(psyData[ch].blockSwitchingControl.windowSequence != SHORT_WINDOW) {
       /* update long block parameter */
 	  advancePsychLong(&psyData[ch],
@@ -317,7 +317,7 @@
       /* determine maxSfb */
       for (sfb=hPsyConfLong->sfbCnt-1; sfb>=0; sfb--) {
         for (line=hPsyConfLong->sfbOffset[sfb+1] - 1; line>=hPsyConfLong->sfbOffset[sfb]; line--) {
-           
+
           if (psyData[ch].mdctSpectrum[line] != 0) break;
         }
         if (line >= hPsyConfLong->sfbOffset[sfb]) break;
@@ -326,7 +326,7 @@
 
       /* Calc bandwise energies for mid and side channel
          Do it only if 2 channels exist */
-       
+
       if (ch == 1)
         advancePsychLongMS(psyData, hPsyConfLong);
     }
@@ -341,7 +341,7 @@
 
       /* Calc bandwise energies for mid and side channel
          Do it only if 2 channels exist */
-       
+
       if (ch == 1)
         advancePsychShortMS (psyData, hPsyConfShort);
     }
@@ -349,7 +349,7 @@
 
   /* group short data */
   for(ch=0; ch<channels; ch++) {
-     
+
     if (psyData[ch].blockSwitchingControl.windowSequence == SHORT_WINDOW) {
       groupShortData(psyData[ch].mdctSpectrum,
                      pScratchTns,
@@ -374,10 +374,10 @@
     stereo Processing
   */
   if (channels == 2) {
-    psyOutElement->toolsInfo.msDigest = MS_NONE;                 
+    psyOutElement->toolsInfo.msDigest = MS_NONE;
     maxSfbPerGroup[0] = maxSfbPerGroup[1] = max(maxSfbPerGroup[0], maxSfbPerGroup[1]);
 
-     
+
     if (psyData[0].blockSwitchingControl.windowSequence != SHORT_WINDOW)
       MsStereoProcessing(psyData[0].sfbEnergy.sfbLong,
                          psyData[1].sfbEnergy.sfbLong,
@@ -420,7 +420,7 @@
     build output
   */
   for(ch=0;ch<channels;ch++) {
-     
+
     if (psyData[ch].blockSwitchingControl.windowSequence != SHORT_WINDOW)
       BuildInterface(psyData[ch].mdctSpectrum,
                      psyData[ch].mdctScale,
@@ -483,7 +483,7 @@
   /* low pass */
   data0 = psyData->mdctSpectrum + hPsyConfLong->lowpassLine;
   for(i=hPsyConfLong->lowpassLine; i<FRAME_LEN_LONG; i++) {
-    *data0++ = 0;                                
+    *data0++ = 0;
   }
 
   /* Calc sfb-bandwise mdct-energies for left and right channel */
@@ -505,7 +505,7 @@
             psyData->blockSwitchingControl.windowSequence,
             psyData->sfbEnergy.sfbLong);
 
-  /*  TnsSync */   
+  /*  TnsSync */
   if (ch == 1) {
     TnsSync(tnsData,
             tnsData2,
@@ -514,7 +514,7 @@
             psyData->blockSwitchingControl.windowSequence);
   }
 
-  /*  Tns Encoder */ 
+  /*  Tns Encoder */
   TnsEncode(&psyOutChannel->tnsInfo,
             tnsData,
             hPsyConfLong->sfbCnt,
@@ -532,15 +532,15 @@
     *data1++ = min(tdata, clipEnergy);
   }
 
-  /* Calc sfb-bandwise mdct-energies for left and right channel again */   
+  /* Calc sfb-bandwise mdct-energies for left and right channel again */
   if (tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive!=0) {
-    Word16 tnsStartBand = hPsyConfLong->tnsConf.tnsStartBand;                            
+    Word16 tnsStartBand = hPsyConfLong->tnsConf.tnsStartBand;
     CalcBandEnergy( psyData->mdctSpectrum,
                     hPsyConfLong->sfbOffset+tnsStartBand,
                     hPsyConfLong->sfbActive - tnsStartBand,
                     psyData->sfbEnergy.sfbLong+tnsStartBand,
                     &psyData->sfbEnergySum.sfbLong);
-    
+
 	data0 = psyData->sfbEnergy.sfbLong;
 	tdata = psyData->sfbEnergySum.sfbLong;
 	for (i=0; i<tnsStartBand; i++)
@@ -565,13 +565,13 @@
 	  data0++; data1++;
   }
 
-  /* preecho control */   
+  /* preecho control */
   if (psyData->blockSwitchingControl.windowSequence == STOP_WINDOW) {
     data0 = psyData->sfbThresholdnm1;
 	for (i=hPsyConfLong->sfbCnt; i; i--) {
-      *data0++ = MAX_32;                              
+      *data0++ = MAX_32;
     }
-    psyData->mdctScalenm1 = 0;                                           
+    psyData->mdctScalenm1 = 0;
   }
 
   PreEchoControl( psyData->sfbThresholdnm1,
@@ -581,15 +581,15 @@
                   psyData->sfbThreshold.sfbLong,
                   psyData->mdctScale,
                   psyData->mdctScalenm1);
-  psyData->mdctScalenm1 = psyData->mdctScale;                            
+  psyData->mdctScalenm1 = psyData->mdctScale;
 
-   
+
   if (psyData->blockSwitchingControl.windowSequence== START_WINDOW) {
     data0 = psyData->sfbThresholdnm1;
 	for (i=hPsyConfLong->sfbCnt; i; i--) {
-      *data0++ = MAX_32;                              
+      *data0++ = MAX_32;
     }
-    psyData->mdctScalenm1 = 0;                                           
+    psyData->mdctScalenm1 = 0;
   }
 
   /* apply tns mult table on cb thresholds */
@@ -603,13 +603,13 @@
   data0 = psyData->sfbSpreadedEnergy.sfbLong;
   data1 = psyData->sfbEnergy.sfbLong;
   for (i=hPsyConfLong->sfbCnt; i; i--) {
-    //psyData->sfbSpreadedEnergy.sfbLong[i] = psyData->sfbEnergy.sfbLong[i];       
+    //psyData->sfbSpreadedEnergy.sfbLong[i] = psyData->sfbEnergy.sfbLong[i];
 	  *data0++ = *data1++;
   }
 
   /* spreading energy */
   SpreadingMax(hPsyConfLong->sfbCnt,
-               hPsyConfLong->sfbMaskLowFactorSprEn, 
+               hPsyConfLong->sfbMaskLowFactorSprEn,
                hPsyConfLong->sfbMaskHighFactorSprEn,
                psyData->sfbSpreadedEnergy.sfbLong);
 
@@ -619,7 +619,7 @@
 /*****************************************************************************
 *
 * function name: advancePsychLongMS
-* description:   update mdct-energies for left add or minus right channel 
+* description:   update mdct-energies for left add or minus right channel
 *				for long block
 *
 *****************************************************************************/
@@ -657,7 +657,7 @@
   Word32 w;
   Word32 normEnergyShift = (psyData->mdctScale + 1) << 1; /* in reference code, mdct spectrum must be multipied with 2, so +1 */
   Word32 clipEnergy = hPsyConfShort->clipEnergy >> normEnergyShift;
-  Word32 wOffset = 0;     
+  Word32 wOffset = 0;
   Word32 *data0, *data1;
 
   for(w = 0; w < TRANS_FAC; w++) {
@@ -666,7 +666,7 @@
     /* low pass */
     data0 = psyData->mdctSpectrum + wOffset + hPsyConfShort->lowpassLine;
 	for(i=hPsyConfShort->lowpassLine; i<FRAME_LEN_SHORT; i++){
-      *data0++ = 0;                                      
+      *data0++ = 0;
     }
 
     /* Calc sfb-bandwise mdct-energies for left and right channel */
@@ -713,9 +713,9 @@
       *data0++ = min(tdata, clipEnergy);
     }
 
-    /* Calc sfb-bandwise mdct-energies for left and right channel again */     
+    /* Calc sfb-bandwise mdct-energies for left and right channel again */
     if (tnsData->dataRaw.tnsShort.subBlockInfo[w].tnsActive != 0) {
-      Word16 tnsStartBand = hPsyConfShort->tnsConf.tnsStartBand;                            
+      Word16 tnsStartBand = hPsyConfShort->tnsConf.tnsStartBand;
       CalcBandEnergy( psyData->mdctSpectrum+wOffset,
                       hPsyConfShort->sfbOffset+tnsStartBand,
                       (hPsyConfShort->sfbActive - tnsStartBand),
@@ -748,7 +748,7 @@
 	}
 
 
-    /* preecho */     
+    /* preecho */
     PreEchoControl( psyData->sfbThresholdnm1,
                     hPsyConfShort->sfbCnt,
                     hPsyConfShort->maxAllowedIncreaseFactor,
@@ -770,14 +770,14 @@
 	  *data0++ = *data1++;
     }
     SpreadingMax(hPsyConfShort->sfbCnt,
-                 hPsyConfShort->sfbMaskLowFactorSprEn, 
+                 hPsyConfShort->sfbMaskLowFactorSprEn,
                  hPsyConfShort->sfbMaskHighFactorSprEn,
                  psyData->sfbSpreadedEnergy.sfbShort[w]);
 
     wOffset += FRAME_LEN_SHORT;
   } /* for TRANS_FAC */
 
-  psyData->mdctScalenm1 = psyData->mdctScale;              
+  psyData->mdctScalenm1 = psyData->mdctScale;
 
   return 0;
 }
@@ -785,7 +785,7 @@
 /*****************************************************************************
 *
 * function name: advancePsychShortMS
-* description:   update mdct-energies for left add or minus right channel 
+* description:   update mdct-energies for left add or minus right channel
 *				for short block
 *
 *****************************************************************************/
@@ -793,7 +793,7 @@
                                    const PSY_CONFIGURATION_SHORT *hPsyConfShort)
 {
   Word32 w, wOffset;
-  wOffset = 0;                                   
+  wOffset = 0;
   for(w=0; w<TRANS_FAC; w++) {
     CalcBandEnergyMS(psyData[0].mdctSpectrum+wOffset,
                      psyData[1].mdctSpectrum+wOffset,
diff --git a/media/libstagefright/codecs/aacenc/src/qc_main.c b/media/libstagefright/codecs/aacenc/src/qc_main.c
index e8c39e4..df6d46e 100644
--- a/media/libstagefright/codecs/aacenc/src/qc_main.c
+++ b/media/libstagefright/codecs/aacenc/src/qc_main.c
@@ -68,12 +68,12 @@
   result = (FRAME_LEN_LONG >> 3) * bitRate;
   quot = result / sampleRate;
 
-   
+
   if (mode == FRAME_LEN_BYTES_MODULO) {
     result -= quot * sampleRate;
   }
   else { /* FRAME_LEN_BYTES_INT */
-    result = quot;                                      
+    result = quot;
   }
 
   return result;
@@ -83,7 +83,7 @@
 *
 *  function name:framePadding
 *  description: Calculates if padding is needed for actual frame
-*  returns: paddingOn or not 
+*  returns: paddingOn or not
 *
 *****************************************************************************/
 static Word16 framePadding(Word32 bitRate,
@@ -93,16 +93,16 @@
   Word16 paddingOn;
   Word16 difference;
 
-  paddingOn = 0;                                                 
+  paddingOn = 0;
 
   difference = calcFrameLen( bitRate,
                              sampleRate,
                              FRAME_LEN_BYTES_MODULO );
   *paddingRest = *paddingRest - difference;
 
-   
+
   if (*paddingRest <= 0 ) {
-    paddingOn = 1;                                               
+    paddingOn = 1;
     *paddingRest = *paddingRest + sampleRate;
   }
 
@@ -123,12 +123,12 @@
   Word32 i;
   Word16 *quantSpec;
   Word16 *scf;
-  UWord16 *maxValueInSfb;	
-	
+  UWord16 *maxValueInSfb;
+
   quantSpec = (Word16 *)mem_malloc(pMemOP, nChannels * FRAME_LEN_LONG * sizeof(Word16), 32, VO_INDEX_ENC_AAC);
   if(NULL == quantSpec)
 	  return 1;
-  scf = (Word16 *)mem_malloc(pMemOP, nChannels * MAX_GROUPED_SFB * sizeof(Word16), 32, VO_INDEX_ENC_AAC);     
+  scf = (Word16 *)mem_malloc(pMemOP, nChannels * MAX_GROUPED_SFB * sizeof(Word16), 32, VO_INDEX_ENC_AAC);
   if(NULL == scf)
   {
 	  return 1;
@@ -141,12 +141,12 @@
 
   for (i=0; i<nChannels; i++) {
     hQC->qcChannel[i].quantSpec = quantSpec + i*FRAME_LEN_LONG;
-    
+
     hQC->qcChannel[i].maxValueInSfb = maxValueInSfb + i*MAX_GROUPED_SFB;
-    
+
     hQC->qcChannel[i].scf = scf + i*MAX_GROUPED_SFB;
   }
- 
+
   return 0;
 }
 
@@ -165,21 +165,21 @@
    {
       if(hQC->qcChannel[0].quantSpec);
 		 mem_free(pMemOP, hQC->qcChannel[0].quantSpec, VO_INDEX_ENC_AAC);
-    
+
       if(hQC->qcChannel[0].maxValueInSfb)
 		  mem_free(pMemOP, hQC->qcChannel[0].maxValueInSfb, VO_INDEX_ENC_AAC);
-    
+
 	  if(hQC->qcChannel[0].scf)
 		  mem_free(pMemOP, hQC->qcChannel[0].scf, VO_INDEX_ENC_AAC);
 
 	  for (i=0; i<MAX_CHANNELS; i++) {
 		  hQC->qcChannel[i].quantSpec = NULL;
-		  
+
 		  hQC->qcChannel[i].maxValueInSfb = NULL;
-		  
+
 		  hQC->qcChannel[i].scf = NULL;
 	  }
-   } 
+   }
 }
 
 /*********************************************************************************
@@ -204,8 +204,8 @@
 **********************************************************************************/
 void QCDelete(QC_STATE *hQC, VO_MEM_OPERATOR *pMemOP)
 {
- 
-  /* 
+
+  /*
      nothing to do
   */
   hQC=NULL;
@@ -221,15 +221,15 @@
 Word16 QCInit(QC_STATE *hQC,
               struct QC_INIT *init)
 {
-  hQC->nChannels       = init->elInfo->nChannelsInEl;              
-  hQC->maxBitsTot      = init->maxBits;                            
+  hQC->nChannels       = init->elInfo->nChannelsInEl;
+  hQC->maxBitsTot      = init->maxBits;
   hQC->bitResTot       = sub(init->bitRes, init->averageBits);
-  hQC->averageBitsTot  = init->averageBits;                        
-  hQC->maxBitFac       = init->maxBitFac;                          
+  hQC->averageBitsTot  = init->averageBits;
+  hQC->maxBitFac       = init->maxBitFac;
 
-  hQC->padding.paddingRest = init->padding.paddingRest;            
+  hQC->padding.paddingRest = init->padding.paddingRest;
 
-  hQC->globStatBits    = 3;                          /* for ID_END */ 
+  hQC->globStatBits    = 3;                          /* for ID_END */
 
   /* channel elements init */
   InitElementBits(&hQC->elementBits,
@@ -248,13 +248,13 @@
 
 
 /*********************************************************************************
-* 
+*
 * function name: QCMain
 * description:  quantization and coding the spectrum
 * returns:      0 if success
 *
 **********************************************************************************/
-Word16 QCMain(QC_STATE* hQC,              
+Word16 QCMain(QC_STATE* hQC,
               ELEMENT_BITS* elBits,
               ATS_ELEMENT* adjThrStateElement,
               PSY_OUT_CHANNEL  psyOutChannel[MAX_CHANNELS],  /* may be modified in-place */
@@ -262,34 +262,34 @@
               QC_OUT_CHANNEL  qcOutChannel[MAX_CHANNELS],    /* out                      */
               QC_OUT_ELEMENT* qcOutElement,
               Word16 nChannels,
-			  Word16 ancillaryDataBytes)      
+			  Word16 ancillaryDataBytes)
 {
   Word16 maxChDynBits[MAX_CHANNELS];
-  Word16 chBitDistribution[MAX_CHANNELS];  
+  Word16 chBitDistribution[MAX_CHANNELS];
   Word32 ch;
-   
+
   if (elBits->bitResLevel < 0) {
     return -1;
   }
-   
+
   if (elBits->bitResLevel > elBits->maxBitResBits) {
     return -1;
   }
 
   qcOutElement->staticBitsUsed = countStaticBitdemand(psyOutChannel,
                                                       psyOutElement,
-                                                      nChannels, 
+                                                      nChannels,
 													  qcOutElement->adtsUsed);
 
-   
+
   if (ancillaryDataBytes) {
     qcOutElement->ancBitsUsed = 7 + (ancillaryDataBytes << 3);
-     
+
     if (ancillaryDataBytes >= 15)
       qcOutElement->ancBitsUsed = qcOutElement->ancBitsUsed + 8;
   }
   else {
-    qcOutElement->ancBitsUsed = 0; 
+    qcOutElement->ancBitsUsed = 0;
   }
 
   CalcFormFactor(hQC->logSfbFormFactor, hQC->sfbNRelevantLines, hQC->logSfbEnergy, psyOutChannel, nChannels);
@@ -301,7 +301,7 @@
                    psyOutElement,
                    chBitDistribution,
                    hQC->logSfbEnergy,
-                   hQC->sfbNRelevantLines,                   
+                   hQC->sfbNRelevantLines,
                    qcOutElement,
 				   elBits,
 				   nChannels,
@@ -323,14 +323,14 @@
     maxChDynBits[ch] = extract_l(chBitDistribution[ch] * maxDynBits / 1000);
   }
 
-  qcOutElement->dynBitsUsed = 0;                                         
+  qcOutElement->dynBitsUsed = 0;
   for (ch = 0; ch < nChannels; ch++) {
     Word32 chDynBits;
     Flag   constraintsFulfilled;
     Word32 iter;
-    iter = 0;                                                          
+    iter = 0;
     do {
-      constraintsFulfilled = 1;                                        
+      constraintsFulfilled = 1;
 
       QuantizeSpectrum(psyOutChannel[ch].sfbCnt,
                        psyOutChannel[ch].maxSfbPerGroup,
@@ -340,14 +340,14 @@
                        qcOutChannel[ch].globalGain,
                        qcOutChannel[ch].scf,
                        qcOutChannel[ch].quantSpec);
-       
+
       if (calcMaxValueInSfb(psyOutChannel[ch].sfbCnt,
                             psyOutChannel[ch].maxSfbPerGroup,
                             psyOutChannel[ch].sfbPerGroup,
                             psyOutChannel[ch].sfbOffsets,
                             qcOutChannel[ch].quantSpec,
                             qcOutChannel[ch].maxValueInSfb) > MAX_QUANT) {
-        constraintsFulfilled = 0;                                        
+        constraintsFulfilled = 0;
       }
 
       chDynBits = dynBitCount(qcOutChannel[ch].quantSpec,
@@ -359,24 +359,24 @@
                               psyOutChannel[ch].sfbPerGroup,
                               psyOutChannel[ch].sfbOffsets,
                               &qcOutChannel[ch].sectionData);
-       
+
       if (chDynBits >= maxChDynBits[ch]) {
-        constraintsFulfilled = 0;                                        
+        constraintsFulfilled = 0;
       }
-       
+
       if (!constraintsFulfilled) {
         qcOutChannel[ch].globalGain = qcOutChannel[ch].globalGain + 1;
       }
 
       iter = iter + 1;
-       
+
     } while(!constraintsFulfilled);
 
     qcOutElement->dynBitsUsed = qcOutElement->dynBitsUsed + chDynBits;
 
-    qcOutChannel[ch].mdctScale    = psyOutChannel[ch].mdctScale;         
-    qcOutChannel[ch].groupingMask = psyOutChannel[ch].groupingMask;      
-    qcOutChannel[ch].windowShape  = psyOutChannel[ch].windowShape;       
+    qcOutChannel[ch].mdctScale    = psyOutChannel[ch].mdctScale;
+    qcOutChannel[ch].groupingMask = psyOutChannel[ch].groupingMask;
+    qcOutChannel[ch].windowShape  = psyOutChannel[ch].windowShape;
   }
 
   /* save dynBitsUsed for correction of bits2pe relation */
@@ -411,13 +411,13 @@
   Word16 sfbOffs, sfb;
   Word16 maxValueAll;
 
-  maxValueAll = 0;                                       
+  maxValueAll = 0;
 
   for(sfbOffs=0;sfbOffs<sfbCnt;sfbOffs+=sfbPerGroup) {
     for (sfb = 0; sfb < maxSfbPerGroup; sfb++) {
       Word16 line;
       Word16 maxThisSfb;
-      maxThisSfb = 0;                                    
+      maxThisSfb = 0;
 
       for (line = sfbOffset[sfbOffs+sfb]; line < sfbOffset[sfbOffs+sfb+1]; line++) {
         Word16 absVal;
@@ -425,7 +425,7 @@
         maxThisSfb = max(maxThisSfb, absVal);
       }
 
-      maxValue[sfbOffs+sfb] = maxThisSfb;                
+      maxValue[sfbOffs+sfb] = maxThisSfb;
       maxValueAll = max(maxValueAll, maxThisSfb);
     }
   }
@@ -441,15 +441,15 @@
 **********************************************************************************/
 void updateBitres(QC_STATE* qcKernel,
                   QC_OUT*   qcOut)
-                  
+
 {
   ELEMENT_BITS *elBits;
- 
-  qcKernel->bitResTot = 0;                               
+
+  qcKernel->bitResTot = 0;
 
   elBits = &qcKernel->elementBits;
 
-   
+
   if (elBits->averageBits > 0) {
     /* constant bitrate */
     Word16 bitsUsed;
@@ -460,8 +460,8 @@
   }
   else {
     /* variable bitrate */
-    elBits->bitResLevel = elBits->maxBits;           
-    qcKernel->bitResTot = qcKernel->maxBitsTot;      
+    elBits->bitResLevel = elBits->maxBits;
+    qcKernel->bitResTot = qcKernel->maxBitsTot;
   }
 }
 
@@ -476,55 +476,55 @@
 {
   Word32 nFullFillElem;
   Word32 totFillBits;
-  Word16 diffBits;  
+  Word16 diffBits;
   Word16 bitsUsed;
 
-  totFillBits = 0;                                       
+  totFillBits = 0;
 
-  qcOut->totStaticBitsUsed = qcKernel->globStatBits;     
+  qcOut->totStaticBitsUsed = qcKernel->globStatBits;
   qcOut->totStaticBitsUsed += qcOut->qcElement.staticBitsUsed;
   qcOut->totDynBitsUsed    = qcOut->qcElement.dynBitsUsed;
   qcOut->totAncBitsUsed    = qcOut->qcElement.ancBitsUsed;
   qcOut->totFillBits       = qcOut->qcElement.fillBits;
-   
+
   if (qcOut->qcElement.fillBits) {
     totFillBits += qcOut->qcElement.fillBits;
   }
 
   nFullFillElem = (max((qcOut->totFillBits - 1), 0) / maxFillElemBits) * maxFillElemBits;
-  
+
   qcOut->totFillBits = qcOut->totFillBits - nFullFillElem;
 
   /* check fill elements */
-   
+
   if (qcOut->totFillBits > 0) {
     /* minimum Fillelement contains 7 (TAG + byte cnt) bits */
     qcOut->totFillBits = max(7, qcOut->totFillBits);
     /* fill element size equals n*8 + 7 */
-    qcOut->totFillBits = qcOut->totFillBits + ((8 - ((qcOut->totFillBits - 7) & 0x0007)) & 0x0007);     
+    qcOut->totFillBits = qcOut->totFillBits + ((8 - ((qcOut->totFillBits - 7) & 0x0007)) & 0x0007);
   }
 
   qcOut->totFillBits = qcOut->totFillBits + nFullFillElem;
 
   /* now distribute extra fillbits and alignbits over channel elements */
   qcOut->alignBits = 7 - ((qcOut->totDynBitsUsed + qcOut->totStaticBitsUsed +
-                           qcOut->totAncBitsUsed + qcOut->totFillBits - 1) & 0x0007);             
+                           qcOut->totAncBitsUsed + qcOut->totFillBits - 1) & 0x0007);
 
-     
+
   if ( (qcOut->alignBits + qcOut->totFillBits - totFillBits == 8) &&
        (qcOut->totFillBits > 8))
     qcOut->totFillBits = qcOut->totFillBits - 8;
 
-   
+
   diffBits = qcOut->alignBits + qcOut->totFillBits - totFillBits;
-   
+
   if(diffBits>=0) {
     qcOut->qcElement.fillBits += diffBits;
   }
 
   bitsUsed = qcOut->totDynBitsUsed + qcOut->totStaticBitsUsed + qcOut->totAncBitsUsed;
   bitsUsed = bitsUsed + qcOut->totFillBits + qcOut->alignBits;
-   
+
   if (bitsUsed > qcKernel->maxBitsTot) {
     return -1;
   }
@@ -564,9 +564,9 @@
   codeBitsLast = hQC->averageBitsTot - hQC->globStatBits;
   codeBits     = frameLen - hQC->globStatBits;
 
-  /* calculate bits for every channel element */   
+  /* calculate bits for every channel element */
   if (codeBits != codeBitsLast) {
-    Word16 totalBits = 0;                                       
+    Word16 totalBits = 0;
 
     hQC->elementBits.averageBits = (hQC->elementBits.relativeBits * codeBits) >> 16; /* relativeBits was scaled down by 2 */
     totalBits += hQC->elementBits.averageBits;
@@ -574,7 +574,7 @@
     hQC->elementBits.averageBits = hQC->elementBits.averageBits + (codeBits - totalBits);
   }
 
-  hQC->averageBitsTot = frameLen;                        
+  hQC->averageBitsTot = frameLen;
 
   return 0;
 }
diff --git a/media/libstagefright/codecs/aacenc/src/quantize.c b/media/libstagefright/codecs/aacenc/src/quantize.c
index 973554e..54add2f 100644
--- a/media/libstagefright/codecs/aacenc/src/quantize.c
+++ b/media/libstagefright/codecs/aacenc/src/quantize.c
@@ -34,32 +34,32 @@
 
 /*****************************************************************************
 *
-* function name:pow34 
-* description: calculate $x^{\frac{3}{4}}, for 0.5 < x < 1.0$.  
+* function name:pow34
+* description: calculate $x^{\frac{3}{4}}, for 0.5 < x < 1.0$.
 *
 *****************************************************************************/
 __inline Word32 pow34(Word32 x)
 {
   /* index table using MANT_DIGITS bits, but mask out the sign bit and the MSB
-     which is always one */   
+     which is always one */
   return mTab_3_4[(x >> (INT_BITS-2-MANT_DIGITS)) & (MANT_SIZE-1)];
 }
 
 
 /*****************************************************************************
 *
-* function name:quantizeSingleLine 
-* description: quantizes spectrum  
-*              quaSpectrum = mdctSpectrum^3/4*2^(-(3/16)*gain)    
+* function name:quantizeSingleLine
+* description: quantizes spectrum
+*              quaSpectrum = mdctSpectrum^3/4*2^(-(3/16)*gain)
 *
 *****************************************************************************/
 static Word16 quantizeSingleLine(const Word16 gain, const Word32 absSpectrum)
 {
   Word32 e, minusFinalExp, finalShift;
   Word32 x;
-  Word16 qua = 0;                        
+  Word16 qua = 0;
 
-   
+
   if (absSpectrum) {
     e = norm_l(absSpectrum);
     x = pow34(absSpectrum << e);
@@ -71,7 +71,7 @@
 
     /* separate the exponent into a shift, and a multiply */
     finalShift = minusFinalExp >> 4;
-     
+
     if (finalShift < INT_BITS) {
       x = L_mpy_wx(x, pow2tominusNover16[minusFinalExp & 15]);
 
@@ -84,7 +84,7 @@
 		  x >>= finalShift;
 	  else
 		  x <<= (-finalShift);
-		
+
 	  qua = saturate(x);
     }
   }
@@ -94,10 +94,10 @@
 
 /*****************************************************************************
 *
-* function name:quantizeLines 
-* description: quantizes spectrum lines  
-*              quaSpectrum = mdctSpectrum^3/4*2^(-(3/16)*gain)    
-*  input: global gain, number of lines to process, spectral data         
+* function name:quantizeLines
+* description: quantizes spectrum lines
+*              quaSpectrum = mdctSpectrum^3/4*2^(-(3/16)*gain)
+*  input: global gain, number of lines to process, spectral data
 *  output: quantized spectrum
 *
 *****************************************************************************/
@@ -116,15 +116,15 @@
   pquat = quantBorders[m];
 
   g += 16;
-  
+
   if(g >= 0)
   {
 	for (line=0; line<noOfLines; line++) {
 	  Word32 qua;
-	  qua = 0;                                                     
-    
+	  qua = 0;
+
 	  mdctSpeL = mdctSpectrum[line];
-	
+
 	  if (mdctSpeL) {
 		Word32 sa;
 		Word32 saShft;
@@ -134,27 +134,27 @@
 	    saShft = sa >> g;
 
         if (saShft > pquat[0]) {
-         
+
           if (saShft < pquat[1]) {
-             
+
             qua = mdctSpeL>0 ? 1 : -1;
 		  }
           else {
-           
+
             if (saShft < pquat[2]) {
-               
+
               qua = mdctSpeL>0 ? 2 : -2;
 			}
             else {
-             
+
               if (saShft < pquat[3]) {
-                 
+
                 qua = mdctSpeL>0 ? 3 : -3;
 			  }
               else {
                 qua = quantizeSingleLine(gain, sa);
                 /* adjust the sign. Since 0 < qua < 1, this cannot overflow. */
-               
+
                 if (mdctSpeL < 0)
                   qua = -qua;
 			  }
@@ -162,17 +162,17 @@
 		  }
 		}
 	  }
-      quaSpectrum[line] = qua ;                                    
+      quaSpectrum[line] = qua ;
 	}
   }
   else
   {
 	for (line=0; line<noOfLines; line++) {
 	  Word32 qua;
-	  qua = 0;                                                     
-    
+	  qua = 0;
+
 	  mdctSpeL = mdctSpectrum[line];
-	
+
 	  if (mdctSpeL) {
 		Word32 sa;
 		Word32 saShft;
@@ -181,27 +181,27 @@
         saShft = sa << g;
 
         if (saShft > pquat[0]) {
-         
+
           if (saShft < pquat[1]) {
-             
+
             qua = mdctSpeL>0 ? 1 : -1;
 		  }
           else {
-           
+
             if (saShft < pquat[2]) {
-               
+
               qua = mdctSpeL>0 ? 2 : -2;
 			}
             else {
-             
+
               if (saShft < pquat[3]) {
-                 
+
                 qua = mdctSpeL>0 ? 3 : -3;
 			  }
               else {
                 qua = quantizeSingleLine(gain, sa);
                 /* adjust the sign. Since 0 < qua < 1, this cannot overflow. */
-               
+
                 if (mdctSpeL < 0)
                   qua = -qua;
 			  }
@@ -209,8 +209,8 @@
 		  }
 		}
 	  }
-      quaSpectrum[line] = qua ;                                    
-	}	  
+      quaSpectrum[line] = qua ;
+	}
   }
 
 }
@@ -218,10 +218,10 @@
 
 /*****************************************************************************
 *
-* function name:iquantizeLines 
+* function name:iquantizeLines
 * description: iquantizes spectrum lines without sign
-*              mdctSpectrum = iquaSpectrum^4/3 *2^(0.25*gain) 
-* input: global gain, number of lines to process,quantized spectrum        
+*              mdctSpectrum = iquaSpectrum^4/3 *2^(0.25*gain)
+* input: global gain, number of lines to process,quantized spectrum
 * output: spectral data
 *
 *****************************************************************************/
@@ -234,11 +234,11 @@
   Word32   iquantizershift;
   Word32   line;
 
-  iquantizermod = gain & 3;                              
+  iquantizermod = gain & 3;
   iquantizershift = gain >> 2;
 
   for (line=0; line<noOfLines; line++) {
-     
+
     if( quantSpectrum[line] != 0 ) {
       Word32 accu;
       Word32 ex;
@@ -252,19 +252,19 @@
       accu = accu << ex;
       specExp = INT_BITS-1 - ex;
 
-      tabIndex = (accu >> (INT_BITS-2-MANT_DIGITS)) & (~MANT_SIZE);        
+      tabIndex = (accu >> (INT_BITS-2-MANT_DIGITS)) & (~MANT_SIZE);
 
       /* calculate "mantissa" ^4/3 */
-      s = mTab_4_3[tabIndex];                                                    
+      s = mTab_4_3[tabIndex];
 
       /* get approperiate exponent multiplier for specExp^3/4 combined with scfMod */
-      t = specExpMantTableComb_enc[iquantizermod][specExp];                      
+      t = specExpMantTableComb_enc[iquantizermod][specExp];
 
       /* multiply "mantissa" ^4/3 with exponent multiplier */
       accu = MULHIGH(s, t);
 
       /* get approperiate exponent shifter */
-      specExp = specExpTableComb_enc[iquantizermod][specExp];                    
+      specExp = specExpTableComb_enc[iquantizermod][specExp];
 
       specExp += iquantizershift + 1;
 	  if(specExp >= 0)
@@ -273,7 +273,7 @@
 		  mdctSpectrum[line] = accu >> (-specExp);
     }
     else {
-      mdctSpectrum[line] = 0;                                                    
+      mdctSpectrum[line] = 0;
     }
   }
 }
@@ -301,7 +301,7 @@
   for(sfbOffs=0;sfbOffs<sfbCnt;sfbOffs+=sfbPerGroup) {
     Word32 sfbNext ;
     for (sfb = 0; sfb < maxSfbPerGroup; sfb = sfbNext) {
-      Word16 scalefactor = scalefactors[sfbOffs+sfb];                          
+      Word16 scalefactor = scalefactors[sfbOffs+sfb];
       /* coalesce sfbs with the same scalefactor */
       for (sfbNext = sfb+1;
            sfbNext < maxSfbPerGroup && scalefactor == scalefactors[sfbOffs+sfbNext];
@@ -318,7 +318,7 @@
 
 /*****************************************************************************
 *
-* function name:calcSfbDist 
+* function name:calcSfbDist
 * description: quantizes and requantizes lines to calculate distortion
 * input:  number of lines to be quantized, ...
 * output: distortion
@@ -338,14 +338,14 @@
 
   pquat = quantBorders[m];
   repquat = quantRecon[m];
-	
-  dist = 0;  
+
+  dist = 0;
   g += 16;
   if(g2 < 0 && g >= 0)
-  {	  
+  {
 	  g2 = -g2;
-	  for(line=0; line<sfbWidth; line++) {		  
-		  if (spec[line]) {			  
+	  for(line=0; line<sfbWidth; line++) {
+		  if (spec[line]) {
 			  Word32 diff;
 			  Word32 distSingle;
 			  Word32 sa;
@@ -359,19 +359,19 @@
 				  distSingle = (saShft * saShft) >> g2;
 			  }
 			  else {
-				  
+
 				  if (saShft < pquat[1]) {
 					  diff = saShft - repquat[0];
 					  distSingle = (diff * diff) >> g2;
 				  }
 				  else {
-					  
+
 					  if (saShft < pquat[2]) {
 						  diff = saShft - repquat[1];
 						  distSingle = (diff * diff) >> g2;
 					  }
 					  else {
-						  
+
 						  if (saShft < pquat[3]) {
 							  diff = saShft - repquat[2];
 							  distSingle = (diff * diff) >> g2;
@@ -387,15 +387,15 @@
 					  }
 				  }
 			  }
-			  
+
 			  dist = L_add(dist, distSingle);
 		  }
 	  }
   }
   else
   {
-	  for(line=0; line<sfbWidth; line++) {		  
-		  if (spec[line]) {			  
+	  for(line=0; line<sfbWidth; line++) {
+		  if (spec[line]) {
 			  Word32 diff;
 			  Word32 distSingle;
 			  Word32 sa;
@@ -408,19 +408,19 @@
 				  distSingle = L_shl((saShft * saShft), g2);
 			  }
 			  else {
-				  
+
 				  if (saShft < pquat[1]) {
 					  diff = saShft - repquat[0];
 					  distSingle = L_shl((diff * diff), g2);
 				  }
 				  else {
-					  
+
 					  if (saShft < pquat[2]) {
 						  diff = saShft - repquat[1];
 						  distSingle = L_shl((diff * diff), g2);
 					  }
 					  else {
-						  
+
 						  if (saShft < pquat[3]) {
 							  diff = saShft - repquat[2];
 							  distSingle = L_shl((diff * diff), g2);
@@ -438,7 +438,7 @@
 			  }
 			  dist = L_add(dist, distSingle);
 		  }
-	  }	  
+	  }
   }
 
   return dist;
diff --git a/media/libstagefright/codecs/aacenc/src/sf_estim.c b/media/libstagefright/codecs/aacenc/src/sf_estim.c
index ffe2e83..fe40137 100644
--- a/media/libstagefright/codecs/aacenc/src/sf_estim.c
+++ b/media/libstagefright/codecs/aacenc/src/sf_estim.c
@@ -30,17 +30,17 @@
 static const Word16 MAX_SCF_DELTA = 60;
 
 /*!
-constants reference in comments 
+constants reference in comments
 
  C0 = 6.75f;
- C1 = -69.33295f;   -16/3*log(MAX_QUANT+0.5-logCon)/log(2) 
+ C1 = -69.33295f;   -16/3*log(MAX_QUANT+0.5-logCon)/log(2)
  C2 = 4.0f;
  C3 = 2.66666666f;
- 
-  PE_C1 = 3.0f;        log(8.0)/log(2) 
-  PE_C2 = 1.3219281f;  log(2.5)/log(2) 
-  PE_C3 = 0.5593573f;  1-C2/C1 
-  
+
+  PE_C1 = 3.0f;        log(8.0)/log(2)
+  PE_C2 = 1.3219281f;  log(2.5)/log(2)
+  PE_C3 = 0.5593573f;  1-C2/C1
+
 */
 
 #define FF_SQRT_BITS                    7
@@ -55,15 +55,15 @@
 /*********************************************************************************
 *
 * function name: formfac_sqrt
-* description:  calculates sqrt(x)/256 
+* description:  calculates sqrt(x)/256
 *
 **********************************************************************************/
 __inline Word32 formfac_sqrt(Word32 x)
 {
 	Word32 y;
 	Word32 preshift, postshift;
-	
-	
+
+
 	if (x==0) return 0;
 	preshift  = norm_l(x) - (INT_BITS-1-FF_SQRT_BITS);
 	postshift = preshift >> 1;
@@ -74,12 +74,12 @@
 	else
 		y = x >> (-preshift);
 	y = formfac_sqrttable[y-32];
-	
+
 	if(postshift >= 0)
 		y = y >> postshift;
 	else
 		y = y << (-postshift);
-	
+
 	return y;
 }
 
@@ -100,19 +100,19 @@
 	Word32 sfbw, sfbw1;
 	Word32 i, j;
 	Word32 sfbOffs, sfb, shift;
-	
+
 	sfbw = sfbw1 = 0;
 	for (sfbOffs=0; sfbOffs<psyOutChan->sfbCnt; sfbOffs+=psyOutChan->sfbPerGroup){
 		for (sfb=0; sfb<psyOutChan->maxSfbPerGroup; sfb++) {
-			i = sfbOffs+sfb;      
-			
+			i = sfbOffs+sfb;
+
 			if (psyOutChan->sfbEnergy[i] > psyOutChan->sfbThreshold[i]) {
 				Word32 accu, avgFormFactor,iSfbWidth;
 				Word32 *mdctSpec;
 				sfbw = psyOutChan->sfbOffsets[i+1] - psyOutChan->sfbOffsets[i];
 				iSfbWidth = invSBF[(sfbw >> 2) - 1];
 				mdctSpec = psyOutChan->mdctSpectrum + psyOutChan->sfbOffsets[i];
-				accu = 0;                                                                       
+				accu = 0;
 				/* calc sum of sqrt(spec) */
 				for (j=sfbw; j; j--) {
 					accu += formfac_sqrt(L_abs(*mdctSpec)); mdctSpec++;
@@ -129,7 +129,7 @@
 			}
 			else {
 				/* set number of lines to zero */
-				sfbNRelevantLines[i] = 0;                                                       
+				sfbNRelevantLines[i] = 0;
 			}
 		}
 	}
@@ -141,68 +141,68 @@
 * description:  find better scalefactor with analysis by synthesis
 *
 **********************************************************************************/
-static Word16 improveScf(Word32 *spec, 
-                         Word16  sfbWidth, 
-                         Word32  thresh, 
+static Word16 improveScf(Word32 *spec,
+                         Word16  sfbWidth,
+                         Word32  thresh,
                          Word16  scf,
                          Word16  minScf,
-                         Word32 *dist, 
+                         Word32 *dist,
                          Word16 *minScfCalculated)
 {
 	Word32 cnt;
 	Word32 sfbDist;
 	Word32 scfBest;
 	Word32 thresh125 = L_add(thresh, (thresh >> 2));
-	
-	scfBest = scf;                                                       
-	
+
+	scfBest = scf;
+
 	/* calc real distortion */
 	sfbDist = calcSfbDist(spec, sfbWidth, scf);
-	*minScfCalculated = scf;     
+	*minScfCalculated = scf;
 	if(!sfbDist)
 	  return scfBest;
-	
+
 	if (sfbDist > thresh125) {
 		Word32 scfEstimated;
 		Word32 sfbDistBest;
-		scfEstimated = scf;                                               
-		sfbDistBest = sfbDist;                                            
-		
-		cnt = 0;                                                          
+		scfEstimated = scf;
+		sfbDistBest = sfbDist;
+
+		cnt = 0;
 		while (sfbDist > thresh125 && (cnt < 3)) {
-			
+
 			scf = scf + 1;
 			sfbDist = calcSfbDist(spec, sfbWidth, scf);
-			
+
 			if (sfbDist < sfbDistBest) {
-				scfBest = scf;                                              
-				sfbDistBest = sfbDist;                                      
+				scfBest = scf;
+				sfbDistBest = sfbDist;
 			}
 			cnt = cnt + 1;
 		}
-		cnt = 0;                                                          
-		scf = scfEstimated;                                               
-		sfbDist = sfbDistBest;                                            
+		cnt = 0;
+		scf = scfEstimated;
+		sfbDist = sfbDistBest;
 		while ((sfbDist > thresh125) && (cnt < 1) && (scf > minScf)) {
-			
+
 			scf = scf - 1;
 			sfbDist = calcSfbDist(spec, sfbWidth, scf);
-			
+
 			if (sfbDist < sfbDistBest) {
-				scfBest = scf;                                              
-				sfbDistBest = sfbDist;                                      
+				scfBest = scf;
+				sfbDistBest = sfbDist;
 			}
-			*minScfCalculated = scf;                                       
+			*minScfCalculated = scf;
 			cnt = cnt + 1;
 		}
-		*dist = sfbDistBest;                                              
+		*dist = sfbDistBest;
 	}
 	else {
-		Word32 sfbDistBest; 
+		Word32 sfbDistBest;
 		Word32 sfbDistAllowed;
 		Word32 thresh08 = fixmul(COEF08_31, thresh);
-		sfbDistBest = sfbDist;                                            
-		
+		sfbDistBest = sfbDist;
+
 		if (sfbDist < thresh08)
 			sfbDistAllowed = sfbDist;
 		else
@@ -210,16 +210,16 @@
 		for (cnt=0; cnt<3; cnt++) {
 			scf = scf + 1;
 			sfbDist = calcSfbDist(spec, sfbWidth, scf);
-			
+
 			if (fixmul(COEF08_31,sfbDist) < sfbDistAllowed) {
 				*minScfCalculated = scfBest + 1;
-				scfBest = scf;                                              
-				sfbDistBest = sfbDist;                                      
+				scfBest = scf;
+				sfbDistBest = sfbDist;
 			}
 		}
-		*dist = sfbDistBest;                                              
+		*dist = sfbDistBest;
 	}
-	
+
 	/* return best scalefactor */
 	return scfBest;
 }
@@ -233,10 +233,10 @@
 static Word16 countSingleScfBits(Word16 scf, Word16 scfLeft, Word16 scfRight)
 {
 	Word16 scfBits;
-	
+
 	scfBits = bitCountScalefactorDelta(scfLeft - scf) +
 		bitCountScalefactorDelta(scf - scfRight);
-	
+
 	return scfBits;
 }
 
@@ -245,7 +245,7 @@
 * function name: calcSingleSpecPe
 * description:  ldRatio = log2(en(n)) - 0,375*scfGain(n)
 *				nbits = 0.7*nLines*ldRation for ldRation >= c1
-*				nbits = 0.7*nLines*(c2 + c3*ldRatio) for ldRation < c1 
+*				nbits = 0.7*nLines*(c2 + c3*ldRatio) for ldRation < c1
 *
 **********************************************************************************/
 static Word16 calcSingleSpecPe(Word16 scf, Word16 sfbConstPePart, Word16 nLines)
@@ -253,18 +253,18 @@
 	Word32 specPe;
 	Word32 ldRatio;
 	Word32 scf3;
-	
+
 	ldRatio = sfbConstPePart << 3; /*  (sfbConstPePart -0.375*scf)*8 */
 	scf3 = scf + scf + scf;
 	ldRatio = ldRatio - scf3;
-    
+
 	if (ldRatio < PE_C1_8) {
-		/* 21 : 2*8*PE_C2, 2*PE_C3 ~ 1*/ 
+		/* 21 : 2*8*PE_C2, 2*PE_C3 ~ 1*/
 		ldRatio = (ldRatio + PE_C2_16) >> 1;
 	}
 	specPe = nLines * ldRatio;
 	specPe = (specPe * PE_SCALE) >> 14;
-	
+
 	return saturate(specPe);
 }
 
@@ -275,53 +275,53 @@
 * description:  count different scf bits used
 *
 **********************************************************************************/
-static Word16 countScfBitsDiff(Word16 *scfOld, Word16 *scfNew, 
+static Word16 countScfBitsDiff(Word16 *scfOld, Word16 *scfNew,
                                Word16 sfbCnt, Word16 startSfb, Word16 stopSfb)
 {
 	Word32 scfBitsDiff;
 	Word32 sfb, sfbLast;
 	Word32 sfbPrev, sfbNext;
-	
-	scfBitsDiff = 0;                                                      
-	sfb = 0;                                                              
-	
+
+	scfBitsDiff = 0;
+	sfb = 0;
+
 	/* search for first relevant sfb */
-	sfbLast = startSfb;                                                   
+	sfbLast = startSfb;
 	while (sfbLast < stopSfb && scfOld[sfbLast] == VOAAC_SHRT_MIN) {
-		
+
 		sfbLast = sfbLast + 1;
 	}
 	/* search for previous relevant sfb and count diff */
 	sfbPrev = startSfb - 1;
 	while ((sfbPrev>=0) && scfOld[sfbPrev] == VOAAC_SHRT_MIN) {
-		
+
 		sfbPrev = sfbPrev - 1;
 	}
-	
+
 	if (sfbPrev>=0) {
 		scfBitsDiff += bitCountScalefactorDelta(scfNew[sfbPrev] - scfNew[sfbLast]) -
 			bitCountScalefactorDelta(scfOld[sfbPrev] - scfOld[sfbLast]);
 	}
 	/* now loop through all sfbs and count diffs of relevant sfbs */
 	for (sfb=sfbLast+1; sfb<stopSfb; sfb++) {
-		
+
 		if (scfOld[sfb] != VOAAC_SHRT_MIN) {
 			scfBitsDiff += bitCountScalefactorDelta(scfNew[sfbLast] - scfNew[sfb]) -
 				bitCountScalefactorDelta(scfOld[sfbLast] - scfOld[sfb]);
-			sfbLast = sfb;                                                    
+			sfbLast = sfb;
 		}
 	}
 	/* search for next relevant sfb and count diff */
-	sfbNext = stopSfb;                                                    
+	sfbNext = stopSfb;
 	while (sfbNext < sfbCnt && scfOld[sfbNext] == VOAAC_SHRT_MIN) {
-		
+
 		sfbNext = sfbNext + 1;
 	}
-	
+
 	if (sfbNext < sfbCnt)
 		scfBitsDiff += bitCountScalefactorDelta(scfNew[sfbLast] - scfNew[sfbNext]) -
 		bitCountScalefactorDelta(scfOld[sfbLast] - scfOld[sfbNext]);
-	
+
 	return saturate(scfBitsDiff);
 }
 
@@ -331,52 +331,52 @@
                              Word16 *logSfbEnergy,
                              Word16 *logSfbFormFactor,
                              Word16 *sfbNRelevantLines,
-                             Word16 startSfb, 
+                             Word16 startSfb,
                              Word16 stopSfb)
 {
 	Word32 specPeDiff;
 	Word32 sfb;
-	
-	specPeDiff = 0;                                                       
-	
+
+	specPeDiff = 0;
+
 	/* loop through all sfbs and count pe difference */
 	for (sfb=startSfb; sfb<stopSfb; sfb++) {
-		
-		
+
+
 		if (scfOld[sfb] != VOAAC_SHRT_MIN) {
 			Word32 ldRatioOld, ldRatioNew;
 			Word32 scf3;
-			
-			
+
+
 			if (sfbConstPePart[sfb] == MIN_16) {
 				sfbConstPePart[sfb] = ((logSfbEnergy[sfb] -
 					logSfbFormFactor[sfb]) + 11-8*4+3) >> 2;
 			}
-			
-			
+
+
 			ldRatioOld = sfbConstPePart[sfb] << 3;
 			scf3 = scfOld[sfb] + scfOld[sfb] + scfOld[sfb];
 			ldRatioOld = ldRatioOld - scf3;
 			ldRatioNew = sfbConstPePart[sfb] << 3;
 			scf3 = scfNew[sfb] + scfNew[sfb] + scfNew[sfb];
 			ldRatioNew = ldRatioNew - scf3;
-			
+
 			if (ldRatioOld < PE_C1_8) {
 				/* 21 : 2*8*PE_C2, 2*PE_C3 ~ 1*/
 				ldRatioOld = (ldRatioOld + PE_C2_16) >> 1;
 			}
-			
+
 			if (ldRatioNew < PE_C1_8) {
 				/* 21 : 2*8*PE_C2, 2*PE_C3 ~ 1*/
 				ldRatioNew = (ldRatioNew + PE_C2_16) >> 1;
 			}
-			
+
 			specPeDiff +=  sfbNRelevantLines[sfb] * (ldRatioNew - ldRatioOld);
 		}
 	}
-	
+
 	specPeDiff = (specPeDiff * PE_SCALE) >> 14;
-	
+
 	return saturate(specPeDiff);
 }
 
@@ -390,9 +390,9 @@
 *
 **********************************************************************************/
 static void assimilateSingleScf(PSY_OUT_CHANNEL *psyOutChan,
-                                Word16 *scf, 
+                                Word16 *scf,
                                 Word16 *minScf,
-                                Word32 *sfbDist, 
+                                Word32 *sfbDist,
                                 Word16 *sfbConstPePart,
                                 Word16 *logSfbEnergy,
                                 Word16 *logSfbFormFactor,
@@ -411,94 +411,94 @@
 	Word16 *prevScfNext = psyOutChan->prevScfNext;
 	Word16 *deltaPeLast = psyOutChan->deltaPeLast;
 	Flag   updateMinScfCalculated;
-	
-	success = 0;                                                                  
-	deltaPe = 0;                                                                  
-	
+
+	success = 0;
+	deltaPe = 0;
+
 	for(j=0;j<psyOutChan->sfbCnt;j++){
-		prevScfLast[j] = MAX_16;                                                    
-		prevScfNext[j] = MAX_16;                                                    
-		deltaPeLast[j] = MAX_16;                                                    
+		prevScfLast[j] = MAX_16;
+		prevScfNext[j] = MAX_16;
+		deltaPeLast[j] = MAX_16;
 	}
-	
-	sfbLast = -1;                                                                 
-	sfbAct = -1;                                                                  
-	sfbNext = -1;                                                                 
+
+	sfbLast = -1;
+	sfbAct = -1;
+	sfbNext = -1;
 	scfLast = 0;
 	scfNext = 0;
-	scfMin = MAX_16;                                                              
+	scfMin = MAX_16;
 	do {
 		/* search for new relevant sfb */
 		sfbNext = sfbNext + 1;
 		while (sfbNext < psyOutChan->sfbCnt && scf[sfbNext] == MIN_16) {
-			
+
 			sfbNext = sfbNext + 1;
 		}
-		
+
 		if ((sfbLast>=0) && (sfbAct>=0) && sfbNext < psyOutChan->sfbCnt) {
 			/* relevant scfs to the left and to the right */
-			scfAct  = scf[sfbAct];                                                    
+			scfAct  = scf[sfbAct];
 			scfLast = scf + sfbLast;
 			scfNext = scf + sfbNext;
 			scfMin  = min(*scfLast, *scfNext);
 		}
 		else {
-			
+
 			if (sfbLast == -1 && (sfbAct>=0) && sfbNext < psyOutChan->sfbCnt) {
 				/* first relevant scf */
-				scfAct  = scf[sfbAct];                                                  
+				scfAct  = scf[sfbAct];
 				scfLast = &scfAct;
 				scfNext = scf + sfbNext;
-				scfMin  = *scfNext;                                                     
+				scfMin  = *scfNext;
 			}
 			else {
-				
+
 				if ((sfbLast>=0) && (sfbAct>=0) && sfbNext == psyOutChan->sfbCnt) {
 					/* last relevant scf */
-					scfAct  = scf[sfbAct];                                                
+					scfAct  = scf[sfbAct];
 					scfLast = scf + sfbLast;
 					scfNext = &scfAct;
-					scfMin  = *scfLast;                                                   
+					scfMin  = *scfLast;
 				}
 			}
 		}
-		
+
 		if (sfbAct>=0)
 			scfMin = max(scfMin, minScf[sfbAct]);
-		
-		if ((sfbAct >= 0) && 
-			(sfbLast>=0 || sfbNext < psyOutChan->sfbCnt) && 
-			scfAct > scfMin && 
-			(*scfLast != prevScfLast[sfbAct] || 
-			*scfNext != prevScfNext[sfbAct] || 
+
+		if ((sfbAct >= 0) &&
+			(sfbLast>=0 || sfbNext < psyOutChan->sfbCnt) &&
+			scfAct > scfMin &&
+			(*scfLast != prevScfLast[sfbAct] ||
+			*scfNext != prevScfNext[sfbAct] ||
 			deltaPe < deltaPeLast[sfbAct])) {
-			success = 0;                                                              
-			
-			/* estimate required bits for actual scf */			
+			success = 0;
+
+			/* estimate required bits for actual scf */
 			if (sfbConstPePart[sfbAct] == MIN_16) {
 				sfbConstPePart[sfbAct] = logSfbEnergy[sfbAct] -
 					logSfbFormFactor[sfbAct] + 11-8*4; /* 4*log2(6.75) - 32 */
-				
+
 				if (sfbConstPePart[sfbAct] < 0)
 					sfbConstPePart[sfbAct] = sfbConstPePart[sfbAct] + 3;
 				sfbConstPePart[sfbAct] = sfbConstPePart[sfbAct] >> 2;
 			}
-			
+
 			sfbPeOld = calcSingleSpecPe(scfAct, sfbConstPePart[sfbAct], sfbNRelevantLines[sfbAct]) +
 				countSingleScfBits(scfAct, *scfLast, *scfNext);
-			deltaPeNew = deltaPe;                                                     
-			updateMinScfCalculated = 1;                                               
+			deltaPeNew = deltaPe;
+			updateMinScfCalculated = 1;
 			do {
 				scfAct = scfAct - 1;
 				/* check only if the same check was not done before */
-				
+
 				if (scfAct < minScfCalculated[sfbAct]) {
 					sfbPeNew = calcSingleSpecPe(scfAct, sfbConstPePart[sfbAct], sfbNRelevantLines[sfbAct]) +
 						countSingleScfBits(scfAct, *scfLast, *scfNext);
-					/* use new scf if no increase in pe and 
+					/* use new scf if no increase in pe and
 					quantization error is smaller */
 					deltaPeTmp = deltaPe + sfbPeNew - sfbPeOld;
-					
+
 					if (deltaPeTmp < 10) {
 						sfbDistNew = calcSfbDist(psyOutChan->mdctSpectrum+
 							psyOutChan->sfbOffsets[sfbAct],
@@ -506,46 +506,46 @@
 							scfAct);
 						if (sfbDistNew < sfbDist[sfbAct]) {
 							/* success, replace scf by new one */
-							scf[sfbAct] = scfAct;                                     
-							sfbDist[sfbAct] = sfbDistNew;                             
-							deltaPeNew = deltaPeTmp;                                  
-							success = 1;                                              
+							scf[sfbAct] = scfAct;
+							sfbDist[sfbAct] = sfbDistNew;
+							deltaPeNew = deltaPeTmp;
+							success = 1;
 						}
 						/* mark as already checked */
-						
+
 						if (updateMinScfCalculated) {
-							minScfCalculated[sfbAct] = scfAct;                        
+							minScfCalculated[sfbAct] = scfAct;
 						}
 					}
 					else {
-						updateMinScfCalculated = 0;                                 
+						updateMinScfCalculated = 0;
 					}
 				}
-				
+
 			} while (scfAct > scfMin);
-			deltaPe = deltaPeNew;                                             
+			deltaPe = deltaPeNew;
 			/* save parameters to avoid multiple computations of the same sfb */
-			prevScfLast[sfbAct] = *scfLast;                                   
-			prevScfNext[sfbAct] = *scfNext;                                   
-			deltaPeLast[sfbAct] = deltaPe;                                    
+			prevScfLast[sfbAct] = *scfLast;
+			prevScfNext[sfbAct] = *scfNext;
+			deltaPeLast[sfbAct] = deltaPe;
 		}
-		
+
 		if (success && restartOnSuccess) {
 			/* start again at first sfb */
-			sfbLast = -1;                                                     
-			sfbAct  = -1;                                                     
-			sfbNext = -1;                                                     
+			sfbLast = -1;
+			sfbAct  = -1;
+			sfbNext = -1;
 			scfLast = 0;
 			scfNext = 0;
-			scfMin  = MAX_16;                                                 
-			success = 0;                                                      
+			scfMin  = MAX_16;
+			success = 0;
 		}
 		else {
 			/* shift sfbs for next band */
-			sfbLast = sfbAct;                                                 
-			sfbAct  = sfbNext;                                                
+			sfbLast = sfbAct;
+			sfbAct  = sfbNext;
 		}
-		
+
   } while (sfbNext < psyOutChan->sfbCnt);
 }
 
@@ -557,9 +557,9 @@
 *
 **********************************************************************************/
 static void assimilateMultipleScf(PSY_OUT_CHANNEL *psyOutChan,
-                                  Word16 *scf, 
+                                  Word16 *scf,
                                   Word16 *minScf,
-                                  Word32 *sfbDist, 
+                                  Word32 *sfbDist,
                                   Word16 *sfbConstPePart,
                                   Word16 *logSfbEnergy,
                                   Word16 *logSfbFormFactor,
@@ -574,95 +574,95 @@
 	Word32 *sfbDistNew = psyOutChan->sfbDistNew;
 	Word16 *scfTmp = psyOutChan->prevScfLast;
 
-	deltaPe = 0;                                                          
-	sfbCnt = psyOutChan->sfbCnt;                                          
-	
+	deltaPe = 0;
+	sfbCnt = psyOutChan->sfbCnt;
+
 	/* calc min and max scalfactors */
-	scfMin = MAX_16;                                                      
-	scfMax = MIN_16;                                                      
+	scfMin = MAX_16;
+	scfMax = MIN_16;
 	for (sfb=0; sfb<sfbCnt; sfb++) {
-		
+
 		if (scf[sfb] != MIN_16) {
 			scfMin = min(scfMin, scf[sfb]);
 			scfMax = max(scfMax, scf[sfb]);
 		}
 	}
-	
+
 	if (scfMax !=  MIN_16) {
-		
-		scfAct = scfMax;                                             
-		
+
+		scfAct = scfMax;
+
 		do {
 			scfAct = scfAct - 1;
 			for (sfb=0; sfb<sfbCnt; sfb++) {
-				scfTmp[sfb] = scf[sfb];                                         
+				scfTmp[sfb] = scf[sfb];
 			}
-			stopSfb = 0;                                                      
+			stopSfb = 0;
 			do {
-				sfb = stopSfb;                                                  
-				
+				sfb = stopSfb;
+
 				while (sfb < sfbCnt && (scf[sfb] == MIN_16 || scf[sfb] <= scfAct)) {
 					sfb = sfb + 1;
 				}
-				startSfb = sfb;                                                 
+				startSfb = sfb;
 				sfb = sfb + 1;
-				
+
 				while (sfb < sfbCnt && (scf[sfb] == MIN_16 || scf[sfb] > scfAct)) {
 					sfb = sfb + 1;
 				}
-				stopSfb = sfb;                                                  
-				
-				possibleRegionFound = 0;                                        
-				
+				stopSfb = sfb;
+
+				possibleRegionFound = 0;
+
 				if (startSfb < sfbCnt) {
-					possibleRegionFound = 1;                                      
+					possibleRegionFound = 1;
 					for (sfb=startSfb; sfb<stopSfb; sfb++) {
-						
+
 						if (scf[sfb]!=MIN_16) {
-							
+
 							if (scfAct < minScf[sfb]) {
-								possibleRegionFound = 0;                                
+								possibleRegionFound = 0;
 								break;
 							}
 						}
 					}
 				}
-				
-				
+
+
 				if (possibleRegionFound) { /* region found */
-					
+
 					/* replace scfs in region by scfAct */
 					for (sfb=startSfb; sfb<stopSfb; sfb++) {
-						
+
 						if (scfTmp[sfb]!=MIN_16)
-							scfTmp[sfb] = scfAct;                                     
+							scfTmp[sfb] = scfAct;
 					}
-					
+
 					/* estimate change in bit demand for new scfs */
 					deltaScfBits = countScfBitsDiff(scf,scfTmp,sfbCnt,startSfb,stopSfb);
 					deltaSpecPe = calcSpecPeDiff(scf, scfTmp, sfbConstPePart,
-						logSfbEnergy, logSfbFormFactor, sfbNRelevantLines, 
+						logSfbEnergy, logSfbFormFactor, sfbNRelevantLines,
 						startSfb, stopSfb);
 					deltaPeNew = deltaPe + deltaScfBits + deltaSpecPe;
-					
-					
+
+
 					if (deltaPeNew < 10) {
 						Word32 distOldSum, distNewSum;
-						
+
 						/* quantize and calc sum of new distortion */
-						distOldSum = 0;                                                     
-						distNewSum = 0;                                                     
+						distOldSum = 0;
+						distNewSum = 0;
 						for (sfb=startSfb; sfb<stopSfb; sfb++) {
-							
+
 							if (scfTmp[sfb] != MIN_16) {
 								distOldSum = L_add(distOldSum, sfbDist[sfb]);
-								
+
 								sfbDistNew[sfb] = calcSfbDist(psyOutChan->mdctSpectrum +
-									psyOutChan->sfbOffsets[sfb], 
+									psyOutChan->sfbOffsets[sfb],
 									(psyOutChan->sfbOffsets[sfb+1] - psyOutChan->sfbOffsets[sfb]),
 									scfAct);
-								
-								
+
+
 								if (sfbDistNew[sfb] > psyOutChan->sfbThreshold[sfb]) {
 									distNewSum = distOldSum << 1;
 									break;
@@ -670,20 +670,20 @@
 								distNewSum = L_add(distNewSum, sfbDistNew[sfb]);
 							}
 						}
-						
+
 						if (distNewSum < distOldSum) {
-							deltaPe = deltaPeNew;                                             
+							deltaPe = deltaPeNew;
 							for (sfb=startSfb; sfb<stopSfb; sfb++) {
-								
+
 								if (scf[sfb]!=MIN_16) {
-									scf[sfb] = scfAct;                                            
-									sfbDist[sfb] = sfbDistNew[sfb];                               
+									scf[sfb] = scfAct;
+									sfbDist[sfb] = sfbDistNew[sfb];
 								}
 							}
 						}
 					}
-				}        
-			} while (stopSfb <= sfbCnt);      
+				}
+			} while (stopSfb <= sfbCnt);
 		} while (scfAct > scfMin);
 	}
 }
@@ -710,125 +710,125 @@
 	Word32 *sfbDist = psyOutChan->sfbDist;
 	Word16 *minSfMaxQuant = psyOutChan->minSfMaxQuant;
 	Word16 *minScfCalculated = psyOutChan->minScfCalculated;
-	
-	
+
+
 	for (i=0; i<psyOutChan->sfbCnt; i++) {
 		Word32 sbfwith, sbfStart;
 		Word32 *mdctSpec;
-		thresh = psyOutChan->sfbThreshold[i];                                       
-		energy = psyOutChan->sfbEnergy[i];                                          
-		
+		thresh = psyOutChan->sfbThreshold[i];
+		energy = psyOutChan->sfbEnergy[i];
+
 		sbfStart = psyOutChan->sfbOffsets[i];
 		sbfwith = psyOutChan->sfbOffsets[i+1] - sbfStart;
 		mdctSpec = psyOutChan->mdctSpectrum+sbfStart;
-		
-		maxSpec = 0;                                                                
+
+		maxSpec = 0;
 		/* maximum of spectrum */
 		for (j=sbfwith; j; j-- ) {
 			Word32 absSpec = L_abs(*mdctSpec); mdctSpec++;
-			maxSpec |= absSpec;                                                       
+			maxSpec |= absSpec;
 		}
-		
+
 		/* scfs without energy or with thresh>energy are marked with MIN_16 */
-		scf[i] = MIN_16;                                                            
-		minSfMaxQuant[i] = MIN_16;    
-		
+		scf[i] = MIN_16;
+		minSfMaxQuant[i] = MIN_16;
+
 		if ((maxSpec > 0) && (energy > thresh)) {
-			
-			energyPart = logSfbFormFactor[i];                                         
-			thresholdPart = iLog4(thresh);  
+
+			energyPart = logSfbFormFactor[i];
+			thresholdPart = iLog4(thresh);
 			/* -20 = 4*log2(6.75) - 32 */
 			scfInt = ((thresholdPart - energyPart - 20) * SCALE_ESTIMATE_COEF) >> 15;
-			
+
 			minSfMaxQuant[i] = iLog4(maxSpec) - 68; /* 68  -16/3*log(MAX_QUANT+0.5-logCon)/log(2) + 1 */
-			
-			
+
+
 			if (minSfMaxQuant[i] > scfInt) {
-				scfInt = minSfMaxQuant[i];                                              
+				scfInt = minSfMaxQuant[i];
 			}
-			
+
 			/* find better scalefactor with analysis by synthesis */
 			scfInt = improveScf(psyOutChan->mdctSpectrum+sbfStart,
 				sbfwith,
-				thresh, scfInt, minSfMaxQuant[i], 
+				thresh, scfInt, minSfMaxQuant[i],
 				&sfbDist[i], &minScfCalculated[i]);
-			
-			scf[i] = scfInt;                                                          
+
+			scf[i] = scfInt;
 		}
 	}
-	
-	
+
+
 	/* scalefactor differece reduction  */
 	{
 		Word16 sfbConstPePart[MAX_GROUPED_SFB];
 		for(i=0;i<psyOutChan->sfbCnt;i++) {
-			sfbConstPePart[i] = MIN_16;                                               
+			sfbConstPePart[i] = MIN_16;
 		}
-		
-		assimilateSingleScf(psyOutChan, scf, 
+
+		assimilateSingleScf(psyOutChan, scf,
 			minSfMaxQuant, sfbDist, sfbConstPePart, logSfbEnergy,
 			logSfbFormFactor, sfbNRelevantLines, minScfCalculated, 1);
-		
-		assimilateMultipleScf(psyOutChan, scf, 
+
+		assimilateMultipleScf(psyOutChan, scf,
 			minSfMaxQuant, sfbDist, sfbConstPePart, logSfbEnergy,
 			logSfbFormFactor, sfbNRelevantLines);
 	}
 
 	/* get max scalefac for global gain */
-	maxScf = MIN_16;                                                              
-	minScf = MAX_16;                                                              
+	maxScf = MIN_16;
+	minScf = MAX_16;
 	for (i=0; i<psyOutChan->sfbCnt; i++) {
-		
+
 		if (maxScf < scf[i]) {
-			maxScf = scf[i];                                                          
+			maxScf = scf[i];
 		}
-		
+
 		if ((scf[i] != MIN_16) && (minScf > scf[i])) {
-			minScf = scf[i];                                                          
+			minScf = scf[i];
 		}
 	}
 	/* limit scf delta */
 	maxAllowedScf = minScf + MAX_SCF_DELTA;
 	for(i=0; i<psyOutChan->sfbCnt; i++) {
-		
+
 		if ((scf[i] != MIN_16) && (maxAllowedScf < scf[i])) {
-			scf[i] = maxAllowedScf;                                                   
+			scf[i] = maxAllowedScf;
 		}
 	}
 	/* new maxScf if any scf has been limited */
-	
+
 	if (maxAllowedScf < maxScf) {
-		maxScf = maxAllowedScf;                                                     
+		maxScf = maxAllowedScf;
 	}
-	
+
 	/* calc loop scalefactors */
-	
+
 	if (maxScf > MIN_16) {
-		*globalGain = maxScf;                                                       
-		lastSf = 0;                                                                 
-		
+		*globalGain = maxScf;
+		lastSf = 0;
+
 		for(i=0; i<psyOutChan->sfbCnt; i++) {
-			
+
 			if (scf[i] == MIN_16) {
-				scf[i] = lastSf;                                                        
+				scf[i] = lastSf;
 				/* set band explicitely to zero */
 				for (j=psyOutChan->sfbOffsets[i]; j<psyOutChan->sfbOffsets[i+1]; j++) {
-					psyOutChan->mdctSpectrum[j] = 0;                                      
+					psyOutChan->mdctSpectrum[j] = 0;
 				}
 			}
 			else {
 				scf[i] = maxScf - scf[i];
-				lastSf = scf[i];                                                        
+				lastSf = scf[i];
 			}
 		}
 	}
 	else{
-		*globalGain = 0;                                                            
+		*globalGain = 0;
 		/* set spectrum explicitely to zero */
 		for(i=0; i<psyOutChan->sfbCnt; i++) {
-			scf[i] = 0;                                                               
+			scf[i] = 0;
 			for (j=psyOutChan->sfbOffsets[i]; j<psyOutChan->sfbOffsets[i+1]; j++) {
-				psyOutChan->mdctSpectrum[j] = 0;                                        
+				psyOutChan->mdctSpectrum[j] = 0;
 			}
 		}
 	}
@@ -848,7 +848,7 @@
                const Word16 nChannels)
 {
 	Word16 j;
-	
+
 	for (j=0; j<nChannels; j++) {
 		CalcFormFactorChannel(logSfbFormFactor[j], sfbNRelevantLines[j], logSfbEnergy[j], &psyOutChannel[j]);
 	}
@@ -869,7 +869,7 @@
                      const Word16    nChannels)
 {
 	Word16 j;
-	
+
 	for (j=0; j<nChannels; j++) {
 		EstimateScaleFactorsChannel(&psyOutChannel[j],
 			qcOutChannel[j].scf,
diff --git a/media/libstagefright/codecs/aacenc/src/stat_bits.c b/media/libstagefright/codecs/aacenc/src/stat_bits.c
index baa289c8..c2bd8bd 100644
--- a/media/libstagefright/codecs/aacenc/src/stat_bits.c
+++ b/media/libstagefright/codecs/aacenc/src/stat_bits.c
@@ -52,9 +52,9 @@
                               struct TOOLSINFO *toolsInfo)
 {
   Word16 msBits, sfbOff, sfb;
-  msBits = 0;                                            
+  msBits = 0;
 
-   
+
   switch(toolsInfo->msDigest) {
     case MS_NONE:
     case MS_ALL:
@@ -85,34 +85,34 @@
   Word32 coefBits;
   Word16 *ptcoef;
 
-  count = 0;       
-  
+  count = 0;
+
   if (blockType == 2)
     numOfWindows = 8;
   else
     numOfWindows = 1;
-  tnsPresent = 0;                                        
+  tnsPresent = 0;
 
   for (i=0; i<numOfWindows; i++) {
-     
+
     if (tnsInfo->tnsActive[i]!=0) {
-      tnsPresent = 1;                                    
+      tnsPresent = 1;
     }
   }
-   
+
   if (tnsPresent) {
     /* there is data to be written*/
     /*count += 1; */
     for (i=0; i<numOfWindows; i++) {
-       
+
       if (blockType == 2)
         count += 1;
       else
         count += 2;
-       
+
       if (tnsInfo->tnsActive[i]) {
         count += 1;
-         
+
         if (blockType == 2) {
           count += 4;
           count += 3;
@@ -121,29 +121,29 @@
           count += 6;
           count += 5;
         }
-         
+
         if (tnsInfo->order[i]) {
           count += 1; /*direction*/
-          count += 1; /*coef_compression */	
-           
+          count += 1; /*coef_compression */
+
           if (tnsInfo->coefRes[i] == 4) {
             ptcoef = tnsInfo->coef + i*TNS_MAX_ORDER_SHORT;
-			coefBits = 3;                                        
+			coefBits = 3;
             for(k=0; k<tnsInfo->order[i]; k++) {
-                 
+
               if ((ptcoef[k] > 3) || (ptcoef[k] < -4)) {
-                coefBits = 4;                                    
+                coefBits = 4;
                 break;
               }
             }
           }
           else {
-            coefBits = 2;                                        
+            coefBits = 2;
             ptcoef = tnsInfo->coef + i*TNS_MAX_ORDER_SHORT;
 			for(k=0; k<tnsInfo->order[i]; k++) {
-                 
+
               if ((ptcoef[k] > 1) || (ptcoef[k] < -2)) {
-                coefBits = 3;                                    
+                coefBits = 3;
                 break;
               }
             }
@@ -155,14 +155,14 @@
       }
     }
   }
-  
+
   return count;
 }
 
 /**********************************************************************************
 *
 * function name: countTnsBits
-* description:   count tns bit demand  
+* description:   count tns bit demand
 *
 **********************************************************************************/
 static Word16 countTnsBits(TNS_INFO *tnsInfo,Word16 blockType)
@@ -173,29 +173,29 @@
 /*********************************************************************************
 *
 * function name: countStaticBitdemand
-* description:   count static bit demand include tns  
+* description:   count static bit demand include tns
 *
 **********************************************************************************/
 Word16 countStaticBitdemand(PSY_OUT_CHANNEL psyOutChannel[MAX_CHANNELS],
                             PSY_OUT_ELEMENT *psyOutElement,
-                            Word16 channels, 
+                            Word16 channels,
 							Word16 adtsUsed)
 {
   Word32 statBits;
   Word32 ch;
-  
-  statBits = 0;                                                  
+
+  statBits = 0;
 
   /* if adts used, add 56 bits */
   if(adtsUsed) statBits += 56;
 
-   
+
   switch (channels) {
     case 1:
       statBits += SI_ID_BITS+SI_SCE_BITS+SI_ICS_BITS;
       statBits += countTnsBits(&(psyOutChannel[0].tnsInfo),
                                psyOutChannel[0].windowSequence);
-       
+
       switch(psyOutChannel[0].windowSequence){
         case LONG_WINDOW:
         case START_WINDOW:
@@ -215,7 +215,7 @@
 								  psyOutChannel[0].sfbPerGroup,
 								  psyOutChannel[0].maxSfbPerGroup,
 								  &psyOutElement->toolsInfo);
-       
+
       switch (psyOutChannel[0].windowSequence) {
         case LONG_WINDOW:
         case START_WINDOW:
diff --git a/media/libstagefright/codecs/aacenc/src/tns.c b/media/libstagefright/codecs/aacenc/src/tns.c
index 473e0a0..455a864 100644
--- a/media/libstagefright/codecs/aacenc/src/tns.c
+++ b/media/libstagefright/codecs/aacenc/src/tns.c
@@ -100,20 +100,20 @@
   /*  assert(freq >= 0);  */
   shift = norm_l(fs);
   lineNumber = (extract_l(fixmul((bandStartOffset[numOfBands] << 2),Div_32(freq << shift,fs << shift))) + 1) >> 1;
- 
+
   /* freq > fs/2 */
-  temp = lineNumber - bandStartOffset[numOfBands] ;                                            
+  temp = lineNumber - bandStartOffset[numOfBands] ;
   if (temp >= 0)
     return numOfBands;
 
   /* find band the line number lies in */
   for (band=0; band<numOfBands; band++) {
-    temp = bandStartOffset[band + 1] - lineNumber;                                           
+    temp = bandStartOffset[band + 1] - lineNumber;
     if (temp > 0) break;
   }
 
   temp = (lineNumber - bandStartOffset[band]);
-  temp = (temp - (bandStartOffset[band + 1] - lineNumber));                                   
+  temp = (temp - (bandStartOffset[band + 1] - lineNumber));
   if ( temp > 0 )
   {
     band = band + 1;
@@ -139,25 +139,25 @@
 {
 
   Word32 bitratePerChannel;
-  tC->maxOrder     = TNS_MAX_ORDER;                                           
+  tC->maxOrder     = TNS_MAX_ORDER;
   tC->tnsStartFreq = 1275;
-  tC->coefRes      = 4;                                                                                 
-  
+  tC->coefRes      = 4;
+
   /* to avoid integer division */
-  if ( sub(channels,2) == 0 ) { 
-    bitratePerChannel = bitRate >> 1;    
+  if ( sub(channels,2) == 0 ) {
+    bitratePerChannel = bitRate >> 1;
   }
   else {
-    bitratePerChannel = bitRate;                                                                    
+    bitratePerChannel = bitRate;
   }
 
   tC->tnsMaxSfb = tnsMaxBandsLongMainLow[pC->sampRateIdx];
 
-  tC->tnsActive = active;                                                                           
+  tC->tnsActive = active;
 
   /* now calc band and line borders */
   tC->tnsStopBand = min(pC->sfbCnt, tC->tnsMaxSfb);
-  tC->tnsStopLine = pC->sfbOffset[tC->tnsStopBand];                                                 
+  tC->tnsStopLine = pC->sfbOffset[tC->tnsStopBand];
 
   tC->tnsStartBand = FreqToBandWithRounding(tC->tnsStartFreq, sampleRate,
                                             pC->sfbCnt, (const Word16*)pC->sfbOffset);
@@ -173,18 +173,18 @@
                                                      (const Word16*)pC->sfbOffset);
 
 
-  tC->tnsStartLine = pC->sfbOffset[tC->tnsStartBand];                                                                                                             
+  tC->tnsStartLine = pC->sfbOffset[tC->tnsStartBand];
 
   tC->lpcStopBand = tnsMaxBandsLongMainLow[pC->sampRateIdx];
   tC->lpcStopBand = min(tC->lpcStopBand, pC->sfbActive);
 
-  tC->lpcStopLine = pC->sfbOffset[tC->lpcStopBand];   
-  
+  tC->lpcStopLine = pC->sfbOffset[tC->lpcStopBand];
+
   tC->lpcStartBand = tnsMinBandNumberLong[pC->sampRateIdx];
 
-  tC->lpcStartLine = pC->sfbOffset[tC->lpcStartBand];                                               
+  tC->lpcStartLine = pC->sfbOffset[tC->lpcStartBand];
 
-  tC->threshold = TNS_GAIN_THRESH;                                                             
+  tC->threshold = TNS_GAIN_THRESH;
 
 
   return(0);
@@ -207,23 +207,23 @@
   Word32 bitratePerChannel;
   tC->maxOrder     = TNS_MAX_ORDER_SHORT;
   tC->tnsStartFreq = 2750;
-  tC->coefRes      = 3;                                                                                 
-  
+  tC->coefRes      = 3;
+
   /* to avoid integer division */
   if ( sub(channels,2) == 0 ) {
-    bitratePerChannel = L_shr(bitRate,1);    
+    bitratePerChannel = L_shr(bitRate,1);
   }
   else {
-    bitratePerChannel = bitRate;                                                                    
+    bitratePerChannel = bitRate;
   }
 
   tC->tnsMaxSfb = tnsMaxBandsShortMainLow[pC->sampRateIdx];
 
-  tC->tnsActive = active;                                                                           
+  tC->tnsActive = active;
 
   /* now calc band and line borders */
   tC->tnsStopBand = min(pC->sfbCnt, tC->tnsMaxSfb);
-  tC->tnsStopLine = pC->sfbOffset[tC->tnsStopBand];                                                 
+  tC->tnsStopLine = pC->sfbOffset[tC->tnsStopBand];
 
   tC->tnsStartBand=FreqToBandWithRounding(tC->tnsStartFreq, sampleRate,
                                           pC->sfbCnt, (const Word16*)pC->sfbOffset);
@@ -239,19 +239,19 @@
                                                      (const Word16*)pC->sfbOffset);
 
 
-  tC->tnsStartLine = pC->sfbOffset[tC->tnsStartBand];                                               
+  tC->tnsStartLine = pC->sfbOffset[tC->tnsStartBand];
 
   tC->lpcStopBand = tnsMaxBandsShortMainLow[pC->sampRateIdx];
 
   tC->lpcStopBand = min(tC->lpcStopBand, pC->sfbActive);
 
-  tC->lpcStopLine = pC->sfbOffset[tC->lpcStopBand];                                                 
+  tC->lpcStopLine = pC->sfbOffset[tC->lpcStopBand];
 
   tC->lpcStartBand = tnsMinBandNumberShort[pC->sampRateIdx];
 
-  tC->lpcStartLine = pC->sfbOffset[tC->lpcStartBand];                                               
+  tC->lpcStartLine = pC->sfbOffset[tC->lpcStartBand];
 
-  tC->threshold = TNS_GAIN_THRESH;                                                             
+  tC->threshold = TNS_GAIN_THRESH;
 
   return(0);
 }
@@ -259,7 +259,7 @@
 /**
 *
 * function name: TnsDetect
-* description:  Calculate TNS filter and decide on TNS usage 
+* description:  Calculate TNS filter and decide on TNS usage
 * returns:		0 if success
 *
 */
@@ -278,7 +278,7 @@
   Word32* pWork32 = &pScratchTns[subBlockNumber >> 8];
   Word16* pWeightedSpectrum = (Word16 *)&pScratchTns[subBlockNumber >> 8];
 
-                                                                                                    
+
   if (tC.tnsActive) {
     CalcWeightedSpectrum(spectrum,
                          pWeightedSpectrum,
@@ -290,7 +290,7 @@
                          tC.lpcStopBand,
                          pWork32);
 
-    temp = blockType - SHORT_WINDOW;                                                          
+    temp = blockType - SHORT_WINDOW;
     if ( temp != 0 ) {
         predictionGain = CalcTnsFilter( &pWeightedSpectrum[tC.lpcStartLine],
                                         tC.acfWindow,
@@ -299,15 +299,15 @@
                                         tnsData->dataRaw.tnsLong.subBlockInfo.parcor);
 
 
-        temp = predictionGain - tC.threshold;                                                  
+        temp = predictionGain - tC.threshold;
         if ( temp > 0 ) {
-          tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 1;                                      
+          tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 1;
         }
         else {
-          tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 0;                                      
+          tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 0;
         }
 
-        tnsData->dataRaw.tnsLong.subBlockInfo.predictionGain = predictionGain;                      
+        tnsData->dataRaw.tnsLong.subBlockInfo.predictionGain = predictionGain;
     }
     else{
 
@@ -317,28 +317,28 @@
                                         tC.maxOrder,
                                         tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].parcor);
 
-        temp = predictionGain - tC.threshold;                                                 
+        temp = predictionGain - tC.threshold;
         if ( temp > 0 ) {
-          tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 1;                     
+          tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 1;
         }
         else {
-          tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 0;                     
+          tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 0;
         }
 
-        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].predictionGain = predictionGain;     
+        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].predictionGain = predictionGain;
     }
 
   }
   else{
 
-    temp = blockType - SHORT_WINDOW;                                                          
+    temp = blockType - SHORT_WINDOW;
     if ( temp != 0 ) {
-        tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 0;                                        
-        tnsData->dataRaw.tnsLong.subBlockInfo.predictionGain = 0;                                   
+        tnsData->dataRaw.tnsLong.subBlockInfo.tnsActive = 0;
+        tnsData->dataRaw.tnsLong.subBlockInfo.predictionGain = 0;
     }
     else {
-        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 0;                       
-        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].predictionGain = 0;                  
+        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].tnsActive = 0;
+        tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber].predictionGain = 0;
     }
   }
 
@@ -362,21 +362,21 @@
    const TNS_SUBBLOCK_INFO *sbInfoSrc;
    Word32 i, temp;
 
-   temp =  blockType - SHORT_WINDOW;                                                           
+   temp =  blockType - SHORT_WINDOW;
    if ( temp != 0 ) {
-      sbInfoDest = &tnsDataDest->dataRaw.tnsLong.subBlockInfo;                                      
-      sbInfoSrc  = &tnsDataSrc->dataRaw.tnsLong.subBlockInfo;                                       
+      sbInfoDest = &tnsDataDest->dataRaw.tnsLong.subBlockInfo;
+      sbInfoSrc  = &tnsDataSrc->dataRaw.tnsLong.subBlockInfo;
    }
    else {
-      sbInfoDest = &tnsDataDest->dataRaw.tnsShort.subBlockInfo[subBlockNumber];                     
-      sbInfoSrc  = &tnsDataSrc->dataRaw.tnsShort.subBlockInfo[subBlockNumber];                      
+      sbInfoDest = &tnsDataDest->dataRaw.tnsShort.subBlockInfo[subBlockNumber];
+      sbInfoSrc  = &tnsDataSrc->dataRaw.tnsShort.subBlockInfo[subBlockNumber];
    }
 
    if (100*abs_s(sbInfoDest->predictionGain - sbInfoSrc->predictionGain) <
        (3 * sbInfoDest->predictionGain)) {
-      sbInfoDest->tnsActive = sbInfoSrc->tnsActive;                                                 
+      sbInfoDest->tnsActive = sbInfoSrc->tnsActive;
       for ( i=0; i< tC.maxOrder; i++) {
-        sbInfoDest->parcor[i] = sbInfoSrc->parcor[i];                                               
+        sbInfoDest->parcor[i] = sbInfoSrc->parcor[i];
       }
    }
 }
@@ -402,11 +402,11 @@
   Word32 temp;
   TNS_SUBBLOCK_INFO *psubBlockInfo;
 
-  temp_s = blockType - SHORT_WINDOW;                                                             
-  if ( temp_s != 0) {                                                                               
+  temp_s = blockType - SHORT_WINDOW;
+  if ( temp_s != 0) {
     psubBlockInfo = &tnsData->dataRaw.tnsLong.subBlockInfo;
 	if (psubBlockInfo->tnsActive == 0) {
-      tnsInfo->tnsActive[subBlockNumber] = 0;                                                       
+      tnsInfo->tnsActive[subBlockNumber] = 0;
       return(0);
     }
     else {
@@ -422,22 +422,22 @@
                    tC.coefRes);
 
       for (i=tC.maxOrder - 1; i>=0; i--)  {
-        temp = psubBlockInfo->parcor[i] - TNS_PARCOR_THRESH;         
+        temp = psubBlockInfo->parcor[i] - TNS_PARCOR_THRESH;
         if ( temp > 0 )
           break;
-        temp = psubBlockInfo->parcor[i] + TNS_PARCOR_THRESH;         
+        temp = psubBlockInfo->parcor[i] + TNS_PARCOR_THRESH;
         if ( temp < 0 )
           break;
       }
-      tnsInfo->order[subBlockNumber] = i + 1;                                                    
+      tnsInfo->order[subBlockNumber] = i + 1;
 
 
-      tnsInfo->tnsActive[subBlockNumber] = 1;                                                       
+      tnsInfo->tnsActive[subBlockNumber] = 1;
       for (i=subBlockNumber+1; i<TRANS_FAC; i++) {
-        tnsInfo->tnsActive[i] = 0;                                                                  
+        tnsInfo->tnsActive[i] = 0;
       }
-      tnsInfo->coefRes[subBlockNumber] = tC.coefRes;                                                
-      tnsInfo->length[subBlockNumber] = numOfSfb - tC.tnsStartBand;                                 
+      tnsInfo->coefRes[subBlockNumber] = tC.coefRes;
+      tnsInfo->length[subBlockNumber] = numOfSfb - tC.tnsStartBand;
 
 
       AnalysisFilterLattice(&(spectrum[tC.tnsStartLine]),
@@ -448,10 +448,10 @@
 
     }
   }     /* if (blockType!=SHORT_WINDOW) */
-  else /*short block*/ {                                                                            
+  else /*short block*/ {
     psubBlockInfo = &tnsData->dataRaw.tnsShort.subBlockInfo[subBlockNumber];
 	if (psubBlockInfo->tnsActive == 0) {
-      tnsInfo->tnsActive[subBlockNumber] = 0;                                                       
+      tnsInfo->tnsActive[subBlockNumber] = 0;
       return(0);
     }
     else {
@@ -466,19 +466,19 @@
                    tC.maxOrder,
                    tC.coefRes);
       for (i=(tC.maxOrder - 1); i>=0; i--)  {
-        temp = psubBlockInfo->parcor[i] - TNS_PARCOR_THRESH;    
+        temp = psubBlockInfo->parcor[i] - TNS_PARCOR_THRESH;
          if ( temp > 0 )
           break;
 
-        temp = psubBlockInfo->parcor[i] + TNS_PARCOR_THRESH;    
+        temp = psubBlockInfo->parcor[i] + TNS_PARCOR_THRESH;
         if ( temp < 0 )
           break;
       }
-      tnsInfo->order[subBlockNumber] = i + 1;                                                    
+      tnsInfo->order[subBlockNumber] = i + 1;
 
-      tnsInfo->tnsActive[subBlockNumber] = 1;                                                       
-      tnsInfo->coefRes[subBlockNumber] = tC.coefRes;                                                
-      tnsInfo->length[subBlockNumber] = numOfSfb - tC.tnsStartBand;                             
+      tnsInfo->tnsActive[subBlockNumber] = 1;
+      tnsInfo->coefRes[subBlockNumber] = tC.coefRes;
+      tnsInfo->length[subBlockNumber] = numOfSfb - tC.tnsStartBand;
 
 
       AnalysisFilterLattice(&(spectrum[tC.tnsStartLine]), (tC.tnsStopLine - tC.tnsStartLine),
@@ -507,14 +507,14 @@
 {
   Word32 k;
 
-  Word32 accu_y = 0x40000000;                                                                     
+  Word32 accu_y = 0x40000000;
   accu_y = L_shr(accu_y,scale);
 
   for(k=1; k<INT_BITS; k++) {
-    const Word32 z = m_log2_table[k];                                                             
+    const Word32 z = m_log2_table[k];
 
     while(L_sub(x,z) >= 0) {
-       
+
       x = L_sub(x, z);
       accu_y = L_add(accu_y, (accu_y >> k));
     }
@@ -548,43 +548,43 @@
     Word32 maxWS;
     Word32 tnsSfbMean[MAX_SFB];    /* length [lpcStopBand-lpcStartBand] should be sufficient here */
 
-    maxWS = 0;                                                                                   
-  
+    maxWS = 0;
+
     /* calc 1.0*2^-INT_BITS/2/sqrt(en) */
     for( sfb = lpcStartBand; sfb < lpcStopBand; sfb++) {
 
-      tmp2 = sfbEnergy[sfb] - 2;                                                            
+      tmp2 = sfbEnergy[sfb] - 2;
       if( tmp2 > 0) {
         tmp = rsqrt(sfbEnergy[sfb], INT_BITS);
-		if(tmp > INT_BITS_SCAL) 
+		if(tmp > INT_BITS_SCAL)
 		{
 			shift =  norm_l(tmp);
-			tmp = Div_32( INT_BITS_SCAL << shift, tmp << shift ); 
+			tmp = Div_32( INT_BITS_SCAL << shift, tmp << shift );
 		}
 		else
 		{
-			tmp = 0x7fffffff; 
+			tmp = 0x7fffffff;
 		}
       }
       else {
-        tmp = 0x7fffffff;                                                                           
-      } 
-      tnsSfbMean[sfb] = tmp;                                                                        
+        tmp = 0x7fffffff;
+      }
+      tnsSfbMean[sfb] = tmp;
     }
 
     /* spread normalized values from sfbs to lines */
-    sfb = lpcStartBand;                                                                             
-    tmp = tnsSfbMean[sfb];                                                                          
+    sfb = lpcStartBand;
+    tmp = tnsSfbMean[sfb];
     for ( i=lpcStartLine; i<lpcStopLine; i++){
-      tmp_s = sfbOffset[sfb + 1] - i;                                                      
+      tmp_s = sfbOffset[sfb + 1] - i;
       if ( tmp_s == 0 ) {
         sfb = sfb + 1;
-        tmp2_s = sfb + 1 - lpcStopBand;                                                       
+        tmp2_s = sfb + 1 - lpcStopBand;
         if (tmp2_s <= 0) {
-          tmp = tnsSfbMean[sfb];                                                                    
+          tmp = tnsSfbMean[sfb];
         }
       }
-      pWork32[i] = tmp;                                                                    
+      pWork32[i] = tmp;
     }
     /*filter down*/
     for (i=(lpcStopLine - 2); i>=lpcStartLine; i--){
@@ -597,8 +597,8 @@
 
     /* weight and normalize */
     for (i=lpcStartLine; i<lpcStopLine; i++){
-      pWork32[i] = MULHIGH(pWork32[i], spectrum[i]);                               
-      maxWS |= L_abs(pWork32[i]);                                                          
+      pWork32[i] = MULHIGH(pWork32[i], spectrum[i]);
+      maxWS |= L_abs(pWork32[i]);
     }
     maxShift = norm_l(maxWS);
 
@@ -646,7 +646,7 @@
   assert(tnsOrder <= TNS_MAX_ORDER);      /* remove asserts later? (btg) */
 
   for(i=0;i<tnsOrder;i++) {
-    parcor[i] = 0;                               
+    parcor[i] = 0;
   }
 
   AutoCorrelation(signal, parcorWorkBuffer, numOfLines, tnsOrderPlus1);
@@ -678,15 +678,15 @@
   Word32 accu;
   Word32 scf;
 
-  scf = 10 - 1;                                                                                      
+  scf = 10 - 1;
 
   isamples = samples;
   /* calc first corrCoef:  R[0] = sum { t[i] * t[i] } ; i = 0..N-1 */
-  accu = 0;                                                                                      
+  accu = 0;
   for(j=0; j<isamples; j++) {
     accu = L_add(accu, ((input[j] * input[j]) >> scf));
   }
-  corr[0] = accu;                                                                                
+  corr[0] = accu;
 
   /* early termination if all corr coeffs are likely going to be zero */
   if(corr[0] == 0) return ;
@@ -694,13 +694,13 @@
   /* calc all other corrCoef:  R[j] = sum { t[i] * t[i+j] } ; i = 0..(N-j-1), j=1..p */
   for(i=1; i<corrCoeff; i++) {
     isamples = isamples - 1;
-    accu = 0;                                                                                    
+    accu = 0;
     for(j=0; j<isamples; j++) {
       accu = L_add(accu, ((input[j] * input[j+i]) >> scf));
     }
-    corr[i] = accu;                                                                              
+    corr[i] = accu;
   }
-}    
+}
 #endif
 
 /*****************************************************************************
@@ -720,20 +720,20 @@
   Word32 predictionGain = 0;
   Word32 num, denom;
   Word32 temp, workBuffer0;
-   
 
-  num = workBuffer[0];                                                                           
-  temp = workBuffer[numOfCoeff];                                                                 
+
+  num = workBuffer[0];
+  temp = workBuffer[numOfCoeff];
 
   for(i=0; i<numOfCoeff-1; i++) {
-    workBuffer[i + numOfCoeff] = workBuffer[i + 1];                                        
+    workBuffer[i + numOfCoeff] = workBuffer[i + 1];
   }
-  workBuffer[i + numOfCoeff] = temp;                                                                           
-  
+  workBuffer[i + numOfCoeff] = temp;
+
   for(i=0; i<numOfCoeff; i++) {
     Word32 refc;
 
-     
+
     if (workBuffer[0] < L_abs(workBuffer[i + numOfCoeff])) {
       return 0 ;
     }
@@ -742,21 +742,21 @@
     /* calculate refc = -workBuffer[numOfCoeff+i] / workBuffer[0]; -1 <= refc < 1 */
 	refc = L_negate(fixmul(workBuffer[numOfCoeff + i], workBuffer0));
 
-    reflCoeff[i] = refc;                                                                           
+    reflCoeff[i] = refc;
 
-    pWorkBuffer = &(workBuffer[numOfCoeff]);                                                        
+    pWorkBuffer = &(workBuffer[numOfCoeff]);
 
     for(j=i; j<numOfCoeff; j++) {
       Word32 accu1, accu2;
       accu1 = L_add(pWorkBuffer[j], fixmul(refc, workBuffer[j - i]));
       accu2 = L_add(workBuffer[j - i], fixmul(refc, pWorkBuffer[j]));
-      pWorkBuffer[j] = accu1;                                                                       
-      workBuffer[j - i] = accu2;                                                                 
+      pWorkBuffer[j] = accu1;
+      workBuffer[j - i] = accu2;
     }
   }
 
   denom = MULHIGH(workBuffer[0], NORM_COEF);
-   
+
   if (denom != 0) {
     Word32 temp;
 	shift = norm_l(denom);
@@ -774,11 +774,11 @@
   Word32 index = 0;
   Word32 i;
   Word32 temp;
-   
+
   for (i=0;i<8;i++) {
-    temp = L_sub( parcor, tnsCoeff3Borders[i]);                                                     
+    temp = L_sub( parcor, tnsCoeff3Borders[i]);
     if (temp > 0)
-      index=i;                                                                                      
+      index=i;
   }
   return extract_l(index - 4);
 }
@@ -788,12 +788,12 @@
   Word32 index = 0;
   Word32 i;
   Word32 temp;
-   
+
 
   for (i=0;i<16;i++) {
-    temp = L_sub(parcor, tnsCoeff4Borders[i]);                                                      
+    temp = L_sub(parcor, tnsCoeff4Borders[i]);
     if (temp > 0)
-      index=i;                                                                                      
+      index=i;
   }
   return extract_l(index - 8);
 }
@@ -814,12 +814,12 @@
   Word32 temp;
 
   for(i=0; i<order; i++) {
-    temp = bitsPerCoeff - 3;                                                                    
+    temp = bitsPerCoeff - 3;
     if (temp == 0) {
-      index[i] = Search3(parcor[i]);                                                                
-    } 
+      index[i] = Search3(parcor[i]);
+    }
     else {
-      index[i] = Search4(parcor[i]);                                                                
+      index[i] = Search4(parcor[i]);
     }
   }
 }
@@ -839,12 +839,12 @@
   Word32 temp;
 
   for (i=0; i<order; i++) {
-    temp = bitsPerCoeff - 4;                                                                     
+    temp = bitsPerCoeff - 4;
     if ( temp == 0 ) {
-        parcor[i] = tnsCoeff4[index[i] + 8];                                                     
+        parcor[i] = tnsCoeff4[index[i] + 8];
     }
     else {
-        parcor[i] = tnsCoeff3[index[i] + 4];                                                  
+        parcor[i] = tnsCoeff3[index[i] + 4];
     }
   }
 }
@@ -865,20 +865,20 @@
    Word32 accu,tmp,tmpSave;
 
    x = x >> 1;
-   tmpSave = x;                                                                                     
+   tmpSave = x;
 
    for (i=0; i<(order - 1); i++) {
 
      tmp = L_add(fixmul(coef_par[i], x), state_par[i]);
      x   = L_add(fixmul(coef_par[i], state_par[i]), x);
 
-     state_par[i] = tmpSave;                                                                        
-     tmpSave = tmp;                                                                                 
+     state_par[i] = tmpSave;
+     tmpSave = tmp;
   }
 
   /* last stage: only need half operations */
   accu = fixmul(state_par[order - 1], coef_par[(order - 1)]);
-  state_par[(order - 1)] = tmpSave;                                                                
+  state_par[(order - 1)] = tmpSave;
 
   x = L_add(accu, x);
   x = L_add(x, x);
@@ -903,11 +903,11 @@
   Word32 j;
 
   for ( j=0; j<TNS_MAX_ORDER; j++ ) {
-    state_par[j] = 0;                                                                               
+    state_par[j] = 0;
   }
 
   for(j=0; j<numOfLines; j++) {
-    output[j] = FIRLattice(order,signal[j],state_par,parCoeff);                                     
+    output[j] = FIRLattice(order,signal[j],state_par,parCoeff);
   }
 }
 
@@ -922,11 +922,11 @@
                                TNS_SUBBLOCK_INFO subInfo, /*!< TNS subblock info */
                                Word32 *thresholds)        /*!< thresholds (modified) */
 {
-  Word32 i;                                                                                         
+  Word32 i;
   if (subInfo.tnsActive) {
     for(i=startCb; i<stopCb; i++) {
       /* thresholds[i] * 0.25 */
-      thresholds[i] = (thresholds[i] >> 2);                                                      
+      thresholds[i] = (thresholds[i] >> 2);
     }
   }
 }
diff --git a/media/libstagefright/codecs/aacenc/src/transform.c b/media/libstagefright/codecs/aacenc/src/transform.c
index 4d11f78..a154a2f 100644
--- a/media/libstagefright/codecs/aacenc/src/transform.c
+++ b/media/libstagefright/codecs/aacenc/src/transform.c
@@ -31,7 +31,7 @@
 #define swap2(p0,p1) \
 	t = p0; t1 = *(&(p0)+1);	\
 	p0 = p1; *(&(p0)+1) = *(&(p1)+1);	\
-	p1 = t; *(&(p1)+1) = t1	
+	p1 = t; *(&(p1)+1) = t1
 
 /*********************************************************************************
 *
@@ -47,18 +47,18 @@
 
 	part0 = buf;
     part1 = buf + num;
-	
+
 	while ((i = *bitTab++) != 0) {
         j = *bitTab++;
 
-        swap2(part0[4*i+0], part0[4*j+0]);	
-        swap2(part0[4*i+2], part1[4*j+0]);	
-        swap2(part1[4*i+0], part0[4*j+2]);	
-        swap2(part1[4*i+2], part1[4*j+2]);	
+        swap2(part0[4*i+0], part0[4*j+0]);
+        swap2(part0[4*i+2], part1[4*j+0]);
+        swap2(part1[4*i+0], part0[4*j+2]);
+        swap2(part1[4*i+2], part1[4*j+2]);
     }
 
     do {
-        swap2(part0[4*i+2], part1[4*i+0]);	
+        swap2(part0[4*i+2], part1[4*i+0]);
     } while ((i = *bitTab++) != 0);
 }
 
@@ -74,8 +74,8 @@
 {
     int r0, r1, r2, r3;
 	int r4, r5, r6, r7;
-	
-	for (; num != 0; num--) 
+
+	for (; num != 0; num--)
 	{
 		r0 = buf[0] + buf[2];
 		r1 = buf[1] + buf[3];
@@ -113,7 +113,7 @@
    int i4, i5, i6, i7;
    int t0, t1, t2, t3;
 
-	for ( ; num != 0; num--) 
+	for ( ; num != 0; num--)
 	{
 		r0 = buf[0] + buf[2];
 		i0 = buf[1] + buf[3];
@@ -194,23 +194,23 @@
 	int i, j, step;
 	int *xptr, *csptr;
 
-	for (num >>= 2; num != 0; num >>= 2) 
+	for (num >>= 2; num != 0; num >>= 2)
 	{
 		step = 2*bgn;
 		xptr = buf;
 
-    	for (i = num; i != 0; i--) 
+    	for (i = num; i != 0; i--)
 		{
 			csptr = twidTab;
 
-			for (j = bgn; j != 0; j--) 
+			for (j = bgn; j != 0; j--)
 			{
 				r0 = xptr[0];
 				r1 = xptr[1];
 				xptr += step;
-				
+
 				t0 = xptr[0];
-				t1 = xptr[1];				
+				t1 = xptr[1];
 				cosx = csptr[0];
 				sinx = csptr[1];
 				r2 = MULHIGH(cosx, t0) + MULHIGH(sinx, t1);		/* cos*br + sin*bi */
@@ -223,7 +223,7 @@
 				r1 = t1 - r3;
 				r2 = t0 + r2;
 				r3 = t1 + r3;
-				
+
 				t0 = xptr[0];
 				t1 = xptr[1];
 				cosx = csptr[2];
@@ -231,7 +231,7 @@
 				r4 = MULHIGH(cosx, t0) + MULHIGH(sinx, t1);		/* cos*cr + sin*ci */
 				r5 = MULHIGH(cosx, t1) - MULHIGH(sinx, t0);		/* cos*ci - sin*cr */
 				xptr += step;
-				
+
 				t0 = xptr[0];
 				t1 = xptr[1];
 				cosx = csptr[4];
@@ -282,25 +282,25 @@
 	int tr1, ti1, tr2, ti2;
 	int cosa, sina, cosb, sinb;
 	int *buf1;
-	
+
 	buf1 = buf0 + num - 1;
 
 	for(i = num >> 2; i != 0; i--)
 	{
-		cosa = *csptr++;	
-		sina = *csptr++;	
-		cosb = *csptr++;	
-		sinb = *csptr++;		
+		cosa = *csptr++;
+		sina = *csptr++;
+		cosb = *csptr++;
+		sinb = *csptr++;
 
 		tr1 = *(buf0 + 0);
 		ti2 = *(buf0 + 1);
 		tr2 = *(buf1 - 1);
 		ti1 = *(buf1 + 0);
-		
+
 		*buf0++ = MULHIGH(cosa, tr1) + MULHIGH(sina, ti1);
-		*buf0++ = MULHIGH(cosa, ti1) - MULHIGH(sina, tr1);		
-		
-		*buf1-- = MULHIGH(cosb, ti2) - MULHIGH(sinb, tr2);		
+		*buf0++ = MULHIGH(cosa, ti1) - MULHIGH(sina, tr1);
+
+		*buf1-- = MULHIGH(cosb, ti2) - MULHIGH(sinb, tr2);
 		*buf1-- = MULHIGH(cosb, tr2) + MULHIGH(sinb, ti2);
 	}
 }
@@ -319,12 +319,12 @@
 	int *buf1;
 
 	buf1 = buf0 + num - 1;
-	
+
 	for(i = num >> 2; i != 0; i--)
 	{
-		cosa = *csptr++;	
-		sina = *csptr++;	
-		cosb = *csptr++;	
+		cosa = *csptr++;
+		sina = *csptr++;
+		cosb = *csptr++;
 		sinb = *csptr++;
 
 		tr1 = *(buf0 + 0);
@@ -333,10 +333,10 @@
 		tr2 = *(buf1 - 1);
 
 		*buf0++ = MULHIGH(cosa, tr1) + MULHIGH(sina, ti1);
-		*buf1-- = MULHIGH(sina, tr1) - MULHIGH(cosa, ti1);		
-		
+		*buf1-- = MULHIGH(sina, tr1) - MULHIGH(cosa, ti1);
+
 		*buf0++ = MULHIGH(sinb, tr2) - MULHIGH(cosb, ti2);
-		*buf1-- = MULHIGH(cosb, tr2) + MULHIGH(sinb, ti2);	
+		*buf1-- = MULHIGH(cosb, tr2) + MULHIGH(sinb, ti2);
 	}
 }
 #endif
@@ -353,17 +353,17 @@
 	PreMDCT(buf, 1024, cossintab + 128);
 
 	Shuffle(buf, 512, bitrevTab + 17);
-	Radix8First(buf, 512 >> 3);						
+	Radix8First(buf, 512 >> 3);
 	Radix4FFT(buf, 512 >> 3, 8, (int *)twidTab512);
 
-	PostMDCT(buf, 1024, cossintab + 128);	
+	PostMDCT(buf, 1024, cossintab + 128);
 }
 
 
 /**********************************************************************************
 *
 * function name: Mdct_Short
-* description:  the short block mdct 
+* description:  the short block mdct
 *
 **********************************************************************************/
 void Mdct_Short(int *buf)
@@ -371,10 +371,10 @@
 	PreMDCT(buf, 128, cossintab);
 
 	Shuffle(buf, 64, bitrevTab);
-	Radix4First(buf, 64 >> 2);						
-	Radix4FFT(buf, 64 >> 2, 4, (int *)twidTab64);	
+	Radix4First(buf, 64 >> 2);
+	Radix4FFT(buf, 64 >> 2, 4, (int *)twidTab64);
 
-	PostMDCT(buf, 128, cossintab);	
+	PostMDCT(buf, 128, cossintab);
 }
 
 
@@ -382,7 +382,7 @@
 *
 * function name: shiftMdctDelayBuffer
 * description:    the mdct delay buffer has a size of 1600,
-*  so the calculation of LONG,STOP must be  spilt in two 
+*  so the calculation of LONG,STOP must be  spilt in two
 *  passes with 1024 samples and a mid shift,
 *  the SHORT transforms can be completed in the delay buffer,
 *  and afterwards a shift
@@ -409,7 +409,7 @@
 	dsBuf = timeSignal;
 
 	for(i=0; i<FRAME_LEN_LONG; i+=8)
-	{   
+	{
 		*srBuf++ = *dsBuf; dsBuf += chIncrement;
 		*srBuf++ = *dsBuf; dsBuf += chIncrement;
 		*srBuf++ = *dsBuf; dsBuf += chIncrement;
@@ -470,10 +470,10 @@
 
 	Word32 delayBufferSf,timeSignalSf,minSf;
 	Word32 headRoom=0;
-	
+
 	switch(blockType){
-		
-		
+
+
 	case LONG_WINDOW:
 		/*
 		we access BLOCK_SWITCHING_OFFSET (1600 ) delay buffer samples + 448 new timeSignal samples
@@ -483,15 +483,15 @@
 		timeSignalSf  = getScalefactorOfShortVectorStride(timeSignal,2*FRAME_LEN_LONG-BLOCK_SWITCHING_OFFSET,chIncrement);
 		minSf = min(delayBufferSf,timeSignalSf);
 		minSf = min(minSf,14);
-		
+
 		dctIn0 = mdctDelayBuffer;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1;
 		outData0 = realOut + FRAME_LEN_LONG/2;
-		
+
 		/* add windows and pre add for mdct to last buffer*/
 		winPtr = (int *)LongWindowKBD;
 		for(i=0;i<FRAME_LEN_LONG/2;i++){
-			timeSignalSample = (*dctIn0++) << minSf; 
+			timeSignalSample = (*dctIn0++) << minSf;
 			ws1 = timeSignalSample * (*winPtr >> 16);
 			timeSignalSample = (*dctIn1--) << minSf;
 			ws2 = timeSignalSample * (*winPtr & 0xffff);
@@ -499,30 +499,30 @@
 			/* shift 2 to avoid overflow next */
 			*outData0++ = (ws1 >> 2) - (ws2 >> 2);
 		}
-		
+
 		shiftMdctDelayBuffer(mdctDelayBuffer,timeSignal,chIncrement);
-		
+
 		/* add windows and pre add for mdct to new buffer*/
 		dctIn0 = mdctDelayBuffer;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1;
-		outData0 = realOut + FRAME_LEN_LONG/2 - 1; 
+		outData0 = realOut + FRAME_LEN_LONG/2 - 1;
 		winPtr = (int *)LongWindowKBD;
-		for(i=0;i<FRAME_LEN_LONG/2;i++){    
+		for(i=0;i<FRAME_LEN_LONG/2;i++){
 			timeSignalSample = (*dctIn0++) << minSf;
 			ws1 = timeSignalSample * (*winPtr & 0xffff);
 			timeSignalSample = (*dctIn1--) << minSf;
 			ws2 = timeSignalSample * (*winPtr >> 16);
 			winPtr++;
 			/* shift 2 to avoid overflow next */
-			*outData0-- = -((ws1 >> 2) + (ws2 >> 2)); 
+			*outData0-- = -((ws1 >> 2) + (ws2 >> 2));
 		}
 
 		Mdct_Long(realOut);
 		/* update scale factor */
 		minSf = 14 - minSf;
-		*mdctScale=minSf; 
+		*mdctScale=minSf;
 		break;
-		
+
 	case START_WINDOW:
 		/*
 		we access BLOCK_SWITCHING_OFFSET (1600 ) delay buffer samples + no timeSignal samples
@@ -533,7 +533,7 @@
 
 		dctIn0 = mdctDelayBuffer;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1;
-		outData0 = realOut + FRAME_LEN_LONG/2; 		
+		outData0 = realOut + FRAME_LEN_LONG/2;
 		winPtr = (int *)LongWindowKBD;
 
 		/* add windows and pre add for mdct to last buffer*/
@@ -545,18 +545,18 @@
 			winPtr ++;
 			*outData0++ = (ws1 >> 2) - (ws2 >> 2);  /* shift 2 to avoid overflow next */
 		}
-		
+
 		shiftMdctDelayBuffer(mdctDelayBuffer,timeSignal,chIncrement);
-		
-		outData0 = realOut + FRAME_LEN_LONG/2 - 1; 
+
+		outData0 = realOut + FRAME_LEN_LONG/2 - 1;
 		for(i=0;i<LS_TRANS;i++){
-			*outData0-- = -mdctDelayBuffer[i] << (15 - 2 + minSf);  
+			*outData0-- = -mdctDelayBuffer[i] << (15 - 2 + minSf);
 		}
-		
+
 		/* add windows and pre add for mdct to new buffer*/
 		dctIn0 = mdctDelayBuffer + LS_TRANS;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1 - LS_TRANS;
-		outData0 = realOut + FRAME_LEN_LONG/2 - 1 -LS_TRANS; 
+		outData0 = realOut + FRAME_LEN_LONG/2 - 1 -LS_TRANS;
 		winPtr = (int *)ShortWindowSine;
 		for(i=0;i<FRAME_LEN_SHORT/2;i++){
 			timeSignalSample= (*dctIn0++) << minSf;
@@ -572,7 +572,7 @@
 		minSf = 14 - minSf;
 		*mdctScale= minSf;
 		break;
-		
+
 	case STOP_WINDOW:
 		/*
 		we access BLOCK_SWITCHING_OFFSET-LS_TRANS (1600-448 ) delay buffer samples + 448 new timeSignal samples
@@ -580,19 +580,19 @@
 		*/
 		delayBufferSf = getScalefactorOfShortVectorStride(mdctDelayBuffer+LS_TRANS,BLOCK_SWITCHING_OFFSET-LS_TRANS,1);
 		timeSignalSf  = getScalefactorOfShortVectorStride(timeSignal,2*FRAME_LEN_LONG-BLOCK_SWITCHING_OFFSET,chIncrement);
-		minSf = min(delayBufferSf,timeSignalSf);    
+		minSf = min(delayBufferSf,timeSignalSf);
 		minSf = min(minSf,13);
-		
+
 		outData0 = realOut + FRAME_LEN_LONG/2;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1;
 		for(i=0;i<LS_TRANS;i++){
-			*outData0++ = -(*dctIn1--) << (15 - 2 + minSf);    
+			*outData0++ = -(*dctIn1--) << (15 - 2 + minSf);
 		}
-		
+
 		/* add windows and pre add for mdct to last buffer*/
 		dctIn0 = mdctDelayBuffer + LS_TRANS;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1 - LS_TRANS;
-		outData0 = realOut + FRAME_LEN_LONG/2 + LS_TRANS; 
+		outData0 = realOut + FRAME_LEN_LONG/2 + LS_TRANS;
 		winPtr = (int *)ShortWindowSine;
 		for(i=0;i<FRAME_LEN_SHORT/2;i++){
 			timeSignalSample = (*dctIn0++) << minSf;
@@ -602,13 +602,13 @@
 			winPtr++;
 			*outData0++ = (ws1 >> 2) - (ws2 >> 2);  /* shift 2 to avoid overflow next */
 		}
-		
+
 		shiftMdctDelayBuffer(mdctDelayBuffer,timeSignal,chIncrement);
-		
+
 		/* add windows and pre add for mdct to new buffer*/
 		dctIn0 = mdctDelayBuffer;
 		dctIn1 = mdctDelayBuffer + FRAME_LEN_LONG - 1;
-		outData0 = realOut + FRAME_LEN_LONG/2 - 1; 
+		outData0 = realOut + FRAME_LEN_LONG/2 - 1;
 		winPtr = (int *)LongWindowKBD;
 		for(i=0;i<FRAME_LEN_LONG/2;i++){
 			timeSignalSample= (*dctIn0++) << minSf;
@@ -618,26 +618,26 @@
 			*outData0-- =  -((ws1 >> 2) + (ws2 >> 2));  /* shift 2 to avoid overflow next */
 			winPtr++;
 		}
-		
+
 		Mdct_Long(realOut);
 		minSf = 14 - minSf;
 		*mdctScale= minSf; /* update scale factor */
 		break;
-		
+
 	case SHORT_WINDOW:
 		/*
 		we access BLOCK_SWITCHING_OFFSET (1600 ) delay buffer samples + no new timeSignal samples
 		and get the biggest scale factor for next calculate more precise
-		*/		
+		*/
 		minSf = getScalefactorOfShortVectorStride(mdctDelayBuffer+TRANSFORM_OFFSET_SHORT,9*FRAME_LEN_SHORT,1);
 		minSf = min(minSf,10);
-		
-		
+
+
 		for(w=0;w<TRANS_FAC;w++){
 			dctIn0 = mdctDelayBuffer+w*FRAME_LEN_SHORT+TRANSFORM_OFFSET_SHORT;
 			dctIn1 = mdctDelayBuffer+w*FRAME_LEN_SHORT+TRANSFORM_OFFSET_SHORT + FRAME_LEN_SHORT-1;
-			outData0 = realOut + FRAME_LEN_SHORT/2; 
-			outData1 = realOut + FRAME_LEN_SHORT/2 - 1; 
+			outData0 = realOut + FRAME_LEN_SHORT/2;
+			outData1 = realOut + FRAME_LEN_SHORT/2 - 1;
 
 			winPtr = (int *)ShortWindowSine;
 			for(i=0;i<FRAME_LEN_SHORT/2;i++){
@@ -646,7 +646,7 @@
 				timeSignalSample= *dctIn1 << minSf;
 				ws2 = timeSignalSample * (*winPtr & 0xffff);
 				*outData0++ = (ws1 >> 2) - (ws2 >> 2);  /* shift 2 to avoid overflow next */
-				
+
 				timeSignalSample= *(dctIn0 + FRAME_LEN_SHORT) << minSf;
 				ws1 = timeSignalSample * (*winPtr & 0xffff);
 				timeSignalSample= *(dctIn1 + FRAME_LEN_SHORT) << minSf;
@@ -661,10 +661,10 @@
 			Mdct_Short(realOut);
 			realOut += FRAME_LEN_SHORT;
 		}
-		
+
 		minSf = 11 - minSf;
 		*mdctScale = minSf; /* update scale factor */
-		
+
 		shiftMdctDelayBuffer(mdctDelayBuffer,timeSignal,chIncrement);
 		break;
   }
diff --git a/media/libstagefright/codecs/amrwbenc/Android.mk b/media/libstagefright/codecs/amrwbenc/Android.mk
index 5179380..ae43870 100644
--- a/media/libstagefright/codecs/amrwbenc/Android.mk
+++ b/media/libstagefright/codecs/amrwbenc/Android.mk
@@ -3,7 +3,7 @@
 include frameworks/base/media/libstagefright/codecs/common/Config.mk
 
 
- 	
+
 LOCAL_SRC_FILES := \
 	AMRWBEncoder.cpp \
 	src/autocorr.c \
@@ -91,7 +91,7 @@
 
 LOCAL_ARM_MODE := arm
 
-LOCAL_STATIC_LIBRARIES := 
+LOCAL_STATIC_LIBRARIES :=
 
 LOCAL_SHARED_LIBRARIES :=
 
diff --git a/media/libstagefright/codecs/amrwbenc/inc/basic_op.h b/media/libstagefright/codecs/amrwbenc/inc/basic_op.h
index 7734913..c23dce6 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/basic_op.h
+++ b/media/libstagefright/codecs/amrwbenc/inc/basic_op.h
@@ -33,7 +33,7 @@
 #define  static_vo  static __inline__
 #else
 #define  static_vo  static __inline
-#endif 
+#endif
 
 #define saturate(L_var1) (((L_var1) > 0X00007fffL) ? (MAX_16): (((L_var1) < (Word32) 0xffff8000L) ? (MIN_16): ((L_var1) & 0xffff)))
 
@@ -87,7 +87,7 @@
 static_vo Word32 L_shr_r (Word32 L_var1, Word16 var2); 				/* Long shift right with round,  3   */
 static_vo Word16 norm_s (Word16 var1);             				/* Short norm,           15  */
 static_vo Word16 div_s (Word16 var1, Word16 var2); 				/* Short division,       18  */
-static_vo Word16 norm_l (Word32 L_var1);           				/* Long norm,            30  */   
+static_vo Word16 norm_l (Word32 L_var1);           				/* Long norm,            30  */
 
 /*___________________________________________________________________________
 |                                                                           |
@@ -1030,8 +1030,8 @@
 				L_num <<= 1;
 				if (L_num >= L_denom)
 				{
-					L_num -= L_denom;      
-					var_out += 1;          
+					L_num -= L_denom;
+					var_out += 1;
 				}
 			}
 		}
diff --git a/media/libstagefright/codecs/amrwbenc/inc/homing.tab b/media/libstagefright/codecs/amrwbenc/inc/homing.tab
index edcccdd..e399fb8 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/homing.tab
+++ b/media/libstagefright/codecs/amrwbenc/inc/homing.tab
@@ -33,89 +33,89 @@
 
 static const Word16 dfh_M7k[PRMN_7k] =
 {
-  3168, 29954, 29213, 16121, 
-	64, 13440, 30624, 16430, 
+  3168, 29954, 29213, 16121,
+	64, 13440, 30624, 16430,
  19008
 };
 
 static const Word16 dfh_M9k[PRMN_9k] =
 {
-   3168, 31665,  9943, 9123, 
-  15599,  4358, 20248, 2048, 
+   3168, 31665,  9943, 9123,
+  15599,  4358, 20248, 2048,
   17040, 27787, 16816, 13888
 };
 
 static const Word16 dfh_M12k[PRMN_12k] =
 {
-  3168, 31665,  9943,  9128, 
-  3647,  8129, 30930, 27926, 
- 18880, 12319,   496,  1042, 
-  4061, 20446, 25629, 28069, 
+  3168, 31665,  9943,  9128,
+  3647,  8129, 30930, 27926,
+ 18880, 12319,   496,  1042,
+  4061, 20446, 25629, 28069,
  13948
 };
 
 static const Word16 dfh_M14k[PRMN_14k] =
 {
-    3168, 31665,  9943,  9131, 
-   24815,   655, 26616, 26764, 
-    7238, 19136,  6144,    88, 
-	4158, 25733, 30567, 30494, 
+    3168, 31665,  9943,  9131,
+   24815,   655, 26616, 26764,
+    7238, 19136,  6144,    88,
+	4158, 25733, 30567, 30494,
 	221, 20321, 17823
 };
 
 static const Word16 dfh_M16k[PRMN_16k] =
 {
-    3168, 31665,  9943,  9131, 
-   24815,   700,  3824,  7271, 
-   26400,  9528,  6594, 26112, 
-     108,  2068, 12867, 16317, 
-   23035, 24632,  7528,  1752, 
+    3168, 31665,  9943,  9131,
+   24815,   700,  3824,  7271,
+   26400,  9528,  6594, 26112,
+     108,  2068, 12867, 16317,
+   23035, 24632,  7528,  1752,
     6759, 24576
 };
 
 static const Word16 dfh_M18k[PRMN_18k] =
 {
-     3168, 31665,  9943,  9135, 
-	14787, 14423, 30477, 24927, 
-	25345, 30154,   916,  5728, 
-	18978,  2048,   528, 16449, 
-	 2436,  3581, 23527, 29479, 
-	 8237, 16810, 27091, 19052, 
+     3168, 31665,  9943,  9135,
+	14787, 14423, 30477, 24927,
+	25345, 30154,   916,  5728,
+	18978,  2048,   528, 16449,
+	 2436,  3581, 23527, 29479,
+	 8237, 16810, 27091, 19052,
 	    0
 };
 
 static const Word16 dfh_M20k[PRMN_20k] =
 {
-     3168, 31665,  9943,  9129, 
-	 8637, 31807, 24646,   736, 
-	28643,  2977,  2566, 25564, 
-	12930, 13960,  2048,   834, 
-	 3270,  4100, 26920, 16237, 
-	31227, 17667, 15059, 20589, 
+     3168, 31665,  9943,  9129,
+	 8637, 31807, 24646,   736,
+	28643,  2977,  2566, 25564,
+	12930, 13960,  2048,   834,
+	 3270,  4100, 26920, 16237,
+	31227, 17667, 15059, 20589,
 	30249, 29123, 0
 };
 
 static const Word16 dfh_M23k[PRMN_23k] =
 {
-	 3168, 31665,  9943,  9132, 
-	16748,  3202, 28179, 16317, 
-	30590, 15857, 19960,  8818, 
-	21711, 21538,  4260, 16690, 
-	20224,  3666,  4194,  9497, 
-	16320, 15388,  5755, 31551, 
-	14080,  3574, 15932,    50, 
+	 3168, 31665,  9943,  9132,
+	16748,  3202, 28179, 16317,
+	30590, 15857, 19960,  8818,
+	21711, 21538,  4260, 16690,
+	20224,  3666,  4194,  9497,
+	16320, 15388,  5755, 31551,
+	14080,  3574, 15932,    50,
 	23392, 26053, 31216
 };
 
 static const Word16 dfh_M24k[PRMN_24k] =
 {
-	 3168, 31665,  9943,  9134, 
-	24776,  5857, 18475, 28535, 
-	29662, 14321, 16725,  4396, 
-	29353, 10003, 17068, 20504, 
-	  720,     0,  8465, 12581, 
-	28863, 24774,  9709, 26043, 
-	 7941, 27649, 13965, 15236, 
+	 3168, 31665,  9943,  9134,
+	24776,  5857, 18475, 28535,
+	29662, 14321, 16725,  4396,
+	29353, 10003, 17068, 20504,
+	  720,     0,  8465, 12581,
+	28863, 24774,  9709, 26043,
+	 7941, 27649, 13965, 15236,
 	18026, 22047, 16681,  3968
 };
 
diff --git a/media/libstagefright/codecs/amrwbenc/inc/isp_isf.tab b/media/libstagefright/codecs/amrwbenc/inc/isp_isf.tab
index 2322845..97c3b68 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/isp_isf.tab
+++ b/media/libstagefright/codecs/amrwbenc/inc/isp_isf.tab
@@ -42,7 +42,7 @@
 
 /* slope in Q11 used to compute y = acos(x) */
 
-const static Word16 slope[128] = { 
+const static Word16 slope[128] = {
  -26214, -9039, -5243, -3799, -2979, -2405, -2064, -1771,
  -1579, -1409, -1279, -1170, -1079, -1004, -933, -880,
  -827, -783, -743, -708, -676, -647, -621, -599,
diff --git a/media/libstagefright/codecs/amrwbenc/inc/log2.h b/media/libstagefright/codecs/amrwbenc/inc/log2.h
index 6a35019..b065eb4 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/log2.h
+++ b/media/libstagefright/codecs/amrwbenc/inc/log2.h
@@ -25,20 +25,20 @@
 */
 #ifndef __LOG2_H__
 #define __LOG2_H__
- 
+
 /*
 ********************************************************************************
 *                         INCLUDE FILES
 ********************************************************************************
 */
 #include "typedef.h"
- 
+
 /*
 ********************************************************************************
 *                         DEFINITION OF DATA TYPES
 ********************************************************************************
 */
- 
+
 /*
 ********************************************************************************
 *                         DECLARATION OF PROTOTYPES
diff --git a/media/libstagefright/codecs/amrwbenc/inc/mime_io.tab b/media/libstagefright/codecs/amrwbenc/inc/mime_io.tab
index 5f85dd0..7b485ea 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/mime_io.tab
+++ b/media/libstagefright/codecs/amrwbenc/inc/mime_io.tab
@@ -98,7 +98,7 @@
    244,  61, 111, 164, 214,  65, 115, 168, 218,  70,
    120, 173, 223,  74, 124, 177, 227,  79, 129, 182,
    232,  83, 133, 186, 236,  88, 138, 191, 241,  92,
-   142, 195, 245                         
+   142, 195, 245
 };
 
 static Word16 sort_1425[285] = {
@@ -205,7 +205,7 @@
    257, 243, 229, 356, 159, 119,  67, 187, 173, 145,
    240,  77, 304, 332, 314, 342, 109, 254,  81, 278,
    105,  91, 346, 318, 183, 250, 197, 328,  95, 155,
-   169, 268, 226, 236, 264                 
+   169, 268, 226, 236, 264
 };
 
 static Word16 sort_1985[397] = {
@@ -248,7 +248,7 @@
    128, 118, 303, 104, 379, 182, 114, 375, 200,  96,
    293, 172, 214, 365, 279,  86, 289, 351, 347, 357,
    261, 186, 176, 271,  90, 100, 147, 322, 275, 361,
-    71, 332,  61, 265, 157, 246, 236         
+    71, 332,  61, 265, 157, 246, 236
 };
 
 static Word16 sort_2305[461] = {
@@ -349,7 +349,7 @@
    132, 453, 336, 425, 325, 347, 126, 104, 137, 458,
    352, 243, 447, 115, 341, 210, 330, 221, 232, 436,
    465, 319, 359, 111, 454, 228, 217, 122, 443, 348,
-   239, 250, 133, 144, 432, 337, 326         
+   239, 250, 133, 144, 432, 337, 326
 };
 
 static Word16 sort_SID[35] = {
diff --git a/media/libstagefright/codecs/amrwbenc/inc/stream.h b/media/libstagefright/codecs/amrwbenc/inc/stream.h
index 3e5336a..4c1d0f0 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/stream.h
+++ b/media/libstagefright/codecs/amrwbenc/inc/stream.h
@@ -26,7 +26,7 @@
 #define __STREAM_H__
 
 #include "voMem.h"
-#define Frame_Maxsize  1024 * 2  //Work Buffer 10K 
+#define Frame_Maxsize  1024 * 2  //Work Buffer 10K
 #define Frame_MaxByte  640        //AMR_WB Encoder one frame 320 samples = 640 Bytes
 #define MIN(a,b)	 ((a) < (b)? (a) : (b))
 
@@ -35,7 +35,7 @@
 	unsigned char *frame_ptr;
 	unsigned char *frame_ptr_bk;
 	int  set_len;
-	int  framebuffer_len; 
+	int  framebuffer_len;
 	int  frame_storelen;
 	int  used_len;
 }FrameStream;
diff --git a/media/libstagefright/codecs/amrwbenc/inc/typedef.h b/media/libstagefright/codecs/amrwbenc/inc/typedef.h
index 533e68b..f08a678 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/typedef.h
+++ b/media/libstagefright/codecs/amrwbenc/inc/typedef.h
@@ -31,7 +31,7 @@
 /*
  * this is the original code from the ETSI file typedef.h
  */
-   
+
 #if defined(__BORLANDC__) || defined(__WATCOMC__) || defined(_MSC_VER) || defined(__ZTC__)
 typedef signed char Word8;
 typedef short Word16;
diff --git a/media/libstagefright/codecs/amrwbenc/inc/typedefs.h b/media/libstagefright/codecs/amrwbenc/inc/typedefs.h
index f30d255..0062584 100644
--- a/media/libstagefright/codecs/amrwbenc/inc/typedefs.h
+++ b/media/libstagefright/codecs/amrwbenc/inc/typedefs.h
@@ -45,7 +45,7 @@
 *        OSF           only defined if the current platform is an Alpha
 *        PC            only defined if the current platform is a PC
 *        SUN           only defined if the current platform is a Sun
-*        
+*
 *        LSBFIRST      is defined if the byte order on this platform is
 *                      "least significant byte first" -> defined on DEC Alpha
 *                      and PC, undefined on Sun
@@ -68,7 +68,7 @@
 
 /*
 ********************************************************************************
-*                         DEFINITION OF CONSTANTS 
+*                         DEFINITION OF CONSTANTS
 ********************************************************************************
 */
 /*
@@ -197,7 +197,7 @@
 #define     Syn_filt_32      voAWB_Syn_filt_32
 #define     Isf_isp          voAWB_Isf_isp
 #define     Levinson         voAWB_Levinson
-#define     median5          voAWB_median5           
+#define     median5          voAWB_median5
 #define     Pred_lt4         voAWB_Pred_lt4
 #define     Reorder_isf      voAWB_Reorder_isf
 #define     Dpisf_2s_36b     voAWB_Dpisf_2s_36b
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Deemph_32_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Deemph_32_opt.s
index c1c74e6..282db92 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Deemph_32_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Deemph_32_opt.s
@@ -30,10 +30,10 @@
 
            .section  .text
            .global   Deemph_32_asm
-	   
+
 Deemph_32_asm:
 
-           STMFD   	r13!, {r4 - r12, r14} 
+           STMFD   	r13!, {r4 - r12, r14}
 	   MOV          r4, #2                   @i=0
 	   LDRSH        r6, [r0], #2             @load x_hi[0]
 	   LDRSH        r7, [r1], #2             @load x_lo[0]
@@ -47,9 +47,9 @@
 	   ADD          r12, r10, r7, LSL #4     @L_tmp += x_lo[0] << 4
 	   MOV          r10, r12, LSL #3         @L_tmp <<= 3
 	   MUL          r9, r5, r8
-	   LDRSH        r6, [r0], #2             @load x_hi[1] 
+	   LDRSH        r6, [r0], #2             @load x_hi[1]
 	   QDADD        r10, r10, r9
-	   LDRSH        r7, [r1], #2             @load x_lo[1]  
+	   LDRSH        r7, [r1], #2             @load x_lo[1]
 	   MOV          r12, r10, LSL #1         @L_tmp = L_mac(L_tmp, *mem, fac)
 	   QADD         r10, r12, r11
 	   MOV          r14, r10, ASR #16        @y[0] = round(L_tmp)
@@ -94,9 +94,9 @@
 
            BLT          LOOP
            STR          r14, [r3]
-           STRH         r14, [r2]	   
+           STRH         r14, [r2]
 
-           LDMFD   	r13!, {r4 - r12, r15} 
+           LDMFD   	r13!, {r4 - r12, r15}
 
 	   @ENDP
 	   .END
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Dot_p_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Dot_p_opt.s
index 02bdcab..4aa317e 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Dot_p_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Dot_p_opt.s
@@ -31,7 +31,7 @@
 
 Dot_product12_asm:
 
-          STMFD   	    r13!, {r4 - r12, r14} 
+          STMFD   	    r13!, {r4 - r12, r14}
           MOV               r4, #0                                 @ L_sum = 0
           MOV               r5, #0                                 @ i = 0
 
@@ -41,13 +41,13 @@
           LDR           r8, [r0], #4
           SMLABB        r4, r6, r7, r4
           LDR           r9, [r1], #4
-	  SMLATT        r4, r6, r7, r4 
+	  SMLATT        r4, r6, r7, r4
 
 	  LDR           r6, [r0], #4
 	  SMLABB        r4, r8, r9, r4
 
 	  LDR           r7, [r1], #4
-	  SMLATT        r4, r8, r9, r4	  
+	  SMLATT        r4, r8, r9, r4
 	  LDR           r8, [r0], #4
 
 	  SMLABB        r4, r6, r7, r4
@@ -58,7 +58,7 @@
 	  CMP           r5, r2
 	  SMLATT        r4, r8, r9, r4
 	  BLT           LOOP
-              
+
           MOV           r12, r4, LSL #1
           ADD           r12, r12, #1                         @ L_sum = (L_sum << 1)  + 1
 	  MOV           r4, r12
@@ -69,12 +69,12 @@
           SUB           r10, r10, #1                         @ sft = norm_l(L_sum)
           MOV           r0, r12, LSL r10                     @ L_sum = L_sum << sft
           RSB           r11, r10, #30                        @ *exp = 30 - sft
-          STRH          r11, [r3]                     
+          STRH          r11, [r3]
 
 Dot_product12_end:
-		     
-          LDMFD   	    r13!, {r4 - r12, r15} 
+
+          LDMFD   	    r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Filt_6k_7k_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Filt_6k_7k_opt.s
index 1ce2a85..856ada8 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Filt_6k_7k_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Filt_6k_7k_opt.s
@@ -23,7 +23,7 @@
 @******************************************************************
 @ r0    ---  signal[]
 @ r1    ---  lg
-@ r2    ---  mem[] 
+@ r2    ---  mem[]
 
           .section  .text
           .global  Filt_6k_7k_asm
@@ -32,7 +32,7 @@
 
 Filt_6k_7k_asm:
 
-          STMFD   		r13!, {r4 - r12, r14} 
+          STMFD   		r13!, {r4 - r12, r14}
           SUB    		r13, r13, #240              @ x[L_SUBFR16k + (L_FIR - 1)]
           MOV     		r8, r0                      @ copy signal[] address
           MOV     		r4, r1                      @ copy lg address
@@ -43,9 +43,9 @@
           MOV     		r2, #30                     @ L_FIR - 1
           BL      		voAWB_Copy                   @ memcpy(x, mem, (L_FIR - 1)<<1)
 
-          LDR     		r10, Lable1                 @ get fir_7k address     
+          LDR     		r10, Lable1                 @ get fir_7k address
 
-          MOV           	r14, #0  
+          MOV           	r14, #0
           MOV                   r3, r8                      @ change myMemCopy to Copy, due to Copy will change r3 content
           ADD     	    	r6, r13, #60                @ get x[L_FIR - 1] address
           MOV           	r7, r3                      @ get signal[i]
@@ -76,14 +76,14 @@
           STRH          	r12, [r6], #2
           ADD           	r14, r14, #8
           CMP           	r14, #80
-          BLT           	LOOP1          
+          BLT           	LOOP1
 
 
           STR     		r5, [sp, #-4]               @ PUSH  r5 to stack
 
           @ not use registers: r4, r10, r12, r14, r5
-          MOV     		r4, r13 
-          MOV     		r5, #0                      @ i = 0              
+          MOV     		r4, r13
+          MOV     		r5, #0                      @ i = 0
 LOOP2:
           LDR           	r0, [r10]
 
@@ -111,13 +111,13 @@
           LDRSH                 r8, [r4, #10]              @ load x[i+5]
           LDRSH                 r9, [r4, #50]              @ load x[i+25]
           SMLABT                r14, r1, r0, r14           @ (x[i+3] + x[i+27]) * fir_7k[3]
-          ADD                   r8, r8, r9                 @ x[i+5] + x[i+25] 
- 
+          ADD                   r8, r8, r9                 @ x[i+5] + x[i+25]
+
           LDR                   r0, [r10, #8]
           LDRSH                 r1, [r4, #12]              @ x[i+6]
           LDRSH                 r2, [r4, #48]              @ x[i+24]
           SMLABB                r14, r6, r0, r14           @ (x[i+4] + x[i+26]) * fir_7k[4]
-          LDRSH                 r6, [r4, #14]              @ x[i+7] 
+          LDRSH                 r6, [r4, #14]              @ x[i+7]
           LDRSH                 r7, [r4, #46]              @ x[i+23]
           SMLABT                r14, r8, r0, r14           @ (x[i+5] + x[i+25]) * fir_7k[5]
           LDR                   r0, [r10, #12]
@@ -125,8 +125,8 @@
           ADD                   r6, r6, r7                 @ (x[i+7] + x[i+23])
           SMLABB                r14, r1, r0, r14           @ (x[i+6] + x[i+24]) * fir_7k[6]
           LDRSH                 r8, [r4, #16]              @ x[i+8]
-          LDRSH                 r9, [r4, #44]              @ x[i+22] 
-          SMLABT                r14, r6, r0, r14           @ (x[i+7] + x[i+23]) * fir_7k[7]  
+          LDRSH                 r9, [r4, #44]              @ x[i+22]
+          SMLABT                r14, r6, r0, r14           @ (x[i+7] + x[i+23]) * fir_7k[7]
           LDR                   r0, [r10, #16]
           LDRSH                 r1, [r4, #18]              @ x[i+9]
           LDRSH                 r2, [r4, #42]              @ x[i+21]
@@ -144,7 +144,7 @@
           LDRSH                 r2, [r4, #36]              @ x[i+18]
           SMLABB                r14, r6, r0, r14           @ (x[i+10] + x[i+20]) * fir_7k[10]
           LDRSH                 r6, [r4, #26]              @ x[i+13]
-          ADD                   r8, r8, r9                 @ (x[i+11] + x[i+19])  
+          ADD                   r8, r8, r9                 @ (x[i+11] + x[i+19])
           LDRSH                 r7, [r4, #34]              @ x[i+17]
           SMLABT                r14, r8, r0, r14           @ (x[i+11] + x[i+19]) * fir_7k[11]
           LDR                   r0, [r10, #24]
@@ -152,31 +152,31 @@
           LDRSH                 r8, [r4, #28]              @ x[i+14]
           SMLABB                r14, r1, r0, r14           @ (x[i+12] + x[i+18]) * fir_7k[12]
           ADD                   r6, r6, r7                 @ (x[i+13] + x[i+17])
-          LDRSH                 r9, [r4, #32]              @ x[i+16] 
+          LDRSH                 r9, [r4, #32]              @ x[i+16]
           SMLABT                r14, r6, r0, r14           @ (x[i+13] + x[i+17]) * fir_7k[13]
-          LDR                   r0, [r10, #28]         
+          LDR                   r0, [r10, #28]
           ADD                   r8, r8, r9                 @ (x[i+14] + x[i+16])
           LDRSH                 r1, [r4, #30]              @ x[i+15]
           SMLABB                r14, r8, r0, r14           @ (x[i+14] + x[i+16]) * fir_7k[14]
-          SMLABT                r14, r1, r0, r14           @ x[i+15] * fir_7k[15]                              
+          SMLABT                r14, r1, r0, r14           @ x[i+15] * fir_7k[15]
 
           ADD     		r5, r5, #1
           ADD     		r14, r14, #0x4000
-          ADD     		r4, r4, #2                
+          ADD     		r4, r4, #2
           MOV     		r1, r14, ASR #15
           CMP     		r5, #80
           STRH    		r1, [r3], #2               @signal[i] = (L_tmp + 0x4000) >> 15
-          BLT     		LOOP2      
-           
+          BLT     		LOOP2
+
           LDR     		r1, [sp, #-4]               @mem address
           ADD     		r0, r13, #160               @x + lg
           MOV     		r2, #30
           BL      		voAWB_Copy
-                    
+
 Filt_6k_7k_end:
-          ADD     		r13, r13, #240  
-          LDMFD   		r13!, {r4 - r12, r15} 
- 
+          ADD     		r13, r13, #240
+          LDMFD   		r13!, {r4 - r12, r15}
+
 Lable1:
           .word   		fir_6k_7k
           @ENDFUNC
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Norm_Corr_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Norm_Corr_opt.s
index b440a31..49bdc2b 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Norm_Corr_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Norm_Corr_opt.s
@@ -32,8 +32,8 @@
 @ r6 --- corr_norm[]
 
 
-	.section  .text 
-        .global   Norm_corr_asm 
+	.section  .text
+        .global   Norm_corr_asm
         .extern   Convolve_asm
         .extern   Isqrt_n
 @******************************
@@ -47,17 +47,17 @@
 .equ         T_MIN         ,   212
 .equ         T_MAX         ,   216
 .equ         CORR_NORM     ,   220
-                  
+
 Norm_corr_asm:
 
-        STMFD      r13!, {r4 - r12, r14}  
+        STMFD      r13!, {r4 - r12, r14}
         SUB        r13, r13, #voSTACK
-  
+
         ADD        r8, r13, #20                 @get the excf[L_SUBFR]
         LDR        r4, [r13, #T_MIN]            @get t_min
         RSB        r11, r4, #0                  @k = -t_min
-        ADD        r5, r0, r11, LSL #1          @get the &exc[k]   
-        
+        ADD        r5, r0, r11, LSL #1          @get the &exc[k]
+
         @transfer Convolve function
         STMFD       sp!, {r0 - r3}
         MOV         r0, r5
@@ -68,7 +68,7 @@
 
         @ r8 --- excf[]
 
-	MOV         r14, r1                       @copy xn[] address                      
+	MOV         r14, r1                       @copy xn[] address
         MOV         r5, #64
         MOV         r6, #0                       @L_tmp = 0
         MOV         r7, #1
@@ -93,21 +93,21 @@
 	CLZ         r7, r9
 	SUB         r6, r7, #1                   @exp = norm_l(L_tmp)
         RSB         r7, r6, #32                  @exp = 32 - exp
-	MOV         r6, r7, ASR #1         
+	MOV         r6, r7, ASR #1
 	RSB         r7, r6, #0                   @scale = -(exp >> 1)
-	
+
         @loop for every possible period
 	@for(t = t_min@ t <= t_max@ t++)
 	@r7 --- scale r4 --- t_min r8 --- excf[]
 
-LOOPFOR:	
+LOOPFOR:
         MOV         r5, #0                       @L_tmp  = 0
 	MOV         r6, #0                       @L_tmp1 = 0
-	MOV         r9, #64  
+	MOV         r9, #64
 	MOV         r12, r1                      @copy of xn[]
 	ADD         r14, r13, #20                @copy of excf[]
 	MOV         r8, #0x8000
-        	
+
 LOOPi:
 	LDR         r11, [r14], #4               @load excf[i], excf[i+1]
         LDR         r10, [r12], #4               @load xn[i], xn[i+1]
@@ -128,13 +128,13 @@
 	MOV         r10, #1
 	ADD         r5, r10, r5, LSL #1          @L_tmp = (L_tmp << 1) + 1
 	ADD         r6, r10, r6, LSL #1          @L_tmp1 = (L_tmp1 << 1) + 1
- 
-	CLZ         r10, r5        
+
+	CLZ         r10, r5
 	CMP         r5, #0
 	RSBLT       r11, r5, #0
 	CLZLT       r10, r11
 	SUB         r10, r10, #1                 @exp = norm_l(L_tmp)
-     
+
 	MOV         r5, r5, LSL r10              @L_tmp = (L_tmp << exp)
 	RSB         r10, r10, #30                @exp_corr = 30 - exp
 	MOV         r11, r5, ASR #16             @corr = extract_h(L_tmp)
@@ -150,7 +150,7 @@
 	@Isqrt_n(&L_tmp, &exp_norm)
 
 	MOV         r14, r0
-	MOV         r12, r1 
+	MOV         r12, r1
 
         STMFD       sp!, {r0 - r4, r7 - r12, r14}
 	ADD         r1, sp, #4
@@ -168,7 +168,7 @@
 	MOV         r6, r6, ASR #16              @norm = extract_h(L_tmp)
 	MUL         r12, r6, r11
 	ADD         r12, r12, r12                @L_tmp = vo_L_mult(corr, norm)
-  
+
 	ADD         r6, r10, r5
 	ADD         r6, r6, r7                   @exp_corr + exp_norm + scale
 
@@ -187,9 +187,9 @@
 
 	CMP         r4, r6
 	BEQ         Norm_corr_asm_end
- 
+
 	ADD         r4, r4, #1                   @ t_min ++
-        
+
 	RSB         r5, r4, #0                   @ k
 
 	MOV         r6, #63                      @ i = 63
@@ -216,16 +216,16 @@
 	MUL         r14, r11, r8
         LDR         r6, [r13, #T_MAX]            @ get t_max
 	MOV         r8, r14, ASR #15
-	STRH        r8, [r10]                    
+	STRH        r8, [r10]
 
 	CMP         r4, r6
 	BLE         LOOPFOR
 
-Norm_corr_asm_end: 
-        
-        ADD            r13, r13, #voSTACK      
+Norm_corr_asm_end:
+
+        ADD            r13, r13, #voSTACK
         LDMFD          r13!, {r4 - r12, r15}
-    
+
         .END
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Syn_filt_32_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Syn_filt_32_opt.s
index 70464e4..3f4930c 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Syn_filt_32_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/Syn_filt_32_opt.s
@@ -38,7 +38,7 @@
 
 Syn_filt_32_asm:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           LDR           r4,  [r13, #40]                  @ get sig_hi[] address
           LDR           r5,  [r13, #44]                  @ get sig_lo[] address
 
@@ -55,7 +55,7 @@
           AND           r8, r8, r14
           ORR           r10, r6, r7, LSL #16             @ Aq[2] -- Aq[1]
           ORR           r11, r8, r9, LSL #16             @ Aq[4] -- Aq[3]
-          STR           r10, [r13, #-4]                  
+          STR           r10, [r13, #-4]
           STR           r11, [r13, #-8]
 
           LDRSH         r6, [r0, #10]                    @ load Aq[5]
@@ -73,12 +73,12 @@
           LDRSH         r7, [r0, #20]                    @ load Aq[10]
           LDRSH         r8, [r0, #22]                    @ load Aq[11]
           LDRSH         r9, [r0, #24]                    @ load Aq[12]
-          AND           r6, r6, r14 
+          AND           r6, r6, r14
           AND           r8, r8, r14
           ORR           r10, r6, r7, LSL #16             @ Aq[10] -- Aq[9]
           ORR           r11, r8, r9, LSL #16             @ Aq[12] -- Aq[11]
           STR           r10, [r13, #-20]
-          STR           r11, [r13, #-24]  
+          STR           r11, [r13, #-24]
 
           LDRSH         r6, [r0, #26]                    @ load Aq[13]
           LDRSH         r7, [r0, #28]                    @ load Aq[14]
@@ -90,14 +90,14 @@
           ORR           r11, r8, r9, LSL #16             @ Aq[16] -- Aq[15]
           STR           r10, [r13, #-28]
           STR           r11, [r13, #-32]
-          
+
           MOV           r8, #0                           @ i = 0
-              
-LOOP:            
+
+LOOP:
           LDRSH         r6, [r5, #-2]                    @ load sig_lo[i-1]
           LDRSH         r7, [r5, #-4]                    @ load sig_lo[i-2]
 
-          LDR           r11, [r13, #-4]                  @ Aq[2] -- Aq[1]        
+          LDR           r11, [r13, #-4]                  @ Aq[2] -- Aq[1]
           LDRSH         r9, [r5, #-6]                    @ load sig_lo[i-3]
           LDRSH         r10, [r5, #-8]                   @ load sig_lo[i-4]
 
@@ -135,12 +135,12 @@
           LDRSH         r10, [r5, #-32]                  @ load sig_lo[i-16]
           SMLABB        r12, r6, r11, r12                @ sig_lo[i-13] * Aq[13]
           SMLABT        r12, r7, r11, r12                @ sig_lo[i-14] * Aq[14]
- 
+
           LDR           r11, [r13, #-32]                 @ Aq[16] -- Aq[15]
-          LDRSH         r6, [r2],#2                      @ load exc[i] 
+          LDRSH         r6, [r2],#2                      @ load exc[i]
           SMLABB        r12, r9, r11, r12                @ sig_lo[i-15] * Aq[15]
           SMLABT        r12, r10, r11, r12               @ sig_lo[i-16] * Aq[16]
-          MUL           r7, r6, r3                       @ exc[i] * a0 
+          MUL           r7, r6, r3                       @ exc[i] * a0
           RSB           r14, r12, #0                     @ L_tmp
           MOV           r14, r14, ASR #11                @ L_tmp >>= 11
           ADD           r14, r14, r7, LSL #1             @ L_tmp += (exc[i] * a0) << 1
@@ -149,7 +149,7 @@
           LDRSH         r6, [r4, #-2]                    @ load sig_hi[i-1]
           LDRSH         r7, [r4, #-4]                    @ load sig_hi[i-2]
 
-          LDR           r11, [r13, #-4]                  @ Aq[2] -- Aq[1]        
+          LDR           r11, [r13, #-4]                  @ Aq[2] -- Aq[1]
           LDRSH         r9, [r4, #-6]                    @ load sig_hi[i-3]
           LDRSH         r10, [r4, #-8]                   @ load sig_hi[i-4]
           SMULBB        r12, r6, r11                     @ sig_hi[i-1] * Aq[1]
@@ -198,14 +198,14 @@
           LDRSH         r10, [r4, #-32]                  @ load sig_hi[i-16]
           SMLABB        r12, r6, r11, r12                @ sig_hi[i-13] * Aq[13]
           SMLABT        r12, r7, r11, r12                @ sig_hi[i-14] * Aq[14]
- 
+
           LDR           r11, [r13, #-32]                 @ Aq[16] -- Aq[15]
           SMLABB        r12, r9, r11, r12                @ sig_hi[i-15] * Aq[15]
-          SMLABT        r12, r10, r11, r12               @ sig_hi[i-16] * Aq[16]       
+          SMLABT        r12, r10, r11, r12               @ sig_hi[i-16] * Aq[16]
           ADD           r6, r12, r12                     @ r12 << 1
-          SUB           r14, r14, r6                     
+          SUB           r14, r14, r6
           MOV           r14, r14, LSL #3                 @ L_tmp <<=3
-  
+
           MOV           r7, r14, ASR #16                 @ L_tmp >> 16
 
           MOV           r14, r14, ASR #4                 @ L_tmp >>=4
@@ -213,14 +213,14 @@
           SUB           r9, r14, r7, LSL #12             @ sig_lo[i] = L_tmp - (sig_hi[i] << 12)
 
           ADD           r8, r8, #1
-          STRH          r9, [r5], #2   
+          STRH          r9, [r5], #2
           CMP           r8, #64
-          BLT           LOOP                            
-         
+          BLT           LOOP
+
 Syn_filt_32_end:
-		     
-          LDMFD   	    r13!, {r4 - r12, r15} 
+
+          LDMFD   	    r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/convolve_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/convolve_opt.s
index 0228bda..71bb532 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/convolve_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/convolve_opt.s
@@ -27,24 +27,24 @@
 @  r3 --- L
 
 	.section  .text
-        .global   Convolve_asm 
+        .global   Convolve_asm
 
 Convolve_asm:
 
-        STMFD          r13!, {r4 - r12, r14}  
+        STMFD          r13!, {r4 - r12, r14}
         MOV            r3,  #0                           @ n
 	MOV            r11, #0x8000
-        
-LOOP: 
+
+LOOP:
         ADD            r4, r1, r3, LSL #1                @ tmpH address
         ADD            r5, r3, #1                        @ i = n + 1
         MOV            r6, r0                            @ tmpX = x
         LDRSH          r9,  [r6], #2                     @ *tmpX++
         LDRSH          r10, [r4], #-2                    @ *tmpH--
         SUB            r5, r5, #1
-        MUL            r8,  r9, r10 
+        MUL            r8,  r9, r10
 
-LOOP1:                    
+LOOP1:
         CMP            r5, #0
         BLE            L1
 	LDRSH          r9,  [r6], #2                     @ *tmpX++
@@ -58,12 +58,12 @@
 	LDRSH          r12, [r6], #2                     @ *tmpX++
 	LDRSH          r14, [r4], #-2                    @ *tmpH--
 	MLA            r8, r9, r10, r8
-        SUBS           r5, r5, #4 
+        SUBS           r5, r5, #4
 	MLA            r8, r12, r14, r8
-    
-        B              LOOP1  
 
-L1:                  
+        B              LOOP1
+
+L1:
 
         ADD            r5, r11, r8, LSL #1
         MOV            r5, r5, LSR #16                   @extract_h(s)
@@ -75,14 +75,14 @@
         ADD            r5, r3, #1
         MOV            r6, r0
         LDRSH          r9,  [r6], #2                     @ *tmpX++
-        LDRSH          r10, [r4], #-2                     
+        LDRSH          r10, [r4], #-2
         LDRSH          r12, [r6], #2
         LDRSH          r14, [r4], #-2
 
         MUL            r8, r9, r10
         SUB            r5, r5, #2
         MLA            r8, r12, r14, r8
-        
+
 LOOP2:
         CMP            r5, #0
         BLE            L2
@@ -97,14 +97,14 @@
 	LDRSH          r12, [r6], #2                     @ *tmpX++
 	LDRSH          r14, [r4], #-2                    @ *tmpH--
 	MLA            r8, r9, r10, r8
-        SUBS           r5, r5, #4 
+        SUBS           r5, r5, #4
 	MLA            r8, r12, r14, r8
         B              LOOP2
 
 L2:
         ADD            r8, r11, r8, LSL #1
         MOV            r8, r8, LSR #16                   @extract_h(s)
-        ADD            r3, r3, #1  
+        ADD            r3, r3, #1
         STRH           r8, [r2], #2                      @y[n]
 
         ADD            r4, r1, r3, LSL #1
@@ -117,7 +117,7 @@
         MUL            r8, r9, r10
         LDRSH          r9,  [r6], #2
         LDRSH          r10, [r4], #-2
-        MLA            r8, r12, r14, r8 
+        MLA            r8, r12, r14, r8
         SUB            r5, r5, #3
         MLA            r8, r9, r10, r8
 
@@ -135,9 +135,9 @@
 	LDRSH          r12, [r6], #2                     @ *tmpX++
 	LDRSH          r14, [r4], #-2                    @ *tmpH--
 	MLA            r8, r9, r10, r8
-        SUBS           r5, r5, #4 
-	MLA            r8, r12, r14, r8 
-        B              LOOP3   
+        SUBS           r5, r5, #4
+	MLA            r8, r12, r14, r8
+        B              LOOP3
 
 L3:
         ADD            r8, r11, r8, LSL #1
@@ -150,7 +150,7 @@
         MOV            r6, r0
         MOV            r8, #0
 
-LOOP4:                    
+LOOP4:
         CMP            r5, #0
         BLE            L4
 	LDRSH          r9,  [r6], #2                     @ *tmpX++
@@ -164,22 +164,22 @@
 	LDRSH          r12, [r6], #2                     @ *tmpX++
 	LDRSH          r14, [r4], #-2                    @ *tmpH--
 	MLA            r8, r9, r10, r8
-        SUBS           r5, r5, #4 
-	MLA            r8, r12, r14, r8        
-        B              LOOP4    
-L4:                  
+        SUBS           r5, r5, #4
+	MLA            r8, r12, r14, r8
+        B              LOOP4
+L4:
         ADD            r5, r11, r8, LSL #1
         MOV            r5, r5, LSR #16                   @extract_h(s)
         ADD            r3, r3, #1
         STRH           r5, [r2], #2                      @y[n]
-        
+
         CMP            r3, #64
         BLT            LOOP
-                
-Convolve_asm_end: 
- 
+
+Convolve_asm_end:
+
         LDMFD      r13!, {r4 - r12, r15}
-    
+
         @ENDFUNC
         .END
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/cor_h_vec_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/cor_h_vec_opt.s
index 8f32733..2d4c7cc 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/cor_h_vec_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/cor_h_vec_opt.s
@@ -51,12 +51,12 @@
          RSB           r11, r2, #62                      @j=62-pos
 
 LOOPj1:
-	 LDRSH         r12, [r10], #2  
+	 LDRSH         r12, [r10], #2
 	 LDRSH         r8,  [r9], #2
 	 LDRSH         r14, [r9]
 	 SUBS          r11, r11, #1
          MLA           r5, r12, r8, r5
-         MLA           r6, r12, r14, r6	 
+         MLA           r6, r12, r14, r6
 	 BGE           LOOPj1
 
 	 LDRSH         r12, [r10], #2                     @*p1++
@@ -64,7 +64,7 @@
          MLA           r5, r12, r14, r5
          MOV           r14, #0x8000
          MOV           r5, r5, LSL #2                     @L_sum1 = (L_sum1 << 2)
-         ADD           r10, r6, r14         
+         ADD           r10, r6, r14
          ADD           r9, r5, r14
          MOV           r5, r9, ASR #16
          MOV           r6, r10, ASR #16
@@ -76,7 +76,7 @@
 	 MUL           r14, r6, r11
 	 MOV           r5, r12, ASR #15
 	 MOV           r6, r14, ASR #15
-	 LDR           r9,  [r13, #44]                   
+	 LDR           r9,  [r13, #44]
 	 LDR           r12, [r13, #48]
          LDRSH         r10, [r7], #2                      @*p0++
 	 LDRSH         r11, [r8]                          @*p3++
@@ -88,7 +88,7 @@
 	 STRH          r6, [r12]
 
          ADD           r2, r2, #4
- 
+
          MOV           r5, #0                            @L_sum1 = 0
 	 MOV           r6, #0                            @L_sum2 = 0
 	 ADD           r9, r1, r2, LSL #1                @p2 = &vec[pos]
@@ -97,12 +97,12 @@
 	 ADD           r4, r4, #1                        @i++
 
 LOOPj2:
-	 LDRSH         r12, [r10], #2  
+	 LDRSH         r12, [r10], #2
 	 LDRSH         r8,  [r9], #2
 	 LDRSH         r14, [r9]
 	 SUBS          r11, r11, #1
          MLA           r5, r12, r8, r5
-         MLA           r6, r12, r14, r6	 
+         MLA           r6, r12, r14, r6
 	 BGE           LOOPj2
 
 	 LDRSH         r12, [r10], #2                     @*p1++
@@ -110,7 +110,7 @@
          MLA           r5, r12, r14, r5
          MOV           r14, #0x8000
          MOV           r5, r5, LSL #2                     @L_sum1 = (L_sum1 << 2)
-         ADD           r10, r6, r14        
+         ADD           r10, r6, r14
          ADD           r9, r5, r14
 
          MOV           r5, r9, ASR #16
@@ -123,7 +123,7 @@
 	 MUL           r14, r6, r11
 	 MOV           r5, r12, ASR #15
 	 MOV           r6, r14, ASR #15
-	 LDR           r9,  [r13, #44]                   
+	 LDR           r9,  [r13, #44]
 	 LDR           r12, [r13, #48]
          LDRSH         r10, [r7], #2                      @*p0++
 	 LDRSH         r11, [r8]                          @*p3++
@@ -136,16 +136,16 @@
 	 ADD           r4, r4, #1                         @i+1
 	 ADD           r2, r2, #4                         @pos += STEP
 	 CMP           r4, #16
-	 
+
 	 BLT           LOOPi
-         
+
 the_end:
          LDMFD         r13!, {r4 - r12, r15}
-      
+
          @ENDFUNC
-         .END	 
-        
-	
-	  
+         .END
+
+
+
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/pred_lt4_1_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/pred_lt4_1_opt.s
index d7b4509..e0b338d 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/pred_lt4_1_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/pred_lt4_1_opt.s
@@ -35,7 +35,7 @@
 
 pred_lt4_asm:
 
-         STMFD     r13!, {r4 - r12, r14} 
+         STMFD     r13!, {r4 - r12, r14}
          RSB       r4, r1, #0                         @-T0
          RSB       r2, r2, #0                         @frac = -frac
          ADD       r5, r0, r4, LSL #1                 @x = exc - T0
@@ -45,7 +45,7 @@
          SUB       r5, r5, #30                        @x -= 15
          RSB       r4, r2, #3                         @k = 3 - frac
          LDR       r6, Table
-	 MOV       r8, r4, LSL #6                    
+	 MOV       r8, r4, LSL #6
          @MOV       r7, #0                             @j = 0
          ADD       r8, r6, r8                         @ptr2 = &(inter4_2[k][0])
 
@@ -63,7 +63,7 @@
 	 LDRSH     r6, [r1], #2                       @x[1]
 	 LDRSH     r9, [r1], #2                       @x[2]
 
-	 SMULBB    r10, r4, r3                        @x[0] * h[0]                  
+	 SMULBB    r10, r4, r3                        @x[0] * h[0]
 	 SMULBB    r11, r6, r3                        @x[1] * h[0]
 	 SMULBB    r12, r9, r3                        @x[2] * h[0]
 
@@ -285,7 +285,7 @@
 
 	 SMLABB    r10, r9, r3, r10                   @x[2] * h[2]
          SMLABB    r11, r4, r3, r11                   @x[3] * h[2]
-      
+
 	 SMLABT    r10, r4, r3, r10                   @x[3] * h[3]
 	 SMLABT    r11, r6, r3, r11                   @x[4] * h[3]
 
@@ -435,7 +435,7 @@
 	 MOV       r11, r11, LSL #1
 
 	 QADD      r10, r10, r10
-	 QADD      r11, r11, r11 
+	 QADD      r11, r11, r11
 
 	 QADD      r10, r10, r5
 	 QADD      r11, r11, r5
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/residu_asm_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/residu_asm_opt.s
index 86b3bd6..5ff0964 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/residu_asm_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/residu_asm_opt.s
@@ -34,12 +34,12 @@
 
         LDRH    r5, [r0], #2
         LDRH    r6, [r0], #2
-        ORR     r5, r6, r5, LSL #16                  @r5 --- a0, a1	
+        ORR     r5, r6, r5, LSL #16                  @r5 --- a0, a1
 
         LDRH    r6, [r0], #2
 	LDRH    r7, [r0], #2
 	ORR     r6, r7, r6, LSL #16                  @r6 --- a2, a3
-	
+
         LDRH    r7, [r0], #2
 	LDRH    r8, [r0], #2
 	ORR     r7, r8, r7, LSL #16                  @r7 --- a4, a5
@@ -59,13 +59,13 @@
         LDRH    r11, [r0], #2
 	LDRH    r12, [r0], #2
 	ORR     r11, r12, r11, LSL #16               @r11 --- a12, a13
-	
+
 	LDRH    r12, [r0], #2
 	LDRH    r4, [r0], #2
 	ORR     r12, r4, r12, LSL #16                @r12 --- a14, a15
-	
 
-	STMFD   r13!, {r8 - r12}                     @store r8-r12 
+
+	STMFD   r13!, {r8 - r12}                     @store r8-r12
 	LDRH    r4, [r0], #2                         @load a16
         MOV     r14, r3, ASR #2                      @one loop get 4 outputs
 	ADD     r1, r1, #4
@@ -78,7 +78,7 @@
 	LDR     r2,  [r1], #-4                       @r2   --- x[1], x[0]
 
 	SMULTB  r3, r5, r2                           @i1(0)  --- r3 = x[0] * a0
-        SMULTT  r4, r5, r2                           @i2(0)  --- r4 = x[1] * a0	
+        SMULTT  r4, r5, r2                           @i2(0)  --- r4 = x[1] * a0
 	SMULTB  r11, r5, r10                         @i3(0)  --- r11 = x[2] * a0
 	SMULTT  r12, r5, r10                         @i4(0)  --- r12 = x[3] * a0
 
@@ -88,20 +88,20 @@
 
 	SMLATB  r11, r6, r2, r11                     @i3(2)  --- r11 += x[0] * a2
 	SMLATT  r12, r6, r2, r12                     @i4(2)  --- r12 += x[1] * a2
-	SMLABB  r12, r6, r2, r12                     @i4(3)  --- r12 += x[0] * a3                 
-	
+	SMLABB  r12, r6, r2, r12                     @i4(3)  --- r12 += x[0] * a3
+
 	LDR     r2, [r1], #-4                        @r2 ---- x[-1], x[-2]
 
 	SMLABT  r3, r5, r2, r3                       @i1(1) --- r3 += x[-1] * a1
 	SMLATT  r4, r6, r2, r4                       @i2(2) --- r4 += x[-1] * a2
 	SMLABT  r11, r6, r2, r11                     @i3(3) --- r11 += x[-1] * a3
 	SMLATT  r12, r7, r2, r12                     @i4(4) --- r12 += x[-1] * a4
-        SMLATB  r3, r6, r2, r3                       @i1(2) --- r3 += x[-2] * a2	
+        SMLATB  r3, r6, r2, r3                       @i1(2) --- r3 += x[-2] * a2
 
 	SMLABB	r4, r6, r2, r4				@ i2	(3)
 	SMLATB  r11,r7, r2, r11				@ i3	(4)
 	SMLABB	r12,r7, r2, r12				@ i4	(5)
-	
+
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r6, r2, r3				@ i1	(3)
 	SMLATT	r4, r7, r2, r4				@ i2	(4)
@@ -111,7 +111,7 @@
 	SMLABB	r4, r7, r2, r4				@ i2	(5)
 	SMLATB	r11,r8, r2, r11				@ i3	(6)
 	SMLABB	r12,r8, r2, r12				@ i4	(7)
-		
+
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r7, r2, r3				@ i1	(5)
 	SMLATT	r4, r8, r2, r4				@ i2	(6)
@@ -122,7 +122,7 @@
 	SMLATB	r11,r9, r2, r11				@ i3	(8)
 	SMLABB	r12,r9, r2, r12				@ i4	(9)
 	LDR	r10, [r13, #8]				@ [ a10 | a11]
-	
+
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r8, r2, r3				@ i1	(7)
 	SMLATT	r4, r9, r2, r4				@ i2	(8)
@@ -133,7 +133,7 @@
 	SMLATB	r11,r10, r2, r11			@ i3	(10)
 	SMLABB	r12,r10, r2, r12			@ i4	(11)
 	LDR	r8, [r13, #12]				@ [ a12 | a13 ]
-		
+
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r9, r2, r3				@ i1	(9)
 	SMLATT	r4, r10, r2, r4				@ i2	(10)
@@ -144,7 +144,7 @@
 	SMLATB	r11,r8, r2, r11				@ i3	(12)
 	SMLABB	r12,r8, r2, r12				@ i4	(13)
 	LDR	r9, [r13, #16]				@ [ a14 | a15 ]
-	
+
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r10, r2, r3				@ i1	(11)
 	SMLATT	r4, r8, r2, r4				@ i2	(12)
@@ -154,7 +154,7 @@
 	SMLABB	r4, r8, r2, r4				@ i2	(13)
 	SMLATB	r11,r9, r2, r11				@ i3	(14)
 	SMLABB	r12,r9, r2, r12				@ i4	(15)
-	
+
 
 	LDR	r2,[r1],#-4
 	SMLABT	r3, r8, r2, r3				@ i1	(13)
@@ -165,64 +165,64 @@
 	SMLABB	r4, r9, r2, r4				@ i2	(15)
 	SMLABB	r11,r14, r2, r11			@ i3	(16)
 	LDR		r8, [r13]					@ [ a6 | a7 ]
-			
+
         LDR     r2,[r1],#44         		@ Change
 	SMLABT	r3, r9, r2, r3
 	SMLABB	r3, r14, r2, r3
 	SMLABT	r4, r14, r2, r4
 	LDR		r9, [r13, #4]				@ [ a8 | a9 ]
-	
 
-	QADD	r3,r3,r3					
-	QADD	r4,r4,r4					
-	QADD	r11,r11,r11					
-	QADD	r12,r12,r12					
-		
-	QADD	r3,r3,r3					
-	QADD	r4,r4,r4					
-	QADD	r11,r11,r11					
-	QADD	r12,r12,r12					
-	
-	QADD	r3,r3,r3					
-	QADD	r4,r4,r4					
-	QADD	r11,r11,r11					
-	QADD	r12,r12,r12					
-	
-	QADD	r3,r3,r3					
-	QADD	r4,r4,r4					
-	QADD	r11,r11,r11					
-	QADD	r12,r12,r12					
-	
-	MOV	r2,#32768	
-	
-	QDADD	r3,r2,r3					
-	QDADD	r4,r2,r4					
-	QDADD	r11,r2,r11					
-	QDADD	r12,r2,r12					
-		
-	
+
+	QADD	r3,r3,r3
+	QADD	r4,r4,r4
+	QADD	r11,r11,r11
+	QADD	r12,r12,r12
+
+	QADD	r3,r3,r3
+	QADD	r4,r4,r4
+	QADD	r11,r11,r11
+	QADD	r12,r12,r12
+
+	QADD	r3,r3,r3
+	QADD	r4,r4,r4
+	QADD	r11,r11,r11
+	QADD	r12,r12,r12
+
+	QADD	r3,r3,r3
+	QADD	r4,r4,r4
+	QADD	r11,r11,r11
+	QADD	r12,r12,r12
+
+	MOV	r2,#32768
+
+	QDADD	r3,r2,r3
+	QDADD	r4,r2,r4
+	QDADD	r11,r2,r11
+	QDADD	r12,r2,r12
+
+
 	MOV	r3,r3,asr #16
 	MOV	r4,r4,asr #16
 	MOV	r11,r11,asr #16
 	MOV	r12,r12,asr #16
-	
+
 	STRH	r3,[r0],#2
 	STRH	r4,[r0],#2
 	STRH	r11,[r0],#2
 	STRH	r12,[r0],#2
-	
+
 	MOV	r2,r14,asr #16
 	SUB	r14, r14, #0x10000
 	SUBS	r2,r2,#1
-	BNE	residu_loop	
+	BNE	residu_loop
 end:
-	LDMFD	r13!, {r8 -r12}	
+	LDMFD	r13!, {r8 -r12}
 	LDMFD	r13!, {r4 -r12,pc}
 
         @ENDFUNC
-        .END	 
-        
-	
-	  
+        .END
+
+
+
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/scale_sig_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/scale_sig_opt.s
index f83e688..b300224 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/scale_sig_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/scale_sig_opt.s
@@ -38,7 +38,7 @@
 	 MOV           r8, #0x7fffffff
 	 MOV           r9, #0x8000
 	 BLE           LOOP2
-	 
+
 LOOP1:
 
          LDRSH          r5, [r4]                    @load x[i]
@@ -65,11 +65,11 @@
 
 The_end:
          LDMFD         r13!, {r4 - r12, r15}
-     
+
          @ENDFUNC
-         .END	 
-        
-	
-	  
+         .END
+
+
+
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/syn_filt_opt.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/syn_filt_opt.s
index f4700cd..0c287a4 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/syn_filt_opt.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV5E/syn_filt_opt.s
@@ -33,18 +33,18 @@
 
 Syn_filt_asm:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           SUB           r13, r13, #700                   @ y_buf[L_FRAME16k + M16k]
-   
+
           MOV           r4, r3                           @ copy mem[] address
           MOV           r5, r13                          @ copy yy = y_buf address
 
           @ for(i = 0@ i < m@ i++)
           @{
           @    *yy++ = mem[i]@
-          @} 
+          @}
 
-          LDRH          r6,  [r4], #2          
+          LDRH          r6,  [r4], #2
           LDRH          r7,  [r4], #2
           LDRH          r8,  [r4], #2
           LDRH          r9,  [r4], #2
@@ -62,7 +62,7 @@
           STRH          r12, [r5], #2
           STRH          r14, [r5], #2
 
-          LDRH          r6,  [r4], #2          
+          LDRH          r6,  [r4], #2
           LDRH          r7,  [r4], #2
           LDRH          r8,  [r4], #2
           LDRH          r9,  [r4], #2
@@ -92,45 +92,45 @@
           LDRSH         r9, [r0, #6]                     @ load a[3]
           LDRSH         r11,[r0, #8]                     @ load a[4]
           AND           r6, r6, r14
-          AND           r9, r9, r14          
+          AND           r9, r9, r14
           ORR           r10, r6, r7, LSL #16             @ -a[2] -- -a[1]
           ORR           r12, r9, r11, LSL #16            @ -a[4] -- -a[3]
           STR           r10, [r13, #-4]
           STR           r12, [r13, #-8]
-          
+
           LDRSH         r6, [r0, #10]                    @ load a[5]
           LDRSH         r7, [r0, #12]                    @ load a[6]
           LDRSH         r9, [r0, #14]                    @ load a[7]
           LDRSH         r11,[r0, #16]                    @ load a[8]
           AND           r6, r6, r14
-          AND           r9, r9, r14          
+          AND           r9, r9, r14
           ORR           r10, r6, r7, LSL #16             @ -a[6] -- -a[5]
           ORR           r12, r9, r11, LSL #16            @ -a[8] -- -a[7]
           STR           r10, [r13, #-12]
-          STR           r12, [r13, #-16]          
-           
+          STR           r12, [r13, #-16]
+
           LDRSH         r6, [r0, #18]                    @ load a[9]
           LDRSH         r7, [r0, #20]                    @ load a[10]
           LDRSH         r9, [r0, #22]                    @ load a[11]
           LDRSH         r11,[r0, #24]                    @ load a[12]
           AND           r6, r6, r14
-          AND           r9, r9, r14          
+          AND           r9, r9, r14
           ORR           r10, r6, r7, LSL #16             @ -a[10] -- -a[9]
           ORR           r12, r9, r11, LSL #16            @ -a[12] -- -a[11]
           STR           r10, [r13, #-20]
-          STR           r12, [r13, #-24]    
+          STR           r12, [r13, #-24]
 
           LDRSH         r6, [r0, #26]                    @ load a[13]
           LDRSH         r7, [r0, #28]                    @ load a[14]
           LDRSH         r9, [r0, #30]                    @ load a[15]
           LDRSH         r11,[r0, #32]                    @ load a[16]
           AND           r6, r6, r14
-          AND           r9, r9, r14          
+          AND           r9, r9, r14
           ORR           r10, r6, r7, LSL #16             @ -a[14] -- -a[13]
           ORR           r12, r9, r11, LSL #16            @ -a[16] -- -a[15]
           STR           r10, [r13, #-28]
-          STR           r12, [r13, #-32]                
-                     
+          STR           r12, [r13, #-32]
+
           ADD           r4, r13, #32
 LOOP:
           LDRSH         r6,  [r1], #2                    @ load x[i]
@@ -155,8 +155,8 @@
           SMLABB        r14, r6, r7, r14                 @ -a[3] * (*(temp_p -3))
 
           LDRSH         r9,  [r10, #-10]                 @ *(temp_p - 5)
-   
-          SMLABT        r14, r11, r7, r14                @ -a[4] * (*(temp_p -4))        
+
+          SMLABT        r14, r11, r7, r14                @ -a[4] * (*(temp_p -4))
 
           LDR           r7,  [r13, #-12]                 @ -a[6]  -a[5]
           LDRSH         r12, [r10, #-12]                 @ *(temp_p - 6)
@@ -169,13 +169,13 @@
 
           LDR           r7,  [r13, #-16]                 @ -a[8] -a[7]
           LDRSH         r11, [r10, #-16]                 @ *(temp_p - 8)
-         
+
           SMLABB        r14, r6, r7, r14                 @ -a[7] * (*(temp_p -7))
 
           LDRSH         r9,  [r10, #-18]                 @ *(temp_p - 9)
 
-          SMLABT        r14, r11, r7, r14                @ -a[8] * (*(temp_p -8))          
- 
+          SMLABT        r14, r11, r7, r14                @ -a[8] * (*(temp_p -8))
+
           LDR           r7,  [r13, #-20]                 @ -a[10]  -a[9]
           LDRSH         r12, [r10, #-20]                 @ *(temp_p - 10)
 
@@ -192,11 +192,11 @@
 
           LDRSH         r9,  [r10, #-26]                 @ *(temp_p - 13)
 
-          SMLABT        r14, r11, r7, r14                @ -a[12] * (*(temp_p -12))           
+          SMLABT        r14, r11, r7, r14                @ -a[12] * (*(temp_p -12))
 
           LDR           r7,  [r13, #-28]                 @ -a[14] -a[13]
           LDRSH         r12, [r10, #-28]                 @ *(temp_p - 14)
- 
+
           SMLABB        r14, r9, r7, r14                 @ -a[13] * (*(temp_p -13))
 
           LDRSH         r6,  [r10, #-30]                 @ *(temp_p - 15)
@@ -211,28 +211,28 @@
           SMLABT        r14, r11, r7, r14                @ -a[16] * (*(temp_p -16))
 
           RSB           r14, r14, r0
-                                  
+
           MOV           r7, r14, LSL #4                  @ L_tmp <<=4
           ADD           r8, r8, #1
-          ADD           r14, r7, #0x8000                 
+          ADD           r14, r7, #0x8000
           MOV           r7, r14, ASR #16                 @ (L_tmp + 0x8000) >> 16
           CMP           r8, #80
           STRH          r7, [r10]                        @ yy[i]
           STRH          r7, [r2], #2                     @ y[i]
           BLT           LOOP
- 
+
           @ update mem[]
           ADD           r5, r13, #160                    @ yy[64] address
           MOV           r1, r3
           MOV           r0, r5
           MOV           r2, #16
-          BL            voAWB_Copy          
+          BL            voAWB_Copy
 
 Syn_filt_asm_end:
- 
-          ADD           r13, r13, #700		     
-          LDMFD   	r13!, {r4 - r12, r15} 
+
+          ADD           r13, r13, #700
+          LDMFD   	r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Deemph_32_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Deemph_32_neon.s
index 2afc146..1d5893f 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Deemph_32_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Deemph_32_neon.s
@@ -30,10 +30,10 @@
 
            .section  .text
            .global   Deemph_32_asm
-	   
+
 Deemph_32_asm:
 
-           STMFD   	r13!, {r4 - r12, r14} 
+           STMFD   	r13!, {r4 - r12, r14}
 	   MOV          r4, #2                   @i=0
 	   LDRSH        r6, [r0], #2             @load x_hi[0]
 	   LDRSH        r7, [r1], #2             @load x_lo[0]
@@ -47,9 +47,9 @@
 	   ADD          r12, r10, r7, LSL #4     @L_tmp += x_lo[0] << 4
 	   MOV          r10, r12, LSL #3         @L_tmp <<= 3
 	   MUL          r9, r5, r8
-	   LDRSH        r6, [r0], #2             @load x_hi[1] 
+	   LDRSH        r6, [r0], #2             @load x_hi[1]
 	   QDADD        r10, r10, r9
-	   LDRSH        r7, [r1], #2             @load x_lo[1]  
+	   LDRSH        r7, [r1], #2             @load x_lo[1]
 	   MOV          r12, r10, LSL #1         @L_tmp = L_mac(L_tmp, *mem, fac)
 	   QADD         r10, r12, r11
 	   MOV          r14, r10, ASR #16        @y[0] = round(L_tmp)
@@ -94,9 +94,9 @@
 
            BLT          LOOP
            STR          r14, [r3]
-           STRH         r14, [r2]	   
+           STRH         r14, [r2]
 
-           LDMFD   	r13!, {r4 - r12, r15} 
+           LDMFD   	r13!, {r4 - r12, r15}
 
 	   .END
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Dot_p_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Dot_p_neon.s
index 678f1d0..8230944d 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Dot_p_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Dot_p_neon.s
@@ -45,14 +45,14 @@
 	  VLD1.S16          {Q12, Q13}, [r1]!             @load 16 Word16 y[]
 
           VMULL.S16         Q15, D16, D0
-          VMLAL.S16         Q15, D17, D1               
+          VMLAL.S16         Q15, D17, D1
           VMLAL.S16         Q15, D18, D2
           VMLAL.S16         Q15, D19, D3
-	  VLD1.S16          {Q0, Q1}, [r1]!               @load 16 Word16 y[]   
-          VMLAL.S16         Q15, D20, D4       
+	  VLD1.S16          {Q0, Q1}, [r1]!               @load 16 Word16 y[]
+          VMLAL.S16         Q15, D20, D4
           VMLAL.S16         Q15, D21, D5
           VMLAL.S16         Q15, D22, D6
-          VMLAL.S16         Q15, D23, D7                                       
+          VMLAL.S16         Q15, D23, D7
           VMLAL.S16         Q15, D24, D8
           VMLAL.S16         Q15, D25, D9
           VMLAL.S16         Q15, D26, D10
@@ -64,9 +64,9 @@
 
           CMP               r2, #64
           BEQ               Lable1
-          VLD1.S16          {Q0, Q1}, [r0]!               @load 16 Word16 x[]  
-	  VLD1.S16          {Q2, Q3}, [r1]! 
-          VMLAL.S16         Q15, D4, D0             
+          VLD1.S16          {Q0, Q1}, [r0]!               @load 16 Word16 x[]
+	  VLD1.S16          {Q2, Q3}, [r1]!
+          VMLAL.S16         Q15, D4, D0
           VMLAL.S16         Q15, D5, D1
           VMLAL.S16         Q15, D6, D2
           VMLAL.S16         Q15, D7, D3
@@ -102,11 +102,11 @@
 	  VMLAL.S16         Q15, D2, D2
 	  VMLAL.S16         Q15, D3, D3
 
-Lable1: 
+Lable1:
 
           VQADD.S32         D30, D30, D31
           VPADD.S32         D30, D30, D30
-          VMOV.S32          r12, D30[0]        
+          VMOV.S32          r12, D30[0]
 
 	  ADD               r12, r12, r12
           ADD               r12, r12, #1                         @ L_sum = (L_sum << 1)  + 1
@@ -117,11 +117,11 @@
           SUB               r10, r10, #1                         @ sft = norm_l(L_sum)
           MOV               r0, r12, LSL r10                     @ L_sum = L_sum << sft
           RSB               r11, r10, #30                        @ *exp = 30 - sft
-          STRH              r11, [r3]                     
+          STRH              r11, [r3]
 
 Dot_product12_end:
-		     
-          LDMFD   	    r13!, {r4 - r12, r15} 
+
+          LDMFD   	    r13!, {r4 - r12, r15}
 
           .END
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Filt_6k_7k_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Filt_6k_7k_neon.s
index 5389a1c..14ba828 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Filt_6k_7k_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Filt_6k_7k_neon.s
@@ -13,7 +13,7 @@
 @ ** See the License for the specific language governing permissions and
 @ ** limitations under the License.
 @ */
-@                             
+@
 @**********************************************************************/
 @void Filt_6k_7k(
 @     Word16 signal[],                      /* input:  signal                  */
@@ -23,7 +23,7 @@
 @***********************************************************************
 @ r0    ---  signal[]
 @ r1    ---  lg
-@ r2    ---  mem[] 
+@ r2    ---  mem[]
 
           .section  .text
           .global   Filt_6k_7k_asm
@@ -31,7 +31,7 @@
 
 Filt_6k_7k_asm:
 
-          STMFD   		r13!, {r0 - r12, r14} 
+          STMFD   		r13!, {r0 - r12, r14}
           SUB    		r13, r13, #240              @ x[L_SUBFR16k + (L_FIR - 1)]
           MOV     		r8, r0                      @ copy signal[] address
           MOV     		r5, r2                      @ copy mem[] address
@@ -49,7 +49,7 @@
 
 
 
-          LDR     		r10, Lable1                 @ get fir_7k address     
+          LDR     		r10, Lable1                 @ get fir_7k address
           MOV                   r3, r8                      @ change myMemCopy to Copy, due to Copy will change r3 content
           ADD     	    	r6, r13, #60                @ get x[L_FIR - 1] address
           MOV           	r7, r3                      @ get signal[i]
@@ -81,9 +81,9 @@
 	  MOV                   r12, r5
           @STR     		r5, [sp, #-4]               @ PUSH  r5 to stack
           @ not use registers: r4, r10, r12, r14, r5
-          MOV     		r4, r13 
-          MOV     		r5, #0                      @ i = 0    
-         
+          MOV     		r4, r13
+          MOV     		r5, #0                      @ i = 0
+
           @ r4 --- x[i], r10 ---- fir_6k_7k
           VLD1.S16              {Q0, Q1}, [r10]!           @fir_6k_7k[0]  ~ fir_6k_7k[15]
 	  VLD1.S16              {Q2, Q3}, [r10]!           @fir_6k_7k[16] ~ fir_6k_7k[31]
@@ -91,20 +91,20 @@
 
 	  VLD1.S16              {Q4, Q5}, [r4]!            @x[0]  ~ x[15]
 	  VLD1.S16              {Q6, Q7}, [r4]!            @x[16] ~ X[31]
-	  VLD1.S16              {Q8}, [r4]! 
-          VMOV.S16              Q15, #0	  
-          
+	  VLD1.S16              {Q8}, [r4]!
+          VMOV.S16              Q15, #0
+
 LOOP_6K7K:
 
-          VMULL.S16             Q9,D8,D0[0]                 
-          VMULL.S16             Q10,D9,D1[0] 
-          VMULL.S16             Q11,D9,D0[0]                 
+          VMULL.S16             Q9,D8,D0[0]
+          VMULL.S16             Q10,D9,D1[0]
+          VMULL.S16             Q11,D9,D0[0]
           VMULL.S16             Q12,D10,D1[0]
           VEXT.8                Q4,Q4,Q5,#2
           VMLAL.S16             Q9,D10,D2[0]
           VMLAL.S16             Q10,D11,D3[0]
           VMLAL.S16             Q11,D11,D2[0]
-          VMLAL.S16             Q12,D12,D3[0]    
+          VMLAL.S16             Q12,D12,D3[0]
           VEXT.8                Q5,Q5,Q6,#2
           VMLAL.S16             Q9,D12,D4[0]
           VMLAL.S16             Q10,D13,D5[0]
@@ -115,18 +115,18 @@
           VMLAL.S16             Q10,D15,D7[0]
           VMLAL.S16             Q11,D15,D6[0]
 	  VMLAL.S16             Q12,D16,D7[0]
-	  VEXT.8  		Q7,Q7,Q8,#2 
+	  VEXT.8  		Q7,Q7,Q8,#2
 
-	  VMLAL.S16 		Q9,D8,D0[1]                
+	  VMLAL.S16 		Q9,D8,D0[1]
 	  VMLAL.S16     	Q10,D9,D1[1]
-	  VEXT.8 		Q8,Q8,Q15,#2 
-	  VMLAL.S16 		Q11,D9,D0[1]                
+	  VEXT.8 		Q8,Q8,Q15,#2
+	  VMLAL.S16 		Q11,D9,D0[1]
 	  VMLAL.S16 		Q12,D10,D1[1]
 	  VEXT.8  		Q4,Q4,Q5,#2
 	  VMLAL.S16 		Q9,D10,D2[1]
 	  VMLAL.S16 		Q10,D11,D3[1]
 	  VMLAL.S16 		Q11,D11,D2[1]
-	  VMLAL.S16 		Q12,D12,D3[1]    
+	  VMLAL.S16 		Q12,D12,D3[1]
 	  VEXT.8  		Q5,Q5,Q6,#2
 	  VMLAL.S16 		Q9,D12,D4[1]
 	  VMLAL.S16 		Q10,D13,D5[1]
@@ -137,18 +137,18 @@
 	  VMLAL.S16 		Q10,D15,D7[1]
 	  VMLAL.S16 		Q11,D15,D6[1]
 	  VMLAL.S16 		Q12,D16,D7[1]
-	  VEXT.8  		Q7,Q7,Q8,#2 
+	  VEXT.8  		Q7,Q7,Q8,#2
 
-	  VMLAL.S16 		Q9,D8,D0[2]           
+	  VMLAL.S16 		Q9,D8,D0[2]
 	  VMLAL.S16 		Q10,D9,D1[2]
-	  VEXT.8 		Q8,Q8,Q15,#2 
-	  VMLAL.S16 		Q11,D9,D0[2]           
+	  VEXT.8 		Q8,Q8,Q15,#2
+	  VMLAL.S16 		Q11,D9,D0[2]
 	  VMLAL.S16 		Q12,D10,D1[2]
 	  VEXT.8  		Q4,Q4,Q5,#2
 	  VMLAL.S16 		Q9,D10,D2[2]
 	  VMLAL.S16 		Q10,D11,D3[2]
 	  VMLAL.S16 		Q11,D11,D2[2]
-	  VMLAL.S16 		Q12,D12,D3[2]    
+	  VMLAL.S16 		Q12,D12,D3[2]
 	  VEXT.8  		Q5,Q5,Q6,#2
 	  VMLAL.S16 		Q9,D12,D4[2]
 	  VMLAL.S16 		Q10,D13,D5[2]
@@ -159,18 +159,18 @@
 	  VMLAL.S16 		Q10,D15,D7[2]
 	  VMLAL.S16 		Q11,D15,D6[2]
 	  VMLAL.S16 		Q12,D16,D7[2]
-	  VEXT.8  		Q7,Q7,Q8,#2 
+	  VEXT.8  		Q7,Q7,Q8,#2
 
-	  VMLAL.S16 		Q9,D8,D0[3]              
+	  VMLAL.S16 		Q9,D8,D0[3]
 	  VMLAL.S16 		Q10,D9,D1[3]
-	  VEXT.8 		Q8,Q8,Q15,#2 
-	  VMLAL.S16 		Q11,D9,D0[3]              
+	  VEXT.8 		Q8,Q8,Q15,#2
+	  VMLAL.S16 		Q11,D9,D0[3]
 	  VMLAL.S16 		Q12,D10,D1[3]
 	  VEXT.8  		Q4,Q4,Q5,#2
 	  VMLAL.S16 		Q9,D10,D2[3]
 	  VMLAL.S16 		Q10,D11,D3[3]
 	  VMLAL.S16 		Q11,D11,D2[3]
-	  VMLAL.S16 		Q12,D12,D3[3]    
+	  VMLAL.S16 		Q12,D12,D3[3]
 	  VEXT.8  		Q5,Q5,Q6,#2
 	  VMLAL.S16 		Q9,D12,D4[3]
 	  VMLAL.S16 		Q10,D13,D5[3]
@@ -181,10 +181,10 @@
 	  VMLAL.S16 		Q10,D15,D7[3]
 	  VMLAL.S16 		Q11,D15,D6[3]
 	  VMLAL.S16 		Q12,D16,D7[3]
-	  VEXT.8 		Q7,Q7,Q8,#2     
+	  VEXT.8 		Q7,Q7,Q8,#2
 
 	  VMOV.S16  		D8,D9
-	  VEXT.8 		Q8,Q8,Q15,#2 
+	  VEXT.8 		Q8,Q8,Q15,#2
 	  VMOV.S16  		D9,D10
 	  VADD.S32  		Q9,Q9,Q10
 	  VMOV.S16  		D10,D11
@@ -214,12 +214,12 @@
 	  VST1.S16              {D4, D5, D6}, [r1]!
 	  VST1.S16              D7[0], [r1]!
 	  VST1.S16              D7[1], [r1]!
-                    
+
 Filt_6k_7k_end:
 
-          ADD     		r13, r13, #240  
-          LDMFD   		r13!, {r0 - r12, r15} 
- 
+          ADD     		r13, r13, #240
+          LDMFD   		r13!, {r0 - r12, r15}
+
 Lable1:
           .word   		fir_6k_7k
           @ENDFUNC
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Norm_Corr_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Norm_Corr_neon.s
index 60e9ade..4263cd4 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Norm_Corr_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Norm_Corr_neon.s
@@ -33,7 +33,7 @@
 
 
 	.section  .text
-        .global    Norm_corr_asm 
+        .global    Norm_corr_asm
         .extern    Convolve_asm
         .extern    Isqrt_n
 @******************************
@@ -47,17 +47,17 @@
 .equ    T_MIN             , 212
 .equ    T_MAX             , 216
 .equ    CORR_NORM         , 220
-                  
+
 Norm_corr_asm:
 
-        STMFD          r13!, {r4 - r12, r14}  
+        STMFD          r13!, {r4 - r12, r14}
         SUB            r13, r13, #voSTACK
-  
+
         ADD            r8, r13, #20                 @get the excf[L_SUBFR]
         LDR            r4, [r13, #T_MIN]            @get t_min
         RSB            r11, r4, #0                  @k = -t_min
-        ADD            r5, r0, r11, LSL #1          @get the &exc[k]   
-        
+        ADD            r5, r0, r11, LSL #1          @get the &exc[k]
+
         @transfer Convolve function
         STMFD          sp!, {r0 - r3}
         MOV            r0, r5
@@ -68,7 +68,7 @@
 
         @ r8 --- excf[]
 
-	MOV            r14, r1                       @copy xn[] address                      
+	MOV            r14, r1                       @copy xn[] address
         MOV            r7, #1
 	VLD1.S16       {Q0, Q1}, [r14]!
 	VLD1.S16       {Q2, Q3}, [r14]!
@@ -95,34 +95,34 @@
         VQADD.S32      D20, D20, D21
         VMOV.S32       r9,  D20[0]
         VMOV.S32       r10, D20[1]
-        QADD           r6, r9, r10 
+        QADD           r6, r9, r10
 	QADD           r6, r6, r6
         QADD           r9, r6, r7                   @L_tmp = (L_tmp << 1) + 1;
 	CLZ            r7, r9
 	SUB            r6, r7, #1                   @exp = norm_l(L_tmp)
         RSB            r7, r6, #32                  @exp = 32 - exp
-	MOV            r6, r7, ASR #1         
+	MOV            r6, r7, ASR #1
 	RSB            r7, r6, #0                   @scale = -(exp >> 1)
-	
+
         @loop for every possible period
 	@for(t = t_min@ t <= t_max@ t++)
 	@r7 --- scale r4 --- t_min r8 --- excf[]
 
-LOOPFOR:	
+LOOPFOR:
 	ADD            r14, r13, #20                @copy of excf[]
 	MOV            r12, r1                      @copy of xn[]
 	MOV            r8, #0x8000
 
         VLD1.S16       {Q0, Q1}, [r14]!                 @ load 16 excf[]
-        VLD1.S16       {Q2, Q3}, [r14]!                 @ load 16 excf[]       
+        VLD1.S16       {Q2, Q3}, [r14]!                 @ load 16 excf[]
         VLD1.S16       {Q4, Q5}, [r12]!                 @ load 16 x[]
 	VLD1.S16       {Q6, Q7}, [r12]!                 @ load 16 x[]
         VMULL.S16    Q10, D0, D0                      @L_tmp1 += excf[] * excf[]
-        VMULL.S16    Q11, D0, D8                      @L_tmp  += x[] * excf[]                   
+        VMULL.S16    Q11, D0, D8                      @L_tmp  += x[] * excf[]
         VMLAL.S16    Q10, D1, D1
         VMLAL.S16    Q11, D1, D9
         VMLAL.S16    Q10, D2, D2
-        VMLAL.S16    Q11, D2, D10        
+        VMLAL.S16    Q11, D2, D10
         VMLAL.S16    Q10, D3, D3
         VMLAL.S16    Q11, D3, D11
         VMLAL.S16    Q10, D4, D4
@@ -143,7 +143,7 @@
         VMLAL.S16    Q10, D1, D1
         VMLAL.S16    Q11, D1, D9
         VMLAL.S16    Q10, D2, D2
-        VMLAL.S16    Q11, D2, D10        
+        VMLAL.S16    Q11, D2, D10
         VMLAL.S16    Q10, D3, D3
         VMLAL.S16    Q11, D3, D11
         VMLAL.S16    Q10, D4, D4
@@ -162,19 +162,19 @@
 	VPADD.S32      D22, D22, D22                   @D22[0] --- L_tmp << 1
 
 	VMOV.S32       r6, D20[0]
-        VMOV.S32       r5, D22[0]	
+        VMOV.S32       r5, D22[0]
 
 	@r5 --- L_tmp, r6 --- L_tmp1
 	MOV            r10, #1
 	ADD            r5, r10, r5, LSL #1                     @L_tmp = (L_tmp << 1) + 1
 	ADD            r6, r10, r6, LSL #1                     @L_tmp1 = (L_tmp1 << 1) + 1
- 
-	CLZ            r10, r5        
+
+	CLZ            r10, r5
 	CMP            r5, #0
 	RSBLT          r11, r5, #0
 	CLZLT          r10, r11
 	SUB            r10, r10, #1                 @exp = norm_l(L_tmp)
-     
+
 	MOV            r5, r5, LSL r10              @L_tmp = (L_tmp << exp)
 	RSB            r10, r10, #30                @exp_corr = 30 - exp
 	MOV            r11, r5, ASR #16             @corr = extract_h(L_tmp)
@@ -190,7 +190,7 @@
 	@Isqrt_n(&L_tmp, &exp_norm)
 
 	MOV            r14, r0
-	MOV            r12, r1 
+	MOV            r12, r1
 
         STMFD          sp!, {r0 - r4, r7 - r12, r14}
 	ADD            r1, sp, #4
@@ -208,7 +208,7 @@
 	MOV            r6, r6, ASR #16              @norm = extract_h(L_tmp)
 	MUL            r12, r6, r11
 	ADD            r12, r12, r12                @L_tmp = vo_L_mult(corr, norm)
-  
+
 	ADD            r6, r10, r5
 	ADD            r6, r6, r7                   @exp_corr + exp_norm + scale
 
@@ -227,8 +227,8 @@
 
 	CMP            r4, r6
 	BEQ            Norm_corr_asm_end
- 
-	ADD            r4, r4, #1                   @ t_min ++ 
+
+	ADD            r4, r4, #1                   @ t_min ++
 	RSB            r5, r4, #0                   @ k
 
 	MOV            r6, #63                      @ i = 63
@@ -255,16 +255,16 @@
 	MUL            r14, r11, r8
         LDR            r6, [r13, #T_MAX]            @ get t_max
 	MOV            r8, r14, ASR #15
-	STRH           r8, [r10]                    
+	STRH           r8, [r10]
 
 	CMP            r4, r6
 	BLE            LOOPFOR
 
-Norm_corr_asm_end: 
-        
-        ADD            r13, r13, #voSTACK      
+Norm_corr_asm_end:
+
+        ADD            r13, r13, #voSTACK
         LDMFD          r13!, {r4 - r12, r15}
-    
+
         .END
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Syn_filt_32_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Syn_filt_32_neon.s
index 1e65efa..e786dde 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Syn_filt_32_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/Syn_filt_32_neon.s
@@ -33,12 +33,12 @@
 @ sig_lo[] --- r5
 @ lg       --- r6
 
-          .section  .text 
+          .section  .text
           .global   Syn_filt_32_asm
 
 Syn_filt_32_asm:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           LDR           r4,  [r13, #40]                  @ get sig_hi[] address
           LDR           r5,  [r13, #44]                  @ get sig_lo[] address
 
@@ -49,8 +49,8 @@
 	  SUB           r10, r4, #32                     @ sig_hi[-16] address
 	  SUB           r11, r5, #32                     @ sig_lo[-16] address
 
-	  VLD1.S16      {D0, D1, D2, D3}, [r0]!          @a[1] ~ a[16] 
-  
+	  VLD1.S16      {D0, D1, D2, D3}, [r0]!          @a[1] ~ a[16]
+
           MOV           r8, #0                           @ i = 0
 
 	  VLD1.S16      {D4, D5, D6, D7}, [r10]!         @ sig_hi[-16] ~ sig_hi[-1]
@@ -58,9 +58,9 @@
           VREV64.16     D1, D1
 	  VLD1.S16      {D8, D9, D10, D11}, [r11]!       @ sig_lo[-16] ~ sig_lo[-1]
           VREV64.16     D2, D2
-          VREV64.16     D3, D3	
+          VREV64.16     D3, D3
           VDUP.S32      Q15, r8
-              
+
 SYN_LOOP:
 
           LDRSH         r6, [r2], #2                     @exc[i]
@@ -73,12 +73,12 @@
 
 	  VEXT.8        D9, D9, D10, #2
 	  VEXT.8        D10, D10, D11, #2
-	  
+
 	  VPADD.S32     D28, D20, D21
           MUL           r12, r6, r3                      @exc[i] * a0
 	  VPADD.S32     D29, D28, D28
 	  VDUP.S32      Q10, D29[0]                      @result1
-          
+
 	  VMULL.S16     Q11, D4, D3
 	  VMLAL.S16     Q11, D5, D2
           VSUB.S32      Q10, Q15, Q10
@@ -101,7 +101,7 @@
 
 	  VSHR.S32      Q10, Q10, #11                    @result1 >>= 11
 	  VSHL.S32      Q11, Q11, #1                     @result2 <<= 1
-	  VDUP.S32      Q12, r14                         
+	  VDUP.S32      Q12, r14
 	  VADD.S32      Q12, Q12, Q10                    @L_tmp = L_tmp - (result1 >>= 11) - (result2 <<= 1)
 	  VSUB.S32      Q12, Q12, Q11
 
@@ -122,12 +122,12 @@
 	  STRH          r12, [r5], #2                    @stroe sig_lo[i]
 
           CMP           r8, #64
-          BLT           SYN_LOOP                          
-         
+          BLT           SYN_LOOP
+
 Syn_filt_32_end:
-		     
-          LDMFD   	    r13!, {r4 - r12, r15} 
+
+          LDMFD   	    r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/convolve_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/convolve_neon.s
index 189e33b..8efa9fb 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/convolve_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/convolve_neon.s
@@ -20,22 +20,22 @@
 @*    Word16 y[],        /* (o)     : output vector                          */
 @*    Word16 L           /* (i)     : vector size                            */
 @*)
-@ 
+@
 @ r0 --- x[]
 @ r1 --- h[]
 @ r2 --- y[]
 @ r3 --- L
 
-	.section  .text 
-        .global   Convolve_asm 
+	.section  .text
+        .global   Convolve_asm
 
 Convolve_asm:
 
-        STMFD          r13!, {r4 - r12, r14}  
-        MOV            r3,  #0                        
+        STMFD          r13!, {r4 - r12, r14}
+        MOV            r3,  #0
 	MOV            r11, #0x8000
-        
-LOOP: 
+
+LOOP:
         @MOV            r8, #0                            @ s = 0
         ADD            r4, r1, r3, LSL #1                @ tmpH address
         ADD            r5, r3, #1                        @ i = n + 1
@@ -43,21 +43,21 @@
         LDRSH          r9,  [r6], #2                     @ *tmpX++
         LDRSH          r10, [r4]                         @ *tmpH--
         SUB            r5, r5, #1
-        VMOV.S32       Q10, #0 
-        MUL            r8,  r9, r10 
+        VMOV.S32       Q10, #0
+        MUL            r8,  r9, r10
 
-LOOP1:                    
+LOOP1:
         CMP            r5, #0
         BLE            L1
         SUB            r4, r4, #8
         MOV            r9, r4
-        VLD1.S16       D0, [r6]!   
+        VLD1.S16       D0, [r6]!
         VLD1.S16       D1, [r9]!
         VREV64.16      D1, D1
-        SUBS           r5, r5, #4  
-        VMLAL.S16      Q10, D0, D1         
-        B              LOOP1    
-L1:                  
+        SUBS           r5, r5, #4
+        VMLAL.S16      Q10, D0, D1
+        B              LOOP1
+L1:
         VADD.S32       D20, D20, D21
         VPADD.S32      D20, D20, D20
         VMOV.S32       r5, D20[0]
@@ -73,25 +73,25 @@
         ADD            r5, r3, #1
         MOV            r6, r0
         LDRSH          r9,  [r6], #2                     @ *tmpX++
-        LDRSH          r10, [r4], #-2                     
+        LDRSH          r10, [r4], #-2
         LDRSH          r12, [r6], #2
         LDRSH          r14, [r4]
 
         MUL            r8, r9, r10
         SUB            r5, r5, #2
         MLA            r8, r12, r14, r8
-        
+
         VMOV.S32       Q10, #0
 LOOP2:
         CMP            r5, #0
         BLE            L2
         SUB            r4, r4, #8
         MOV            r9, r4
-        VLD1.S16       D0, [r6]!   
+        VLD1.S16       D0, [r6]!
         VLD1.S16       D1, [r9]!
         SUBS           r5, r5, #4
         VREV64.16      D1, D1
-        VMLAL.S16      Q10, D0, D1 
+        VMLAL.S16      Q10, D0, D1
         B              LOOP2
 L2:
         VADD.S32       D20, D20, D21
@@ -100,7 +100,7 @@
         ADD            r8, r8, r5
         ADD            r8, r11, r8, LSL #1
         MOV            r8, r8, LSR #16                   @extract_h(s)
-        ADD            r3, r3, #1  
+        ADD            r3, r3, #1
         STRH           r8, [r2], #2                      @y[n]
 
 
@@ -115,7 +115,7 @@
         MUL            r8, r9, r10
         LDRSH          r9,  [r6], #2
         LDRSH          r10, [r4]
-        MLA            r8, r12, r14, r8 
+        MLA            r8, r12, r14, r8
         SUB            r5, r5, #3
         MLA            r8, r9, r10, r8
 
@@ -125,12 +125,12 @@
         BLE            L3
         SUB            r4, r4, #8
         MOV            r9, r4
-        VLD1.S16       D0, [r6]!   
+        VLD1.S16       D0, [r6]!
         VLD1.S16       D1, [r9]!
         VREV64.16      D1, D1
         SUBS           r5, r5, #4
-        VMLAL.S16      Q10, D0, D1 
-        B              LOOP3   
+        VMLAL.S16      Q10, D0, D1
+        B              LOOP3
 
 L3:
         VADD.S32       D20, D20, D21
@@ -146,18 +146,18 @@
         ADD            r4, r1, r5, LSL #1                @ tmpH address
         MOV            r6, r0
         VMOV.S32       Q10, #0
-LOOP4:                    
+LOOP4:
         CMP            r5, #0
         BLE            L4
         SUB            r4, r4, #8
         MOV            r9, r4
-        VLD1.S16       D0, [r6]!   
+        VLD1.S16       D0, [r6]!
         VLD1.S16       D1, [r9]!
         VREV64.16      D1, D1
-        SUBS           r5, r5, #4  
-        VMLAL.S16      Q10, D0, D1         
-        B              LOOP4    
-L4:                  
+        SUBS           r5, r5, #4
+        VMLAL.S16      Q10, D0, D1
+        B              LOOP4
+L4:
         VADD.S32       D20, D20, D21
         VPADD.S32      D20, D20, D20
         VMOV.S32       r5,  D20[0]
@@ -165,14 +165,14 @@
         MOV            r5, r5, LSR #16                   @extract_h(s)
         ADD            r3, r3, #1
         STRH           r5, [r2], #2                      @y[n]
-        
+
         CMP            r3, #64
         BLT            LOOP
-                
-Convolve_asm_end: 
- 
+
+Convolve_asm_end:
+
         LDMFD      r13!, {r4 - r12, r15}
-    
+
         @ENDFUNC
         .END
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/cor_h_vec_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/cor_h_vec_neon.s
index c314a88..8904289 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/cor_h_vec_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/cor_h_vec_neon.s
@@ -31,7 +31,7 @@
 @r5 ---- cor_1[]
 @r6 ---- cor_2[]
 
-              .section .text 
+              .section .text
 	      .global  cor_h_vec_012_asm
 
 cor_h_vec_012_asm:
@@ -52,12 +52,12 @@
 	     RSB           r11, r2, #62                      @j=62-pos
 
 LOOPj1:
-	     LDRSH         r12, [r10], #2  
+	     LDRSH         r12, [r10], #2
 	     LDRSH         r8,  [r9], #2
 	     LDRSH         r14, [r9]
 	     SUBS          r11, r11, #1
              MLA           r5, r12, r8, r5
-             MLA           r6, r12, r14, r6	 
+             MLA           r6, r12, r14, r6
 	     BGE           LOOPj1
 
 	     LDRSH         r12, [r10], #2                     @*p1++
@@ -65,7 +65,7 @@
              MLA           r5, r12, r14, r5
              MOV           r14, #0x8000
              MOV           r5, r5, LSL #2                     @L_sum1 = (L_sum1 << 2)
-             ADD           r10, r6, r14         
+             ADD           r10, r6, r14
              ADD           r9, r5, r14
              MOV           r5, r9, ASR #16
              MOV           r6, r10, ASR #16
@@ -77,7 +77,7 @@
 	     MUL           r14, r6, r11
 	     MOV           r5, r12, ASR #15
 	     MOV           r6, r14, ASR #15
-	     LDR           r9,  [r13, #44]                   
+	     LDR           r9,  [r13, #44]
 	     LDR           r12, [r13, #48]
              LDRSH         r10, [r7], #2                      @*p0++
 	     LDRSH         r11, [r8]                          @*p3++
@@ -89,7 +89,7 @@
 	     STRH          r6, [r12]
 
              ADD           r2, r2, #4
- 
+
              MOV           r5, #0                            @L_sum1 = 0
 	     MOV           r6, #0                            @L_sum2 = 0
 	     ADD           r9, r1, r2, LSL #1                @p2 = &vec[pos]
@@ -98,12 +98,12 @@
 	     ADD           r4, r4, #1                        @i++
 
 LOOPj2:
-	     LDRSH         r12, [r10], #2  
+	     LDRSH         r12, [r10], #2
 	     LDRSH         r8,  [r9], #2
 	     LDRSH         r14, [r9]
 	     SUBS          r11, r11, #1
              MLA           r5, r12, r8, r5
-             MLA           r6, r12, r14, r6	 
+             MLA           r6, r12, r14, r6
 	     BGE           LOOPj2
 
 	     LDRSH         r12, [r10], #2                     @*p1++
@@ -111,7 +111,7 @@
              MLA           r5, r12, r14, r5
              MOV           r14, #0x8000
              MOV           r5, r5, LSL #2                     @L_sum1 = (L_sum1 << 2)
-             ADD           r10, r6, r14        
+             ADD           r10, r6, r14
              ADD           r9, r5, r14
 
              MOV           r5, r9, ASR #16
@@ -124,7 +124,7 @@
 	     MUL           r14, r6, r11
 	     MOV           r5, r12, ASR #15
 	     MOV           r6, r14, ASR #15
-	     LDR           r9,  [r13, #44]                   
+	     LDR           r9,  [r13, #44]
 	     LDR           r12, [r13, #48]
              LDRSH         r10, [r7], #2                      @*p0++
 	     LDRSH         r11, [r8]                          @*p3++
@@ -137,15 +137,15 @@
 	     ADD           r4, r4, #1                         @i+1
 	     ADD           r2, r2, #4                         @pos += STEP
 	     CMP           r4, #16
-	     
+
 	     BLT           LOOPi
-         
+
 the_end:
              LDMFD         r13!, {r4 - r12, r15}
-             
-	     .END	 
-        
-	
-	  
+
+	     .END
+
+
+
 
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/pred_lt4_1_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/pred_lt4_1_neon.s
index dffb750..6b782cb 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/pred_lt4_1_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/pred_lt4_1_neon.s
@@ -25,14 +25,14 @@
 @ r1    ---  T0
 @ r2    ---  frac
 @ r3    ---  L_subfr
- 
-          .section  .text 
+
+          .section  .text
           .global   pred_lt4_asm
           .extern   inter4_2
 
 pred_lt4_asm:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           SUB           r4, r0, r1, LSL #1                        @ x = exc - T0
           RSB           r2, r2, #0                                @ frac = - frac
           SUB           r4, r4, #30                               @ x -= L_INTERPOL2 - 1
@@ -47,8 +47,8 @@
 
 	  VLD1.S16      {Q0, Q1}, [r11]!
 	  VLD1.S16      {Q2, Q3}, [r11]!
-          
-	  MOV           r6, #0x8000 
+
+	  MOV           r6, #0x8000
 
           VLD1.S16      {Q4, Q5}, [r4]!                           @load 16 x[]
           VLD1.S16      {Q6, Q7}, [r4]!                           @load 16 x[]
@@ -58,14 +58,14 @@
           VQDMLAL.S16   Q15, D9, D1
           VQDMLAL.S16   Q15, D10, D2
           VQDMLAL.S16   Q15, D11, D3
-        
+
           VQDMLAL.S16   Q15, D12, D4
           VQDMLAL.S16   Q15, D13, D5
           VQDMLAL.S16   Q15, D14, D6
           VQDMLAL.S16   Q15, D15, D7
 
-          LDRSH         r12, [r4], #2                
-          
+          LDRSH         r12, [r4], #2
+
           VEXT.S16      D8, D8, D9, #1
           VEXT.S16      D9, D9, D10, #1
           VEXT.S16      D10, D10, D11, #1
@@ -73,26 +73,26 @@
           VDUP.S16      D24, r12
           VEXT.S16      D12, D12, D13, #1
           VEXT.S16      D13, D13, D14, #1
-     
+
           VQADD.S32     D30, D30, D31
-	  MOV           r11, #0x8000          
+	  MOV           r11, #0x8000
           VPADD.S32     D30, D30, D30
           ADD           r8, r8, #1
           VMOV.S32      r12, D30[0]
-          VEXT.S16      D14, D14, D15, #1          
+          VEXT.S16      D14, D14, D15, #1
 
           QADD          r1, r12, r12                              @ L_sum = (L_sum << 2)
           VEXT.S16      D15, D15, D24, #1
-          QADD          r5, r1, r6                         
+          QADD          r5, r1, r6
           MOV           r1, r5, ASR #16
           CMP           r8, r3
           STRH          r1, [r0], #2                              @ exc[j] = (L_sum + 0x8000) >> 16
           BLT           LOOP
-                    
+
 pred_lt4_end:
-		     
-          LDMFD   	r13!, {r4 - r12, r15} 
- 
+
+          LDMFD   	r13!, {r4 - r12, r15}
+
 Lable1:
           .word   	inter4_2
           @ENDFUNC
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/residu_asm_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/residu_asm_neon.s
index b9e6b23..394fa83 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/residu_asm_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/residu_asm_neon.s
@@ -26,17 +26,17 @@
 @lg         RN     r3
 
 	.section   .text
-        .global    Residu_opt 
+        .global    Residu_opt
 
 Residu_opt:
 
-        STMFD          r13!, {r4 - r12, r14} 
+        STMFD          r13!, {r4 - r12, r14}
         SUB            r7, r3, #4                       @i = lg - 4
-        
-        VLD1.S16       {D0, D1, D2, D3}, [r0]!              @get all a[]  
+
+        VLD1.S16       {D0, D1, D2, D3}, [r0]!              @get all a[]
 	VLD1.S16       {D4}, [r0]!
         VMOV.S32       Q8,  #0x8000
-        
+
 LOOP1:
         ADD            r9, r1, r7, LSL #1               @copy the address
         ADD            r10, r2, r7, LSL #1
@@ -45,7 +45,7 @@
         VQDMULL.S16    Q10, D5, D0[0]                  @finish the first L_mult
 
         SUB            r8, r9, #2                       @get the x[i-1] address
-        VLD1.S16       D5, [r8]! 
+        VLD1.S16       D5, [r8]!
         VQDMLAL.S16    Q10, D5, D0[1]
 
         SUB            r8, r9, #4                       @load the x[i-2] address
@@ -53,36 +53,36 @@
         VQDMLAL.S16    Q10, D5, D0[2]
 
         SUB            r8, r9, #6                       @load the x[i-3] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D0[3]                    
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D0[3]
 
         SUB            r8, r9, #8                       @load the x[i-4] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D1[0]  
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D1[0]
 
         SUB            r8, r9, #10                      @load the x[i-5] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D1[1] 
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D1[1]
 
         SUB            r8, r9, #12                      @load the x[i-6] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D1[2]  
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D1[2]
 
         SUB            r8, r9, #14                      @load the x[i-7] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D1[3]  
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D1[3]
 
         SUB            r8, r9, #16                      @load the x[i-8] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D2[0]  
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D2[0]
 
         SUB            r8, r9, #18                      @load the x[i-9] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D2[1]         
-           
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D2[1]
+
         SUB            r8, r9, #20                      @load the x[i-10] address
-        VLD1.S16       D5, [r8]!     
-        VQDMLAL.S16    Q10, D5, D2[2]  
+        VLD1.S16       D5, [r8]!
+        VQDMLAL.S16    Q10, D5, D2[2]
 
 	SUB            r8, r9, #22                      @load the x[i-11] address
 	VLD1.S16       D5, [r8]!
@@ -117,10 +117,10 @@
 
         BGE            LOOP1
 
-Residu_asm_end: 
- 
+Residu_asm_end:
+
         LDMFD      r13!, {r4 - r12, r15}
-    
+
         @ENDFUNC
         .END
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/scale_sig_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/scale_sig_neon.s
index bbd354d..e45daac 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/scale_sig_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/scale_sig_neon.s
@@ -13,7 +13,7 @@
 @ ** See the License for the specific language governing permissions and
 @ ** limitations under the License.
 @ */
-@                   
+@
 @**********************************************************************/
 @void Scale_sig(
 @               Word16 x[],                           /* (i/o) : signal to scale               */
@@ -25,16 +25,16 @@
 @  lg    ---  r1
 @  exp   ---  r2
 
-          .section  .text 
+          .section  .text
           .global   Scale_sig_opt
 
 Scale_sig_opt:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           MOV           r4, #4
-          VMOV.S32      Q15, #0x8000       
-          VDUP.S32      Q14, r2  
-          MOV           r5, r0                          @ copy x[] address    
+          VMOV.S32      Q15, #0x8000
+          VDUP.S32      Q14, r2
+          MOV           r5, r0                          @ copy x[] address
           CMP           r1, #64
           MOVEQ         r4, #1
           BEQ           LOOP
@@ -48,7 +48,7 @@
 	  BEQ           LOOP1
 
 LOOP1:
-          VLD1.S16      {Q0, Q1}, [r5]!                 @load 16 Word16 x[]     
+          VLD1.S16      {Q0, Q1}, [r5]!                 @load 16 Word16 x[]
           VSHLL.S16     Q10, D0, #16
           VSHLL.S16     Q11, D1, #16
           VSHLL.S16     Q12, D2, #16
@@ -63,7 +63,7 @@
           VADDHN.S32    D19, Q13, Q15
           VST1.S16      {Q8, Q9}, [r0]!                 @store 16 Word16 x[]
 
-LOOP:                
+LOOP:
           VLD1.S16      {Q0, Q1}, [r5]!                 @load 16 Word16 x[]
           VLD1.S16      {Q2, Q3}, [r5]!                 @load 16 Word16 x[]
           VLD1.S16      {Q4, Q5}, [r5]!                 @load 16 Word16 x[]
@@ -72,7 +72,7 @@
           VSHLL.S16     Q8, D0, #16
           VSHLL.S16     Q9, D1, #16
           VSHLL.S16     Q10, D2, #16
-          VSHLL.S16     Q11, D3, #16     
+          VSHLL.S16     Q11, D3, #16
           VSHL.S32      Q8, Q8, Q14
           VSHL.S32      Q9, Q9, Q14
           VSHL.S32      Q10, Q10, Q14
@@ -83,7 +83,7 @@
           VADDHN.S32    D19, Q11, Q15
           VST1.S16      {Q8, Q9}, [r0]!                 @store 16 Word16 x[]
 
-   
+
           VSHLL.S16     Q12, D4, #16
           VSHLL.S16     Q13, D5, #16
           VSHLL.S16     Q10, D6, #16
@@ -112,7 +112,7 @@
           VADDHN.S32    D19, Q13, Q15
           VST1.S16      {Q8, Q9}, [r0]!                 @store 16 Word16 x[]
 
-          VSHLL.S16     Q10, D12, #16   
+          VSHLL.S16     Q10, D12, #16
           VSHLL.S16     Q11, D13, #16
           VSHLL.S16     Q12, D14, #16
           VSHLL.S16     Q13, D15, #16
@@ -123,16 +123,16 @@
           VADDHN.S32    D16, Q10, Q15
           VADDHN.S32    D17, Q11, Q15
           VADDHN.S32    D18, Q12, Q15
-          VADDHN.S32    D19, Q13, Q15 
-          VST1.S16      {Q8, Q9}, [r0]!                 @store 16 Word16 x[]  
+          VADDHN.S32    D19, Q13, Q15
+          VST1.S16      {Q8, Q9}, [r0]!                 @store 16 Word16 x[]
           SUBS          r4, r4, #1
-          BGT           LOOP     
-                
-                          
+          BGT           LOOP
+
+
 Scale_sig_asm_end:
 
-          LDMFD   	r13!, {r4 - r12, r15} 
+          LDMFD   	r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/syn_filt_neon.s b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/syn_filt_neon.s
index db4559c..5731bdb 100644
--- a/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/syn_filt_neon.s
+++ b/media/libstagefright/codecs/amrwbenc/src/asm/ARMV7/syn_filt_neon.s
@@ -27,21 +27,21 @@
 @ mem[]  ---   r3
 @ m ---  16  lg --- 80  update --- 1
 
-          .section  .text 
+          .section  .text
           .global   Syn_filt_asm
 
 Syn_filt_asm:
 
-          STMFD   	r13!, {r4 - r12, r14} 
+          STMFD   	r13!, {r4 - r12, r14}
           SUB           r13, r13, #700                   @ y_buf[L_FRAME16k + M16k]
-   
+
           MOV           r4, r3                           @ copy mem[] address
           MOV           r5, r13                          @ copy yy = y_buf address
 
           @ for(i = 0@ i < m@ i++)
           @{
           @    *yy++ = mem[i]@
-          @} 
+          @}
           VLD1.S16      {D0, D1, D2, D3}, [r4]!          @load 16 mems
 	  VST1.S16      {D0, D1, D2, D3}, [r5]!          @store 16 mem[] to *yy
 
@@ -54,7 +54,7 @@
 	  VREV64.16     D0, D0
 	  VREV64.16     D1, D1
 	  VREV64.16     D2, D2
-	  VREV64.16     D3, D3 
+	  VREV64.16     D3, D3
 	  MOV           r8, #0                           @ loop times
 	  MOV           r10, r13                         @ temp = y_buf
 	  ADD           r4, r13, #32                     @ yy[i] address
@@ -68,7 +68,7 @@
 	  ADD           r10, r4, r8, LSL #1              @ y[i], yy[i] address
 
 	  VDUP.S32      Q10, r12
-	  VMULL.S16     Q5, D3, D4                    
+	  VMULL.S16     Q5, D3, D4
           VMLAL.S16     Q5, D2, D5
           VMLAL.S16     Q5, D1, D6
           VMLAL.S16     Q5, D0, D7
@@ -82,25 +82,25 @@
 	  VDUP.S32      Q7, D10[0]
 
 	  VSUB.S32      Q9, Q10, Q7
-          VQRSHRN.S32   D20, Q9, #12   
+          VQRSHRN.S32   D20, Q9, #12
           VMOV.S16      r9, D20[0]
           VEXT.8        D7, D7, D20, #2
           CMP           r8, #80
           STRH          r9, [r10]                        @ yy[i]
-          STRH          r9, [r2], #2                     @ y[i]          	         
-	  
+          STRH          r9, [r2], #2                     @ y[i]
+
           BLT           SYN_LOOP
- 
+
           @ update mem[]
           ADD           r5, r13, #160                    @ yy[64] address
 	  VLD1.S16      {D0, D1, D2, D3}, [r5]!
-	  VST1.S16      {D0, D1, D2, D3}, [r3]!              
+	  VST1.S16      {D0, D1, D2, D3}, [r3]!
 
 Syn_filt_asm_end:
- 
-          ADD           r13, r13, #700		     
-          LDMFD   	r13!, {r4 - r12, r15} 
+
+          ADD           r13, r13, #700
+          LDMFD   	r13!, {r4 - r12, r15}
           @ENDFUNC
           .END
- 
+
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/autocorr.c b/media/libstagefright/codecs/amrwbenc/src/autocorr.c
index 9baa937..8c477ca 100644
--- a/media/libstagefright/codecs/amrwbenc/src/autocorr.c
+++ b/media/libstagefright/codecs/amrwbenc/src/autocorr.c
@@ -70,19 +70,19 @@
 		p1 = y;
 		for (i = 0; i < L_WINDOW; i+=4)
 		{
-			*p1 = vo_shr_r(*p1, shift); 
-			p1++;
-			*p1 = vo_shr_r(*p1, shift); 
+			*p1 = vo_shr_r(*p1, shift);
 			p1++;
 			*p1 = vo_shr_r(*p1, shift);
 			p1++;
-			*p1 = vo_shr_r(*p1, shift); 
+			*p1 = vo_shr_r(*p1, shift);
+			p1++;
+			*p1 = vo_shr_r(*p1, shift);
 			p1++;
 		}
 	}
 
 	/* Compute and normalize r[0] */
-	L_sum = 1; 
+	L_sum = 1;
 	for (i = 0; i < L_WINDOW; i+=4)
 	{
 		L_sum += vo_L_mult(y[i], y[i]);
diff --git a/media/libstagefright/codecs/amrwbenc/src/az_isp.c b/media/libstagefright/codecs/amrwbenc/src/az_isp.c
index 9333d19..43db27a 100644
--- a/media/libstagefright/codecs/amrwbenc/src/az_isp.c
+++ b/media/libstagefright/codecs/amrwbenc/src/az_isp.c
@@ -90,9 +90,9 @@
 		f1[i] = vo_round(t0 + (a[M - i] << 15));        /* =(a[i]+a[M-i])/2 */
 		f2[i] = vo_round(t0 - (a[M - i] << 15));        /* =(a[i]-a[M-i])/2 */
 	}
-	f1[NC] = a[NC];                        
+	f1[NC] = a[NC];
 	for (i = 2; i < NC; i++)               /* Divide by (1-z^-2) */
-		f2[i] = add1(f2[i], f2[i - 2]);     
+		f2[i] = add1(f2[i], f2[i - 2]);
 
 	/*---------------------------------------------------------------------*
 	 * Find the ISPs (roots of F1(z) and F2(z) ) using the                 *
@@ -107,17 +107,17 @@
 	 *---------------------------------------------------------------------*/
 	nf = 0;                                  /* number of found frequencies */
 	ip = 0;                                  /* indicator for f1 or f2      */
-	coef = f1;                             
-	order = NC;                            
-	xlow = vogrid[0];                        
+	coef = f1;
+	order = NC;
+	xlow = vogrid[0];
 	ylow = Chebps2(xlow, coef, order);
 	j = 0;
 	while ((nf < M - 1) && (j < GRID_POINTS))
 	{
 		j ++;
-		xhigh = xlow;                     
-		yhigh = ylow;                      
-		xlow = vogrid[j];                    
+		xhigh = xlow;
+		yhigh = ylow;
+		xlow = vogrid[j];
 		ylow = Chebps2(xlow, coef, order);
 		if ((ylow * yhigh) <= (Word32) 0)
 		{
@@ -128,12 +128,12 @@
 				ymid = Chebps2(xmid, coef, order);
 				if ((ylow * ymid) <= (Word32) 0)
 				{
-					yhigh = ymid;         
-					xhigh = xmid;          
+					yhigh = ymid;
+					xhigh = xmid;
 				} else
 				{
-					ylow = ymid;           
-					xlow = xmid;          
+					ylow = ymid;
+					xlow = xmid;
 				}
 			}
 			/*-------------------------------------------------------------*
@@ -144,10 +144,10 @@
 			y = yhigh - ylow;
 			if (y == 0)
 			{
-				xint = xlow;               
+				xint = xlow;
 			} else
 			{
-				sign = y;                 
+				sign = y;
 				y = abs_s(y);
 				exp = norm_s(y);
 				y = y << exp;
@@ -161,19 +161,19 @@
 				t0 = (t0 >> 10);        /* result in Q15 */
 				xint = vo_sub(xlow, vo_extract_l(t0));        /* xint = xlow - ylow*y */
 			}
-			isp[nf] = xint;                
-			xlow = xint;                   
-			nf++;                          
+			isp[nf] = xint;
+			xlow = xint;
+			nf++;
 			if (ip == 0)
 			{
-				ip = 1;                    
-				coef = f2;                
-				order = NC - 1;           
+				ip = 1;
+				coef = f2;
+				order = NC - 1;
 			} else
 			{
-				ip = 0;                   
-				coef = f1;                 
-				order = NC;              
+				ip = 0;
+				coef = f1;
+				order = NC;
 			}
 			ylow = Chebps2(xlow, coef, order);
 		}
@@ -183,7 +183,7 @@
 	{
 		for (i = 0; i < M; i++)
 		{
-			isp[i] = old_isp[i];          
+			isp[i] = old_isp[i];
 		}
 	} else
 	{
@@ -243,9 +243,9 @@
 		b0_l = (t0 & 0xffff) >> 1;
 
 		b2_l = b1_l;                         /* b2 = b1; */
-		b2_h = b1_h;                       
+		b2_h = b1_h;
 		b1_l = b0_l;                         /* b1 = b0; */
-		b1_h = b0_h;                       
+		b1_h = b0_h;
 	}
 
 	t0 = ((b1_h * x)<<1) + (((b1_l * x)>>15)<<1);
diff --git a/media/libstagefright/codecs/amrwbenc/src/bits.c b/media/libstagefright/codecs/amrwbenc/src/bits.c
index 61cac3d5..e78dc1f 100644
--- a/media/libstagefright/codecs/amrwbenc/src/bits.c
+++ b/media/libstagefright/codecs/amrwbenc/src/bits.c
@@ -34,8 +34,8 @@
 
 int PackBits(Word16 prms[],             /*  i: analysis parameters */
 			 Word16 coding_mode,        /*  i: coding bit-stream ratio mode */
-			 Word16 mode,               /*  i: coding bit-stream ratio mode*/ 
-			 Coder_State *st            /*i/o: coder global parameters struct */           
+			 Word16 mode,               /*  i: coding bit-stream ratio mode*/
+			 Coder_State *st            /*i/o: coder global parameters struct */
 			 )
 {
 	Word16 i, frame_type;
@@ -46,7 +46,7 @@
 	unsigned short* dataOut = st->outputStream;
 
 	if (coding_mode == MRDTX)
-	{	   
+	{
 		st->sid_update_counter--;
 
 		if (st->prev_ft == TX_SPEECH)
@@ -92,7 +92,7 @@
 	} else
 	{
 		if (bitstreamformat == 1)		/* ITU file format */
-		{  						
+		{
 			*(dataOut) = 0x6b21;
 			if(frame_type != TX_NO_DATA && frame_type != TX_SID_FIRST)
 			{
@@ -100,17 +100,17 @@
 				for (i = 0; i < nb_of_bits[coding_mode]; i++)
 				{
 					if(prms[i] == BIT_0){
-						*(dataOut + 2 + i) = BIT_0_ITU;	 			
+						*(dataOut + 2 + i) = BIT_0_ITU;
 					}
 					else{
 						*(dataOut + 2 + i) = BIT_1_ITU;
 					}
 				}
-				return (2 + nb_of_bits[coding_mode])<<1;   
+				return (2 + nb_of_bits[coding_mode])<<1;
 			} else
 			{
 				*(dataOut + 1) = 0;
-				return 2<<1;	   
+				return 2<<1;
 			}
 		} else							/* MIME/storage file format */
 		{
@@ -191,7 +191,7 @@
 		)
 {
 	Word16 i, bit;
-	*prms += no_of_bits;                  
+	*prms += no_of_bits;
 	for (i = 0; i < no_of_bits; i++)
 	{
 		bit = (Word16) (value & 0x0001);    /* get lsb */
@@ -199,9 +199,9 @@
 			*--(*prms) = BIT_0;
 		else
 			*--(*prms) = BIT_1;
-		value >>= 1;          
+		value >>= 1;
 	}
-	*prms += no_of_bits;                  
+	*prms += no_of_bits;
 	return;
 }
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/c2t64fx.c b/media/libstagefright/codecs/amrwbenc/src/c2t64fx.c
index 80990d9..18698e2 100644
--- a/media/libstagefright/codecs/amrwbenc/src/c2t64fx.c
+++ b/media/libstagefright/codecs/amrwbenc/src/c2t64fx.c
@@ -79,7 +79,7 @@
 #endif
 
 	Isqrt_n(&s, &exp);
-	s = L_shl(s, add1(exp, 5));             
+	s = L_shl(s, add1(exp, 5));
 	k_cn = vo_round(s);
 
 	/* set k_dn = 32..512 (ener_dn = 2^30..2^22) */
@@ -107,22 +107,22 @@
 		s = (k_cn* (*p0++))+(k_dn * (*p1++));
 		*p2++ = s >> 7;
 		s = (k_cn* (*p0++))+(k_dn * (*p1++));
-		*p2++ = s >> 7; 
+		*p2++ = s >> 7;
 	}
 
 	/* set sign according to dn2[] = k_cn*cn[] + k_dn*dn[]    */
 	for (i = 0; i < L_SUBFR; i ++)
 	{
-		val = dn[i];                   
-		ps = dn2[i];                   
+		val = dn[i];
+		ps = dn2[i];
 		if (ps >= 0)
 		{
 			sign[i] = 32767;             /* sign = +1 (Q12) */
-			vec[i] = -32768;           
+			vec[i] = -32768;
 		} else
 		{
 			sign[i] = -32768;            /* sign = -1 (Q12) */
-			vec[i] = 32767;            
+			vec[i] = 32767;
 			dn[i] = -val;
 		}
 	}
@@ -130,13 +130,13 @@
 	 * Compute h_inv[i].                                          *
 	 *------------------------------------------------------------*/
 	/* impulse response buffer for fast computation */
-	h = h_buf + L_SUBFR;                             
-	h_inv = h + (L_SUBFR<<1);         
+	h = h_buf + L_SUBFR;
+	h_inv = h + (L_SUBFR<<1);
 
 	for (i = 0; i < L_SUBFR; i++)
 	{
-		h[i] = H[i];                       
-		h_inv[i] = vo_negate(h[i]);           
+		h[i] = H[i];
+		h_inv[i] = vo_negate(h[i]);
 	}
 
 	/*------------------------------------------------------------*
@@ -144,46 +144,46 @@
 	 * Result is multiplied by 0.5                                *
 	 *------------------------------------------------------------*/
 	/* Init pointers to last position of rrixix[] */
-	p0 = &rrixix[0][NB_POS - 1];           
-	p1 = &rrixix[1][NB_POS - 1];           
+	p0 = &rrixix[0][NB_POS - 1];
+	p1 = &rrixix[1][NB_POS - 1];
 
-	ptr_h1 = h;                            
+	ptr_h1 = h;
 	cor = 0x00010000L;                          /* for rounding */
 	for (i = 0; i < NB_POS; i++)
 	{
 		cor += ((*ptr_h1) * (*ptr_h1) << 1);
 		ptr_h1++;
-		*p1-- = (extract_h(cor) >> 1);            
+		*p1-- = (extract_h(cor) >> 1);
 		cor += ((*ptr_h1) * (*ptr_h1) << 1);
 		ptr_h1++;
-		*p0-- = (extract_h(cor) >> 1);            
+		*p0-- = (extract_h(cor) >> 1);
 	}
 
 	/*------------------------------------------------------------*
 	 * Compute rrixiy[][] needed for the codebook search.         *
 	 *------------------------------------------------------------*/
-	pos = MSIZE - 1;                       
-	pos2 = MSIZE - 2;                      
-	ptr_hf = h + 1;                        
+	pos = MSIZE - 1;
+	pos2 = MSIZE - 2;
+	ptr_hf = h + 1;
 
 	for (k = 0; k < NB_POS; k++)
 	{
-		p1 = &rrixiy[pos];                 
-		p0 = &rrixiy[pos2];                
+		p1 = &rrixiy[pos];
+		p0 = &rrixiy[pos2];
 		cor = 0x00008000L;                        /* for rounding */
-		ptr_h1 = h;                        
-		ptr_h2 = ptr_hf;                   
+		ptr_h1 = h;
+		ptr_h2 = ptr_hf;
 
 		for (i = (k + 1); i < NB_POS; i++)
 		{
 			cor += ((*ptr_h1) * (*ptr_h2))<<1;
 			ptr_h1++;
 			ptr_h2++;
-			*p1 = extract_h(cor);          
+			*p1 = extract_h(cor);
 			cor += ((*ptr_h1) * (*ptr_h2))<<1;
 			ptr_h1++;
 			ptr_h2++;
-			*p0 = extract_h(cor);         
+			*p0 = extract_h(cor);
 
 			p1 -= (NB_POS + 1);
 			p0 -= (NB_POS + 1);
@@ -191,7 +191,7 @@
 		cor += ((*ptr_h1) * (*ptr_h2))<<1;
 		ptr_h1++;
 		ptr_h2++;
-		*p1 = extract_h(cor);              
+		*p1 = extract_h(cor);
 
 		pos -= NB_POS;
 		pos2--;
@@ -201,17 +201,17 @@
 	/*------------------------------------------------------------*
 	 * Modification of rrixiy[][] to take signs into account.     *
 	 *------------------------------------------------------------*/
-	p0 = rrixiy;                          
+	p0 = rrixiy;
 	for (i = 0; i < L_SUBFR; i += STEP)
 	{
-		psign = sign;                      
+		psign = sign;
 		if (psign[i] < 0)
 		{
-			psign = vec;                   
+			psign = vec;
 		}
 		for (j = 1; j < L_SUBFR; j += STEP)
 		{
-			*p0 = vo_mult(*p0, psign[j]);     
+			*p0 = vo_mult(*p0, psign[j]);
 			p0++;
 		}
 	}
@@ -220,20 +220,20 @@
 	 * ~@~~~~~~~~~~~~~~                                                  *
 	 * 32 pos x 32 pos = 1024 tests (all combinaisons is tested)         *
 	 *-------------------------------------------------------------------*/
-	p0 = rrixix[0];                        
-	p1 = rrixix[1];                        
-	p2 = rrixiy;                          
+	p0 = rrixix[0];
+	p1 = rrixix[1];
+	p2 = rrixiy;
 
-	psk = -1;                              
-	alpk = 1;                              
-	ix = 0;                                
-	iy = 1;                                
+	psk = -1;
+	alpk = 1;
+	ix = 0;
+	iy = 1;
 
 	for (i0 = 0; i0 < L_SUBFR; i0 += STEP)
 	{
-		ps1 = dn[i0];                      
-		alp1 = (*p0++);                    
-		pos = -1;                          
+		ps1 = dn[i0];
+		alp1 = (*p0++);
+		pos = -1;
 		for (i1 = 1; i1 < L_SUBFR; i1 += STEP)
 		{
 			ps2 = add1(ps1, dn[i1]);
@@ -242,16 +242,16 @@
 			s = vo_L_mult(alpk, sq) - ((psk * alp2)<<1);
 			if (s > 0)
 			{
-				psk = sq;                  
-				alpk = alp2;               
-				pos = i1;                  
+				psk = sq;
+				alpk = alp2;
+				pos = i1;
 			}
 		}
 		p1 -= NB_POS;
 		if (pos >= 0)
 		{
-			ix = i0;                      
-			iy = pos;                      
+			ix = i0;
+			iy = pos;
 		}
 	}
 	/*-------------------------------------------------------------------*
@@ -260,7 +260,7 @@
 
 	for (i = 0; i < L_SUBFR; i++)
 	{
-		code[i] = 0;                       
+		code[i] = 0;
 	}
 
 	i0 = (ix >> 1);                       /* pos of pulse 1 (0..31) */
@@ -268,24 +268,24 @@
 	if (sign[ix] > 0)
 	{
 		code[ix] = 512;                     /* codeword in Q9 format */
-		p0 = h - ix;                       
+		p0 = h - ix;
 	} else
 	{
-		code[ix] = -512;                   
-		i0 += NB_POS;                      
-		p0 = h_inv - ix;                   
+		code[ix] = -512;
+		i0 += NB_POS;
+		p0 = h_inv - ix;
 	}
 	if (sign[iy] > 0)
 	{
-		code[iy] = 512;                    
-		p1 = h - iy;                       
+		code[iy] = 512;
+		p1 = h - iy;
 	} else
 	{
-		code[iy] = -512;                   
-		i1 += NB_POS;                      
-		p1 = h_inv - iy;                   
+		code[iy] = -512;
+		i1 += NB_POS;
+		p1 = h_inv - iy;
 	}
-	*index = add1((i0 << 6), i1);          
+	*index = add1((i0 << 6), i1);
 	for (i = 0; i < L_SUBFR; i++)
 	{
 		y[i] = vo_shr_r(add1((*p0++), (*p1++)), 3);
diff --git a/media/libstagefright/codecs/amrwbenc/src/c4t64fx.c b/media/libstagefright/codecs/amrwbenc/src/c4t64fx.c
index 17f3d47..1ecc11f 100644
--- a/media/libstagefright/codecs/amrwbenc/src/c4t64fx.c
+++ b/media/libstagefright/codecs/amrwbenc/src/c4t64fx.c
@@ -151,58 +151,58 @@
 		case 20:                               /* 20 bits, 4 pulses, 4 tracks */
 			nbiter = 4;                          /* 4x16x16=1024 loop */
 			alp = 8192;                          /* alp = 2.0 (Q12) */
-			nb_pulse = 4;                      
-			nbpos[0] = 4;                      
-			nbpos[1] = 8;                      
+			nb_pulse = 4;
+			nbpos[0] = 4;
+			nbpos[1] = 8;
 			break;
 		case 36:                               /* 36 bits, 8 pulses, 4 tracks */
 			nbiter = 4;                          /* 4x20x16=1280 loop */
 			alp = 4096;                          /* alp = 1.0 (Q12) */
-			nb_pulse = 8;                      
-			nbpos[0] = 4;                      
-			nbpos[1] = 8;                      
-			nbpos[2] = 8;                      
+			nb_pulse = 8;
+			nbpos[0] = 4;
+			nbpos[1] = 8;
+			nbpos[2] = 8;
 			break;
 		case 44:                               /* 44 bits, 10 pulses, 4 tracks */
 			nbiter = 4;                          /* 4x26x16=1664 loop */
 			alp = 4096;                          /* alp = 1.0 (Q12) */
-			nb_pulse = 10;                     
-			nbpos[0] = 4;                      
-			nbpos[1] = 6;                      
-			nbpos[2] = 8;                      
-			nbpos[3] = 8;                      
+			nb_pulse = 10;
+			nbpos[0] = 4;
+			nbpos[1] = 6;
+			nbpos[2] = 8;
+			nbpos[3] = 8;
 			break;
 		case 52:                               /* 52 bits, 12 pulses, 4 tracks */
 			nbiter = 4;                          /* 4x26x16=1664 loop */
 			alp = 4096;                          /* alp = 1.0 (Q12) */
-			nb_pulse = 12;                     
-			nbpos[0] = 4;                      
-			nbpos[1] = 6;                      
-			nbpos[2] = 8;                      
-			nbpos[3] = 8;                      
+			nb_pulse = 12;
+			nbpos[0] = 4;
+			nbpos[1] = 6;
+			nbpos[2] = 8;
+			nbpos[3] = 8;
 			break;
 		case 64:                               /* 64 bits, 16 pulses, 4 tracks */
 			nbiter = 3;                          /* 3x36x16=1728 loop */
 			alp = 3277;                          /* alp = 0.8 (Q12) */
-			nb_pulse = 16;                     
-			nbpos[0] = 4;                      
-			nbpos[1] = 4;                      
-			nbpos[2] = 6;                      
-			nbpos[3] = 6;                      
-			nbpos[4] = 8;                      
-			nbpos[5] = 8;                      
+			nb_pulse = 16;
+			nbpos[0] = 4;
+			nbpos[1] = 4;
+			nbpos[2] = 6;
+			nbpos[3] = 6;
+			nbpos[4] = 8;
+			nbpos[5] = 8;
 			break;
 		case 72:                               /* 72 bits, 18 pulses, 4 tracks */
 			nbiter = 3;                          /* 3x35x16=1680 loop */
 			alp = 3072;                          /* alp = 0.75 (Q12) */
-			nb_pulse = 18;                     
-			nbpos[0] = 2;                      
-			nbpos[1] = 3;                      
-			nbpos[2] = 4;                      
-			nbpos[3] = 5;                      
-			nbpos[4] = 6;                      
-			nbpos[5] = 7;                      
-			nbpos[6] = 8;                      
+			nb_pulse = 18;
+			nbpos[0] = 2;
+			nbpos[1] = 3;
+			nbpos[2] = 4;
+			nbpos[3] = 5;
+			nbpos[4] = 6;
+			nbpos[5] = 7;
+			nbpos[6] = 8;
 			break;
 		case 88:                               /* 88 bits, 24 pulses, 4 tracks */
 			if(ser_size > 462)
@@ -211,17 +211,17 @@
 				nbiter = 2;                    /* 2x53x16=1696 loop */
 
 			alp = 2048;                          /* alp = 0.5 (Q12) */
-			nb_pulse = 24;                     
-			nbpos[0] = 2;                      
-			nbpos[1] = 2;                      
-			nbpos[2] = 3;                      
-			nbpos[3] = 4;                      
-			nbpos[4] = 5;                      
-			nbpos[5] = 6;                      
-			nbpos[6] = 7;                      
-			nbpos[7] = 8;                      
-			nbpos[8] = 8;                      
-			nbpos[9] = 8;                      
+			nb_pulse = 24;
+			nbpos[0] = 2;
+			nbpos[1] = 2;
+			nbpos[2] = 3;
+			nbpos[3] = 4;
+			nbpos[4] = 5;
+			nbpos[5] = 6;
+			nbpos[6] = 7;
+			nbpos[7] = 8;
+			nbpos[8] = 8;
+			nbpos[9] = 8;
 			break;
 		default:
 			nbiter = 0;
@@ -231,7 +231,7 @@
 
 	for (i = 0; i < nb_pulse; i++)
 	{
-		codvec[i] = i;                     
+		codvec[i] = i;
 	}
 
 	/*----------------------------------------------------------------*
@@ -246,7 +246,7 @@
 #endif
 
 	Isqrt_n(&s, &exp);
-	s = L_shl(s, (exp + 5)); 
+	s = L_shl(s, (exp + 5));
 	k_cn = extract_h(L_add(s, 0x8000));
 
 	/* set k_dn = 32..512 (ener_dn = 2^30..2^22) */
@@ -274,22 +274,22 @@
 		s = (k_cn* (*p0++))+(k_dn * (*p1++));
 		*p2++ = s >> 7;
 		s = (k_cn* (*p0++))+(k_dn * (*p1++));
-		*p2++ = s >> 7; 
+		*p2++ = s >> 7;
 	}
 
 	/* set sign according to dn2[] = k_cn*cn[] + k_dn*dn[]    */
 	for(i = 0; i < L_SUBFR; i++)
 	{
-		val = dn[i];                   
-		ps = dn2[i];                   
+		val = dn[i];
+		ps = dn2[i];
 		if (ps >= 0)
 		{
 			sign[i] = 32767;             /* sign = +1 (Q12) */
-			vec[i] = -32768;           
+			vec[i] = -32768;
 		} else
 		{
 			sign[i] = -32768;            /* sign = -1 (Q12) */
-			vec[i] = 32767;            
+			vec[i] = 32767;
 			dn[i] = -val;
 			dn2[i] = -ps;
 		}
@@ -302,19 +302,19 @@
 	{
 		for (k = 0; k < NB_MAX; k++)
 		{
-			ps = -1;                       
+			ps = -1;
 			for (j = i; j < L_SUBFR; j += STEP)
 			{
 				if(dn2[j] > ps)
 				{
-					ps = dn2[j];          
-					pos = j;               
+					ps = dn2[j];
+					pos = j;
 				}
 			}
 			dn2[pos] = (k - NB_MAX);     /* dn2 < 0 when position is selected */
 			if (k == 0)
 			{
-				pos_max[i] = pos;          
+				pos_max[i] = pos;
 			}
 		}
 	}
@@ -335,22 +335,22 @@
 
 	/* impulse response buffer for fast computation */
 
-	h = h_buf;                             
-	h_inv = h_buf + (2 * L_SUBFR);   
+	h = h_buf;
+	h_inv = h_buf + (2 * L_SUBFR);
 	L_tmp = 0;
 	for (i = 0; i < L_SUBFR; i++)
 	{
-		*h++ = 0;                          
-		*h_inv++ = 0;   
+		*h++ = 0;
+		*h_inv++ = 0;
 		L_tmp += (H[i] * H[i]) << 1;
 	}
 	/* scale h[] down (/2) when energy of h[] is high with many pulses used */
 	val = extract_h(L_tmp);
-	h_shift = 0;                           
+	h_shift = 0;
 
 	if ((nb_pulse >= 12) && (val > 1024))
 	{
-		h_shift = 1;                       
+		h_shift = 1;
 	}
 	p0 = H;
 	p1 = h;
@@ -358,14 +358,14 @@
 
 	for (i = 0; i < L_SUBFR/4; i++)
 	{
-		*p1 = *p0++ >> h_shift;         
-		*p2++ = -(*p1++);  
-		*p1 = *p0++ >> h_shift;         
-		*p2++ = -(*p1++); 
-		*p1 = *p0++ >> h_shift;         
-		*p2++ = -(*p1++); 
-		*p1 = *p0++ >> h_shift;         
-		*p2++ = -(*p1++); 
+		*p1 = *p0++ >> h_shift;
+		*p2++ = -(*p1++);
+		*p1 = *p0++ >> h_shift;
+		*p2++ = -(*p1++);
+		*p1 = *p0++ >> h_shift;
+		*p2++ = -(*p1++);
+		*p1 = *p0++ >> h_shift;
+		*p2++ = -(*p1++);
 	}
 
 	/*------------------------------------------------------------*
@@ -377,27 +377,27 @@
 	/* storage order --> i3i3, i2i2, i1i1, i0i0 */
 
 	/* Init pointers to last position of rrixix[] */
-	p0 = &rrixix[0][NB_POS - 1];           
-	p1 = &rrixix[1][NB_POS - 1];           
-	p2 = &rrixix[2][NB_POS - 1];           
-	p3 = &rrixix[3][NB_POS - 1];           
+	p0 = &rrixix[0][NB_POS - 1];
+	p1 = &rrixix[1][NB_POS - 1];
+	p2 = &rrixix[2][NB_POS - 1];
+	p3 = &rrixix[3][NB_POS - 1];
 
-	ptr_h1 = h;                            
+	ptr_h1 = h;
 	cor = 0x00008000L;                             /* for rounding */
 	for (i = 0; i < NB_POS; i++)
 	{
 		cor += vo_L_mult((*ptr_h1), (*ptr_h1));
 		ptr_h1++;
-		*p3-- = extract_h(cor);            
+		*p3-- = extract_h(cor);
 		cor += vo_L_mult((*ptr_h1), (*ptr_h1));
 		ptr_h1++;
-		*p2-- = extract_h(cor);            
+		*p2-- = extract_h(cor);
 		cor += vo_L_mult((*ptr_h1), (*ptr_h1));
 		ptr_h1++;
-		*p1-- = extract_h(cor);            
+		*p1-- = extract_h(cor);
 		cor += vo_L_mult((*ptr_h1), (*ptr_h1));
 		ptr_h1++;
-		*p0-- = extract_h(cor);            
+		*p0-- = extract_h(cor);
 	}
 
 	/*------------------------------------------------------------*
@@ -409,38 +409,38 @@
 
 	/* storage order --> i2i3, i1i2, i0i1, i3i0 */
 
-	pos = MSIZE - 1;                       
-	ptr_hf = h + 1;                        
+	pos = MSIZE - 1;
+	ptr_hf = h + 1;
 
 	for (k = 0; k < NB_POS; k++)
 	{
-		p3 = &rrixiy[2][pos];              
-		p2 = &rrixiy[1][pos];              
-		p1 = &rrixiy[0][pos];              
-		p0 = &rrixiy[3][pos - NB_POS];     
+		p3 = &rrixiy[2][pos];
+		p2 = &rrixiy[1][pos];
+		p1 = &rrixiy[0][pos];
+		p0 = &rrixiy[3][pos - NB_POS];
 
 		cor = 0x00008000L;                   /* for rounding */
-		ptr_h1 = h;                        
-		ptr_h2 = ptr_hf;                   
+		ptr_h1 = h;
+		ptr_h2 = ptr_hf;
 
 		for (i = k + 1; i < NB_POS; i++)
 		{
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p3 = extract_h(cor);          
+			*p3 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p2 = extract_h(cor);          
+			*p2 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p1 = extract_h(cor);          
+			*p1 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p0 = extract_h(cor);         
+			*p0 = extract_h(cor);
 
 			p3 -= (NB_POS + 1);
 			p2 -= (NB_POS + 1);
@@ -450,15 +450,15 @@
 		cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 		ptr_h1++;
 		ptr_h2++;
-		*p3 = extract_h(cor);              
+		*p3 = extract_h(cor);
 		cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 		ptr_h1++;
 		ptr_h2++;
-		*p2 = extract_h(cor);              
+		*p2 = extract_h(cor);
 		cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 		ptr_h1++;
 		ptr_h2++;
-		*p1 = extract_h(cor);              
+		*p1 = extract_h(cor);
 
 		pos -= NB_POS;
 		ptr_hf += STEP;
@@ -466,38 +466,38 @@
 
 	/* storage order --> i3i0, i2i3, i1i2, i0i1 */
 
-	pos = MSIZE - 1;                       
-	ptr_hf = h + 3;                        
+	pos = MSIZE - 1;
+	ptr_hf = h + 3;
 
 	for (k = 0; k < NB_POS; k++)
 	{
-		p3 = &rrixiy[3][pos];              
-		p2 = &rrixiy[2][pos - 1];          
-		p1 = &rrixiy[1][pos - 1];          
-		p0 = &rrixiy[0][pos - 1];          
+		p3 = &rrixiy[3][pos];
+		p2 = &rrixiy[2][pos - 1];
+		p1 = &rrixiy[1][pos - 1];
+		p0 = &rrixiy[0][pos - 1];
 
 		cor = 0x00008000L;								/* for rounding */
-		ptr_h1 = h;                        
-		ptr_h2 = ptr_hf;                   
+		ptr_h1 = h;
+		ptr_h2 = ptr_hf;
 
 		for (i = k + 1; i < NB_POS; i++)
 		{
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p3 = extract_h(cor);          
+			*p3 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p2 = extract_h(cor);          
+			*p2 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p1 = extract_h(cor);          
+			*p1 = extract_h(cor);
 			cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 			ptr_h1++;
 			ptr_h2++;
-			*p0 = extract_h(cor);          
+			*p0 = extract_h(cor);
 
 			p3 -= (NB_POS + 1);
 			p2 -= (NB_POS + 1);
@@ -507,7 +507,7 @@
 		cor += vo_L_mult((*ptr_h1), (*ptr_h2));
 		ptr_h1++;
 		ptr_h2++;
-		*p3 = extract_h(cor);              
+		*p3 = extract_h(cor);
 
 		pos--;
 		ptr_hf += STEP;
@@ -517,22 +517,22 @@
 	 * Modification of rrixiy[][] to take signs into account.     *
 	 *------------------------------------------------------------*/
 
-	p0 = &rrixiy[0][0];                    
+	p0 = &rrixiy[0][0];
 
 	for (k = 0; k < NB_TRACK; k++)
 	{
 		j_temp = (k + 1)&0x03;
 		for (i = k; i < L_SUBFR; i += STEP)
 		{
-			psign = sign;                  
+			psign = sign;
 			if (psign[i] < 0)
 			{
-				psign = vec;               
+				psign = vec;
 			}
 			j = j_temp;
 			for (; j < L_SUBFR; j += STEP)
 			{
-				*p0 = vo_mult(*p0, psign[j]);    
+				*p0 = vo_mult(*p0, psign[j]);
 				p0++;
 			}
 		}
@@ -542,8 +542,8 @@
 	 *                       Deep first search                           *
 	 *-------------------------------------------------------------------*/
 
-	psk = -1;                              
-	alpk = 1;                              
+	psk = -1;
+	alpk = 1;
 
 	for (k = 0; k < nbiter; k++)
 	{
@@ -553,12 +553,12 @@
 
 		if(nbbits == 20)
 		{
-			pos = 0;                       
-			ps = 0;                        
-			alp = 0;                       
+			pos = 0;
+			ps = 0;
+			alp = 0;
 			for (i = 0; i < L_SUBFR; i++)
 			{
-				vec[i] = 0;                
+				vec[i] = 0;
 			}
 		} else if ((nbbits == 36) || (nbbits == 44))
 		{
@@ -591,18 +591,18 @@
 
 			if(nbbits == 44)
 			{
-				ipos[8] = 0;               
-				ipos[9] = 1;               
+				ipos[8] = 0;
+				ipos[9] = 1;
 			}
 		} else
 		{
 			/* first stage: fix 4 pulses */
 			pos = 4;
 
-			ix = ind[0] = pos_max[ipos[0]];  
-			iy = ind[1] = pos_max[ipos[1]];  
-			i = ind[2] = pos_max[ipos[2]];   
-			j = ind[3] = pos_max[ipos[3]];   
+			ix = ind[0] = pos_max[ipos[0]];
+			iy = ind[1] = pos_max[ipos[1]];
+			i = ind[2] = pos_max[ipos[2]];
+			j = ind[3] = pos_max[ipos[3]];
 			ps = add1(add1(add1(dn[ix], dn[iy]), dn[i]), dn[j]);
 
 			if (sign[ix] < 0)
@@ -636,8 +636,8 @@
 
 			if(nbbits == 72)
 			{
-				ipos[16] = 0;              
-				ipos[17] = 1;              
+				ipos[16] = 0;
+				ipos[17] = 1;
 			}
 		}
 
@@ -668,8 +668,8 @@
 			search_ixiy(nbpos[st], ipos[j], ipos[j + 1], &ps, &alp,
 					&ix, &iy, dn, dn2, cor_x, cor_y, rrixiy);
 
-			ind[j] = ix;                   
-			ind[j + 1] = iy;               
+			ind[j] = ix;
+			ind[j + 1] = iy;
 
 			if (sign[ix] < 0)
 				p0 = h_inv - ix;
@@ -682,10 +682,10 @@
 
 			for (i = 0; i < L_SUBFR; i+=4)
 			{
-				vec[i]   += add1((*p0++), (*p1++));       
-				vec[i+1] += add1((*p0++), (*p1++));        
-				vec[i+2] += add1((*p0++), (*p1++));        
-				vec[i+3] += add1((*p0++), (*p1++));      
+				vec[i]   += add1((*p0++), (*p1++));
+				vec[i+1] += add1((*p0++), (*p1++));
+				vec[i+2] += add1((*p0++), (*p1++));
+				vec[i+3] += add1((*p0++), (*p1++));
 			}
 		}
 		/* memorise the best codevector */
@@ -693,15 +693,15 @@
 		s = vo_L_msu(vo_L_mult(alpk, ps), psk, alp);
 		if (s > 0)
 		{
-			psk = ps;                      
-			alpk = alp;                    
+			psk = ps;
+			alpk = alp;
 			for (i = 0; i < nb_pulse; i++)
 			{
-				codvec[i] = ind[i];        
+				codvec[i] = ind[i];
 			}
 			for (i = 0; i < L_SUBFR; i++)
 			{
-				y[i] = vec[i];             
+				y[i] = vec[i];
 			}
 		}
 	}
@@ -710,11 +710,11 @@
 	 *-------------------------------------------------------------------*/
 	for (i = 0; i < NPMAXPT * NB_TRACK; i++)
 	{
-		ind[i] = -1;                       
+		ind[i] = -1;
 	}
 	for (i = 0; i < L_SUBFR; i++)
 	{
-		code[i] = 0;                       
+		code[i] = 0;
 		y[i] = vo_shr_r(y[i], 3);               /* Q12 to Q9 */
 	}
 	val = (512 >> h_shift);               /* codeword in Q9 format */
@@ -727,12 +727,12 @@
 
 		if (j > 0)
 		{
-			code[i] += val;   
-			codvec[k] += 128;  
+			code[i] += val;
+			codvec[k] += 128;
 		} else
 		{
-			code[i] -= val;   
-			index += NB_POS;    
+			code[i] -= val;
+			index += NB_POS;
 		}
 
 		i = (Word16)((vo_L_mult(track, NPMAXPT) >> 1));
@@ -741,10 +741,10 @@
 		{
 			i += 1;
 		}
-		ind[i] = index;                    
+		ind[i] = index;
 	}
 
-	k = 0;                                 
+	k = 0;
 	/* Build index of codevector */
 	if(nbbits == 20)
 	{
@@ -849,20 +849,20 @@
 		p2 = &vec[pos];
 		for (j=pos;j < L_SUBFR; j++)
 		{
-			L_sum1 += *p1 * *p2;		
+			L_sum1 += *p1 * *p2;
 			p2-=3;
-			L_sum2 += *p1++ * *p2;		
+			L_sum2 += *p1++ * *p2;
 			p2+=4;
 		}
 		p2-=3;
-		L_sum2 += *p1++ * *p2++;	
-		L_sum2 += *p1++ * *p2++;	
-		L_sum2 += *p1++ * *p2++;	
+		L_sum2 += *p1++ * *p2++;
+		L_sum2 += *p1++ * *p2++;
+		L_sum2 += *p1++ * *p2++;
 
 		L_sum1 = (L_sum1 << 2);
 		L_sum2 = (L_sum2 << 2);
 
-		corr = vo_round(L_sum1);	
+		corr = vo_round(L_sum1);
 		*cor_x++ = vo_mult(corr, sign[pos]) + (*p0++);
 		corr = vo_round(L_sum2);
 		*cor_y++ = vo_mult(corr, sign[pos-3]) + (*p3++);
@@ -873,20 +873,20 @@
 		p2 = &vec[pos];
 		for (j=pos;j < L_SUBFR; j++)
 		{
-			L_sum1 += *p1 * *p2;		
+			L_sum1 += *p1 * *p2;
 			p2-=3;
-			L_sum2 += *p1++ * *p2;		
+			L_sum2 += *p1++ * *p2;
 			p2+=4;
 		}
 		p2-=3;
-		L_sum2 += *p1++ * *p2++;	
-		L_sum2 += *p1++ * *p2++;	
-		L_sum2 += *p1++ * *p2++;	
+		L_sum2 += *p1++ * *p2++;
+		L_sum2 += *p1++ * *p2++;
+		L_sum2 += *p1++ * *p2++;
 
 		L_sum1 = (L_sum1 << 2);
 		L_sum2 = (L_sum2 << 2);
 
-		corr = vo_round(L_sum1);	
+		corr = vo_round(L_sum1);
 		*cor_x++ = vo_mult(corr, sign[pos]) + (*p0++);
 		corr = vo_round(L_sum2);
 		*cor_y++ = vo_mult(corr, sign[pos-3]) + (*p3++);
@@ -982,17 +982,17 @@
 	Word16 *p0, *p1, *p2;
 	Word32 s, alp0, alp1, alp2;
 
-	p0 = cor_x;                            
-	p1 = cor_y;                            
-	p2 = rrixiy[track_x];                  
+	p0 = cor_x;
+	p1 = cor_y;
+	p2 = rrixiy[track_x];
 
 	thres_ix = nb_pos_ix - NB_MAX;
 
 	alp0 = L_deposit_h(*alp);
 	alp0 = (alp0 + 0x00008000L);       /* for rounding */
 
-	sqk = -1;                              
-	alpk = 1;                              
+	sqk = -1;
+	alpk = 1;
 
 	for (x = track_x; x < L_SUBFR; x += STEP)
 	{
@@ -1014,17 +1014,17 @@
 
 				if (s > 0)
 				{
-					sqk = sq;              
-					alpk = alp_16;         
-					pos = y;               
+					sqk = sq;
+					alpk = alp_16;
+					pos = y;
 				}
 			}
 			p1 -= NB_POS;
 
 			if (pos >= 0)
 			{
-				*ix = x;                   
-				*iy = pos;                 
+				*ix = x;
+				*iy = pos;
 			}
 		} else
 		{
@@ -1032,8 +1032,8 @@
 		}
 	}
 
-	*ps = add1(*ps, add1(dn[*ix], dn[*iy])); 
-	*alp = alpk;                           
+	*ps = add1(*ps, add1(dn[*ix], dn[*iy]));
+	*alp = alpk;
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/convolve.c b/media/libstagefright/codecs/amrwbenc/src/convolve.c
index 4f7fd8a..acba532 100644
--- a/media/libstagefright/codecs/amrwbenc/src/convolve.c
+++ b/media/libstagefright/codecs/amrwbenc/src/convolve.c
@@ -49,7 +49,7 @@
 			s += vo_mult32((*tmpX++), (*tmpH--));
 			i -= 4;
 		}
-		y[n] = ((s<<1) + 0x8000)>>16;   
+		y[n] = ((s<<1) + 0x8000)>>16;
 		n++;
 
 		tmpH = h+n;
@@ -66,7 +66,7 @@
 			s += vo_mult32((*tmpX++), (*tmpH--));
 			i -= 4;
 		}
-		y[n] = ((s<<1) + 0x8000)>>16;    
+		y[n] = ((s<<1) + 0x8000)>>16;
 		n++;
 
 		tmpH = h+n;
@@ -84,7 +84,7 @@
 			s += vo_mult32((*tmpX++), (*tmpH--));
 			i -= 4;
 		}
-		y[n] = ((s<<1) + 0x8000)>>16;   
+		y[n] = ((s<<1) + 0x8000)>>16;
 		n++;
 
 		s = 0;
@@ -99,8 +99,8 @@
 			s += vo_mult32((*tmpX++), (*tmpH--));
 			i -= 4;
 		}
-		y[n] = ((s<<1) + 0x8000)>>16;   
-		n++;        
+		y[n] = ((s<<1) + 0x8000)>>16;
+		n++;
 	}
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/cor_h_x.c b/media/libstagefright/codecs/amrwbenc/src/cor_h_x.c
index b645fa3..d9245ed 100644
--- a/media/libstagefright/codecs/amrwbenc/src/cor_h_x.c
+++ b/media/libstagefright/codecs/amrwbenc/src/cor_h_x.c
@@ -18,7 +18,7 @@
 *       File: cor_h_x.c                                                *
 *                                                                      *
 *	   Description:Compute correlation between target "x[]" and "h[]"  *
-*	               Designed for codebook search (24 pulses, 4 tracks,  * 
+*	               Designed for codebook search (24 pulses, 4 tracks,  *
 *				   4 pulses per track, 16 positions in each track) to  *
 *				   avoid saturation.                                   *
 *                                                                      *
@@ -44,8 +44,8 @@
 	Word32 *p3;
 	Word32 L_max, L_max1, L_max2, L_max3;
 	/* first keep the result on 32 bits and find absolute maximum */
-	L_tot  = 1;                            
-	L_max  = 0; 
+	L_tot  = 1;
+	L_max  = 0;
 	L_max1 = 0;
 	L_max2 = 0;
 	L_max3 = 0;
@@ -57,11 +57,11 @@
 		for (j = i; j < L_SUBFR; j++)
 			L_tmp += vo_L_mult(*p1++, *p2++);
 
-		y32[i] = L_tmp;               
+		y32[i] = L_tmp;
 		L_tmp = (L_tmp > 0)? L_tmp:-L_tmp;
 		if(L_tmp > L_max)
 		{
-			L_max = L_tmp;             
+			L_max = L_tmp;
 		}
 
 		L_tmp = 1L;
@@ -70,11 +70,11 @@
 		for (j = i+1; j < L_SUBFR; j++)
 			L_tmp += vo_L_mult(*p1++, *p2++);
 
-		y32[i+1] = L_tmp;               
+		y32[i+1] = L_tmp;
 		L_tmp = (L_tmp > 0)? L_tmp:-L_tmp;
 		if(L_tmp > L_max1)
 		{
-			L_max1 = L_tmp;             
+			L_max1 = L_tmp;
 		}
 
 		L_tmp = 1;
@@ -83,11 +83,11 @@
 		for (j = i+2; j < L_SUBFR; j++)
 			L_tmp += vo_L_mult(*p1++, *p2++);
 
-		y32[i+2] = L_tmp;               
+		y32[i+2] = L_tmp;
 		L_tmp = (L_tmp > 0)? L_tmp:-L_tmp;
 		if(L_tmp > L_max2)
 		{
-			L_max2 = L_tmp;             
+			L_max2 = L_tmp;
 		}
 
 		L_tmp = 1;
@@ -96,11 +96,11 @@
 		for (j = i+3; j < L_SUBFR; j++)
 			L_tmp += vo_L_mult(*p1++, *p2++);
 
-		y32[i+3] = L_tmp;               
+		y32[i+3] = L_tmp;
 		L_tmp = (L_tmp > 0)? L_tmp:-L_tmp;
 		if(L_tmp > L_max3)
 		{
-			L_max3 = L_tmp;             
+			L_max3 = L_tmp;
 		}
 	}
 	/* tot += 3*max / 8 */
diff --git a/media/libstagefright/codecs/amrwbenc/src/decim54.c b/media/libstagefright/codecs/amrwbenc/src/decim54.c
index 7bc5576..3b88514 100644
--- a/media/libstagefright/codecs/amrwbenc/src/decim54.c
+++ b/media/libstagefright/codecs/amrwbenc/src/decim54.c
@@ -136,8 +136,8 @@
 		L_sum += vo_mult32((*x++),(*y++));
 		L_sum += vo_mult32((*x),(*y));
 
-		L_sum = L_shl2(L_sum, 2);              
-		sig_d[j] = extract_h(L_add(L_sum, 0x8000)); 
+		L_sum = L_shl2(L_sum, 2);
+		sig_d[j] = extract_h(L_add(L_sum, 0x8000));
 		pos += FAC5;              /* pos + 5/4 */
 	}
 	return;
diff --git a/media/libstagefright/codecs/amrwbenc/src/deemph.c b/media/libstagefright/codecs/amrwbenc/src/deemph.c
index 4ee1449..0c49d6b 100644
--- a/media/libstagefright/codecs/amrwbenc/src/deemph.c
+++ b/media/libstagefright/codecs/amrwbenc/src/deemph.c
@@ -39,16 +39,16 @@
 
 	L_tmp = L_deposit_h(x[0]);
 	L_tmp = L_mac(L_tmp, *mem, mu);
-	x[0] = vo_round(L_tmp);                   
+	x[0] = vo_round(L_tmp);
 
 	for (i = 1; i < L; i++)
 	{
 		L_tmp = L_deposit_h(x[i]);
 		L_tmp = L_mac(L_tmp, x[i - 1], mu);
-		x[i] = voround(L_tmp);               
+		x[i] = voround(L_tmp);
 	}
 
-	*mem = x[L - 1];                       
+	*mem = x[L - 1];
 
 	return;
 }
@@ -65,14 +65,14 @@
 	Word32 L_tmp;
 	L_tmp = x[0] << 15;
 	L_tmp += ((*mem) * mu)<<1;
-	x[0] = (L_tmp + 0x8000)>>16;                   
+	x[0] = (L_tmp + 0x8000)>>16;
 	for (i = 1; i < L; i++)
 	{
 		L_tmp = x[i] << 15;
 		L_tmp += (x[i - 1] * mu)<<1;
-		x[i] = (L_tmp + 0x8000)>>16;               
+		x[i] = (L_tmp + 0x8000)>>16;
 	}
-	*mem = x[L - 1];                       
+	*mem = x[L - 1];
 	return;
 }
 
@@ -95,8 +95,8 @@
 	L_tmp += (x_lo[0] * 8)<<1;
 	L_tmp = (L_tmp << 3);
 	L_tmp += ((*mem) * fac)<<1;
-	L_tmp = (L_tmp << 1);               
-	y[0] = (L_tmp + 0x8000)>>16;                  
+	L_tmp = (L_tmp << 1);
+	y[0] = (L_tmp + 0x8000)>>16;
 
 	for (i = 1; i < L; i++)
 	{
@@ -104,11 +104,11 @@
 		L_tmp += (x_lo[i] * 8)<<1;
 		L_tmp = (L_tmp << 3);
 		L_tmp += (y[i - 1] * fac)<<1;
-		L_tmp = (L_tmp << 1);           
-		y[i] = (L_tmp + 0x8000)>>16;               
+		L_tmp = (L_tmp << 1);
+		y[i] = (L_tmp + 0x8000)>>16;
 	}
 
-	*mem = y[L - 1];                       
+	*mem = y[L - 1];
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/dtx.c b/media/libstagefright/codecs/amrwbenc/src/dtx.c
index df53131..2cfaced 100644
--- a/media/libstagefright/codecs/amrwbenc/src/dtx.c
+++ b/media/libstagefright/codecs/amrwbenc/src/dtx.c
@@ -105,30 +105,30 @@
 		fprintf(stderr, "dtx_enc_reset: invalid parameter\n");
 		return -1;
 	}
-	st->hist_ptr = 0;                      
-	st->log_en_index = 0;                  
+	st->hist_ptr = 0;
+	st->log_en_index = 0;
 
 	/* Init isf_hist[] */
 	for (i = 0; i < DTX_HIST_SIZE; i++)
 	{
 		Copy(isf_init, &st->isf_hist[i * M], M);
 	}
-	st->cng_seed = RANDOM_INITSEED;       
+	st->cng_seed = RANDOM_INITSEED;
 
 	/* Reset energy history */
 	Set_zero(st->log_en_hist, DTX_HIST_SIZE);
 
-	st->dtxHangoverCount = DTX_HANG_CONST; 
-	st->decAnaElapsedCount = 32767;        
+	st->dtxHangoverCount = DTX_HANG_CONST;
+	st->decAnaElapsedCount = 32767;
 
 	for (i = 0; i < 28; i++)
 	{
-		st->D[i] = 0;                      
+		st->D[i] = 0;
 	}
 
 	for (i = 0; i < DTX_HIST_SIZE - 1; i++)
 	{
-		st->sumD[i] = 0;                   
+		st->sumD[i] = 0;
 	}
 
 	return 1;
@@ -279,7 +279,7 @@
 	for (i = 0; i < L_FRAME; i++)
 	{
 		tmp = mult(exc2[i], gain);         /* Q0 * Q15 */
-		exc2[i] = shl(tmp, exp); 
+		exc2[i] = shl(tmp, exp);
 	}
 
 	return 0;
@@ -301,7 +301,7 @@
 
 	Word16 log_en_e;
 	Word16 log_en_m;
-	st->hist_ptr = add(st->hist_ptr, 1); 
+	st->hist_ptr = add(st->hist_ptr, 1);
 	if(st->hist_ptr == DTX_HIST_SIZE)
 	{
 		st->hist_ptr = 0;
@@ -345,7 +345,7 @@
 {
 
 	/* this state machine is in synch with the GSMEFR txDtx machine      */
-	st->decAnaElapsedCount = add(st->decAnaElapsedCount, 1); 
+	st->decAnaElapsedCount = add(st->decAnaElapsedCount, 1);
 
 	if (vad_flag != 0)
 	{
@@ -354,8 +354,8 @@
 	{                                      /* non-speech */
 		if (st->dtxHangoverCount == 0)
 		{                                  /* out of decoder analysis hangover  */
-			st->decAnaElapsedCount = 0;    
-			*usedMode = MRDTX;            
+			st->decAnaElapsedCount = 0;
+			*usedMode = MRDTX;
 		} else
 		{                                  /* in possible analysis hangover */
 			st->dtxHangoverCount = sub(st->dtxHangoverCount, 1);
@@ -394,8 +394,8 @@
 		{
 			for (i = 0; i < M; i++)
 			{
-				isf_tmp[k * M + i] = isf_old[indices[k] * M + i];      
-				isf_old[indices[k] * M + i] = isf_old[indices[2] * M + i];    
+				isf_tmp[k * M + i] = isf_old[indices[k] * M + i];
+				isf_old[indices[k] * M + i] = isf_old[indices[2] * M + i];
 			}
 		}
 	}
@@ -403,13 +403,13 @@
 	/* Perform the ISF averaging */
 	for (j = 0; j < M; j++)
 	{
-		L_tmp = 0;                      
+		L_tmp = 0;
 
 		for (i = 0; i < DTX_HIST_SIZE; i++)
 		{
 			L_tmp = L_add(L_tmp, L_deposit_l(isf_old[i * M + j]));
 		}
-		isf_aver[j] = L_tmp;              
+		isf_aver[j] = L_tmp;
 	}
 
 	/* Retrieve from isf_tmp[][] the ISF vectors saved prior to averaging */
@@ -441,12 +441,12 @@
 	/* sum sumD[0..DTX_HIST_SIZE-1]. sumD[DTX_HIST_SIZE] is    */
 	/* not updated since it will be removed later.           */
 
-	tmp = DTX_HIST_SIZE_MIN_ONE;           
-	j = -1;                                
+	tmp = DTX_HIST_SIZE_MIN_ONE;
+	j = -1;
 	for (i = 0; i < DTX_HIST_SIZE_MIN_ONE; i++)
 	{
 		j = add(j, tmp);
-		st->sumD[i] = L_sub(st->sumD[i], st->D[j]);     
+		st->sumD[i] = L_sub(st->sumD[i], st->D[j]);
 		tmp = sub(tmp, 1);
 	}
 
@@ -458,86 +458,86 @@
 
 	for (i = DTX_HIST_SIZE_MIN_ONE; i > 0; i--)
 	{
-		st->sumD[i] = st->sumD[i - 1];     
+		st->sumD[i] = st->sumD[i - 1];
 	}
-	st->sumD[0] = 0;                       
+	st->sumD[0] = 0;
 
 	/* Remove the oldest frame from the distance matrix.           */
 	/* Note that the distance matrix is replaced by a one-         */
 	/* dimensional array to save static memory.                    */
 
-	tmp = 0;                               
+	tmp = 0;
 	for (i = 27; i >= 12; i = (Word16) (i - tmp))
 	{
 		tmp = add(tmp, 1);
 		for (j = tmp; j > 0; j--)
 		{
-			st->D[i - j + 1] = st->D[i - j - tmp];   
+			st->D[i - j + 1] = st->D[i - j - tmp];
 		}
 	}
 
 	/* Compute the first column of the distance matrix D            */
 	/* (squared Euclidean distances from isf1[] to isf_old_tx[][]). */
 
-	ptr = st->hist_ptr;                 
+	ptr = st->hist_ptr;
 	for (i = 1; i < DTX_HIST_SIZE; i++)
 	{
 		/* Compute the distance between the latest isf and the other isfs. */
 		ptr = sub(ptr, 1);
 		if (ptr < 0)
 		{
-			ptr = DTX_HIST_SIZE_MIN_ONE;   
+			ptr = DTX_HIST_SIZE_MIN_ONE;
 		}
-		L_tmp = 0;                         
+		L_tmp = 0;
 		for (j = 0; j < M; j++)
 		{
 			tmp = sub(isf_old_tx[st->hist_ptr * M + j], isf_old_tx[ptr * M + j]);
 			L_tmp = L_mac(L_tmp, tmp, tmp);
 		}
-		st->D[i - 1] = L_tmp;           
+		st->D[i - 1] = L_tmp;
 
 		/* Update also the column sums. */
-		st->sumD[0] = L_add(st->sumD[0], st->D[i - 1]); 
-		st->sumD[i] = L_add(st->sumD[i], st->D[i - 1]); 
+		st->sumD[0] = L_add(st->sumD[0], st->D[i - 1]);
+		st->sumD[i] = L_add(st->sumD[i], st->D[i - 1]);
 	}
 
 	/* Find the minimum and maximum distances */
-	summax = st->sumD[0];                  
-	summin = st->sumD[0];                  
-	indices[0] = 0;                        
-	indices[2] = 0;                        
+	summax = st->sumD[0];
+	summin = st->sumD[0];
+	indices[0] = 0;
+	indices[2] = 0;
 	for (i = 1; i < DTX_HIST_SIZE; i++)
 	{
 		if (L_sub(st->sumD[i], summax) > 0)
 		{
-			indices[0] = i;                
-			summax = st->sumD[i];          
+			indices[0] = i;
+			summax = st->sumD[i];
 		}
 		if (L_sub(st->sumD[i], summin) < 0)
 		{
-			indices[2] = i;                
-			summin = st->sumD[i];          
+			indices[2] = i;
+			summin = st->sumD[i];
 		}
 	}
 
 	/* Find the second largest distance */
-	summax2nd = -2147483647L;              
-	indices[1] = -1;                       
+	summax2nd = -2147483647L;
+	indices[1] = -1;
 	for (i = 0; i < DTX_HIST_SIZE; i++)
 	{
 		if ((L_sub(st->sumD[i], summax2nd) > 0) && (sub(i, indices[0]) != 0))
 		{
-			indices[1] = i;                
-			summax2nd = st->sumD[i];       
+			indices[1] = i;
+			summax2nd = st->sumD[i];
 		}
 	}
 
 	for (i = 0; i < 3; i++)
 	{
-		indices[i] = sub(st->hist_ptr, indices[i]);     
+		indices[i] = sub(st->hist_ptr, indices[i]);
 		if (indices[i] < 0)
 		{
-			indices[i] = add(indices[i], DTX_HIST_SIZE);       
+			indices[i] = add(indices[i], DTX_HIST_SIZE);
 		}
 	}
 
@@ -549,7 +549,7 @@
 	L_tmp = L_mult(voround(summax), INV_MED_THRESH);
 	if(L_tmp <= summin)
 	{
-		indices[0] = -1; 
+		indices[0] = -1;
 	}
 	/* If second largest distance/MED_THRESH is smaller than     */
 	/* minimum distance then the median ISF vector replacement is    */
@@ -558,7 +558,7 @@
 	L_tmp = L_mult(voround(summax2nd), INV_MED_THRESH);
 	if(L_tmp <= summin)
 	{
-		indices[1] = -1;                 
+		indices[1] = -1;
 	}
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/g_pitch.c b/media/libstagefright/codecs/amrwbenc/src/g_pitch.c
index f5112c5..d681f2e 100644
--- a/media/libstagefright/codecs/amrwbenc/src/g_pitch.c
+++ b/media/libstagefright/codecs/amrwbenc/src/g_pitch.c
@@ -48,10 +48,10 @@
 
 #endif
 
-	g_coeff[0] = yy;                       
-	g_coeff[1] = exp_yy;                   
-	g_coeff[2] = xy;                       
-	g_coeff[3] = exp_xy;                   
+	g_coeff[0] = yy;
+	g_coeff[1] = exp_yy;
+	g_coeff[2] = xy;
+	g_coeff[3] = exp_xy;
 
 	/* If (xy < 0) gain = 0 */
 	if (xy < 0)
@@ -65,12 +65,12 @@
 	i = exp_xy;
 	i -= exp_yy;
 
-	gain = shl(gain, i);                   
+	gain = shl(gain, i);
 
 	/* if (gain > 1.2) gain = 1.2  in Q14 */
 	if(gain > 19661)
 	{
-		gain = 19661;                      
+		gain = 19661;
 	}
 	return (gain);
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/gpclip.c b/media/libstagefright/codecs/amrwbenc/src/gpclip.c
index 24158e3..800b3f9 100644
--- a/media/libstagefright/codecs/amrwbenc/src/gpclip.c
+++ b/media/libstagefright/codecs/amrwbenc/src/gpclip.c
@@ -22,7 +22,7 @@
 *      case occurs                                                        *
 *      a resonance on LPC filter(lp_disp < 60Hz)                          *
 *      a good pitch prediction (lp_gp > 0.95)                             *
-*                                                                         *   
+*                                                                         *
 ***************************************************************************/
 #include "typedef.h"
 #include "basic_op.h"
@@ -38,8 +38,8 @@
 		Word16 mem[]                          /* (o) : memory of gain of pitch clipping algorithm */
 		)
 {
-	mem[0] = DIST_ISF_MAX;                 
-	mem[1] = GAIN_PIT_MIN;                 
+	mem[0] = DIST_ISF_MAX;
+	mem[1] = GAIN_PIT_MIN;
 }
 
 
@@ -49,7 +49,7 @@
 {
 	Word16 clip = 0;
 	if ((mem[0] < DIST_ISF_THRES) && (mem[1] > GAIN_PIT_THRES))
-		clip = 1;                          
+		clip = 1;
 
 	return (clip);
 }
@@ -70,7 +70,7 @@
 		dist = vo_sub(isf[i], isf[i - 1]);
 		if(dist < dist_min)
 		{
-			dist_min = dist;               
+			dist_min = dist;
 		}
 	}
 
@@ -78,9 +78,9 @@
 
 	if (dist > DIST_ISF_MAX)
 	{
-		dist = DIST_ISF_MAX;               
+		dist = DIST_ISF_MAX;
 	}
-	mem[0] = dist;                        
+	mem[0] = dist;
 
 	return;
 }
@@ -100,9 +100,9 @@
 
 	if(gain < GAIN_PIT_MIN)
 	{
-		gain = GAIN_PIT_MIN;              
+		gain = GAIN_PIT_MIN;
 	}
-	mem[1] = gain;                         
+	mem[1] = gain;
 	return;
 }
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/hp400.c b/media/libstagefright/codecs/amrwbenc/src/hp400.c
index fa66f1a..a6f9701 100644
--- a/media/libstagefright/codecs/amrwbenc/src/hp400.c
+++ b/media/libstagefright/codecs/amrwbenc/src/hp400.c
@@ -68,8 +68,8 @@
 	y2_lo = *mem++;
 	y1_hi = *mem++;
 	y1_lo = *mem++;
-	x0 = *mem++;   
-	x1 = *mem;   
+	x0 = *mem++;
+	x1 = *mem;
 	num = (Word32)lg;
 	do
 	{
@@ -98,7 +98,7 @@
 	*mem-- = y1_lo;
 	*mem-- = y1_hi;
 	*mem-- = y2_lo;
-	*mem   = y2_hi;  
+	*mem   = y2_hi;
 	return;
 }
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/hp50.c b/media/libstagefright/codecs/amrwbenc/src/hp50.c
index 36dd1f1..c1c7b83 100644
--- a/media/libstagefright/codecs/amrwbenc/src/hp50.c
+++ b/media/libstagefright/codecs/amrwbenc/src/hp50.c
@@ -70,7 +70,7 @@
 	y2_lo = *mem++;
 	y1_hi = *mem++;
 	y1_lo = *mem++;
-	x0 = *mem++;   
+	x0 = *mem++;
 	x1 = *mem;
 	num = (Word32)lg;
 	do
@@ -98,7 +98,7 @@
 	*mem-- = y1_lo;
 	*mem-- = y1_hi;
 	*mem-- = y2_lo;
-	*mem-- = y2_hi;  
+	*mem-- = y2_hi;
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/hp6k.c b/media/libstagefright/codecs/amrwbenc/src/hp6k.c
index 578633a..8e66eb0 100644
--- a/media/libstagefright/codecs/amrwbenc/src/hp6k.c
+++ b/media/libstagefright/codecs/amrwbenc/src/hp6k.c
@@ -20,7 +20,7 @@
 *	Description:15th order band pass 6kHz to 7kHz FIR filter        *
 *       frequency: 4kHz   5kHz  5.5kHz  6kHz  6.5kHz  7kHz 7.5kHz 8kHz  *
 *	dB loss:  -60dB  -45dB  -13dB   -3dB   0dB    -3dB -13dB  -45dB *
-*	                                                                *                                                                 
+*	                                                                *
 ************************************************************************/
 
 #include "typedef.h"
@@ -63,7 +63,7 @@
 	for (i = lg - 1; i >= 0; i--)
 	{
 		x[i + L_FIR - 1] = signal[i] >> 2;                         /* gain of filter = 4 */
-	}	
+	}
 	for (i = 0; i < lg; i++)
 	{
 		L_tmp =  (x[i] + x[i+ 30]) * fir_6k_7k[0];
diff --git a/media/libstagefright/codecs/amrwbenc/src/hp_wsp.c b/media/libstagefright/codecs/amrwbenc/src/hp_wsp.c
index 3510272..bc1ec49 100644
--- a/media/libstagefright/codecs/amrwbenc/src/hp_wsp.c
+++ b/media/libstagefright/codecs/amrwbenc/src/hp_wsp.c
@@ -88,22 +88,22 @@
 	Word16 y3_hi, y3_lo, y2_hi, y2_lo, y1_hi, y1_lo;
 	Word32 i, L_tmp;
 
-	y3_hi = mem[0];                        
-	y3_lo = mem[1];                        
-	y2_hi = mem[2];                        
-	y2_lo = mem[3];                        
-	y1_hi = mem[4];                        
-	y1_lo = mem[5];                        
-	x0 = mem[6];                           
-	x1 = mem[7];                           
-	x2 = mem[8];                           
+	y3_hi = mem[0];
+	y3_lo = mem[1];
+	y2_hi = mem[2];
+	y2_lo = mem[3];
+	y1_hi = mem[4];
+	y1_lo = mem[5];
+	x0 = mem[6];
+	x1 = mem[7];
+	x2 = mem[8];
 
 	for (i = 0; i < lg; i++)
 	{
-		x3 = x2;                           
-		x2 = x1;                           
-		x1 = x0;                           
-		x0 = wsp[i];                       
+		x3 = x2;
+		x2 = x1;
+		x1 = x0;
+		x0 = wsp[i];
 		/* y[i] = b[0]*x[i] + b[1]*x[i-1] + b140[2]*x[i-2] + b[3]*x[i-3]  */
 		/* + a[1]*y[i-1] + a[2] * y[i-2]  + a[3]*y[i-3]  */
 
@@ -122,25 +122,25 @@
 
 		L_tmp = L_tmp << 2;
 
-		y3_hi = y2_hi;                     
-		y3_lo = y2_lo;                     
-		y2_hi = y1_hi;                     
-		y2_lo = y1_lo; 
+		y3_hi = y2_hi;
+		y3_lo = y2_lo;
+		y2_hi = y1_hi;
+		y2_lo = y1_lo;
 		y1_hi = L_tmp >> 16;
 		y1_lo = (L_tmp & 0xffff) >>1;
 
-		hp_wsp[i] = (L_tmp + 0x4000)>>15;          
+		hp_wsp[i] = (L_tmp + 0x4000)>>15;
 	}
 
-	mem[0] = y3_hi;                        
-	mem[1] = y3_lo;                        
-	mem[2] = y2_hi;                        
-	mem[3] = y2_lo;                        
-	mem[4] = y1_hi;                        
-	mem[5] = y1_lo;                        
-	mem[6] = x0;                           
-	mem[7] = x1;                           
-	mem[8] = x2;                           
+	mem[0] = y3_hi;
+	mem[1] = y3_lo;
+	mem[2] = y2_hi;
+	mem[3] = y2_lo;
+	mem[4] = y1_hi;
+	mem[5] = y1_lo;
+	mem[6] = x0;
+	mem[7] = x1;
+	mem[8] = x2;
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/int_lpc.c b/media/libstagefright/codecs/amrwbenc/src/int_lpc.c
index 88285e8..1119bc7 100644
--- a/media/libstagefright/codecs/amrwbenc/src/int_lpc.c
+++ b/media/libstagefright/codecs/amrwbenc/src/int_lpc.c
@@ -36,21 +36,21 @@
 		Word16 Az[]                           /* output: LP coefficients in 4 subframes    */
 	    )
 {
-	Word32 i, k; 
+	Word32 i, k;
 	Word16 fac_old, fac_new;
 	Word16 isp[M];
 	Word32 L_tmp;
 
 	for (k = 0; k < 3; k++)
 	{
-		fac_new = frac[k];                
+		fac_new = frac[k];
 		fac_old = (32767 - fac_new) + 1;  /* 1.0 - fac_new */
 
 		for (i = 0; i < M; i++)
 		{
 			L_tmp = (isp_old[i] * fac_old)<<1;
 			L_tmp += (isp_new[i] * fac_new)<<1;
-			isp[i] = (L_tmp + 0x8000)>>16;        
+			isp[i] = (L_tmp + 0x8000)>>16;
 		}
 		Isp_Az(isp, Az, M, 0);
 		Az += MP1;
diff --git a/media/libstagefright/codecs/amrwbenc/src/isp_az.c b/media/libstagefright/codecs/amrwbenc/src/isp_az.c
index c235c5d..30a8bbd 100644
--- a/media/libstagefright/codecs/amrwbenc/src/isp_az.c
+++ b/media/libstagefright/codecs/amrwbenc/src/isp_az.c
@@ -42,7 +42,7 @@
 		                                      /*     1   : adaptive scaling enabled  */
 	   )
 {
-	Word32 i, j; 
+	Word32 i, j;
 	Word16 hi, lo;
 	Word32 f1[NC16k + 1], f2[NC16k];
 	Word16 nc;
@@ -92,14 +92,14 @@
 		lo = (f1[i] & 0xffff)>>1;
 
 		t0 = Mpy_32_16(hi, lo, isp[m - 1]);
-		f1[i] = vo_L_add(f1[i], t0); 
+		f1[i] = vo_L_add(f1[i], t0);
 
 		/* f2[i] *= (1.0 - isp[M-1]); */
 
 		hi = f2[i] >> 16;
 		lo = (f2[i] & 0xffff)>>1;
 		t0 = Mpy_32_16(hi, lo, isp[m - 1]);
-		f2[i] = vo_L_sub(f2[i], t0); 
+		f2[i] = vo_L_sub(f2[i], t0);
 	}
 
 	/*-----------------------------------------------------*
@@ -108,20 +108,20 @@
 	 *-----------------------------------------------------*/
 
 	/* a[0] = 1.0; */
-	a[0] = 4096;  
-	tmax = 1;                            
+	a[0] = 4096;
+	tmax = 1;
 	for (i = 1, j = m - 1; i < nc; i++, j--)
 	{
 		/* a[i] = 0.5*(f1[i] + f2[i]); */
 
 		t0 = vo_L_add(f1[i], f2[i]);          /* f1[i] + f2[i]             */
-		tmax |= L_abs(t0);                 
+		tmax |= L_abs(t0);
 		a[i] = (Word16)(vo_L_shr_r(t0, 12)); /* from Q23 to Q12 and * 0.5 */
 
 		/* a[j] = 0.5*(f1[i] - f2[i]); */
 
 		t0 = vo_L_sub(f1[i], f2[i]);          /* f1[i] - f2[i]             */
-		tmax |= L_abs(t0);                
+		tmax |= L_abs(t0);
 		a[j] = (Word16)(vo_L_shr_r(t0, 12)); /* from Q23 to Q12 and * 0.5 */
 	}
 
@@ -144,12 +144,12 @@
 			t0 = vo_L_sub(f1[i], f2[i]);          /* f1[i] - f2[i]             */
 			a[j] = (Word16)(vo_L_shr_r(t0, q_sug)); /* from Q23 to Q12 and * 0.5 */
 		}
-		a[0] = shr(a[0], q); 
+		a[0] = shr(a[0], q);
 	}
 	else
 	{
-		q_sug = 12; 
-		q     = 0; 
+		q_sug = 12;
+		q     = 0;
 	}
 	/* a[NC] = 0.5*f1[NC]*(1.0 + isp[M-1]); */
 	hi = f1[nc] >> 16;
@@ -196,7 +196,7 @@
 	isp += 2;                                /* Advance isp pointer        */
 	for (i = 2; i <= n; i++)
 	{
-		*f = f[-2];                        
+		*f = f[-2];
 		for (j = 1; j < i; j++, f--)
 		{
 			hi = f[-1]>>16;
@@ -228,7 +228,7 @@
 
 	for (i = 2; i <= n; i++)
 	{
-		*f = f[-2];                        
+		*f = f[-2];
 		for (j = 1; j < i; j++, f--)
 		{
 			VO_L_Extract(f[-1], &hi, &lo);
diff --git a/media/libstagefright/codecs/amrwbenc/src/isp_isf.c b/media/libstagefright/codecs/amrwbenc/src/isp_isf.c
index fbe80eb..b4ba408 100644
--- a/media/libstagefright/codecs/amrwbenc/src/isp_isf.c
+++ b/media/libstagefright/codecs/amrwbenc/src/isp_isf.c
@@ -51,9 +51,9 @@
 		/* acos(isp[i])= ind*128 + ( ( isp[i]-table[ind] ) * slope[ind] )/2048 */
 		L_tmp = vo_L_mult(vo_sub(isp[i], table[ind]), slope[ind]);
 		isf[i] = vo_round((L_tmp << 4));   /* (isp[i]-table[ind])*slope[ind])>>11 */
-		isf[i] = add1(isf[i], (ind << 7)); 
+		isf[i] = add1(isf[i], (ind << 7));
 	}
-	isf[m - 1] = (isf[m - 1] >> 1);      
+	isf[m - 1] = (isf[m - 1] >> 1);
 	return;
 }
 
@@ -69,7 +69,7 @@
 
 	for (i = 0; i < m - 1; i++)
 	{
-		isp[i] = isf[i];                  
+		isp[i] = isf[i];
 	}
 	isp[m - 1] = (isf[m - 1] << 1);
 
@@ -80,7 +80,7 @@
 
 		/* isp[i] = table[ind]+ ((table[ind+1]-table[ind])*offset) / 128 */
 		L_tmp = vo_L_mult(vo_sub(table[ind + 1], table[ind]), offset);
-		isp[i] = add1(table[ind], (Word16)((L_tmp >> 8)));   
+		isp[i] = add1(table[ind], (Word16)((L_tmp >> 8)));
 	}
 
 	return;
diff --git a/media/libstagefright/codecs/amrwbenc/src/levinson.c b/media/libstagefright/codecs/amrwbenc/src/levinson.c
index a68845f..4b2f8ed 100644
--- a/media/libstagefright/codecs/amrwbenc/src/levinson.c
+++ b/media/libstagefright/codecs/amrwbenc/src/levinson.c
@@ -122,8 +122,8 @@
 	Word16 *old_A, *old_rc;
 
 	/* Last A(z) for case of unstable filter */
-	old_A = mem;                           
-	old_rc = mem + M;                      
+	old_A = mem;
+	old_rc = mem + M;
 
 	/* K = A[1] = -R[1] / R[0] */
 
@@ -135,7 +135,7 @@
 
 	Kh = t0 >> 16;
 	Kl = (t0 & 0xffff)>>1;
-	rc[0] = Kh;                            
+	rc[0] = Kh;
 	t0 = (t0 >> 4);                        /* A[1] in Q27      */
 
 	Ah[1] = t0 >> 16;
@@ -163,7 +163,7 @@
 	for (i = 2; i <= M; i++)
 	{
 		/* t0 = SUM ( R[j]*A[i-j] ,j=1,i-1 ) +  R[i] */
-		t0 = 0;                           
+		t0 = 0;
 		for (j = 1; j < i; j++)
 			t0 = vo_L_add(t0, Mpy_32(Rh[j], Rl[j], Ah[i - j], Al[i - j]));
 
@@ -182,14 +182,14 @@
 		Kh = t2 >> 16;
 		Kl = (t2 & 0xffff)>>1;
 
-		rc[i - 1] = Kh;                   
+		rc[i - 1] = Kh;
 		/* Test for unstable filter. If unstable keep old A(z) */
 		if (abs_s(Kh) > 32750)
 		{
 			A[0] = 4096;                    /* Ai[0] not stored (always 1.0) */
 			for (j = 0; j < M; j++)
 			{
-				A[j + 1] = old_A[j];       
+				A[j + 1] = old_A[j];
 			}
 			rc[0] = old_rc[0];             /* only two rc coefficients are needed */
 			rc[1] = old_rc[1];
@@ -229,19 +229,19 @@
 		/* A[j] = An[j] */
 		for (j = 1; j <= i; j++)
 		{
-			Ah[j] = Anh[j];               
-			Al[j] = Anl[j];                
+			Ah[j] = Anh[j];
+			Al[j] = Anl[j];
 		}
 	}
 	/* Truncate A[i] in Q27 to Q12 with rounding */
-	A[0] = 4096;                          
+	A[0] = 4096;
 	for (i = 1; i <= M; i++)
 	{
 		t0 = (Ah[i] << 16) + (Al[i] << 1);
-		old_A[i - 1] = A[i] = vo_round((t0 << 1));      
+		old_A[i - 1] = A[i] = vo_round((t0 << 1));
 	}
-	old_rc[0] = rc[0];                    
-	old_rc[1] = rc[1];                    
+	old_rc[0] = rc[0];
+	old_rc[1] = rc[1];
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/log2.c b/media/libstagefright/codecs/amrwbenc/src/log2.c
index 646d6af..0f65541 100644
--- a/media/libstagefright/codecs/amrwbenc/src/log2.c
+++ b/media/libstagefright/codecs/amrwbenc/src/log2.c
@@ -64,11 +64,11 @@
 	Word32 L_y;
 	if (L_x <= (Word32) 0)
 	{
-		*exponent = 0; 
-		*fraction = 0; 
+		*exponent = 0;
+		*fraction = 0;
 		return;
 	}
-	*exponent = (30 - exp); 
+	*exponent = (30 - exp);
 	L_x = (L_x >> 9);
 	i = extract_h (L_x);                /* Extract b25-b31 */
 	L_x = (L_x >> 1);
@@ -78,7 +78,7 @@
 	L_y = L_deposit_h (table[i]);       /* table[i] << 16        */
 	tmp = vo_sub(table[i], table[i + 1]); /* table[i] - table[i+1] */
 	L_y = vo_L_msu (L_y, tmp, a);          /* L_y -= tmp*a*2        */
-	*fraction = extract_h (L_y); 
+	*fraction = extract_h (L_y);
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/lp_dec2.c b/media/libstagefright/codecs/amrwbenc/src/lp_dec2.c
index 29bd46b..1d5d076 100644
--- a/media/libstagefright/codecs/amrwbenc/src/lp_dec2.c
+++ b/media/libstagefright/codecs/amrwbenc/src/lp_dec2.c
@@ -42,25 +42,25 @@
 	Word32 i, j;
 	Word32 L_tmp;
 	/* copy initial filter states into buffer */
-	p_x = x_buf;                           
+	p_x = x_buf;
 	for (i = 0; i < L_MEM; i++)
 	{
-		*p_x++ = mem[i];  
-		mem[i] = x[l - L_MEM + i];  
+		*p_x++ = mem[i];
+		mem[i] = x[l - L_MEM + i];
 	}
 	for (i = 0; i < l; i++)
 	{
-		*p_x++ = x[i];                     
+		*p_x++ = x[i];
 	}
 	for (i = 0, j = 0; i < l; i += 2, j++)
 	{
-		p_x = &x_buf[i];  
+		p_x = &x_buf[i];
 		L_tmp  = ((*p_x++) * h_fir[0]);
 		L_tmp += ((*p_x++) * h_fir[1]);
 		L_tmp += ((*p_x++) * h_fir[2]);
 		L_tmp += ((*p_x++) * h_fir[3]);
 		L_tmp += ((*p_x++) * h_fir[4]);
-		x[j] = (L_tmp + 0x4000)>>15;              
+		x[j] = (L_tmp + 0x4000)>>15;
 	}
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/math_op.c b/media/libstagefright/codecs/amrwbenc/src/math_op.c
index 1a7b513..7affbb2 100644
--- a/media/libstagefright/codecs/amrwbenc/src/math_op.c
+++ b/media/libstagefright/codecs/amrwbenc/src/math_op.c
@@ -106,21 +106,21 @@
 
 	if (*frac <= (Word32) 0)
 	{
-		*exp = 0;                          
-		*frac = 0x7fffffffL;               
+		*exp = 0;
+		*frac = 0x7fffffffL;
 		return;
 	}
 
 	if((*exp & 1) == 1)                       /*If exponant odd -> shift right */
 		*frac = (*frac) >> 1;
 
-	*exp = negate((*exp - 1) >> 1);   
+	*exp = negate((*exp - 1) >> 1);
 
-	*frac = (*frac >> 9);               
+	*frac = (*frac >> 9);
 	i = extract_h(*frac);                  /* Extract b25-b31 */
-	*frac = (*frac >> 1);              
+	*frac = (*frac >> 1);
 	a = (Word16)(*frac);                  /* Extract b10-b24 */
-	a = (Word16) (a & (Word16) 0x7fff);    
+	a = (Word16) (a & (Word16) 0x7fff);
 	i -= 16;
 	*frac = L_deposit_h(table_isqrt[i]);   /* table[i] << 16         */
 	tmp = vo_sub(table_isqrt[i], table_isqrt[i + 1]);      /* table[i] - table[i+1]) */
@@ -167,7 +167,7 @@
 	i = extract_h(L_x);                    /* Extract b10-b16 of fraction */
 	L_x =L_x >> 1;
 	a = (Word16)(L_x);                    /* Extract b0-b9   of fraction */
-	a = (Word16) (a & (Word16) 0x7fff); 
+	a = (Word16) (a & (Word16) 0x7fff);
 
 	L_x = L_deposit_h(table_pow2[i]);      /* table[i] << 16        */
 	tmp = vo_sub(table_pow2[i], table_pow2[i + 1]);        /* table[i] - table[i+1] */
diff --git a/media/libstagefright/codecs/amrwbenc/src/mem_align.c b/media/libstagefright/codecs/amrwbenc/src/mem_align.c
index e58915a..a29baf3 100644
--- a/media/libstagefright/codecs/amrwbenc/src/mem_align.c
+++ b/media/libstagefright/codecs/amrwbenc/src/mem_align.c
@@ -27,7 +27,7 @@
 /*****************************************************************************
 *
 * function name: mem_malloc
-* description:  malloc the alignments memory 
+* description:  malloc the alignments memory
 * returns:      the point of the memory
 *
 **********************************************************************************/
diff --git a/media/libstagefright/codecs/amrwbenc/src/p_med_ol.c b/media/libstagefright/codecs/amrwbenc/src/p_med_ol.c
index 08f430f..b8174b9 100644
--- a/media/libstagefright/codecs/amrwbenc/src/p_med_ol.c
+++ b/media/libstagefright/codecs/amrwbenc/src/p_med_ol.c
@@ -18,7 +18,7 @@
 *      File: p_med_ol.c                                                *
 *                                                                      *
 *      Description: Compute the open loop pitch lag                    *
-*	            output: open loop pitch lag                        *                            
+*	            output: open loop pitch lag                        *
 ************************************************************************/
 
 #include "typedef.h"
@@ -29,7 +29,7 @@
 #include "p_med_ol.tab"
 
 Word16 Pitch_med_ol(
-		   Word16      wsp[],        /*   i: signal used to compute the open loop pitch*/  
+		   Word16      wsp[],        /*   i: signal used to compute the open loop pitch*/
                                      /*      wsp[-pit_max] to wsp[-1] should be known */
 		   Coder_State *st,          /* i/o: codec global structure */
 		   Word16      L_frame       /*   i: length of frame to compute pitch */
@@ -52,8 +52,8 @@
 	ww = &corrweight[198];
 	we = &corrweight[98 + L_max - L_0];
 
-	max = MIN_32;                          
-	Tm = 0;                                
+	max = MIN_32;
+	Tm = 0;
 	for (i = L_max; i > L_min; i--)
 	{
 		/* Compute the correlation */
@@ -65,7 +65,7 @@
 			R0 += vo_L_mult((*p1++), (*p2++));
 			R0 += vo_L_mult((*p1++), (*p2++));
 			R0 += vo_L_mult((*p1++), (*p2++));
-			R0 += vo_L_mult((*p1++), (*p2++));     
+			R0 += vo_L_mult((*p1++), (*p2++));
 		}
 		/* Weighting of the correlation function.   */
 		hi = R0>>16;
@@ -90,13 +90,13 @@
 	}
 
 	/* Hypass the wsp[] vector */
-	hp_wsp = old_hp_wsp + L_max;           
+	hp_wsp = old_hp_wsp + L_max;
 	Hp_wsp(wsp, hp_wsp, L_frame, hp_wsp_mem);
 
 	/* Compute normalize correlation at delay Tm */
-	R0 = 0;                                
-	R1 = 0;                               
-	R2 = 0; 
+	R0 = 0;
+	R1 = 0;
+	R2 = 0;
 	p1 = hp_wsp;
 	p2 = hp_wsp - Tm;
 	for (j = 0; j < L_frame; j+=4)
@@ -174,57 +174,57 @@
 	Word16 x1, x2, x3, x4, x5;
 	Word16 tmp;
 
-	x1 = x[-2];                            
-	x2 = x[-1];                            
-	x3 = x[0];                             
-	x4 = x[1];                             
-	x5 = x[2];                             
+	x1 = x[-2];
+	x2 = x[-1];
+	x3 = x[0];
+	x4 = x[1];
+	x5 = x[2];
 
 	if (x2 < x1)
 	{
 		tmp = x1;
 		x1 = x2;
-		x2 = tmp;                          
+		x2 = tmp;
 	}
 	if (x3 < x1)
 	{
 		tmp = x1;
 		x1 = x3;
-		x3 = tmp;                          
+		x3 = tmp;
 	}
 	if (x4 < x1)
 	{
 		tmp = x1;
 		x1 = x4;
-		x4 = tmp;                          
+		x4 = tmp;
 	}
 	if (x5 < x1)
 	{
-		x5 = x1;                           
+		x5 = x1;
 	}
 	if (x3 < x2)
 	{
 		tmp = x2;
 		x2 = x3;
-		x3 = tmp;                          
+		x3 = tmp;
 	}
 	if (x4 < x2)
 	{
 		tmp = x2;
 		x2 = x4;
-		x4 = tmp;                          
+		x4 = tmp;
 	}
 	if (x5 < x2)
 	{
-		x5 = x2;                           
+		x5 = x2;
 	}
 	if (x4 < x3)
 	{
-		x3 = x4;                           
+		x3 = x4;
 	}
 	if (x5 < x3)
 	{
-		x3 = x5;                           
+		x3 = x5;
 	}
 	return (x3);
 }
@@ -241,10 +241,10 @@
 
 	for (i = 4; i > 0; i--)
 	{
-		old_ol_lag[i] = old_ol_lag[i - 1]; 
+		old_ol_lag[i] = old_ol_lag[i - 1];
 	}
 
-	old_ol_lag[0] = prev_ol_lag;           
+	old_ol_lag[0] = prev_ol_lag;
 
 	i = median5(&old_ol_lag[2]);
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/pitch_f4.c b/media/libstagefright/codecs/amrwbenc/src/pitch_f4.c
index 41d7413..0d66c31 100644
--- a/media/libstagefright/codecs/amrwbenc/src/pitch_f4.c
+++ b/media/libstagefright/codecs/amrwbenc/src/pitch_f4.c
@@ -90,7 +90,7 @@
     Norm_corr_asm(exc, xn, h, L_subfr, t_min, t_max, corr);
 #else
 	Norm_Corr(exc, xn, h, L_subfr, t_min, t_max, corr);
-#endif 
+#endif
 
 	/* Find integer pitch */
 
@@ -100,8 +100,8 @@
 	{
 		if (corr[i] >= max)
 		{
-			max = corr[i];                 
-			t0 = i;                        
+			max = corr[i];
+			t0 = i;
 		}
 	}
 	/* If first subframe and t0 >= t0_fr1, do not search fractionnal pitch */
@@ -182,7 +182,7 @@
 #endif
 
 	/* Compute rounded down 1/sqrt(energy of xn[]) */
-	L_tmp = 0; 
+	L_tmp = 0;
 	for (i = 0; i < 64; i+=4)
 	{
 		L_tmp += (xn[i] * xn[i]);
@@ -202,7 +202,7 @@
 	for (t = t_min; t <= t_max; t++)
 	{
 		/* Compute correlation between xn[] and excf[] */
-		L_tmp  = 0;  
+		L_tmp  = 0;
 		L_tmp1 = 0;
 		for (i = 0; i < 64; i+=4)
 		{
@@ -246,7 +246,7 @@
 			L_tmp = L_tmp << L_tmp2;
 		}
 
-		corr_norm[t] = vo_round(L_tmp);      
+		corr_norm[t] = vo_round(L_tmp);
 		/* modify the filtered excitation excf[] for the next iteration */
 
 		if(t != t_max)
@@ -310,10 +310,10 @@
 	L_sum += vo_mult32(x[1], (*ptr++));
 	L_sum += vo_mult32(x[2], (*ptr++));
 	L_sum += vo_mult32(x[3], (*ptr++));
-	L_sum += vo_mult32(x[4], (*ptr++));  
+	L_sum += vo_mult32(x[4], (*ptr++));
 	L_sum += vo_mult32(x[5], (*ptr++));
 	L_sum += vo_mult32(x[6], (*ptr++));
-	L_sum += vo_mult32(x[7], (*ptr++));   
+	L_sum += vo_mult32(x[7], (*ptr++));
 
 	sum = extract_h(L_add(L_shl2(L_sum, 2), 0x8000));
 	return (sum);
diff --git a/media/libstagefright/codecs/amrwbenc/src/pred_lt4.c b/media/libstagefright/codecs/amrwbenc/src/pred_lt4.c
index b359651..8404cf9 100644
--- a/media/libstagefright/codecs/amrwbenc/src/pred_lt4.c
+++ b/media/libstagefright/codecs/amrwbenc/src/pred_lt4.c
@@ -60,13 +60,13 @@
 	Word16 *ptr, *ptr1;
 	Word16 *ptr2;
 
-	x = exc - T0;   
+	x = exc - T0;
 	frac = -frac;
 	if (frac < 0)
 	{
 		frac += UP_SAMP;
 		x--;
-	}   
+	}
 	x -= 15;                                     /* x = L_INTERPOL2 - 1 */
 	k = 3 - frac;                                /* k = UP_SAMP - 1 - frac */
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/preemph.c b/media/libstagefright/codecs/amrwbenc/src/preemph.c
index 5408617..c867bf7 100644
--- a/media/libstagefright/codecs/amrwbenc/src/preemph.c
+++ b/media/libstagefright/codecs/amrwbenc/src/preemph.c
@@ -35,20 +35,20 @@
 	Word16 temp;
 	Word32 i, L_tmp;
 
-	temp = x[lg - 1];                     
+	temp = x[lg - 1];
 
 	for (i = lg - 1; i > 0; i--)
 	{
 		L_tmp = L_deposit_h(x[i]);
 		L_tmp -= (x[i - 1] * mu)<<1;
-		x[i] = (L_tmp + 0x8000)>>16;               
+		x[i] = (L_tmp + 0x8000)>>16;
 	}
 
 	L_tmp = L_deposit_h(x[0]);
 	L_tmp -= ((*mem) * mu)<<1;
-	x[0] = (L_tmp + 0x8000)>>16;                   
+	x[0] = (L_tmp + 0x8000)>>16;
 
-	*mem = temp;                           
+	*mem = temp;
 
 	return;
 }
@@ -64,22 +64,22 @@
 	Word16 temp;
 	Word32 i, L_tmp;
 
-	temp = x[lg - 1];                     
+	temp = x[lg - 1];
 
 	for (i = (Word16) (lg - 1); i > 0; i--)
 	{
 		L_tmp = L_deposit_h(x[i]);
 		L_tmp -= (x[i - 1] * mu)<<1;
 		L_tmp = (L_tmp << 1);
-		x[i] = (L_tmp + 0x8000)>>16;               
+		x[i] = (L_tmp + 0x8000)>>16;
 	}
 
 	L_tmp = L_deposit_h(x[0]);
 	L_tmp -= ((*mem) * mu)<<1;
 	L_tmp = (L_tmp << 1);
-	x[0] = (L_tmp + 0x8000)>>16;                   
+	x[0] = (L_tmp + 0x8000)>>16;
 
-	*mem = temp;                           
+	*mem = temp;
 
 	return;
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/q_gain2.c b/media/libstagefright/codecs/amrwbenc/src/q_gain2.c
index 7bc299f..e8ca043 100644
--- a/media/libstagefright/codecs/amrwbenc/src/q_gain2.c
+++ b/media/libstagefright/codecs/amrwbenc/src/q_gain2.c
@@ -83,7 +83,7 @@
 	Word32 i, j, L_tmp, dist_min;
 	Word16 *past_qua_en, *t_qua_gain;
 
-	past_qua_en = mem;                     
+	past_qua_en = mem;
 
 	/*-----------------------------------------------------------------*
 	 * - Find the initial quantization pitch index                     *
@@ -91,9 +91,9 @@
 	 *-----------------------------------------------------------------*/
 	if (nbits == 6)
 	{
-		t_qua_gain = t_qua_gain6b;         
-		min_ind = 0;                       
-		size = RANGE;                      
+		t_qua_gain = t_qua_gain6b;
+		min_ind = 0;
+		size = RANGE;
 
 		if(gp_clip == 1)
 		{
@@ -101,18 +101,18 @@
 		}
 	} else
 	{
-		t_qua_gain = t_qua_gain7b;         
+		t_qua_gain = t_qua_gain7b;
 
 		p = t_qua_gain7b + RANGE;            /* pt at 1/4th of table */
 
-		j = nb_qua_gain7b - RANGE;         
+		j = nb_qua_gain7b - RANGE;
 
 		if (gp_clip == 1)
 		{
 			j = j - 27;                /* limit gain pitch to 1.0 */
 		}
-		min_ind = 0;                       
-		g_pitch = *gain_pit;               
+		min_ind = 0;
+		g_pitch = *gain_pit;
 
 		for (i = 0; i < j; i++, p += 2)
 		{
@@ -121,7 +121,7 @@
 				min_ind = min_ind + 1;
 			}
 		}
-		size = RANGE;                      
+		size = RANGE;
 	}
 
 	/*------------------------------------------------------------------*
@@ -137,10 +137,10 @@
 	 * are in vector g_coeff[].                                         *
 	 *------------------------------------------------------------------*/
 
-	coeff[0] = g_coeff[0];                 
-	exp_coeff[0] = g_coeff[1];             
+	coeff[0] = g_coeff[0];
+	exp_coeff[0] = g_coeff[1];
 	coeff[1] = negate(g_coeff[2]);                    /* coeff[1] = -2 xn y1 */
-	exp_coeff[1] = g_coeff[3] + 1;     
+	exp_coeff[1] = g_coeff[3] + 1;
 
 	/* Compute scalar product <y2[],y2[]> */
 #ifdef ASM_OPT                   /* asm optimization branch */
@@ -242,20 +242,20 @@
 	 *-------------------------------------------------------------------------*/
 
 	exp_code = (exp_gcode0 + 4);
-	exp_max[0] = (exp_coeff[0] - 13);    
-	exp_max[1] = (exp_coeff[1] - 14);    
-	exp_max[2] = (exp_coeff[2] + (15 + (exp_code << 1)));  
-	exp_max[3] = (exp_coeff[3] + exp_code);   
-	exp_max[4] = (exp_coeff[4] + (1 + exp_code));  
+	exp_max[0] = (exp_coeff[0] - 13);
+	exp_max[1] = (exp_coeff[1] - 14);
+	exp_max[2] = (exp_coeff[2] + (15 + (exp_code << 1)));
+	exp_max[3] = (exp_coeff[3] + exp_code);
+	exp_max[4] = (exp_coeff[4] + (1 + exp_code));
 
 	/* Find maximum exponant */
 
-	e_max = exp_max[0];                   
+	e_max = exp_max[0];
 	for (i = 1; i < 5; i++)
 	{
 		if(exp_max[i] > e_max)
 		{
-			e_max = exp_max[i];            
+			e_max = exp_max[i];
 		}
 	}
 
@@ -271,14 +271,14 @@
 	}
 
 	/* Codebook search */
-	dist_min = MAX_32;                     
-	p = &t_qua_gain[min_ind << 1];      
+	dist_min = MAX_32;
+	p = &t_qua_gain[min_ind << 1];
 
-	index = 0;                             
+	index = 0;
 	for (i = 0; i < size; i++)
 	{
-		g_pitch = *p++;                    
-		g_code = *p++;                     
+		g_pitch = *p++;
+		g_code = *p++;
 
 		g_code = ((g_code * gcode0) + 0x4000)>>15;
 		g2_pitch = ((g_pitch * g_pitch) + 0x4000)>>15;
@@ -302,14 +302,14 @@
 
 		if(L_tmp < dist_min)
 		{
-			dist_min = L_tmp;              
-			index = i;                     
+			dist_min = L_tmp;
+			index = i;
 		}
 	}
 
 	/* Read the quantized gains */
 	index = index + min_ind;
-	p = &t_qua_gain[(index + index)];    
+	p = &t_qua_gain[(index + index)];
 	*gain_pit = *p++;                       /* selected pitch gain in Q14 */
 	g_code = *p++;                          /* selected code gain in Q11  */
 
@@ -333,10 +333,10 @@
 
 	/* update table of past quantized energies */
 
-	past_qua_en[3] = past_qua_en[2];       
-	past_qua_en[2] = past_qua_en[1];       
-	past_qua_en[1] = past_qua_en[0];       
-	past_qua_en[0] = qua_ener;             
+	past_qua_en[3] = past_qua_en[2];
+	past_qua_en[2] = past_qua_en[1];
+	past_qua_en[1] = past_qua_en[0];
+	past_qua_en[0] = qua_ener;
 
 	return (index);
 }
diff --git a/media/libstagefright/codecs/amrwbenc/src/q_pulse.c b/media/libstagefright/codecs/amrwbenc/src/q_pulse.c
index 496ca80..80a0b73 100644
--- a/media/libstagefright/codecs/amrwbenc/src/q_pulse.c
+++ b/media/libstagefright/codecs/amrwbenc/src/q_pulse.c
@@ -82,7 +82,7 @@
 		if (vo_sub((Word16) (pos1 & mask), (Word16) (pos2 & mask)) <= 0)
 		{
 			/* index = ((pos2 & mask) << N) + (pos1 & mask); */
-			index = L_deposit_l(add1((((Word16) (pos2 & mask)) << N), ((Word16) (pos1 & mask)))); 
+			index = L_deposit_l(add1((((Word16) (pos2 & mask)) << N), ((Word16) (pos1 & mask))));
 			if ((pos2 & NB_POS) != 0)
 			{
 				tmp = (N << 1);           /* index += 1 << (2*N); */
@@ -91,7 +91,7 @@
 		} else
 		{
 			/* index = ((pos1 & mask) << N) + (pos2 & mask);	 */
-			index = L_deposit_l(add1((((Word16) (pos1 & mask)) << N), ((Word16) (pos2 & mask)))); 
+			index = L_deposit_l(add1((((Word16) (pos1 & mask)) << N), ((Word16) (pos2 & mask))));
 			if ((pos1 & NB_POS) != 0)
 			{
 				tmp = (N << 1);
@@ -120,14 +120,14 @@
 	{
 		index = quant_2p_2N1(pos1, pos2, sub(N, 1));    /* index = quant_2p_2N1(pos1, pos2, (N-1)); */
 		/* index += (pos1 & nb_pos) << N; */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));  
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));
 		/* index += quant_1p_N1(pos3, N) << (2*N); */
 		index = vo_L_add(index, (quant_1p_N1(pos3, N)<<(N << 1)));
 
 	} else if (((pos1 ^ pos3) & nb_pos) == 0)
 	{
 		index = quant_2p_2N1(pos1, pos3, sub(N, 1));    /* index = quant_2p_2N1(pos1, pos3, (N-1)); */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N)); 
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));
 		/* index += (pos1 & nb_pos) << N; */
 		index = vo_L_add(index, (quant_1p_N1(pos2, N) << (N << 1)));
 		/* index += quant_1p_N1(pos2, N) <<
@@ -136,7 +136,7 @@
 	{
 		index = quant_2p_2N1(pos2, pos3, (N - 1));    /* index = quant_2p_2N1(pos2, pos3, (N-1)); */
 		/* index += (pos2 & nb_pos) << N;			 */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos2 & nb_pos)) << N));  
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos2 & nb_pos)) << N));
 		/* index += quant_1p_N1(pos1, N) << (2*N);	 */
 		index = vo_L_add(index, (quant_1p_N1(pos1, N) << (N << 1)));
 	}
@@ -162,21 +162,21 @@
 	{
 		index = quant_2p_2N1(pos1, pos2, sub(N, 1));    /* index = quant_2p_2N1(pos1, pos2, (N-1)); */
 		/* index += (pos1 & nb_pos) << N;	 */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));  
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));
 		/* index += quant_2p_2N1(pos3, pos4, N) << (2*N); */
 		index = vo_L_add(index, (quant_2p_2N1(pos3, pos4, N) << (N << 1)));
 	} else if (((pos1 ^ pos3) & nb_pos) == 0)
 	{
 		index = quant_2p_2N1(pos1, pos3, (N - 1));
 		/* index += (pos1 & nb_pos) << N; */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));  
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos1 & nb_pos)) << N));
 		/* index += quant_2p_2N1(pos2, pos4, N) << (2*N); */
 		index = vo_L_add(index, (quant_2p_2N1(pos2, pos4, N) << (N << 1)));
 	} else
 	{
 		index = quant_2p_2N1(pos2, pos3, (N - 1));
 		/* index += (pos2 & nb_pos) << N; */
-		index = vo_L_add(index, (L_deposit_l((Word16) (pos2 & nb_pos)) << N));  
+		index = vo_L_add(index, (L_deposit_l((Word16) (pos2 & nb_pos)) << N));
 		/* index += quant_2p_2N1(pos1, pos4, N) << (2*N); */
 		index = vo_L_add(index, (quant_2p_2N1(pos1, pos4, N) << (N << 1)));
 	}
@@ -192,20 +192,20 @@
 	Word16 posA[4], posB[4];
 	Word32 i, j, k, index;
 
-	n_1 = (Word16) (N - 1);                
+	n_1 = (Word16) (N - 1);
 	nb_pos = (1 << n_1);                  /* nb_pos = (1<<n_1); */
 	mask = vo_sub((1 << N), 1);              /* mask = ((1<<N)-1); */
 
-	i = 0;                                 
-	j = 0;                                 
+	i = 0;
+	j = 0;
 	for (k = 0; k < 4; k++)
 	{
 		if ((pos[k] & nb_pos) == 0)
 		{
-			posA[i++] = pos[k];            
+			posA[i++] = pos[k];
 		} else
 		{
-			posB[j++] = pos[k];            
+			posB[j++] = pos[k];
 		}
 	}
 
@@ -258,19 +258,19 @@
 	Word16 posA[5], posB[5];
 	Word32 i, j, k, index, tmp2;
 
-	n_1 = (Word16) (N - 1);                
+	n_1 = (Word16) (N - 1);
 	nb_pos = (1 << n_1);                  /* nb_pos = (1<<n_1); */
 
-	i = 0;                                 
-	j = 0;                                 
+	i = 0;
+	j = 0;
 	for (k = 0; k < 5; k++)
 	{
 		if ((pos[k] & nb_pos) == 0)
 		{
-			posA[i++] = pos[k];            
+			posA[i++] = pos[k];
 		} else
 		{
-			posB[j++] = pos[k];            
+			posB[j++] = pos[k];
 		}
 	}
 
@@ -333,19 +333,19 @@
 	Word32 i, j, k, index;
 
 	/* !!  N and n_1 are constants -> it doesn't need to be operated by Basic Operators */
-	n_1 = (Word16) (N - 1);                
+	n_1 = (Word16) (N - 1);
 	nb_pos = (1 << n_1);                  /* nb_pos = (1<<n_1); */
 
-	i = 0;                                 
-	j = 0;                                 
+	i = 0;
+	j = 0;
 	for (k = 0; k < 6; k++)
 	{
 		if ((pos[k] & nb_pos) == 0)
 		{
-			posA[i++] = pos[k];            
+			posA[i++] = pos[k];
 		} else
 		{
-			posB[j++] = pos[k];            
+			posB[j++] = pos[k];
 		}
 	}
 
@@ -368,23 +368,23 @@
 			index = vo_L_add(index, quant_2p_2N1(posA[0], posA[1], n_1));      /* index += quant_2p_2N1(posA[0], posA[1], n_1); */
 			break;
 		case 3:
-			index = (quant_3p_3N1(posA[0], posA[1], posA[2], n_1) << (Word16) (3 * n_1 + 1));    
+			index = (quant_3p_3N1(posA[0], posA[1], posA[2], n_1) << (Word16) (3 * n_1 + 1));
 			                                  /* index = quant_3p_3N1(posA[0], posA[1], posA[2], n_1) << ((3*n_1)+1); */
-			index =vo_L_add(index, quant_3p_3N1(posB[0], posB[1], posB[2], n_1));     
+			index =vo_L_add(index, quant_3p_3N1(posB[0], posB[1], posB[2], n_1));
 			                                 /* index += quant_3p_3N1(posB[0], posB[1], posB[2], n_1); */
 			break;
 		case 4:
-			i = 2;                            
+			i = 2;
 			index = (quant_4p_4N(posA, n_1) << (Word16) (2 * n_1 + 1));  /* index = quant_4p_4N(posA, n_1) << ((2*n_1)+1); */
 			index = vo_L_add(index, quant_2p_2N1(posB[0], posB[1], n_1));      /* index += quant_2p_2N1(posB[0], posB[1], n_1); */
 			break;
 		case 5:
-			i = 1;                            
+			i = 1;
 			index = (quant_5p_5N(posA, n_1) << N);       /* index = quant_5p_5N(posA, n_1) << N; */
 			index = vo_L_add(index, quant_1p_N1(posB[0], n_1));        /* index += quant_1p_N1(posB[0], n_1); */
 			break;
 		case 6:
-			i = 0;                             
+			i = 0;
 			index = (quant_5p_5N(posA, n_1) << N);       /* index = quant_5p_5N(posA, n_1) << N; */
 			index = vo_L_add(index, quant_1p_N1(posA[5], n_1));        /* index += quant_1p_N1(posA[5], n_1); */
 			break;
diff --git a/media/libstagefright/codecs/amrwbenc/src/qisf_ns.c b/media/libstagefright/codecs/amrwbenc/src/qisf_ns.c
index f6d53de..fc2f00d 100644
--- a/media/libstagefright/codecs/amrwbenc/src/qisf_ns.c
+++ b/media/libstagefright/codecs/amrwbenc/src/qisf_ns.c
@@ -43,14 +43,14 @@
 
 	for (i = 0; i < ORDER; i++)
 	{
-		isf_q[i] = sub(isf1[i], mean_isf_noise[i]);     
+		isf_q[i] = sub(isf1[i], mean_isf_noise[i]);
 	}
 
-	indice[0] = Sub_VQ(&isf_q[0], dico1_isf_noise, 2, SIZE_BK_NOISE1, &tmp);    
-	indice[1] = Sub_VQ(&isf_q[2], dico2_isf_noise, 3, SIZE_BK_NOISE2, &tmp);    
-	indice[2] = Sub_VQ(&isf_q[5], dico3_isf_noise, 3, SIZE_BK_NOISE3, &tmp);    
-	indice[3] = Sub_VQ(&isf_q[8], dico4_isf_noise, 4, SIZE_BK_NOISE4, &tmp);    
-	indice[4] = Sub_VQ(&isf_q[12], dico5_isf_noise, 4, SIZE_BK_NOISE5, &tmp);   
+	indice[0] = Sub_VQ(&isf_q[0], dico1_isf_noise, 2, SIZE_BK_NOISE1, &tmp);
+	indice[1] = Sub_VQ(&isf_q[2], dico2_isf_noise, 3, SIZE_BK_NOISE2, &tmp);
+	indice[2] = Sub_VQ(&isf_q[5], dico3_isf_noise, 3, SIZE_BK_NOISE3, &tmp);
+	indice[3] = Sub_VQ(&isf_q[8], dico4_isf_noise, 4, SIZE_BK_NOISE4, &tmp);
+	indice[4] = Sub_VQ(&isf_q[12], dico5_isf_noise, 4, SIZE_BK_NOISE5, &tmp);
 
 	/* decoding the ISFs */
 
@@ -78,28 +78,28 @@
 
 	for (i = 0; i < 2; i++)
 	{
-		isf_q[i] = dico1_isf_noise[indice[0] * 2 + i];  
+		isf_q[i] = dico1_isf_noise[indice[0] * 2 + i];
 	}
 	for (i = 0; i < 3; i++)
 	{
-		isf_q[i + 2] = dico2_isf_noise[indice[1] * 3 + i];      
+		isf_q[i + 2] = dico2_isf_noise[indice[1] * 3 + i];
 	}
 	for (i = 0; i < 3; i++)
 	{
-		isf_q[i + 5] = dico3_isf_noise[indice[2] * 3 + i];      
+		isf_q[i + 5] = dico3_isf_noise[indice[2] * 3 + i];
 	}
 	for (i = 0; i < 4; i++)
 	{
-		isf_q[i + 8] = dico4_isf_noise[indice[3] * 4 + i];      
+		isf_q[i + 8] = dico4_isf_noise[indice[3] * 4 + i];
 	}
 	for (i = 0; i < 4; i++)
 	{
-		isf_q[i + 12] = dico5_isf_noise[indice[4] * 4 + i];     
+		isf_q[i + 12] = dico5_isf_noise[indice[4] * 4 + i];
 	}
 
 	for (i = 0; i < ORDER; i++)
 	{
-		isf_q[i] = add(isf_q[i], mean_isf_noise[i]);   
+		isf_q[i] = add(isf_q[i], mean_isf_noise[i]);
 	}
 
 	Reorder_isf(isf_q, ISF_GAP, ORDER);
diff --git a/media/libstagefright/codecs/amrwbenc/src/qpisf_2s.c b/media/libstagefright/codecs/amrwbenc/src/qpisf_2s.c
index ac13a67..c711cd0 100644
--- a/media/libstagefright/codecs/amrwbenc/src/qpisf_2s.c
+++ b/media/libstagefright/codecs/amrwbenc/src/qpisf_2s.c
@@ -70,30 +70,30 @@
 	for (i = 0; i < ORDER; i++)
 	{
 		isf[i] = vo_sub(isf1[i], mean_isf[i]);
-		isf[i] = vo_sub(isf[i], vo_mult(MU, past_isfq[i])); 
+		isf[i] = vo_sub(isf[i], vo_mult(MU, past_isfq[i]));
 	}
 
 	VQ_stage1(&isf[0], dico1_isf, 9, SIZE_BK1, surv1, nb_surv);
 
-	distance = MAX_32;          
+	distance = MAX_32;
 
 	for (k = 0; k < nb_surv; k++)
 	{
 		for (i = 0; i < 9; i++)
 		{
-			isf_stage2[i] = vo_sub(isf[i], dico1_isf[i + surv1[k] * 9]); 
+			isf_stage2[i] = vo_sub(isf[i], dico1_isf[i + surv1[k] * 9]);
 		}
-		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico21_isf, 3, SIZE_BK21, &min_err); 
+		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico21_isf, 3, SIZE_BK21, &min_err);
 		temp = min_err;
-		tmp_ind[1] = Sub_VQ(&isf_stage2[3], dico22_isf, 3, SIZE_BK22, &min_err); 
+		tmp_ind[1] = Sub_VQ(&isf_stage2[3], dico22_isf, 3, SIZE_BK22, &min_err);
 		temp = vo_L_add(temp, min_err);
-		tmp_ind[2] = Sub_VQ(&isf_stage2[6], dico23_isf, 3, SIZE_BK23, &min_err);  
+		tmp_ind[2] = Sub_VQ(&isf_stage2[6], dico23_isf, 3, SIZE_BK23, &min_err);
 		temp = vo_L_add(temp, min_err);
 
 		if(temp < distance)
 		{
-			distance = temp;               
-			indice[0] = surv1[k];          
+			distance = temp;
+			indice[0] = surv1[k];
 			for (i = 0; i < 3; i++)
 			{
 				indice[i + 2] = tmp_ind[i];
@@ -104,24 +104,24 @@
 
 	VQ_stage1(&isf[9], dico2_isf, 7, SIZE_BK2, surv1, nb_surv);
 
-	distance = MAX_32;                   
+	distance = MAX_32;
 
 	for (k = 0; k < nb_surv; k++)
 	{
 		for (i = 0; i < 7; i++)
 		{
-			isf_stage2[i] = vo_sub(isf[9 + i], dico2_isf[i + surv1[k] * 7]);       
+			isf_stage2[i] = vo_sub(isf[9 + i], dico2_isf[i + surv1[k] * 7]);
 		}
 
 		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico24_isf, 3, SIZE_BK24, &min_err);
-		temp = min_err; 
+		temp = min_err;
 		tmp_ind[1] = Sub_VQ(&isf_stage2[3], dico25_isf, 4, SIZE_BK25, &min_err);
 		temp = vo_L_add(temp, min_err);
 
 		if(temp < distance)
 		{
-			distance = temp;               
-			indice[1] = surv1[k];          
+			distance = temp;
+			indice[1] = surv1[k];
 			for (i = 0; i < 2; i++)
 			{
 				indice[i + 5] = tmp_ind[i];
@@ -165,24 +165,24 @@
 
 	VQ_stage1(&isf[0], dico1_isf, 9, SIZE_BK1, surv1, nb_surv);
 
-	distance = MAX_32;                  
+	distance = MAX_32;
 
 	for (k = 0; k < nb_surv; k++)
 	{
 		for (i = 0; i < 9; i++)
 		{
-			isf_stage2[i] = vo_sub(isf[i], dico1_isf[i + surv1[k] * 9]); 
+			isf_stage2[i] = vo_sub(isf[i], dico1_isf[i + surv1[k] * 9]);
 		}
 
-		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico21_isf_36b, 5, SIZE_BK21_36b, &min_err);        
-		temp = min_err;                  
-		tmp_ind[1] = Sub_VQ(&isf_stage2[5], dico22_isf_36b, 4, SIZE_BK22_36b, &min_err);        
+		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico21_isf_36b, 5, SIZE_BK21_36b, &min_err);
+		temp = min_err;
+		tmp_ind[1] = Sub_VQ(&isf_stage2[5], dico22_isf_36b, 4, SIZE_BK22_36b, &min_err);
 		temp = vo_L_add(temp, min_err);
 
 		if(temp < distance)
 		{
-			distance = temp;               
-			indice[0] = surv1[k];          
+			distance = temp;
+			indice[0] = surv1[k];
 			for (i = 0; i < 2; i++)
 			{
 				indice[i + 2] = tmp_ind[i];
@@ -191,23 +191,23 @@
 	}
 
 	VQ_stage1(&isf[9], dico2_isf, 7, SIZE_BK2, surv1, nb_surv);
-	distance = MAX_32;                    
+	distance = MAX_32;
 
 	for (k = 0; k < nb_surv; k++)
 	{
 		for (i = 0; i < 7; i++)
 		{
-			isf_stage2[i] = vo_sub(isf[9 + i], dico2_isf[i + surv1[k] * 7]);     
+			isf_stage2[i] = vo_sub(isf[9 + i], dico2_isf[i + surv1[k] * 7]);
 		}
 
-		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico23_isf_36b, 7, SIZE_BK23_36b, &min_err);  
-		temp = min_err;                  
+		tmp_ind[0] = Sub_VQ(&isf_stage2[0], dico23_isf_36b, 7, SIZE_BK23_36b, &min_err);
+		temp = min_err;
 
 		if(temp < distance)
 		{
-			distance = temp;               
-			indice[1] = surv1[k];          
-			indice[4] = tmp_ind[0];        
+			distance = temp;
+			indice[1] = surv1[k];
+			indice[4] = tmp_ind[0];
 		}
 	}
 
@@ -239,32 +239,32 @@
 	{
 		for (i = 0; i < 9; i++)
 		{
-			isf_q[i] = dico1_isf[indice[0] * 9 + i];    
+			isf_q[i] = dico1_isf[indice[0] * 9 + i];
 		}
 		for (i = 0; i < 7; i++)
 		{
-			isf_q[i + 9] = dico2_isf[indice[1] * 7 + i];       
+			isf_q[i + 9] = dico2_isf[indice[1] * 7 + i];
 		}
 
 		for (i = 0; i < 3; i++)
 		{
-			isf_q[i] = add1(isf_q[i], dico21_isf[indice[2] * 3 + i]);   
-			isf_q[i + 3] = add1(isf_q[i + 3], dico22_isf[indice[3] * 3 + i]);  
-			isf_q[i + 6] = add1(isf_q[i + 6], dico23_isf[indice[4] * 3 + i]); 
-			isf_q[i + 9] = add1(isf_q[i + 9], dico24_isf[indice[5] * 3 + i]); 
+			isf_q[i] = add1(isf_q[i], dico21_isf[indice[2] * 3 + i]);
+			isf_q[i + 3] = add1(isf_q[i + 3], dico22_isf[indice[3] * 3 + i]);
+			isf_q[i + 6] = add1(isf_q[i + 6], dico23_isf[indice[4] * 3 + i]);
+			isf_q[i + 9] = add1(isf_q[i + 9], dico24_isf[indice[5] * 3 + i]);
 		}
 
 		for (i = 0; i < 4; i++)
 		{
-			isf_q[i + 12] = add1(isf_q[i + 12], dico25_isf[indice[6] * 4 + i]);  
+			isf_q[i + 12] = add1(isf_q[i + 12], dico25_isf[indice[6] * 4 + i]);
 		}
 
 		for (i = 0; i < ORDER; i++)
 		{
-			tmp = isf_q[i];               
-			isf_q[i] = add1(tmp, mean_isf[i]);  
+			tmp = isf_q[i];
+			isf_q[i] = add1(tmp, mean_isf[i]);
 			isf_q[i] = add1(isf_q[i], vo_mult(MU, past_isfq[i]));
-			past_isfq[i] = tmp;  
+			past_isfq[i] = tmp;
 		}
 
 		if (enc_dec)
@@ -273,9 +273,9 @@
 			{
 				for (j = (L_MEANBUF - 1); j > 0; j--)
 				{
-					isf_buf[j * M + i] = isf_buf[(j - 1) * M + i]; 
+					isf_buf[j * M + i] = isf_buf[(j - 1) * M + i];
 				}
-				isf_buf[i] = isf_q[i]; 
+				isf_buf[i] = isf_q[i];
 			}
 		}
 	} else
@@ -293,14 +293,14 @@
 		/* use the past ISFs slightly shifted towards their mean */
 		for (i = 0; i < ORDER; i++)
 		{
-			isf_q[i] = add1(vo_mult(ALPHA, isfold[i]), vo_mult(ONE_ALPHA, ref_isf[i])); 
+			isf_q[i] = add1(vo_mult(ALPHA, isfold[i]), vo_mult(ONE_ALPHA, ref_isf[i]));
 		}
 
 		/* estimate past quantized residual to be used in next frame */
 		for (i = 0; i < ORDER; i++)
 		{
 			tmp = add1(ref_isf[i], vo_mult(past_isfq[i], MU));      /* predicted ISF */
-			past_isfq[i] = vo_sub(isf_q[i], tmp); 
+			past_isfq[i] = vo_sub(isf_q[i], tmp);
 			past_isfq[i] = (past_isfq[i] >> 1);        /* past_isfq[i] *= 0.5 */
 		}
 	}
@@ -332,32 +332,32 @@
 	{
 		for (i = 0; i < 9; i++)
 		{
-			isf_q[i] = dico1_isf[indice[0] * 9 + i];    
+			isf_q[i] = dico1_isf[indice[0] * 9 + i];
 		}
 		for (i = 0; i < 7; i++)
 		{
-			isf_q[i + 9] = dico2_isf[indice[1] * 7 + i];       
+			isf_q[i + 9] = dico2_isf[indice[1] * 7 + i];
 		}
 
 		for (i = 0; i < 5; i++)
 		{
-			isf_q[i] = add1(isf_q[i], dico21_isf_36b[indice[2] * 5 + i]);       
+			isf_q[i] = add1(isf_q[i], dico21_isf_36b[indice[2] * 5 + i]);
 		}
 		for (i = 0; i < 4; i++)
 		{
-			isf_q[i + 5] = add1(isf_q[i + 5], dico22_isf_36b[indice[3] * 4 + i]);        
+			isf_q[i + 5] = add1(isf_q[i + 5], dico22_isf_36b[indice[3] * 4 + i]);
 		}
 		for (i = 0; i < 7; i++)
 		{
-			isf_q[i + 9] = add1(isf_q[i + 9], dico23_isf_36b[indice[4] * 7 + i]);       
+			isf_q[i + 9] = add1(isf_q[i + 9], dico23_isf_36b[indice[4] * 7 + i]);
 		}
 
 		for (i = 0; i < ORDER; i++)
 		{
 			tmp = isf_q[i];
-			isf_q[i] = add1(tmp, mean_isf[i]);   
-			isf_q[i] = add1(isf_q[i], vo_mult(MU, past_isfq[i]));   
-			past_isfq[i] = tmp;           
+			isf_q[i] = add1(tmp, mean_isf[i]);
+			isf_q[i] = add1(isf_q[i], vo_mult(MU, past_isfq[i]));
+			past_isfq[i] = tmp;
 		}
 
 
@@ -367,9 +367,9 @@
 			{
 				for (j = (L_MEANBUF - 1); j > 0; j--)
 				{
-					isf_buf[j * M + i] = isf_buf[(j - 1) * M + i];      
+					isf_buf[j * M + i] = isf_buf[(j - 1) * M + i];
 				}
-				isf_buf[i] = isf_q[i];    
+				isf_buf[i] = isf_q[i];
 			}
 		}
 	} else
@@ -381,20 +381,20 @@
 			{
 				L_tmp += (isf_buf[j * M + i] << 14);
 			}
-			ref_isf[i] = vo_round(L_tmp);    
+			ref_isf[i] = vo_round(L_tmp);
 		}
 
 		/* use the past ISFs slightly shifted towards their mean */
 		for (i = 0; i < ORDER; i++)
 		{
-			isf_q[i] = add1(vo_mult(ALPHA, isfold[i]), vo_mult(ONE_ALPHA, ref_isf[i]));        
+			isf_q[i] = add1(vo_mult(ALPHA, isfold[i]), vo_mult(ONE_ALPHA, ref_isf[i]));
 		}
 
 		/* estimate past quantized residual to be used in next frame */
 		for (i = 0; i < ORDER; i++)
 		{
 			tmp = add1(ref_isf[i], vo_mult(past_isfq[i], MU));      /* predicted ISF */
-			past_isfq[i] = vo_sub(isf_q[i], tmp);  
+			past_isfq[i] = vo_sub(isf_q[i], tmp);
 			past_isfq[i] = past_isfq[i] >> 1;         /* past_isfq[i] *= 0.5 */
 		}
 	}
@@ -424,15 +424,15 @@
 		Word16 n                              /* (i)      : number of ISF                        */
 		)
 {
-	Word32 i; 
+	Word32 i;
 	Word16 isf_min;
 
-	isf_min = min_dist;                    
+	isf_min = min_dist;
 	for (i = 0; i < n - 1; i++)
 	{
 		if(isf[i] < isf_min)
 		{
-			isf[i] = isf_min;              
+			isf[i] = isf_min;
 		}
 		isf_min = (isf[i] + min_dist);
 	}
@@ -452,13 +452,13 @@
 	Word32 i, j, index;
 	Word32 dist_min, dist;
 
-	dist_min = MAX_32;                     
-	p_dico = dico;                         
+	dist_min = MAX_32;
+	p_dico = dico;
 
-	index = 0;                             
+	index = 0;
 	for (i = 0; i < dico_size; i++)
 	{
-		dist = 0;  
+		dist = 0;
 
 		for (j = 0; j < dim; j++)
 		{
@@ -468,18 +468,18 @@
 
 		if(dist < dist_min)
 		{
-			dist_min = dist;               
-			index = i;                     
+			dist_min = dist;
+			index = i;
 		}
 	}
 
-	*distance = dist_min;                  
+	*distance = dist_min;
 
 	/* Reading the selected vector */
-	p_dico = &dico[index * dim];           
+	p_dico = &dico[index * dim];
 	for (j = 0; j < dim; j++)
 	{
-		x[j] = *p_dico++;                  
+		x[j] = *p_dico++;
 	}
 
 	return index;
@@ -508,11 +508,11 @@
 	index[2] = 2;
 	index[3] = 3;
 
-	p_dico = dico;                         
+	p_dico = dico;
 
 	for (i = 0; i < dico_size; i++)
 	{
-		dist = 0;                          
+		dist = 0;
 		for (j = 0; j < dim; j++)
 		{
 			temp = x[j] -  (*p_dico++);
@@ -525,11 +525,11 @@
 			{
 				for (l = surv - 1; l > k; l--)
 				{
-					dist_min[l] = dist_min[l - 1];      
-					index[l] = index[l - 1];    
+					dist_min[l] = dist_min[l - 1];
+					index[l] = index[l - 1];
 				}
-				dist_min[k] = dist;        
-				index[k] = i;              
+				dist_min[k] = dist;
+				index[k] = i;
 				break;
 			}
 		}
diff --git a/media/libstagefright/codecs/amrwbenc/src/residu.c b/media/libstagefright/codecs/amrwbenc/src/residu.c
index 328aed2..b0c04b5 100644
--- a/media/libstagefright/codecs/amrwbenc/src/residu.c
+++ b/media/libstagefright/codecs/amrwbenc/src/residu.c
@@ -56,7 +56,7 @@
 		s += vo_mult32((*p1++), (*p2--));
 		s += vo_mult32((*p1), (*p2));
 
-		s = L_shl2(s, 5); 
+		s = L_shl2(s, 5);
 		y[i] = extract_h(L_add(s, 0x8000));
 	}
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/scale.c b/media/libstagefright/codecs/amrwbenc/src/scale.c
index b203bec..418cc06 100644
--- a/media/libstagefright/codecs/amrwbenc/src/scale.c
+++ b/media/libstagefright/codecs/amrwbenc/src/scale.c
@@ -36,8 +36,8 @@
 	{
 		for (i = lg - 1 ; i >= 0; i--)
 		{
-			L_tmp = L_shl2(x[i], 16 + exp);  
-			x[i] = extract_h(L_add(L_tmp, 0x8000));            
+			L_tmp = L_shl2(x[i], 16 + exp);
+			x[i] = extract_h(L_add(L_tmp, 0x8000));
 		}
 	}
 	else
@@ -46,8 +46,8 @@
 		for (i = lg - 1; i >= 0; i--)
 		{
 			L_tmp = x[i] << 16;
-			L_tmp >>= exp; 
-			x[i] = (L_tmp + 0x8000)>>16;            
+			L_tmp >>= exp;
+			x[i] = (L_tmp + 0x8000)>>16;
 		}
 	}
 	return;
diff --git a/media/libstagefright/codecs/amrwbenc/src/stream.c b/media/libstagefright/codecs/amrwbenc/src/stream.c
index bdf0d46..780f009 100644
--- a/media/libstagefright/codecs/amrwbenc/src/stream.c
+++ b/media/libstagefright/codecs/amrwbenc/src/stream.c
@@ -29,11 +29,11 @@
 	stream->frame_ptr_bk = stream->frame_ptr;
 	stream->set_len = 0;
 	stream->framebuffer_len = 0;
-	stream->frame_storelen = 0;	
+	stream->frame_storelen = 0;
 }
 
 void voAWB_UpdateFrameBuffer(
-		FrameStream *stream, 
+		FrameStream *stream,
 		VO_MEM_OPERATOR *pMemOP
 		)
 {
@@ -53,6 +53,6 @@
 	stream->frame_ptr_bk = stream->frame_ptr;
 	stream->set_len = 0;
 	stream->framebuffer_len = 0;
-	stream->frame_storelen = 0;	
+	stream->frame_storelen = 0;
 }
 
diff --git a/media/libstagefright/codecs/amrwbenc/src/syn_filt.c b/media/libstagefright/codecs/amrwbenc/src/syn_filt.c
index 90fafb0..1bda05a 100644
--- a/media/libstagefright/codecs/amrwbenc/src/syn_filt.c
+++ b/media/libstagefright/codecs/amrwbenc/src/syn_filt.c
@@ -39,11 +39,11 @@
 	Word16 y_buf[L_SUBFR16k + M16k];
 	Word32 L_tmp;
 	Word16 *yy, *p1, *p2;
-	yy = &y_buf[0];                        
+	yy = &y_buf[0];
 	/* copy initial filter states into synthesis buffer */
 	for (i = 0; i < 16; i++)
 	{
-		*yy++ = mem[i];                    
+		*yy++ = mem[i];
 	}
 	a0 = (a[0] >> 1);                     /* input / 2 */
 	/* Do the filtering. */
@@ -70,7 +70,7 @@
 		L_tmp -= vo_mult32((*p1), (*p2));
 
 		L_tmp = L_shl2(L_tmp, 4);
-		y[i] = yy[i] = extract_h(L_add(L_tmp, 0x8000));  
+		y[i] = yy[i] = extract_h(L_add(L_tmp, 0x8000));
 	}
 	/* Update memory if required */
 	if (update)
@@ -99,7 +99,7 @@
 	/* Do the filtering. */
 	for (i = 0; i < lg; i++)
 	{
-		L_tmp  = 0; 
+		L_tmp  = 0;
 		L_tmp1 = 0;
 		p1 = a;
 		p2 = &sig_lo[i - 1];
@@ -138,18 +138,18 @@
 		L_tmp  -= vo_mult32((*p2--), (*p1));
 		L_tmp1 -= vo_mult32((*p3--), (*p1++));
 
-		L_tmp = L_tmp >> 11;      
+		L_tmp = L_tmp >> 11;
 		L_tmp += vo_L_mult(exc[i], a0);
 
 		/* sig_hi = bit16 to bit31 of synthesis */
 		L_tmp = L_tmp - (L_tmp1<<1);
 
 		L_tmp = L_tmp >> 3;           /* ai in Q12 */
-		sig_hi[i] = extract_h(L_tmp);      
+		sig_hi[i] = extract_h(L_tmp);
 
 		/* sig_lo = bit4 to bit15 of synthesis */
 		L_tmp >>= 4;           /* 4 : sig_lo[i] >> 4 */
-		sig_lo[i] = (Word16)((L_tmp - (sig_hi[i] << 13)));  
+		sig_lo[i] = (Word16)((L_tmp - (sig_hi[i] << 13)));
 	}
 
 	return;
diff --git a/media/libstagefright/codecs/amrwbenc/src/updt_tar.c b/media/libstagefright/codecs/amrwbenc/src/updt_tar.c
index eda2b1c..96779fd 100644
--- a/media/libstagefright/codecs/amrwbenc/src/updt_tar.c
+++ b/media/libstagefright/codecs/amrwbenc/src/updt_tar.c
@@ -39,7 +39,7 @@
 	{
 		L_tmp = x[i] << 15;
 		L_tmp -= (y[i] * gain)<<1;
-		x2[i] = extract_h(L_shl2(L_tmp, 1)); 
+		x2[i] = extract_h(L_shl2(L_tmp, 1));
 	}
 
 	return;
diff --git a/media/libstagefright/codecs/amrwbenc/src/voAMRWBEnc.c b/media/libstagefright/codecs/amrwbenc/src/voAMRWBEnc.c
index bac00dd..0f4d689 100644
--- a/media/libstagefright/codecs/amrwbenc/src/voAMRWBEnc.c
+++ b/media/libstagefright/codecs/amrwbenc/src/voAMRWBEnc.c
@@ -84,11 +84,11 @@
 	Set_zero(cod_state->old_exc, PIT_MAX + L_INTERPOL);
 	Set_zero(cod_state->mem_syn, M);
 	Set_zero(cod_state->past_isfq, M);
-	cod_state->mem_w0 = 0;                 
-	cod_state->tilt_code = 0;              
-	cod_state->first_frame = 1;            
+	cod_state->mem_w0 = 0;
+	cod_state->tilt_code = 0;
+	cod_state->first_frame = 1;
 	Init_gp_clip(cod_state->gp_clip);
-	cod_state->L_gc_thres = 0;             
+	cod_state->L_gc_thres = 0;
 	if (reset_all != 0)
 	{
 		/* Static vectors to zero */
@@ -105,21 +105,21 @@
 		Copy(isp_init, cod_state->ispold, M);
 		Copy(isp_init, cod_state->ispold_q, M);
 		/* variable initialization */
-		cod_state->mem_preemph = 0;        
-		cod_state->mem_wsp = 0;            
-		cod_state->Q_old = 15;             
-		cod_state->Q_max[0] = 15;          
-		cod_state->Q_max[1] = 15;          
-		cod_state->old_wsp_max = 0;        
-		cod_state->old_wsp_shift = 0;      
+		cod_state->mem_preemph = 0;
+		cod_state->mem_wsp = 0;
+		cod_state->Q_old = 15;
+		cod_state->Q_max[0] = 15;
+		cod_state->Q_max[1] = 15;
+		cod_state->old_wsp_max = 0;
+		cod_state->old_wsp_shift = 0;
 		/* pitch ol initialization */
-		cod_state->old_T0_med = 40;        
-		cod_state->ol_gain = 0;            
-		cod_state->ada_w = 0;              
-		cod_state->ol_wght_flg = 0;        
+		cod_state->old_T0_med = 40;
+		cod_state->ol_gain = 0;
+		cod_state->ada_w = 0;
+		cod_state->ol_wght_flg = 0;
 		for (i = 0; i < 5; i++)
 		{
-			cod_state->old_ol_lag[i] = 40; 
+			cod_state->old_ol_lag[i] = 40;
 		}
 		Set_zero(cod_state->old_hp_wsp, (L_FRAME / 2) / OPL_DECIM + (PIT_MAX / OPL_DECIM));
 		Set_zero(cod_state->mem_syn_hf, M);
@@ -129,10 +129,10 @@
 		Init_Filt_6k_7k(cod_state->mem_hf);
 		Init_HP400_12k8(cod_state->mem_hp400);
 		Copy(isf_init, cod_state->isfold, M);
-		cod_state->mem_deemph = 0;         
-		cod_state->seed2 = 21845;          
+		cod_state->mem_deemph = 0;
+		cod_state->seed2 = 21845;
 		Init_Filt_6k_7k(cod_state->mem_hf2);
-		cod_state->gain_alpha = 32767;     
+		cod_state->gain_alpha = 32767;
 		cod_state->vad_hist = 0;
 		wb_vad_reset(cod_state->vadSt);
 		dtx_enc_reset(cod_state->dtx_encSt, isf_init);
@@ -212,8 +212,8 @@
 
 	st = (Coder_State *) spe_state;
 
-	*ser_size = nb_of_bits[*mode];         
-	codec_mode = *mode;                    
+	*ser_size = nb_of_bits[*mode];
+	codec_mode = *mode;
 
 	/*--------------------------------------------------------------------------*
 	 *          Initialize pointers to speech vector.                           *
@@ -233,10 +233,10 @@
 
 	new_speech = old_speech + L_TOTAL - L_FRAME - L_FILT;         /* New speech     */
 	speech = old_speech + L_TOTAL - L_FRAME - L_NEXT;             /* Present frame  */
-	p_window = old_speech + L_TOTAL - L_WINDOW; 
+	p_window = old_speech + L_TOTAL - L_WINDOW;
 
-	exc = old_exc + PIT_MAX + L_INTERPOL;  
-	wsp = old_wsp + (PIT_MAX / OPL_DECIM); 
+	exc = old_exc + PIT_MAX + L_INTERPOL;
+	wsp = old_wsp + (PIT_MAX / OPL_DECIM);
 
 	/* copy coder memory state into working space */
 	Copy(st->old_speech, old_speech, L_TOTAL - L_FRAME);
@@ -287,7 +287,7 @@
 		L_tmp = L_abs(L_tmp);
 		if(L_tmp > L_max)
 		{
-			L_max = L_tmp;                 
+			L_max = L_tmp;
 		}
 	}
 
@@ -297,50 +297,50 @@
 	tmp = extract_h(L_max);
 	if (tmp == 0)
 	{
-		shift = Q_MAX;                     
+		shift = Q_MAX;
 	} else
 	{
 		shift = norm_s(tmp) - 1;
 		if (shift < 0)
 		{
-			shift = 0;                     
+			shift = 0;
 		}
 		if (shift > Q_MAX)
 		{
-			shift = Q_MAX;                 
+			shift = Q_MAX;
 		}
 	}
-	Q_new = shift;                         
+	Q_new = shift;
 	if (Q_new > st->Q_max[0])
 	{
-		Q_new = st->Q_max[0];              
+		Q_new = st->Q_max[0];
 	}
 	if (Q_new > st->Q_max[1])
 	{
-		Q_new = st->Q_max[1];              
+		Q_new = st->Q_max[1];
 	}
 	exp = (Q_new - st->Q_old);
-	st->Q_old = Q_new;                     
-	st->Q_max[1] = st->Q_max[0];           
-	st->Q_max[0] = shift;                  
+	st->Q_old = Q_new;
+	st->Q_max[1] = st->Q_max[0];
+	st->Q_max[0] = shift;
 
 	/* preemphasis with scaling (L_FRAME+L_FILT) */
-	tmp = new_speech[L_FRAME - 1];         
+	tmp = new_speech[L_FRAME - 1];
 
 	for (i = L_FRAME + L_FILT - 1; i > 0; i--)
 	{
 		L_tmp = new_speech[i] << 15;
 		L_tmp -= (new_speech[i - 1] * mu)<<1;
 		L_tmp = (L_tmp << Q_new);
-		new_speech[i] = vo_round(L_tmp);      
+		new_speech[i] = vo_round(L_tmp);
 	}
 
 	L_tmp = new_speech[0] << 15;
 	L_tmp -= (st->mem_preemph * mu)<<1;
 	L_tmp = (L_tmp << Q_new);
-	new_speech[0] = vo_round(L_tmp);          
+	new_speech[0] = vo_round(L_tmp);
 
-	st->mem_preemph = tmp;                 
+	st->mem_preemph = tmp;
 
 	/* scale previous samples and memory */
 
@@ -364,13 +364,13 @@
 	Scale_sig(buf, L_FRAME, 1 - Q_new);
 #endif
 
-	vad_flag = wb_vad(st->vadSt, buf);          /* Voice Activity Detection */ 
+	vad_flag = wb_vad(st->vadSt, buf);          /* Voice Activity Detection */
 	if (vad_flag == 0)
 	{
-		st->vad_hist = (st->vad_hist + 1);        
+		st->vad_hist = (st->vad_hist + 1);
 	} else
 	{
-		st->vad_hist = 0;             
+		st->vad_hist = 0;
 	}
 
 	/* DTX processing */
@@ -378,7 +378,7 @@
 	{
 		/* Note that mode may change here */
 		tx_dtx_handler(st->dtx_encSt, vad_flag, mode);
-		*ser_size = nb_of_bits[*mode]; 
+		*ser_size = nb_of_bits[*mode];
 	}
 
 	if(*mode != MRDTX)
@@ -423,7 +423,7 @@
 	 * - scale wsp[] to avoid overflow in pitch estimation                  *
 	 * - Find open loop pitch lag for whole speech frame                    *
 	 *----------------------------------------------------------------------*/
-	p_A = A;                             
+	p_A = A;
 	for (i_subfr = 0; i_subfr < L_FRAME; i_subfr += L_SUBFR)
 	{
 		/* Weighting of LPC coefficients */
@@ -435,27 +435,27 @@
 		Residu(Ap, &speech[i_subfr], &wsp[i_subfr], L_SUBFR);
 #endif
 
-		p_A += (M + 1);                    
+		p_A += (M + 1);
 	}
 
 	Deemph2(wsp, TILT_FAC, L_FRAME, &(st->mem_wsp));
 
 	/* find maximum value on wsp[] for 12 bits scaling */
-	max = 0;                              
+	max = 0;
 	for (i = 0; i < L_FRAME; i++)
 	{
 		tmp = abs_s(wsp[i]);
 		if(tmp > max)
 		{
-			max = tmp;                     
+			max = tmp;
 		}
 	}
-	tmp = st->old_wsp_max;                 
+	tmp = st->old_wsp_max;
 	if(max > tmp)
 	{
 		tmp = max;                         /* tmp = max(wsp_max, old_wsp_max) */
 	}
-	st->old_wsp_max = max;                
+	st->old_wsp_max = max;
 
 	shift = norm_s(tmp) - 3;
 	if (shift > 0)
@@ -494,8 +494,8 @@
 
 	if(st->ol_gain > 19661)       /* 0.6 in Q15 */
 	{
-		st->old_T0_med = Med_olag(T_op, st->old_ol_lag);       
-		st->ada_w = 32767;                 
+		st->old_T0_med = Med_olag(T_op, st->old_ol_lag);
+		st->ada_w = 32767;
 	} else
 	{
 		st->ada_w = vo_mult(st->ada_w, 29491);
@@ -507,7 +507,7 @@
 		st->ol_wght_flg = 1;
 
 	wb_vad_tone_detection(st->vadSt, st->ol_gain);
-	T_op *= OPL_DECIM;                     
+	T_op *= OPL_DECIM;
 
 	if(*ser_size != NBBITS_7k)
 	{
@@ -516,11 +516,11 @@
 
 		if(st->ol_gain > 19661)   /* 0.6 in Q15 */
 		{
-			st->old_T0_med = Med_olag(T_op2, st->old_ol_lag);  
-			st->ada_w = 32767;             
+			st->old_T0_med = Med_olag(T_op2, st->old_ol_lag);
+			st->ada_w = 32767;
 		} else
 		{
-			st->ada_w = mult(st->ada_w, 29491); 
+			st->ada_w = mult(st->ada_w, 29491);
 		}
 
 		if(st->ada_w < 26214)
@@ -530,11 +530,11 @@
 
 		wb_vad_tone_detection(st->vadSt, st->ol_gain);
 
-		T_op2 *= OPL_DECIM;                
+		T_op2 *= OPL_DECIM;
 
 	} else
 	{
-		T_op2 = T_op;                      
+		T_op2 = T_op;
 	}
 	/*----------------------------------------------------------------------*
 	 *                              DTX-CNG                                 *
@@ -550,10 +550,10 @@
 
 		for (i = 0; i < L_FRAME; i++)
 		{
-			exc2[i] = shr(exc[i], Q_new);  
+			exc2[i] = shr(exc[i], Q_new);
 		}
 
-		L_tmp = 0;                         
+		L_tmp = 0;
 		for (i = 0; i < L_FRAME; i++)
 			L_tmp += (exc2[i] * exc2[i])<<1;
 
@@ -617,23 +617,23 @@
 
 	/* Check stability on isf : distance between old isf and current isf */
 
-	L_tmp = 0;                           
+	L_tmp = 0;
 	for (i = 0; i < M - 1; i++)
 	{
 		tmp = vo_sub(isf[i], st->isfold[i]);
 		L_tmp += (tmp * tmp)<<1;
 	}
 
-	tmp = extract_h(L_shl2(L_tmp, 8)); 
+	tmp = extract_h(L_shl2(L_tmp, 8));
 
 	tmp = vo_mult(tmp, 26214);                /* tmp = L_tmp*0.8/256 */
 	tmp = vo_sub(20480, tmp);                 /* 1.25 - tmp (in Q14) */
 
-	stab_fac = shl(tmp, 1); 
+	stab_fac = shl(tmp, 1);
 
 	if (stab_fac < 0)
 	{
-		stab_fac = 0;                      
+		stab_fac = 0;
 	}
 	Copy(isf, st->isfold, M);
 
@@ -642,7 +642,7 @@
 
 	if (st->first_frame != 0)
 	{
-		st->first_frame = 0;              
+		st->first_frame = 0;
 		Copy(ispnew_q, st->ispold_q, M);
 	}
 	/* Find the interpolated ISPs and convert to a[] for all subframes */
@@ -660,7 +660,7 @@
 #else
 		Residu(p_Aq, &speech[i_subfr], &exc[i_subfr], L_SUBFR);
 #endif
-		p_Aq += (M + 1);                   
+		p_Aq += (M + 1);
 	}
 
 	/* Buffer isf's and energy for dtx on non-speech frame */
@@ -670,7 +670,7 @@
 		{
 			exc2[i] = exc[i] >> Q_new;
 		}
-		L_tmp = 0;                         
+		L_tmp = 0;
 		for (i = 0; i < L_FRAME; i++)
 			L_tmp += (exc2[i] * exc2[i])<<1;
 		L_tmp >>= 1;
@@ -682,14 +682,14 @@
 	T0_min = T_op - 8;
 	if (T0_min < PIT_MIN)
 	{
-		T0_min = PIT_MIN;                  
+		T0_min = PIT_MIN;
 	}
 	T0_max = (T0_min + 15);
 
 	if(T0_max > PIT_MAX)
 	{
-		T0_max = PIT_MAX;                  
-		T0_min = T0_max - 15;          
+		T0_max = PIT_MAX;
+		T0_min = T0_max - 15;
 	}
 	/*------------------------------------------------------------------------*
 	 *          Loop for every subframe in the analysis frame                 *
@@ -711,25 +711,25 @@
 	 *     - update states of weighting filter                                *
 	 *     - find excitation and synthesis speech                             *
 	 *------------------------------------------------------------------------*/
-	p_A = A;                               
-	p_Aq = Aq;                             
+	p_A = A;
+	p_Aq = Aq;
 	for (i_subfr = 0; i_subfr < L_FRAME; i_subfr += L_SUBFR)
 	{
-		pit_flag = i_subfr;                
+		pit_flag = i_subfr;
 		if ((i_subfr == 2 * L_SUBFR) && (*ser_size > NBBITS_7k))
 		{
-			pit_flag = 0;                 
+			pit_flag = 0;
 			/* range for closed loop pitch search in 3rd subframe */
 			T0_min = (T_op2 - 8);
 
 			if (T0_min < PIT_MIN)
 			{
-				T0_min = PIT_MIN;          
+				T0_min = PIT_MIN;
 			}
 			T0_max = (T0_min + 15);
 			if (T0_max > PIT_MAX)
 			{
-				T0_max = PIT_MAX;         
+				T0_max = PIT_MAX;
 				T0_min = (T0_max - 15);
 			}
 		}
@@ -776,7 +776,7 @@
 		/* first half: xn[] --> cn[] */
 		Set_zero(code, M);
 		Copy(xn, code + M, L_SUBFR / 2);
-		tmp = 0;                          
+		tmp = 0;
 		Preemph2(code + M, TILT_FAC, L_SUBFR / 2, &tmp);
 		Weight_a(p_A, Ap, GAMMA1, M);
 		Syn_filt(Ap,code + M, code + M, L_SUBFR / 2, code, 0);
@@ -791,7 +791,7 @@
 		Copy(&exc[i_subfr + (L_SUBFR / 2)], cn + (L_SUBFR / 2), L_SUBFR / 2);
 
 		/*---------------------------------------------------------------*
-		 * Compute impulse response, h1[], of weighted synthesis filter  * 
+		 * Compute impulse response, h1[], of weighted synthesis filter  *
 		 *---------------------------------------------------------------*/
 
 		Set_zero(error, M + L_SUBFR);
@@ -814,7 +814,7 @@
 			*vo_p3++ = *vo_p0++ = vo_round((L_tmp <<4));
 		}
 		/* deemph without division by 2 -> Q14 to Q15 */
-		tmp = 0; 
+		tmp = 0;
 		Deemph2(h1, TILT_FAC, L_SUBFR, &tmp);   /* h1 in Q14 */
 
 		/* h2 in Q12 for codebook search */
@@ -917,7 +917,7 @@
 				T0_min = (T0 - 8);
 				if (T0_min < PIT_MIN)
 				{
-					T0_min = PIT_MIN; 
+					T0_min = PIT_MIN;
 				}
 				T0_max = T0_min + 15;
 
@@ -964,18 +964,18 @@
 			Convolve_asm(&exc[i_subfr], h1, y1, L_SUBFR);
 #else
 			Convolve(&exc[i_subfr], h1, y1, L_SUBFR);
-#endif 
+#endif
 			gain1 = G_pitch(xn, y1, g_coeff, L_SUBFR);
 			/* clip gain if necessary to avoid problem at decoder */
 			if ((clip_gain != 0) && (gain1 > GP_CLIP))
 			{
-				gain1 = GP_CLIP; 
+				gain1 = GP_CLIP;
 			}
 			/* find energy of new target xn2[] */
 			Updt_tar(xn, dn, y1, gain1, L_SUBFR);       /* dn used temporary */
 		} else
 		{
-			gain1 = 0; 
+			gain1 = 0;
 		}
 		/*-----------------------------------------------------------------*
 		 * - find pitch excitation filtered by 1st order LP filter.        *
@@ -1002,7 +1002,7 @@
 		Convolve_asm(code, h1, y2, L_SUBFR);
 #else
 		Convolve(code, h1, y2, L_SUBFR);
-#endif 
+#endif
 
 		gain2 = G_pitch(xn, y2, g_coeff2, L_SUBFR);
 
@@ -1016,7 +1016,7 @@
 		/*-----------------------------------------------------------------*
 		 * use the best prediction (minimise quadratic error).             *
 		 *-----------------------------------------------------------------*/
-		select = 0; 
+		select = 0;
 		if(*ser_size > NBBITS_9k)
 		{
 			L_tmp = 0L;
@@ -1036,7 +1036,7 @@
 
 			if (L_tmp <= 0)
 			{
-				select = 1; 
+				select = 1;
 			}
 			Parm_serial(select, 1, &prms);
 		}
@@ -1154,7 +1154,7 @@
 		/*-------------------------------------------------------*
 		 * - Add the fixed-gain pitch contribution to code[].    *
 		 *-------------------------------------------------------*/
-		tmp = 0; 
+		tmp = 0;
 		Preemph(code, st->tilt_code, L_SUBFR, &tmp);
 		Pit_shrp(code, T0, PIT_SHARP, L_SUBFR);
 		/*----------------------------------------------------------*
@@ -1175,7 +1175,7 @@
 		/* test quantized gain of pitch for pitch clipping algorithm */
 		Gp_clip_test_gain_pit(gain_pit, st->gp_clip);
 
-		L_tmp = L_shl(L_gain_code, Q_new); 
+		L_tmp = L_shl(L_gain_code, Q_new);
 		gain_code = extract_h(L_add(L_tmp, 0x8000));
 
 		/*----------------------------------------------------------*
@@ -1218,7 +1218,7 @@
 			L_tmp = (gain_code * code[i])<<1;
 			L_tmp = (L_tmp << 5);
 			L_tmp += (exc[i + i_subfr] * gain_pit)<<1;
-			L_tmp = L_shl2(L_tmp, 1); 
+			L_tmp = L_shl2(L_tmp, 1);
 			exc[i + i_subfr] = extract_h(L_add(L_tmp, 0x8000));
 		}
 
@@ -1242,7 +1242,7 @@
 			 *------------------------------------------------------------*/
 			tmp = (16384 - (voice_fac >> 1));        /* 1=unvoiced, 0=voiced */
 			fac = vo_mult(stab_fac, tmp);
-			L_tmp = L_gain_code; 
+			L_tmp = L_gain_code;
 			if(L_tmp < st->L_gc_thres)
 			{
 				L_tmp = vo_L_add(L_tmp, Mpy_32_16(gain_code, gain_code_lo, 6226));
@@ -1276,19 +1276,19 @@
 
 			L_tmp = L_deposit_h(code[0]);
 			L_tmp -= (code[1] * tmp)<<1;
-			code2[0] = vo_round(L_tmp); 
+			code2[0] = vo_round(L_tmp);
 
 			for (i = 1; i < L_SUBFR - 1; i++)
 			{
 				L_tmp = L_deposit_h(code[i]);
 				L_tmp -= (code[i + 1] * tmp)<<1;
 				L_tmp -= (code[i - 1] * tmp)<<1;
-				code2[i] = vo_round(L_tmp); 
+				code2[i] = vo_round(L_tmp);
 			}
 
 			L_tmp = L_deposit_h(code[L_SUBFR - 1]);
 			L_tmp -= (code[L_SUBFR - 2] * tmp)<<1;
-			code2[L_SUBFR - 1] = vo_round(L_tmp); 
+			code2[L_SUBFR - 1] = vo_round(L_tmp);
 
 			/* build excitation */
 			gain_code = vo_round(L_shl(L_gain_code, Q_new));
@@ -1381,7 +1381,7 @@
 	/* Original speech signal as reference for high band gain quantisation */
 	for (i = 0; i < L_SUBFR16k; i++)
 	{
-		HF_SP[i] = synth16k[i]; 
+		HF_SP[i] = synth16k[i];
 	}
 
 	/*------------------------------------------------------*
@@ -1454,7 +1454,7 @@
 		fac = div_s(tmp, ener);
 	} else
 	{
-		fac = 0; 
+		fac = 0;
 	}
 
 	/* modify energy of white noise according to synthesis tilt */
@@ -1550,7 +1550,7 @@
 
 /*************************************************
 *
-* Breif: Codec main function 
+* Breif: Codec main function
 *
 **************************************************/
 
@@ -1622,7 +1622,7 @@
 	else
 	{
 		pMemOP = (VO_MEM_OPERATOR *)pUserData->memData;
-	} 
+	}
 	/*-------------------------------------------------------------------------*
 	 * Memory allocation for coder state.                                      *
 	 *-------------------------------------------------------------------------*/
@@ -1631,8 +1631,8 @@
 		return VO_ERR_OUTOF_MEMORY;
 	}
 
-	st->vadSt = NULL;                      
-	st->dtx_encSt = NULL;                  
+	st->vadSt = NULL;
+	st->dtx_encSt = NULL;
 	st->sid_update_counter = 3;
 	st->sid_handover_debt = 0;
 	st->prev_ft = TX_SPEECH;
@@ -1764,7 +1764,7 @@
 	{
 		pAudioFormat->Format.Channels = 1;
 		pAudioFormat->Format.SampleRate = 8000;
-		pAudioFormat->Format.SampleBits = 16;	
+		pAudioFormat->Format.SampleBits = 16;
 		pAudioFormat->InputUsed = stream->used_len;
 	}
 	return VO_ERR_NONE;
@@ -1792,14 +1792,14 @@
 		/* setting AMR-WB frame type*/
 		case VO_PID_AMRWB_FRAMETYPE:
 			if(*lValue < VOAMRWB_DEFAULT || *lValue > VOAMRWB_RFC3267)
-				return VO_ERR_WRONG_PARAM_ID; 
+				return VO_ERR_WRONG_PARAM_ID;
 			gData->frameType = *lValue;
 			break;
 		/* setting AMR-WB bit rate */
 		case VO_PID_AMRWB_MODE:
 			{
 				if(*lValue < VOAMRWB_MD66 || *lValue > VOAMRWB_MD2385)
-					return VO_ERR_WRONG_PARAM_ID; 
+					return VO_ERR_WRONG_PARAM_ID;
 				gData->mode = *lValue;
 			}
 			break;
@@ -1839,7 +1839,7 @@
 	int    temp;
 	Coder_State* gData = (Coder_State*)hCodec;
 
-	if (gData==NULL) 
+	if (gData==NULL)
 		return VO_ERR_INVALID_ARG;
 	switch(uParamID)
 	{
diff --git a/media/libstagefright/codecs/amrwbenc/src/voicefac.c b/media/libstagefright/codecs/amrwbenc/src/voicefac.c
index 17e4e55..d890044 100644
--- a/media/libstagefright/codecs/amrwbenc/src/voicefac.c
+++ b/media/libstagefright/codecs/amrwbenc/src/voicefac.c
@@ -18,7 +18,7 @@
 *   File: voicefac.c                                                   *
 *                                                                      *
 *   Description: Find the voicing factors (1 = voice to -1 = unvoiced) *
-*                                                                      *                                                 
+*                                                                      *
 ************************************************************************/
 
 #include "typedef.h"
diff --git a/media/libstagefright/codecs/amrwbenc/src/wb_vad.c b/media/libstagefright/codecs/amrwbenc/src/wb_vad.c
index 7e1d673..13dd2aa 100644
--- a/media/libstagefright/codecs/amrwbenc/src/wb_vad.c
+++ b/media/libstagefright/codecs/amrwbenc/src/wb_vad.c
@@ -52,7 +52,7 @@
 
 	if (mant <= 0)
 	{
-		mant = 1;                         
+		mant = 1;
 	}
 	ex = norm_s(mant);
 	mant = mant << ex;
@@ -88,14 +88,14 @@
 
 	temp0 = vo_sub(*in0, vo_mult(COEFF5_1, data[0]));
 	temp1 = add1(data[0], vo_mult(COEFF5_1, temp0));
-	data[0] = temp0;                      
+	data[0] = temp0;
 
 	temp0 = vo_sub(*in1, vo_mult(COEFF5_2, data[1]));
 	temp2 = add1(data[1], vo_mult(COEFF5_2, temp0));
-	data[1] = temp0;                       
+	data[1] = temp0;
 
-	*in0 = extract_h((vo_L_add(temp1, temp2) << 15));   
-	*in1 = extract_h((vo_L_sub(temp1, temp2) << 15));  
+	*in0 = extract_h((vo_L_add(temp1, temp2) << 15));
+	*in1 = extract_h((vo_L_sub(temp1, temp2) << 15));
 }
 
 /******************************************************************************
@@ -116,10 +116,10 @@
 
 	temp1 = vo_sub(*in1, vo_mult(COEFF3, *data));
 	temp2 = add1(*data, vo_mult(COEFF3, temp1));
-	*data = temp1;                        
+	*data = temp1;
 
-	*in1 = extract_h((vo_L_sub(*in0, temp2) << 15));   
-	*in0 = extract_h((vo_L_add(*in0, temp2) << 15));   
+	*in1 = extract_h((vo_L_sub(*in0, temp2) << 15));
+	*in0 = extract_h((vo_L_add(*in0, temp2) << 15));
 }
 
 /******************************************************************************
@@ -149,14 +149,14 @@
 	Word32 i, l_temp1, l_temp2;
 	Word16 level;
 
-	l_temp1 = 0L;                          
+	l_temp1 = 0L;
 	for (i = count1; i < count2; i++)
 	{
 		l_temp1 += (abs_s(data[ind_m * i + ind_a])<<1);
 	}
 
 	l_temp2 = vo_L_add(l_temp1, L_shl(*sub_level, 16 - scale));
-	*sub_level = extract_h(L_shl(l_temp1, scale));      
+	*sub_level = extract_h(L_shl(l_temp1, scale));
 
 	for (i = 0; i < count1; i++)
 	{
@@ -187,7 +187,7 @@
 	/* shift input 1 bit down for safe scaling */
 	for (i = 0; i < FRAME_LEN; i++)
 	{
-		tmp_buf[i] = in[i] >> 1;       
+		tmp_buf[i] = in[i] >> 1;
 	}
 
 	/* run the filter bank */
@@ -222,29 +222,29 @@
 	/* calculate levels in each frequency band */
 
 	/* 4800 - 6400 Hz */
-	level[11] = level_calculation(tmp_buf, &st->sub_level[11], 16, 64, 4, 1, 14);   
+	level[11] = level_calculation(tmp_buf, &st->sub_level[11], 16, 64, 4, 1, 14);
 	/* 4000 - 4800 Hz */
-	level[10] = level_calculation(tmp_buf, &st->sub_level[10], 8, 32, 8, 7, 15);   
+	level[10] = level_calculation(tmp_buf, &st->sub_level[10], 8, 32, 8, 7, 15);
 	/* 3200 - 4000 Hz */
-	level[9] = level_calculation(tmp_buf, &st->sub_level[9],8, 32, 8, 3, 15);   
+	level[9] = level_calculation(tmp_buf, &st->sub_level[9],8, 32, 8, 3, 15);
 	/* 2400 - 3200 Hz */
-	level[8] = level_calculation(tmp_buf, &st->sub_level[8],8, 32, 8, 2, 15);   
+	level[8] = level_calculation(tmp_buf, &st->sub_level[8],8, 32, 8, 2, 15);
 	/* 2000 - 2400 Hz */
-	level[7] = level_calculation(tmp_buf, &st->sub_level[7],4, 16, 16, 14, 16);       
+	level[7] = level_calculation(tmp_buf, &st->sub_level[7],4, 16, 16, 14, 16);
 	/* 1600 - 2000 Hz */
-	level[6] = level_calculation(tmp_buf, &st->sub_level[6],4, 16, 16, 6, 16);        
+	level[6] = level_calculation(tmp_buf, &st->sub_level[6],4, 16, 16, 6, 16);
 	/* 1200 - 1600 Hz */
-	level[5] = level_calculation(tmp_buf, &st->sub_level[5],4, 16, 16, 4, 16);        
+	level[5] = level_calculation(tmp_buf, &st->sub_level[5],4, 16, 16, 4, 16);
 	/* 800 - 1200 Hz */
-	level[4] = level_calculation(tmp_buf, &st->sub_level[4],4, 16, 16, 12, 16);       
+	level[4] = level_calculation(tmp_buf, &st->sub_level[4],4, 16, 16, 12, 16);
 	/* 600 - 800 Hz */
-	level[3] = level_calculation(tmp_buf, &st->sub_level[3],2, 8, 32, 8, 17); 
+	level[3] = level_calculation(tmp_buf, &st->sub_level[3],2, 8, 32, 8, 17);
 	/* 400 - 600 Hz */
-	level[2] = level_calculation(tmp_buf, &st->sub_level[2],2, 8, 32, 24, 17);        
+	level[2] = level_calculation(tmp_buf, &st->sub_level[2],2, 8, 32, 24, 17);
 	/* 200 - 400 Hz */
-	level[1] = level_calculation(tmp_buf, &st->sub_level[1],2, 8, 32, 16, 17);        
+	level[1] = level_calculation(tmp_buf, &st->sub_level[1],2, 8, 32, 16, 17);
 	/* 0 - 200 Hz */
-	level[0] = level_calculation(tmp_buf, &st->sub_level[0],2, 8, 32, 0, 17); 
+	level[0] = level_calculation(tmp_buf, &st->sub_level[0],2, 8, 32, 0, 17);
 }
 
 /******************************************************************************
@@ -266,31 +266,31 @@
 	/* if a tone has been detected for a while, initialize stat_count */
 	if (sub((Word16) (st->tone_flag & 0x7c00), 0x7c00) == 0)
 	{
-		st->stat_count = STAT_COUNT;      
+		st->stat_count = STAT_COUNT;
 	} else
 	{
 		/* if 8 last vad-decisions have been "0", reinitialize stat_count */
 		if ((st->vadreg & 0x7f80) == 0)
 		{
-			st->stat_count = STAT_COUNT;   
+			st->stat_count = STAT_COUNT;
 		} else
 		{
-			stat_rat = 0;                  
+			stat_rat = 0;
 			for (i = 0; i < COMPLEN; i++)
 			{
 				if(level[i] > st->ave_level[i])
 				{
-					num = level[i];        
-					denom = st->ave_level[i];   
+					num = level[i];
+					denom = st->ave_level[i];
 				} else
 				{
 					num = st->ave_level[i];
-					denom = level[i];      
+					denom = level[i];
 				}
 				/* Limit nimimum value of num and denom to STAT_THR_LEVEL */
 				if(num < STAT_THR_LEVEL)
 				{
-					num = STAT_THR_LEVEL;  
+					num = STAT_THR_LEVEL;
 				}
 				if(denom < STAT_THR_LEVEL)
 				{
@@ -307,7 +307,7 @@
 			/* compare stat_rat with a threshold and update stat_count */
 			if(stat_rat > STAT_THR)
 			{
-				st->stat_count = STAT_COUNT;    
+				st->stat_count = STAT_COUNT;
 			} else
 			{
 				if ((st->vadreg & 0x4000) != 0)
@@ -315,7 +315,7 @@
 
 					if (st->stat_count != 0)
 					{
-						st->stat_count = st->stat_count - 1;       
+						st->stat_count = st->stat_count - 1;
 					}
 				}
 			}
@@ -323,17 +323,17 @@
 	}
 
 	/* Update average amplitude estimate for stationarity estimation */
-	alpha = ALPHA4;                        
+	alpha = ALPHA4;
 	if(st->stat_count == STAT_COUNT)
 	{
-		alpha = 32767;                    
+		alpha = 32767;
 	} else if ((st->vadreg & 0x4000) == 0)
 	{
-		alpha = ALPHA5;                   
+		alpha = ALPHA5;
 	}
 	for (i = 0; i < COMPLEN; i++)
 	{
-		st->ave_level[i] = add1(st->ave_level[i], vo_mult_r(alpha, vo_sub(level[i], st->ave_level[i])));   
+		st->ave_level[i] = add1(st->ave_level[i], vo_mult_r(alpha, vo_sub(level[i], st->ave_level[i])));
 	}
 }
 
@@ -354,25 +354,25 @@
 	/* if the input power (pow_sum) is lower than a threshold, clear counters and set VAD_flag to "0"         */
 	if (low_power != 0)
 	{
-		st->burst_count = 0;               
-		st->hang_count = 0;                
+		st->burst_count = 0;
+		st->hang_count = 0;
 		return 0;
 	}
 	/* update the counters (hang_count, burst_count) */
 	if ((st->vadreg & 0x4000) != 0)
 	{
-		st->burst_count = st->burst_count + 1;    
+		st->burst_count = st->burst_count + 1;
 		if(st->burst_count >= burst_len)
 		{
-			st->hang_count = hang_len;     
+			st->hang_count = hang_len;
 		}
 		return 1;
 	} else
 	{
-		st->burst_count = 0;               
+		st->burst_count = 0;
 		if (st->hang_count > 0)
 		{
-			st->hang_count = st->hang_count - 1;    
+			st->hang_count = st->hang_count - 1;
 			return 1;
 		}
 	}
@@ -391,7 +391,7 @@
 		Word16 level[]                        /* i   : sub-band levels of the input frame */
 		)
 {
-	Word32 i; 
+	Word32 i;
 	Word16 alpha_up, alpha_down, bckr_add = 2;
 
 	/* Control update of bckr_est[] */
@@ -400,19 +400,19 @@
 	/* Choose update speed */
 	if ((0x7800 & st->vadreg) == 0)
 	{
-		alpha_up = ALPHA_UP1;              
-		alpha_down = ALPHA_DOWN1;          
+		alpha_up = ALPHA_UP1;
+		alpha_down = ALPHA_DOWN1;
 	} else
 	{
 		if ((st->stat_count == 0))
 		{
-			alpha_up = ALPHA_UP2;          
-			alpha_down = ALPHA_DOWN2;      
+			alpha_up = ALPHA_UP2;
+			alpha_down = ALPHA_DOWN2;
 		} else
 		{
-			alpha_up = 0;                  
-			alpha_down = ALPHA3;           
-			bckr_add = 0;                  
+			alpha_up = 0;
+			alpha_down = ALPHA3;
+			bckr_add = 0;
 		}
 	}
 
@@ -424,20 +424,20 @@
 
 		if (temp < 0)
 		{                                  /* update downwards */
-			st->bckr_est[i] = add1(-2, add(st->bckr_est[i],vo_mult_r(alpha_down, temp))); 
+			st->bckr_est[i] = add1(-2, add(st->bckr_est[i],vo_mult_r(alpha_down, temp)));
 			/* limit minimum value of the noise estimate to NOISE_MIN */
 			if(st->bckr_est[i] < NOISE_MIN)
 			{
-				st->bckr_est[i] = NOISE_MIN;   
+				st->bckr_est[i] = NOISE_MIN;
 			}
 		} else
 		{                                  /* update upwards */
-			st->bckr_est[i] = add1(bckr_add, add1(st->bckr_est[i],vo_mult_r(alpha_up, temp)));   
+			st->bckr_est[i] = add1(bckr_add, add1(st->bckr_est[i],vo_mult_r(alpha_up, temp)));
 
 			/* limit maximum value of the noise estimate to NOISE_MAX */
 			if(st->bckr_est[i] > NOISE_MAX)
 			{
-				st->bckr_est[i] = NOISE_MAX;    
+				st->bckr_est[i] = NOISE_MAX;
 			}
 		}
 	}
@@ -445,7 +445,7 @@
 	/* Update signal levels of the previous frame (old_level) */
 	for (i = 0; i < COMPLEN; i++)
 	{
-		st->old_level[i] = level[i];      
+		st->old_level[i] = level[i];
 	}
 }
 
@@ -473,7 +473,7 @@
 
 	/* Calculate squared sum of the input levels (level) divided by the background noise components
 	 * (bckr_est). */
-	L_snr_sum = 0;                        
+	L_snr_sum = 0;
 	for (i = 0; i < COMPLEN; i++)
 	{
 		Word16 exp;
@@ -486,7 +486,7 @@
 	}
 
 	/* Calculate average level of estimated background noise */
-	L_temp = 0;                           
+	L_temp = 0;
 	for (i = 1; i < COMPLEN; i++)          /* ignore lowest band */
 	{
 		L_temp = vo_L_add(L_temp, st->bckr_est[i]);
@@ -498,7 +498,7 @@
 
 	if(st->speech_level < temp)
 	{
-		st->speech_level = temp;          
+		st->speech_level = temp;
 	}
 	ilog2_noise_level = ilog2(noise_level);
 
@@ -511,33 +511,33 @@
 	temp2 = add1(SP_CH_MIN, vo_mult(SP_SLOPE, (ilog2_speech_level - SP_P1)));
 	if (temp2 < SP_CH_MIN)
 	{
-		temp2 = SP_CH_MIN;                 
+		temp2 = SP_CH_MIN;
 	}
 	if (temp2 > SP_CH_MAX)
 	{
-		temp2 = SP_CH_MAX;                 
+		temp2 = SP_CH_MAX;
 	}
 	vad_thr = temp + temp2;
 
 	if(vad_thr < THR_MIN)
 	{
-		vad_thr = THR_MIN;                 
+		vad_thr = THR_MIN;
 	}
 	/* Shift VAD decision register */
-	st->vadreg = (st->vadreg >> 1);       
+	st->vadreg = (st->vadreg >> 1);
 
 	/* Make intermediate VAD decision */
 	if(L_snr_sum > vo_L_mult(vad_thr, (512 * COMPLEN)))
 	{
-		st->vadreg = (Word16) (st->vadreg | 0x4000); 
+		st->vadreg = (Word16) (st->vadreg | 0x4000);
 	}
 	/* check if the input power (pow_sum) is lower than a threshold" */
 	if(pow_sum < VAD_POW_LOW)
 	{
-		low_power_flag = 1;               
+		low_power_flag = 1;
 	} else
 	{
-		low_power_flag = 0;               
+		low_power_flag = 0;
 	}
 	/* Update background noise estimates */
 	noise_estimate_update(st, level);
@@ -546,7 +546,7 @@
 	hang_len = add1(vo_mult(HANG_SLOPE, (vad_thr - HANG_P1)), HANG_HIGH);
 	if(hang_len < HANG_LOW)
 	{
-		hang_len = HANG_LOW;              
+		hang_len = HANG_LOW;
 	}
 	burst_len = add1(vo_mult(BURST_SLOPE, (vad_thr - BURST_P1)), BURST_HIGH);
 
@@ -575,20 +575,20 @@
 	/* if the required activity count cannot be achieved, reset counters */
 	if((st->sp_est_cnt - st->sp_max_cnt) > (SP_EST_COUNT - SP_ACTIVITY_COUNT))
 	{
-		st->sp_est_cnt = 0;                
-		st->sp_max = 0;                    
-		st->sp_max_cnt = 0;                
+		st->sp_est_cnt = 0;
+		st->sp_max = 0;
+		st->sp_max_cnt = 0;
 	}
-	st->sp_est_cnt += 1; 
+	st->sp_est_cnt += 1;
 
 	if (((st->vadreg & 0x4000)||(in_level > st->speech_level)) && (in_level > MIN_SPEECH_LEVEL1))
 	{
 		/* update sp_max */
 		if(in_level > st->sp_max)
 		{
-			st->sp_max = in_level;         
+			st->sp_max = in_level;
 		}
-		st->sp_max_cnt += 1;        
+		st->sp_max_cnt += 1;
 
 		if(st->sp_max_cnt >= SP_ACTIVITY_COUNT)
 		{
@@ -599,19 +599,19 @@
 			/* select update speed */
 			if(tmp > st->speech_level)
 			{
-				alpha = ALPHA_SP_UP;       
+				alpha = ALPHA_SP_UP;
 			} else
 			{
-				alpha = ALPHA_SP_DOWN;    
+				alpha = ALPHA_SP_DOWN;
 			}
 			if(tmp > MIN_SPEECH_LEVEL2)
 			{
-				st->speech_level = add1(st->speech_level, vo_mult_r(alpha, vo_sub(tmp, st->speech_level))); 
+				st->speech_level = add1(st->speech_level, vo_mult_r(alpha, vo_sub(tmp, st->speech_level)));
 			}
 			/* clear all counters used for speech estimation */
-			st->sp_max = 0;                
-			st->sp_max_cnt = 0;            
-			st->sp_est_cnt = 0;            
+			st->sp_max = 0;
+			st->sp_max_cnt = 0;
+			st->sp_est_cnt = 0;
 		}
 	}
 }
@@ -767,22 +767,22 @@
 	Word32 L_temp, pow_sum;
 
 	/* Calculate power of the input frame. */
-	L_temp = 0L;                           
+	L_temp = 0L;
 	for (i = 0; i < FRAME_LEN; i++)
 	{
 		L_temp = L_mac(L_temp, in_buf[i], in_buf[i]);
 	}
 
 	/* pow_sum = power of current frame and previous frame */
-	pow_sum = L_add(L_temp, st->prev_pow_sum);  
+	pow_sum = L_add(L_temp, st->prev_pow_sum);
 
 	/* save power of current frame for next call */
-	st->prev_pow_sum = L_temp;             
+	st->prev_pow_sum = L_temp;
 
 	/* If input power is very low, clear tone flag */
 	if (pow_sum < POW_TONE_THR)
 	{
-		st->tone_flag = (Word16) (st->tone_flag & 0x1fff);      
+		st->tone_flag = (Word16) (st->tone_flag & 0x1fff);
 	}
 	/* Run the filter bank and calculate signal levels at each band */
 	filter_bank(st, in_buf, level);
@@ -791,7 +791,7 @@
 	VAD_flag = vad_decision(st, level, pow_sum);
 
 	/* Calculate input level */
-	L_temp = 0;                          
+	L_temp = 0;
 	for (i = 1; i < COMPLEN; i++)          /* ignore lowest band */
 	{
 		L_temp = vo_L_add(L_temp, level[i]);
diff --git a/media/libstagefright/codecs/amrwbenc/src/weight_a.c b/media/libstagefright/codecs/amrwbenc/src/weight_a.c
index 8f0fb39..a02b48d 100644
--- a/media/libstagefright/codecs/amrwbenc/src/weight_a.c
+++ b/media/libstagefright/codecs/amrwbenc/src/weight_a.c
@@ -19,7 +19,7 @@
 *                                                                      *
 *       Description:Weighting of LPC coefficients                      *
 *	               ap[i] = a[i] * (gamma ** i)                     *
-*                                                                      * 
+*                                                                      *
 ************************************************************************/
 
 #include "typedef.h"
diff --git a/media/libstagefright/codecs/common/Config.mk b/media/libstagefright/codecs/common/Config.mk
index 3d754e7..187f25c 100644
--- a/media/libstagefright/codecs/common/Config.mk
+++ b/media/libstagefright/codecs/common/Config.mk
@@ -1,8 +1,8 @@
-# 
+#
 # This configure file is just for Linux projects against Android
 #
 
-VOPRJ := 
+VOPRJ :=
 VONJ :=
 
 # WARNING:
@@ -20,5 +20,5 @@
 
 VOTEST := 0
 
-VO_CFLAGS:=-DLINUX 
+VO_CFLAGS:=-DLINUX
 
diff --git a/media/libstagefright/codecs/common/include/voAMRWB.h b/media/libstagefright/codecs/common/include/voAMRWB.h
index 13290c7..d3eb537 100644
--- a/media/libstagefright/codecs/common/include/voAMRWB.h
+++ b/media/libstagefright/codecs/common/include/voAMRWB.h
@@ -29,20 +29,20 @@
 #pragma pack(push, 4)
 
 /*!* the bit rate the codec supports*/
-typedef enum { 
+typedef enum {
 	VOAMRWB_MDNONE		= -1,	/*!< Invalid mode */
 	VOAMRWB_MD66		= 0,	/*!< 6.60kbps   */
-	VOAMRWB_MD885		= 1,    /*!< 8.85kbps   */       
+	VOAMRWB_MD885		= 1,    /*!< 8.85kbps   */
 	VOAMRWB_MD1265		= 2,	/*!< 12.65kbps  */
 	VOAMRWB_MD1425		= 3,	/*!< 14.25kbps  */
 	VOAMRWB_MD1585		= 4,	/*!< 15.85bps   */
 	VOAMRWB_MD1825		= 5,	/*!< 18.25bps   */
 	VOAMRWB_MD1985		= 6,	/*!< 19.85kbps  */
 	VOAMRWB_MD2305		= 7,    /*!< 23.05kbps  */
-	VOAMRWB_MD2385          = 8,    /*!< 23.85kbps> */	
+	VOAMRWB_MD2385          = 8,    /*!< 23.85kbps> */
 	VOAMRWB_N_MODES 	= 9,	/*!< Invalid mode */
 	VOAMRWB_MODE_MAX    = VO_MAX_ENUM_VALUE
-	
+
 }VOAMRWBMODE;
 
 /*!* the frame format the codec supports*/
@@ -51,17 +51,17 @@
 	/*One word (2-byte) for sync word (0x6b21)*/
 	/*One word (2-byte) for frame length N.*/
 	/*N words (2-byte) containing N bits (bit 0 = 0x007f, bit 1 = 0x0081).*/
-	VOAMRWB_ITU         = 1, 
+	VOAMRWB_ITU         = 1,
 	/*One word (2-byte) for sync word (0x6b21).*/
-	/*One word (2-byte) to indicate the frame type.*/	
+	/*One word (2-byte) to indicate the frame type.*/
 	/*One word (2-byte) to indicate the mode.*/
 	/*N words  (2-byte) containing N bits (bit 0 = 0xff81, bit 1 = 0x007f).*/
-	VOAMRWB_RFC3267		= 2,	/* see RFC 3267 */  
-    VOAMRWB_TMAX        = VO_MAX_ENUM_VALUE	
+	VOAMRWB_RFC3267		= 2,	/* see RFC 3267 */
+    VOAMRWB_TMAX        = VO_MAX_ENUM_VALUE
 }VOAMRWBFRAMETYPE;
 
 
-#define    VO_PID_AMRWB_Module							0x42261000 
+#define    VO_PID_AMRWB_Module							0x42261000
 #define    VO_PID_AMRWB_FORMAT                          (VO_PID_AMRWB_Module | 0x0002)
 #define    VO_PID_AMRWB_CHANNELS                        (VO_PID_AMRWB_Module | 0x0003)
 #define    VO_PID_AMRWB_SAMPLERATE                      (VO_PID_AMRWB_Module | 0x0004)
diff --git a/media/libstagefright/codecs/common/include/voAudio.h b/media/libstagefright/codecs/common/include/voAudio.h
index 21d0cf6..d8628ee 100644
--- a/media/libstagefright/codecs/common/include/voAudio.h
+++ b/media/libstagefright/codecs/common/include/voAudio.h
@@ -135,7 +135,7 @@
 	 * \param pOutInfo [OUT] The codec fills audio format and the input data size used in current call.
 	 *						 pOutInfo->InputUsed is total used input data size in byte.
 	 * \retval  VO_ERR_NONE Succeeded.
-	 *			VO_ERR_INPUT_BUFFER_SMALL. The input was finished or the input data was not enought. Continue to input 
+	 *			VO_ERR_INPUT_BUFFER_SMALL. The input was finished or the input data was not enought. Continue to input
 	 *										data before next call.
 	 */
 	VO_U32 (VO_API * GetOutputData) (VO_HANDLE hCodec, VO_CODECBUFFER * pOutBuffer, VO_AUDIO_OUTPUTINFO * pOutInfo);
diff --git a/media/libstagefright/codecs/common/include/voIndex.h b/media/libstagefright/codecs/common/include/voIndex.h
index a409a6e..320a2f8 100644
--- a/media/libstagefright/codecs/common/include/voIndex.h
+++ b/media/libstagefright/codecs/common/include/voIndex.h
@@ -173,7 +173,7 @@
 // Module own error ID
 #define VO_ERR_Module					0x8xxx0X00
 */
- 
+
 #define	VO_PID_COMMON_BASE				 0x40000000						/*!< The base of common param ID */
 #define	VO_PID_COMMON_QUERYMEM			(VO_PID_COMMON_BASE | 0X0001)	/*!< Query the memory needed; Reserved. */
 #define	VO_PID_COMMON_INPUTTYPE			(VO_PID_COMMON_BASE | 0X0002)	/*!< Set or get the input buffer type. VO_INPUT_TYPE */
diff --git a/media/libstagefright/include/AwesomePlayer.h b/media/libstagefright/include/AwesomePlayer.h
index 0985f47..82c6476 100644
--- a/media/libstagefright/include/AwesomePlayer.h
+++ b/media/libstagefright/include/AwesomePlayer.h
@@ -290,6 +290,7 @@
 
     bool isStreamingHTTP() const;
     void sendCacheStats();
+    void checkDrmStatus(const sp<DataSource>& dataSource);
 
     enum FlagMode {
         SET,
diff --git a/media/libstagefright/include/ChromiumHTTPDataSource.h b/media/libstagefright/include/ChromiumHTTPDataSource.h
index 18f8913..82e08fd 100644
--- a/media/libstagefright/include/ChromiumHTTPDataSource.h
+++ b/media/libstagefright/include/ChromiumHTTPDataSource.h
@@ -43,7 +43,7 @@
     virtual status_t getSize(off64_t *size);
     virtual uint32_t flags();
 
-    virtual sp<DecryptHandle> DrmInitialization();
+    virtual sp<DecryptHandle> DrmInitialization(const char *mime);
 
     virtual void getDrmInfo(sp<DecryptHandle> &handle, DrmManagerClient **client);
 
diff --git a/media/libstagefright/include/NuCachedSource2.h b/media/libstagefright/include/NuCachedSource2.h
index 7a03e7e..c27a29b 100644
--- a/media/libstagefright/include/NuCachedSource2.h
+++ b/media/libstagefright/include/NuCachedSource2.h
@@ -40,7 +40,7 @@
     virtual status_t getSize(off64_t *size);
     virtual uint32_t flags();
 
-    virtual sp<DecryptHandle> DrmInitialization();
+    virtual sp<DecryptHandle> DrmInitialization(const char* mime);
     virtual void getDrmInfo(sp<DecryptHandle> &handle, DrmManagerClient **client);
     virtual String8 getUri();
 
diff --git a/media/libstagefright/include/WVMExtractor.h b/media/libstagefright/include/WVMExtractor.h
index deecd25..9f763f9 100644
--- a/media/libstagefright/include/WVMExtractor.h
+++ b/media/libstagefright/include/WVMExtractor.h
@@ -23,6 +23,8 @@
 
 namespace android {
 
+struct AMessage;
+class String8;
 class DataSource;
 
 class WVMLoadableExtractor : public MediaExtractor {
@@ -58,6 +60,8 @@
     // is used.
     void setAdaptiveStreamingMode(bool adaptive);
 
+    static bool getVendorLibHandle();
+
 protected:
     virtual ~WVMExtractor();
 
@@ -69,6 +73,10 @@
     WVMExtractor &operator=(const WVMExtractor &);
 };
 
+bool SniffWVM(
+        const sp<DataSource> &source, String8 *mimeType, float *confidence,
+        sp<AMessage> *);
+
 }  // namespace android
 
 #endif  // DRM_EXTRACTOR_H_
diff --git a/media/mtp/Android.mk b/media/mtp/Android.mk
index e590bab..fc7fc4f 100644
--- a/media/mtp/Android.mk
+++ b/media/mtp/Android.mk
@@ -39,6 +39,9 @@
 
 LOCAL_CFLAGS := -DMTP_DEVICE -DMTP_HOST
 
+# Needed for <bionic_time.h>
+LOCAL_C_INCLUDES := bionic/libc/private
+
 LOCAL_SHARED_LIBRARIES := libutils libcutils libusbhost libbinder
 
 include $(BUILD_SHARED_LIBRARY)
diff --git a/opengl/libs/GLES_trace/src/gltrace_fixup.cpp b/opengl/libs/GLES_trace/src/gltrace_fixup.cpp
index 5220aa4..daba3ff 100644
--- a/opengl/libs/GLES_trace/src/gltrace_fixup.cpp
+++ b/opengl/libs/GLES_trace/src/gltrace_fixup.cpp
@@ -107,19 +107,11 @@
     fb->add_contents(fbcontents, fbsize);
 }
 
-void fixup_glTexImage2D(GLMessage *glmsg) {
-    /* void glTexImage2D(GLenum target,
-                        GLint level,
-                        GLint internalformat,
-                        GLsizei width,
-                        GLsizei height,
-                        GLint border,
-                        GLenum format,
-                        GLenum type,
-                        const GLvoid *data); 
-     */
-    GLMessage_DataType arg_width  = glmsg->args(3);
-    GLMessage_DataType arg_height = glmsg->args(4);
+/** Common fixup routing for glTexImage2D & glTexSubImage2D. */
+void fixup_glTexImage(int widthIndex, int heightIndex, GLMessage *glmsg) {
+    GLMessage_DataType arg_width  = glmsg->args(widthIndex);
+    GLMessage_DataType arg_height = glmsg->args(heightIndex);
+
     GLMessage_DataType arg_format = glmsg->args(6);
     GLMessage_DataType arg_type   = glmsg->args(7);
     GLMessage_DataType *arg_data  = glmsg->mutable_args(8);
@@ -133,21 +125,51 @@
     int bytesPerTexel = getBytesPerTexel(format, type);
 
     arg_data->set_type(GLMessage::DataType::BYTE);
-    arg_data->set_isarray(true);
     arg_data->clear_rawbytes();
 
     if (data != NULL) {
+        arg_data->set_isarray(true);
         arg_data->add_rawbytes(data, bytesPerTexel * width * height);
     } else {
-        ALOGE("fixup_glTexImage2D: image data is NULL.\n");
+        arg_data->set_isarray(false);
         arg_data->set_type(GLMessage::DataType::VOID);
-        // FIXME:
-        // This will create the texture, but it will be uninitialized. 
-        // It can later be initialized with glTexSubImage2D or by
-        // attaching an FBO to it and rendering into the FBO.
     }
 }
 
+
+void fixup_glTexImage2D(GLMessage *glmsg) {
+    /* void glTexImage2D(GLenum target,
+                        GLint level,
+                        GLint internalformat,
+                        GLsizei width,
+                        GLsizei height,
+                        GLint border,
+                        GLenum format,
+                        GLenum type,
+                        const GLvoid *data); 
+    */
+    int widthIndex = 3;
+    int heightIndex = 4;
+    fixup_glTexImage(widthIndex, heightIndex, glmsg);
+}
+
+void fixup_glTexSubImage2D(GLMessage *glmsg) {
+    /*
+    void glTexSubImage2D(GLenum target,
+                        GLint level,
+                        GLint xoffset,
+                        GLint yoffset,
+                        GLsizei width,
+                        GLsizei height,
+                        GLenum format,
+                        GLenum type,
+                        const GLvoid * data);
+    */
+    int widthIndex = 4;
+    int heightIndex = 5;
+    fixup_glTexImage(widthIndex, heightIndex, glmsg);
+}
+
 void fixup_glShaderSource(GLMessage *glmsg) {
     /* void glShaderSource(GLuint shader, GLsizei count, const GLchar** string, 
                                     const GLint* length) */
@@ -218,6 +240,14 @@
     fixup_GenericIntArray(1, n, glmsg);
 }
 
+void fixup_glDeleteGeneric(GLMessage *glmsg) {
+    /* void glDelete*(GLsizei n, GLuint *buffers); */
+    GLMessage_DataType arg_n  = glmsg->args(0);
+    GLsizei n = arg_n.intvalue(0);
+
+    fixup_GenericIntArray(1, n, glmsg);
+}
+
 void fixup_glGetBooleanv(GLMessage *glmsg) {
     /* void glGetBooleanv(GLenum pname, GLboolean *params); */
     GLMessage_DataType *arg_params = glmsg->mutable_args(1);
@@ -250,10 +280,16 @@
 
     // do any custom message dependent processing
     switch (glmsg->function()) {
-    case GLMessage::glGenBuffers:        /* void glGenBuffers(GLsizei n, GLuint * buffers); */
-    case GLMessage::glGenFramebuffers:   /* void glGenFramebuffers(GLsizei n, GLuint * buffers); */
-    case GLMessage::glGenRenderbuffers:  /* void glGenFramebuffers(GLsizei n, GLuint * buffers); */
-    case GLMessage::glGenTextures:       /* void glGenTextures(GLsizei n, GLuint * buffers); */
+    case GLMessage::glDeleteBuffers:      /* glDeleteBuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glDeleteFramebuffers: /* glDeleteFramebuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glDeleteRenderbuffers:/* glDeleteRenderbuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glDeleteTextures:     /* glDeleteTextures(GLsizei n, GLuint *textures); */
+        fixup_glDeleteGeneric(glmsg);
+        break;
+    case GLMessage::glGenBuffers:        /* void glGenBuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glGenFramebuffers:   /* void glGenFramebuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glGenRenderbuffers:  /* void glGenFramebuffers(GLsizei n, GLuint *buffers); */
+    case GLMessage::glGenTextures:       /* void glGenTextures(GLsizei n, GLuint *textures); */
         fixup_glGenGeneric(glmsg);
         break;
     case GLMessage::glGetAttribLocation:  
@@ -287,6 +323,11 @@
             fixup_glTexImage2D(glmsg);
         }
         break;
+    case GLMessage::glTexSubImage2D:
+        if (context->getGlobalTraceState()->shouldCollectTextureDataOnGlTexImage()) {
+            fixup_glTexSubImage2D(glmsg);
+        }
+        break;
     case GLMessage::glShaderSource:
         fixup_glShaderSource(glmsg);
         break;
diff --git a/packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java b/packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java
index 24744b5..a10e363 100644
--- a/packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java
+++ b/packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java
@@ -397,8 +397,10 @@
 
         mPreloadTasksRunnable = new Runnable() {
             public void run() {
-                setVisibility(INVISIBLE);
-                refreshRecentTasksList();
+                if (!mShowing) {
+                    setVisibility(INVISIBLE);
+                    refreshRecentTasksList();
+                }
             }
         };
     }
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
index 468f0d5..b440bde 100755
--- a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
+++ b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
@@ -2403,7 +2403,7 @@
         if (DEBUG_LAYOUT) Slog.i(TAG, "Win " + win + ": isVisibleOrBehindKeyguardLw="
                 + win.isVisibleOrBehindKeyguardLw());
         if (mTopFullscreenOpaqueWindowState == null &&
-                win.isVisibleOrBehindKeyguardLw()) {
+                win.isVisibleOrBehindKeyguardLw() && !win.isGoneForLayoutLw()) {
             if ((attrs.flags & FLAG_FORCE_NOT_FULLSCREEN) != 0) {
                 mForceStatusBar = true;
             }
@@ -2458,7 +2458,7 @@
                 // case though.
                 if (topIsFullscreen) {
                     if (mStatusBarCanHide) {
-                        if (DEBUG_LAYOUT) Log.v(TAG, "Hiding status bar");
+                        if (DEBUG_LAYOUT) Log.v(TAG, "** HIDING status bar");
                         if (mStatusBar.hideLw(true)) {
                             changes |= FINISH_LAYOUT_REDO_LAYOUT;
 
@@ -2474,7 +2474,7 @@
                         Log.v(TAG, "Preventing status bar from hiding by policy");
                     }
                 } else {
-                    if (DEBUG_LAYOUT) Log.v(TAG, "Showing status bar: top is not fullscreen");
+                    if (DEBUG_LAYOUT) Log.v(TAG, "** SHOWING status bar: top is not fullscreen");
                     if (mStatusBar.showLw(true)) changes |= FINISH_LAYOUT_REDO_LAYOUT;
                 }
             }
@@ -3456,7 +3456,6 @@
     public void systemReady() {
         // tell the keyguard
         mKeyguardMediator.onSystemReady();
-        android.os.SystemProperties.set("dev.bootcomplete", "1"); 
         synchronized (mLock) {
             updateOrientationListenerLp();
             mSystemReady = true;
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp
index 9fb666e..fb2a072 100644
--- a/services/audioflinger/AudioFlinger.cpp
+++ b/services/audioflinger/AudioFlinger.cpp
@@ -72,7 +72,7 @@
 
 //static const nsecs_t kStandbyTimeInNsecs = seconds(3);
 static const float MAX_GAIN = 4096.0f;
-static const float MAX_GAIN_INT = 0x1000;
+static const uint32_t MAX_GAIN_INT = 0x1000;
 
 // retry counts for buffer fill timeout
 // 50 * ~20msecs = 1 second
@@ -380,7 +380,7 @@
 
 sp<IAudioTrack> AudioFlinger::createTrack(
         pid_t pid,
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate,
         uint32_t format,
         uint32_t channelMask,
@@ -398,7 +398,9 @@
     status_t lStatus;
     int lSessionId;
 
-    if (streamType >= AUDIO_STREAM_CNT) {
+    // client AudioTrack::set already implements AUDIO_STREAM_DEFAULT => AUDIO_STREAM_MUSIC,
+    // but if someone uses binder directly they could bypass that and cause us to crash
+    if (uint32_t(streamType) >= AUDIO_STREAM_CNT) {
         ALOGE("createTrack() invalid stream type %d", streamType);
         lStatus = BAD_VALUE;
         goto Exit;
@@ -563,7 +565,7 @@
     return NO_ERROR;
 }
 
-status_t AudioFlinger::setMode(int mode)
+status_t AudioFlinger::setMode(audio_mode_t mode)
 {
     status_t ret = initCheck();
     if (ret != NO_ERROR) {
@@ -646,22 +648,24 @@
 
 float AudioFlinger::masterVolume() const
 {
-    return mMasterVolume;
+    Mutex::Autolock _l(mLock);
+    return masterVolume_l();
 }
 
 bool AudioFlinger::masterMute() const
 {
-    return mMasterMute;
+    Mutex::Autolock _l(mLock);
+    return masterMute_l();
 }
 
-status_t AudioFlinger::setStreamVolume(int stream, float value, int output)
+status_t AudioFlinger::setStreamVolume(audio_stream_type_t stream, float value, int output)
 {
     // check calling permissions
     if (!settingsAllowed()) {
         return PERMISSION_DENIED;
     }
 
-    if (stream < 0 || uint32_t(stream) >= AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         ALOGE("setStreamVolume() invalid stream %d", stream);
         return BAD_VALUE;
     }
@@ -688,14 +692,14 @@
     return NO_ERROR;
 }
 
-status_t AudioFlinger::setStreamMute(int stream, bool muted)
+status_t AudioFlinger::setStreamMute(audio_stream_type_t stream, bool muted)
 {
     // check calling permissions
     if (!settingsAllowed()) {
         return PERMISSION_DENIED;
     }
 
-    if (stream < 0 || uint32_t(stream) >= AUDIO_STREAM_CNT ||
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT ||
         uint32_t(stream) == AUDIO_STREAM_ENFORCED_AUDIBLE) {
         ALOGE("setStreamMute() invalid stream %d", stream);
         return BAD_VALUE;
@@ -709,9 +713,9 @@
     return NO_ERROR;
 }
 
-float AudioFlinger::streamVolume(int stream, int output) const
+float AudioFlinger::streamVolume(audio_stream_type_t stream, int output) const
 {
-    if (stream < 0 || uint32_t(stream) >= AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         return 0.0f;
     }
 
@@ -730,9 +734,9 @@
     return volume;
 }
 
-bool AudioFlinger::streamMute(int stream) const
+bool AudioFlinger::streamMute(audio_stream_type_t stream) const
 {
-    if (stream < 0 || stream >= (int)AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         return true;
     }
 
@@ -1118,7 +1122,7 @@
     result.append(buffer);
     snprintf(buffer, SIZE, "Format: %d\n", mFormat);
     result.append(buffer);
-    snprintf(buffer, SIZE, "Frame size: %d\n", mFrameSize);
+    snprintf(buffer, SIZE, "Frame size: %u\n", mFrameSize);
     result.append(buffer);
 
     snprintf(buffer, SIZE, "\nPending setParameters commands: \n");
@@ -1379,13 +1383,19 @@
 
     readOutputParameters();
 
-    mMasterVolume = mAudioFlinger->masterVolume();
-    mMasterMute = mAudioFlinger->masterMute();
+    // Assumes constructor is called by AudioFlinger with it's mLock held,
+    // but it would be safer to explicitly pass these as parameters
+    mMasterVolume = mAudioFlinger->masterVolume_l();
+    mMasterMute = mAudioFlinger->masterMute_l();
 
-    for (int stream = 0; stream < AUDIO_STREAM_CNT; stream++) {
+    // mStreamTypes[AUDIO_STREAM_CNT] is initialized by stream_type_t default constructor
+    // There is no AUDIO_STREAM_MIN, and ++ operator does not compile
+    for (audio_stream_type_t stream = (audio_stream_type_t) 0; stream < AUDIO_STREAM_CNT;
+            stream = (audio_stream_type_t) (stream + 1)) {
         mStreamTypes[stream].volume = mAudioFlinger->streamVolumeInternal(stream);
         mStreamTypes[stream].mute = mAudioFlinger->streamMute(stream);
-        mStreamTypes[stream].valid = true;
+        // initialized by stream_type_t default constructor
+        // mStreamTypes[stream].valid = true;
     }
 }
 
@@ -1483,7 +1493,7 @@
 // PlaybackThread::createTrack_l() must be called with AudioFlinger::mLock held
 sp<AudioFlinger::PlaybackThread::Track>  AudioFlinger::PlaybackThread::createTrack_l(
         const sp<AudioFlinger::Client>& client,
-        int streamType,
+        audio_stream_type_t streamType,
         uint32_t sampleRate,
         uint32_t format,
         uint32_t channelMask,
@@ -1606,24 +1616,24 @@
     return mMasterMute;
 }
 
-status_t AudioFlinger::PlaybackThread::setStreamVolume(int stream, float value)
+status_t AudioFlinger::PlaybackThread::setStreamVolume(audio_stream_type_t stream, float value)
 {
     mStreamTypes[stream].volume = value;
     return NO_ERROR;
 }
 
-status_t AudioFlinger::PlaybackThread::setStreamMute(int stream, bool muted)
+status_t AudioFlinger::PlaybackThread::setStreamMute(audio_stream_type_t stream, bool muted)
 {
     mStreamTypes[stream].mute = muted;
     return NO_ERROR;
 }
 
-float AudioFlinger::PlaybackThread::streamVolume(int stream) const
+float AudioFlinger::PlaybackThread::streamVolume(audio_stream_type_t stream) const
 {
     return mStreamTypes[stream].volume;
 }
 
-bool AudioFlinger::PlaybackThread::streamMute(int stream) const
+bool AudioFlinger::PlaybackThread::streamMute(audio_stream_type_t stream) const
 {
     return mStreamTypes[stream].mute;
 }
@@ -1727,7 +1737,7 @@
     mChannelMask = mOutput->stream->common.get_channels(&mOutput->stream->common);
     mChannelCount = (uint16_t)popcount(mChannelMask);
     mFormat = mOutput->stream->common.get_format(&mOutput->stream->common);
-    mFrameSize = (uint16_t)audio_stream_frame_size(&mOutput->stream->common);
+    mFrameSize = audio_stream_frame_size(&mOutput->stream->common);
     mFrameCount = mOutput->stream->common.get_buffer_size(&mOutput->stream->common) / mFrameSize;
 
     // FIXME - Current mixer implementation only supports stereo output: Always
@@ -2180,10 +2190,31 @@
                 // read original volumes with volume control
                 float typeVolume = mStreamTypes[track->type()].volume;
                 float v = masterVolume * typeVolume;
-                vl = (uint32_t)(v * cblk->volume[0]) << 12;
-                vr = (uint32_t)(v * cblk->volume[1]) << 12;
+                uint32_t vlr = cblk->volumeLR;
+                vl = vlr & 0xFFFF;
+                vr = vlr >> 16;
+                // track volumes come from shared memory, so can't be trusted and must be clamped
+                if (vl > MAX_GAIN_INT) {
+                    ALOGV("Track left volume out of range: %04X", vl);
+                    vl = MAX_GAIN_INT;
+                }
+                if (vr > MAX_GAIN_INT) {
+                    ALOGV("Track right volume out of range: %04X", vr);
+                    vr = MAX_GAIN_INT;
+                }
+                // now apply the master volume and stream type volume
+                vl = (uint32_t)(v * vl) << 12;
+                vr = (uint32_t)(v * vr) << 12;
+                // assuming master volume and stream type volume each go up to 1.0,
+                // vl and vr are now in 8.24 format
 
-                va = (uint32_t)(v * cblk->sendLevel);
+                uint16_t sendLevel = cblk->getSendLevel_U4_12();
+                // send level comes from shared memory and so may be corrupt
+                if (sendLevel >= MAX_GAIN_INT) {
+                    ALOGV("Track send level out of range: %04X", sendLevel);
+                    sendLevel = MAX_GAIN_INT;
+                }
+                va = (uint32_t)(v * sendLevel);
             }
             // Delegate volume control to effect in track effect chain if needed
             if (chain != 0 && chain->setVolume_l(&vl, &vr)) {
@@ -2201,6 +2232,7 @@
 
             // Convert volumes from 8.24 to 4.12 format
             int16_t left, right, aux;
+            // This additional clamping is needed in case chain->setVolume_l() overshot
             uint32_t v_clamped = (vl + (1 << 11)) >> 12;
             if (v_clamped > MAX_GAIN_INT) v_clamped = MAX_GAIN_INT;
             left = int16_t(v_clamped);
@@ -2297,7 +2329,7 @@
     return mixerStatus;
 }
 
-void AudioFlinger::MixerThread::invalidateTracks(int streamType)
+void AudioFlinger::MixerThread::invalidateTracks(audio_stream_type_t streamType)
 {
     ALOGV ("MixerThread::invalidateTracks() mixer %p, streamType %d, mTracks.size %d",
             this,  streamType, mTracks.size());
@@ -2313,7 +2345,7 @@
     }
 }
 
-void AudioFlinger::PlaybackThread::setStreamValid(int streamType, bool valid)
+void AudioFlinger::PlaybackThread::setStreamValid(audio_stream_type_t streamType, bool valid)
 {
     ALOGV ("PlaybackThread::setStreamValid() thread %p, streamType %d, valid %d",
             this,  streamType, valid);
@@ -2683,10 +2715,11 @@
                     } else {
                         float typeVolume = mStreamTypes[track->type()].volume;
                         float v = mMasterVolume * typeVolume;
-                        float v_clamped = v * cblk->volume[0];
+                        uint32_t vlr = cblk->volumeLR;
+                        float v_clamped = v * (vlr & 0xFFFF);
                         if (v_clamped > MAX_GAIN) v_clamped = MAX_GAIN;
                         left = v_clamped/MAX_GAIN;
-                        v_clamped = v * cblk->volume[1];
+                        v_clamped = v * (vlr >> 16);
                         if (v_clamped > MAX_GAIN) v_clamped = MAX_GAIN;
                         right = v_clamped/MAX_GAIN;
                     }
@@ -3324,12 +3357,13 @@
 
 void* AudioFlinger::ThreadBase::TrackBase::getBuffer(uint32_t offset, uint32_t frames) const {
     audio_track_cblk_t* cblk = this->cblk();
-    int8_t *bufferStart = (int8_t *)mBuffer + (offset-cblk->serverBase)*cblk->frameSize;
-    int8_t *bufferEnd = bufferStart + frames * cblk->frameSize;
+    size_t frameSize = cblk->frameSize;
+    int8_t *bufferStart = (int8_t *)mBuffer + (offset-cblk->serverBase)*frameSize;
+    int8_t *bufferEnd = bufferStart + frames * frameSize;
 
     // Check validity of returned pointer in case the track control block would have been corrupted.
     if (bufferStart < mBuffer || bufferStart > bufferEnd || bufferEnd > mBufferEnd ||
-        ((unsigned long)bufferStart & (unsigned long)(cblk->frameSize - 1))) {
+        ((unsigned long)bufferStart & (unsigned long)(frameSize - 1))) {
         ALOGE("TrackBase::getBuffer buffer out of range:\n    start: %p, end %p , mBuffer %p mBufferEnd %p\n    \
                 server %d, serverBase %d, user %d, userBase %d",
                 bufferStart, bufferEnd, mBuffer, mBufferEnd,
@@ -3346,7 +3380,7 @@
 AudioFlinger::PlaybackThread::Track::Track(
             const wp<ThreadBase>& thread,
             const sp<Client>& client,
-            int streamType,
+            audio_stream_type_t streamType,
             uint32_t sampleRate,
             uint32_t format,
             uint32_t channelMask,
@@ -3368,8 +3402,6 @@
         if (mName < 0) {
             ALOGE("no more track names available");
         }
-        mVolume[0] = 1.0f;
-        mVolume[1] = 1.0f;
         mStreamType = streamType;
         // NOTE: audio_track_cblk_t::frameSize for 8 bit PCM data is based on a sample size of
         // 16 bit because data is converted to 16 bit before being stored in buffer by AudioTrack
@@ -3421,6 +3453,7 @@
 
 void AudioFlinger::PlaybackThread::Track::dump(char* buffer, size_t size)
 {
+    uint32_t vlr = mCblk->volumeLR;
     snprintf(buffer, size, "   %05d %05d %03u %03u 0x%08x %05u   %04u %1d %1d %1d %05u %05u %05u  0x%08x 0x%08x 0x%08x 0x%08x\n",
             mName - AudioMixer::TRACK0,
             (mClient == NULL) ? getpid() : mClient->pid(),
@@ -3433,8 +3466,8 @@
             mMute,
             mFillingUpStatus,
             mCblk->sampleRate,
-            mCblk->volume[0],
-            mCblk->volume[1],
+            vlr & 0xFFFF,
+            vlr >> 16,
             mCblk->server,
             mCblk->user,
             (int)mMainBuffer,
@@ -3631,12 +3664,6 @@
     mMute = muted;
 }
 
-void AudioFlinger::PlaybackThread::Track::setVolume(float left, float right)
-{
-    mVolume[0] = left;
-    mVolume[1] = right;
-}
-
 status_t AudioFlinger::PlaybackThread::Track::attachAuxEffect(int EffectId)
 {
     status_t status = DEAD_OBJECT;
@@ -3785,7 +3812,7 @@
     if (mCblk != NULL) {
         mCblk->flags |= CBLK_DIRECTION_OUT;
         mCblk->buffers = (char*)mCblk + sizeof(audio_track_cblk_t);
-        mCblk->volume[0] = mCblk->volume[1] = 0x1000;
+        mCblk->volumeLR = (MAX_GAIN_INT << 16) | MAX_GAIN_INT;
         mOutBuffer.frameCount = 0;
         playbackThread->mTracks.add(this);
         ALOGV("OutputTrack constructor mCblk %p, mBuffer %p, mCblk->buffers %p, " \
@@ -4086,10 +4113,6 @@
     mTrack->pause();
 }
 
-void AudioFlinger::TrackHandle::setVolume(float left, float right) {
-    mTrack->setVolume(left, right);
-}
-
 sp<IMemory> AudioFlinger::TrackHandle::getCblk() const {
     return mTrack->getCblk();
 }
@@ -4800,7 +4823,7 @@
     mChannelMask = mInput->stream->common.get_channels(&mInput->stream->common);
     mChannelCount = (uint16_t)popcount(mChannelMask);
     mFormat = mInput->stream->common.get_format(&mInput->stream->common);
-    mFrameSize = (uint16_t)audio_stream_frame_size(&mInput->stream->common);
+    mFrameSize = audio_stream_frame_size(&mInput->stream->common);
     mInputBytes = mInput->stream->common.get_buffer_size(&mInput->stream->common);
     mFrameCount = mInputBytes / mFrameSize;
     mRsmpInBuffer = new int16_t[mFrameCount * mChannelCount];
@@ -5156,7 +5179,7 @@
     return NO_ERROR;
 }
 
-status_t AudioFlinger::setStreamOutput(uint32_t stream, int output)
+status_t AudioFlinger::setStreamOutput(audio_stream_type_t stream, int output)
 {
     Mutex::Autolock _l(mLock);
     MixerThread *dstThread = checkMixerThread_l(output);
@@ -5883,7 +5906,7 @@
     return chain;
 }
 
-void AudioFlinger::ThreadBase::setMode(uint32_t mode)
+void AudioFlinger::ThreadBase::setMode(audio_mode_t mode)
 {
     Mutex::Autolock _l(mLock);
     size_t size = mEffectChains.size();
@@ -6681,7 +6704,7 @@
     return status;
 }
 
-status_t AudioFlinger::EffectModule::setMode(uint32_t mode)
+status_t AudioFlinger::EffectModule::setMode(audio_mode_t mode)
 {
     Mutex::Autolock _l(mLock);
     status_t status = NO_ERROR;
@@ -6690,7 +6713,7 @@
         uint32_t size = sizeof(status_t);
         status = (*mEffectInterface)->command(mEffectInterface,
                                               EFFECT_CMD_SET_AUDIO_MODE,
-                                              sizeof(int),
+                                              sizeof(audio_mode_t),
                                               &mode,
                                               &size,
                                               &cmdStatus);
@@ -7340,7 +7363,7 @@
 }
 
 // setMode_l() must be called with PlaybackThread::mLock held
-void AudioFlinger::EffectChain::setMode_l(uint32_t mode)
+void AudioFlinger::EffectChain::setMode_l(audio_mode_t mode)
 {
     size_t size = mEffects.size();
     for (size_t i = 0; i < size; i++) {
diff --git a/services/audioflinger/AudioFlinger.h b/services/audioflinger/AudioFlinger.h
index f99e764..275f40e 100644
--- a/services/audioflinger/AudioFlinger.h
+++ b/services/audioflinger/AudioFlinger.h
@@ -70,7 +70,7 @@
     // IAudioFlinger interface
     virtual sp<IAudioTrack> createTrack(
                                 pid_t pid,
-                                int streamType,
+                                audio_stream_type_t streamType,
                                 uint32_t sampleRate,
                                 uint32_t format,
                                 uint32_t channelMask,
@@ -93,13 +93,13 @@
     virtual     float       masterVolume() const;
     virtual     bool        masterMute() const;
 
-    virtual     status_t    setStreamVolume(int stream, float value, int output);
-    virtual     status_t    setStreamMute(int stream, bool muted);
+    virtual     status_t    setStreamVolume(audio_stream_type_t stream, float value, int output);
+    virtual     status_t    setStreamMute(audio_stream_type_t stream, bool muted);
 
-    virtual     float       streamVolume(int stream, int output) const;
-    virtual     bool        streamMute(int stream) const;
+    virtual     float       streamVolume(audio_stream_type_t stream, int output) const;
+    virtual     bool        streamMute(audio_stream_type_t stream) const;
 
-    virtual     status_t    setMode(int mode);
+    virtual     status_t    setMode(audio_mode_t mode);
 
     virtual     status_t    setMicMute(bool state);
     virtual     bool        getMicMute() const;
@@ -135,7 +135,7 @@
 
     virtual status_t closeInput(int input);
 
-    virtual status_t setStreamOutput(uint32_t stream, int output);
+    virtual status_t setStreamOutput(audio_stream_type_t stream, int output);
 
     virtual status_t setVoiceVolume(float volume);
 
@@ -202,7 +202,7 @@
                                 Parcel* reply,
                                 uint32_t flags);
 
-                uint32_t    getMode() { return mMode; }
+               audio_mode_t getMode() const { return mMode; }
 
                 bool        btNrecIsOff() { return mBtNrecIsOff; }
 
@@ -461,7 +461,7 @@
                     // unlock effect chains after process
                     void unlockEffectChains(Vector<sp <EffectChain> >& effectChains);
                     // set audio mode to all effect chains
-                    void setMode(uint32_t mode);
+                    void setMode(audio_mode_t mode);
                     // get effect module with corresponding ID on specified audio session
                     sp<AudioFlinger::EffectModule> getEffect_l(int sessionId, int effectId);
                     // add and effect module. Also creates the effect chain is none exists for
@@ -536,7 +536,7 @@
                     size_t                  mFrameCount;
                     uint32_t                mChannelMask;
                     uint16_t                mChannelCount;
-                    uint16_t                mFrameSize;
+                    size_t                  mFrameSize;
                     uint32_t                mFormat;
                     Condition               mParamCond;
                     Vector<String8>         mNewParameters;
@@ -573,7 +573,7 @@
         public:
                                 Track(  const wp<ThreadBase>& thread,
                                         const sp<Client>& client,
-                                        int streamType,
+                                        audio_stream_type_t streamType,
                                         uint32_t sampleRate,
                                         uint32_t format,
                                         uint32_t channelMask,
@@ -590,12 +590,11 @@
                     void        flush();
                     void        destroy();
                     void        mute(bool);
-                    void        setVolume(float left, float right);
                     int name() const {
                         return mName;
                     }
 
-                    int type() const {
+                    audio_stream_type_t type() const {
                         return mStreamType;
                     }
                     status_t    attachAuxEffect(int EffectId);
@@ -633,7 +632,6 @@
             }
 
             // we don't really need a lock for these
-            float               mVolume[2];
             volatile bool       mMute;
             // FILLED state is used for suppressing volume ramp at begin of playing
             enum {FS_FILLING, FS_FILLED, FS_ACTIVE};
@@ -641,7 +639,7 @@
             int8_t              mRetryCount;
             sp<IMemory>         mSharedBuffer;
             bool                mResetDone;
-            int                 mStreamType;
+            audio_stream_type_t mStreamType;
             int                 mName;
             int16_t             *mMainBuffer;
             int32_t             *mAuxBuffer;
@@ -707,15 +705,15 @@
         virtual     float       masterVolume() const;
         virtual     bool        masterMute() const;
 
-        virtual     status_t    setStreamVolume(int stream, float value);
-        virtual     status_t    setStreamMute(int stream, bool muted);
+        virtual     status_t    setStreamVolume(audio_stream_type_t stream, float value);
+        virtual     status_t    setStreamMute(audio_stream_type_t stream, bool muted);
 
-        virtual     float       streamVolume(int stream) const;
-        virtual     bool        streamMute(int stream) const;
+        virtual     float       streamVolume(audio_stream_type_t stream) const;
+        virtual     bool        streamMute(audio_stream_type_t stream) const;
 
                     sp<Track>   createTrack_l(
                                     const sp<AudioFlinger::Client>& client,
-                                    int streamType,
+                                    audio_stream_type_t streamType,
                                     uint32_t sampleRate,
                                     uint32_t format,
                                     uint32_t channelMask,
@@ -747,7 +745,7 @@
                     virtual uint32_t hasAudioSession(int sessionId);
                     virtual uint32_t getStrategyForSession_l(int sessionId);
 
-                            void setStreamValid(int streamType, bool valid);
+                            void setStreamValid(audio_stream_type_t streamType, bool valid);
 
         struct  stream_type_t {
             stream_type_t()
@@ -765,7 +763,9 @@
         int16_t*                        mMixBuffer;
         int                             mSuspended;
         int                             mBytesWritten;
+    private:
         bool                            mMasterMute;
+    protected:
         SortedVector< wp<Track> >       mActiveTracks;
 
         virtual int             getTrackName_l() = 0;
@@ -797,7 +797,7 @@
         status_t    dumpTracks(int fd, const Vector<String16>& args);
 
         SortedVector< sp<Track> >       mTracks;
-        // mStreamTypes[] uses 1 additionnal stream type internally for the OutputTrack used by DuplicatingThread
+        // mStreamTypes[] uses 1 additional stream type internally for the OutputTrack used by DuplicatingThread
         stream_type_t                   mStreamTypes[AUDIO_STREAM_CNT + 1];
         AudioStreamOut*                 mOutput;
         float                           mMasterVolume;
@@ -818,7 +818,7 @@
         // Thread virtuals
         virtual     bool        threadLoop();
 
-                    void        invalidateTracks(int streamType);
+                    void        invalidateTracks(audio_stream_type_t streamType);
         virtual     bool        checkForNewParameters_l();
         virtual     status_t    dumpInternals(int fd, const Vector<String16>& args);
 
@@ -884,7 +884,7 @@
               PlaybackThread *checkPlaybackThread_l(int output) const;
               MixerThread *checkMixerThread_l(int output) const;
               RecordThread *checkRecordThread_l(int input) const;
-              float streamVolumeInternal(int stream) const { return mStreamTypes[stream].volume; }
+              float streamVolumeInternal(audio_stream_type_t stream) const { return mStreamTypes[stream].volume; }
               void audioConfigChanged_l(int event, int ioHandle, void *param2);
 
               uint32_t nextUniqueId();
@@ -906,7 +906,6 @@
         virtual void        flush();
         virtual void        mute(bool);
         virtual void        pause();
-        virtual void        setVolume(float left, float right);
         virtual sp<IMemory> getCblk() const;
         virtual status_t    attachAuxEffect(int effectId);
         virtual status_t onTransact(
@@ -1111,7 +1110,7 @@
 
         status_t         setDevice(uint32_t device);
         status_t         setVolume(uint32_t *left, uint32_t *right, bool controller);
-        status_t         setMode(uint32_t mode);
+        status_t         setMode(audio_mode_t mode);
         status_t         start();
         status_t         stop();
         void             setSuspended(bool suspended);
@@ -1264,7 +1263,7 @@
         sp<EffectModule> getEffectFromType_l(const effect_uuid_t *type);
         bool setVolume_l(uint32_t *left, uint32_t *right);
         void setDevice_l(uint32_t device);
-        void setMode_l(uint32_t mode);
+        void setMode_l(audio_mode_t mode);
 
         void setInBuffer(int16_t *buffer, bool ownsBuffer = false) {
             mInBuffer = buffer;
@@ -1388,6 +1387,8 @@
 
                 DefaultKeyedVector< int, sp<PlaybackThread> >  mPlaybackThreads;
                 PlaybackThread::stream_type_t       mStreamTypes[AUDIO_STREAM_CNT];
+
+                // both are protected by mLock
                 float                               mMasterVolume;
                 bool                                mMasterMute;
 
@@ -1395,10 +1396,13 @@
 
                 DefaultKeyedVector< pid_t, sp<NotificationClient> >    mNotificationClients;
                 volatile int32_t                    mNextUniqueId;
-                uint32_t                            mMode;
+                audio_mode_t                        mMode;
                 bool                                mBtNrecIsOff;
 
                 Vector<AudioSessionRef*> mAudioSessionRefs;
+
+                float       masterVolume_l() const  { return mMasterVolume; }
+                bool        masterMute_l() const    { return mMasterMute; }
 };
 
 
diff --git a/services/audioflinger/AudioPolicyService.cpp b/services/audioflinger/AudioPolicyService.cpp
index 3f86d58..fcf014f 100644
--- a/services/audioflinger/AudioPolicyService.cpp
+++ b/services/audioflinger/AudioPolicyService.cpp
@@ -185,7 +185,7 @@
                                                       device_address);
 }
 
-status_t AudioPolicyService::setPhoneState(int state)
+status_t AudioPolicyService::setPhoneState(audio_mode_t state)
 {
     if (mpAudioPolicy == NULL) {
         return NO_INIT;
@@ -400,14 +400,16 @@
     if (!checkPermission()) {
         return PERMISSION_DENIED;
     }
-    if (stream < 0 || stream >= AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         return BAD_VALUE;
     }
     mpAudioPolicy->init_stream_volume(mpAudioPolicy, stream, indexMin, indexMax);
     return NO_ERROR;
 }
 
-status_t AudioPolicyService::setStreamVolumeIndex(audio_stream_type_t stream, int index)
+status_t AudioPolicyService::setStreamVolumeIndex(audio_stream_type_t stream,
+                                                  int index,
+                                                  audio_devices_t device)
 {
     if (mpAudioPolicy == NULL) {
         return NO_INIT;
@@ -415,22 +417,38 @@
     if (!checkPermission()) {
         return PERMISSION_DENIED;
     }
-    if (stream < 0 || stream >= AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         return BAD_VALUE;
     }
 
-    return mpAudioPolicy->set_stream_volume_index(mpAudioPolicy, stream, index);
+    if (mpAudioPolicy->set_stream_volume_index_for_device) {
+        return mpAudioPolicy->set_stream_volume_index_for_device(mpAudioPolicy,
+                                                                stream,
+                                                                index,
+                                                                device);
+    } else {
+        return mpAudioPolicy->set_stream_volume_index(mpAudioPolicy, stream, index);
+    }
 }
 
-status_t AudioPolicyService::getStreamVolumeIndex(audio_stream_type_t stream, int *index)
+status_t AudioPolicyService::getStreamVolumeIndex(audio_stream_type_t stream,
+                                                  int *index,
+                                                  audio_devices_t device)
 {
     if (mpAudioPolicy == NULL) {
         return NO_INIT;
     }
-    if (stream < 0 || stream >= AUDIO_STREAM_CNT) {
+    if (uint32_t(stream) >= AUDIO_STREAM_CNT) {
         return BAD_VALUE;
     }
-    return mpAudioPolicy->get_stream_volume_index(mpAudioPolicy, stream, index);
+    if (mpAudioPolicy->get_stream_volume_index_for_device) {
+        return mpAudioPolicy->get_stream_volume_index_for_device(mpAudioPolicy,
+                                                                stream,
+                                                                index,
+                                                                device);
+    } else {
+        return mpAudioPolicy->get_stream_volume_index(mpAudioPolicy, stream, index);
+    }
 }
 
 uint32_t AudioPolicyService::getStrategyForStream(audio_stream_type_t stream)
@@ -486,7 +504,7 @@
     return mpAudioPolicy->set_effect_enabled(mpAudioPolicy, id, enabled);
 }
 
-bool AudioPolicyService::isStreamActive(int stream, uint32_t inPastMs) const
+bool AudioPolicyService::isStreamActive(audio_stream_type_t stream, uint32_t inPastMs) const
 {
     if (mpAudioPolicy == NULL) {
         return 0;
@@ -781,7 +799,7 @@
     return NO_ERROR;
 }
 
-void AudioPolicyService::AudioCommandThread::startToneCommand(int type, int stream)
+void AudioPolicyService::AudioCommandThread::startToneCommand(int type, audio_stream_type_t stream)
 {
     AudioCommand *command = new AudioCommand();
     command->mCommand = START_TONE;
@@ -808,7 +826,7 @@
     mWaitWorkCV.signal();
 }
 
-status_t AudioPolicyService::AudioCommandThread::volumeCommand(int stream,
+status_t AudioPolicyService::AudioCommandThread::volumeCommand(audio_stream_type_t stream,
                                                                float volume,
                                                                int output,
                                                                int delayMs)
@@ -1019,7 +1037,7 @@
                                         audio_io_handle_t output,
                                         int delayMs)
 {
-    return (int)mAudioCommandThread->volumeCommand((int)stream, volume,
+    return (int)mAudioCommandThread->volumeCommand(stream, volume,
                                                    (int)output, delayMs);
 }
 
diff --git a/services/audioflinger/AudioPolicyService.h b/services/audioflinger/AudioPolicyService.h
index 88cb1e9..0715790 100644
--- a/services/audioflinger/AudioPolicyService.h
+++ b/services/audioflinger/AudioPolicyService.h
@@ -58,7 +58,7 @@
     virtual audio_policy_dev_state_t getDeviceConnectionState(
                                                                 audio_devices_t device,
                                                                 const char *device_address);
-    virtual status_t setPhoneState(int state);
+    virtual status_t setPhoneState(audio_mode_t state);
     virtual status_t setRingerMode(uint32_t mode, uint32_t mask);
     virtual status_t setForceUse(audio_policy_force_use_t usage, audio_policy_forced_cfg_t config);
     virtual audio_policy_forced_cfg_t getForceUse(audio_policy_force_use_t usage);
@@ -88,8 +88,12 @@
     virtual status_t initStreamVolume(audio_stream_type_t stream,
                                       int indexMin,
                                       int indexMax);
-    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream, int index);
-    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream, int *index);
+    virtual status_t setStreamVolumeIndex(audio_stream_type_t stream,
+                                          int index,
+                                          audio_devices_t device);
+    virtual status_t getStreamVolumeIndex(audio_stream_type_t stream,
+                                          int *index,
+                                          audio_devices_t device);
 
     virtual uint32_t getStrategyForStream(audio_stream_type_t stream);
     virtual uint32_t getDevicesForStream(audio_stream_type_t stream);
@@ -102,7 +106,7 @@
                                     int id);
     virtual status_t unregisterEffect(int id);
     virtual status_t setEffectEnabled(int id, bool enabled);
-    virtual bool isStreamActive(int stream, uint32_t inPastMs = 0) const;
+    virtual bool isStreamActive(audio_stream_type_t stream, uint32_t inPastMs = 0) const;
 
     virtual status_t queryDefaultPreProcessing(int audioSession,
                                               effect_descriptor_t *descriptors,
@@ -168,9 +172,9 @@
         virtual     bool        threadLoop();
 
                     void        exit();
-                    void        startToneCommand(int type = 0, int stream = 0);
+                    void        startToneCommand(int type = 0, audio_stream_type_t stream = AUDIO_STREAM_VOICE_CALL);
                     void        stopToneCommand();
-                    status_t    volumeCommand(int stream, float volume, int output, int delayMs = 0);
+                    status_t    volumeCommand(audio_stream_type_t stream, float volume, int output, int delayMs = 0);
                     status_t    parametersCommand(int ioHandle, const char *keyValuePairs, int delayMs = 0);
                     status_t    voiceVolumeCommand(float volume, int delayMs = 0);
                     void        insertCommand_l(AudioCommand *command, int delayMs = 0);
@@ -196,12 +200,12 @@
         class ToneData {
         public:
             int mType;      // tone type (START_TONE only)
-            int mStream;    // stream type (START_TONE only)
+            audio_stream_type_t mStream;    // stream type (START_TONE only)
         };
 
         class VolumeData {
         public:
-            int mStream;
+            audio_stream_type_t mStream;
             float mVolume;
             int mIO;
         };
diff --git a/services/input/InputDispatcher.cpp b/services/input/InputDispatcher.cpp
index a0f372a..9f09062 100644
--- a/services/input/InputDispatcher.cpp
+++ b/services/input/InputDispatcher.cpp
@@ -1906,10 +1906,21 @@
                     connection->getInputChannelName());
             logOutboundMotionDetailsLocked("  ", splitMotionEntry);
 #endif
-            eventEntry = splitMotionEntry;
+            enqueueDispatchEntriesLocked(currentTime, connection,
+                    splitMotionEntry, inputTarget, resumeWithAppendedMotionSample);
+            splitMotionEntry->release();
+            return;
         }
     }
 
+    // Not splitting.  Enqueue dispatch entries for the event as is.
+    enqueueDispatchEntriesLocked(currentTime, connection, eventEntry, inputTarget,
+            resumeWithAppendedMotionSample);
+}
+
+void InputDispatcher::enqueueDispatchEntriesLocked(nsecs_t currentTime,
+        const sp<Connection>& connection, EventEntry* eventEntry, const InputTarget* inputTarget,
+        bool resumeWithAppendedMotionSample) {
     // Resume the dispatch cycle with a freshly appended motion sample.
     // First we check that the last dispatch entry in the outbound queue is for the same
     // motion event to which we appended the motion sample.  If we find such a dispatch
@@ -2046,9 +2057,6 @@
     DispatchEntry* dispatchEntry = new DispatchEntry(eventEntry, // increments ref
             inputTargetFlags, inputTarget->xOffset, inputTarget->yOffset,
             inputTarget->scaleFactor);
-    if (dispatchEntry->hasForegroundTarget()) {
-        incrementPendingForegroundDispatchesLocked(eventEntry);
-    }
 
     // Handle the case where we could not stream a new motion sample because the consumer has
     // already consumed the motion event (otherwise the corresponding dispatch entry would
@@ -2077,6 +2085,7 @@
             ALOGD("channel '%s' ~ enqueueDispatchEntryLocked: skipping inconsistent key event",
                     connection->getInputChannelName());
 #endif
+            delete dispatchEntry;
             return; // skip the inconsistent event
         }
         break;
@@ -2118,12 +2127,18 @@
             ALOGD("channel '%s' ~ enqueueDispatchEntryLocked: skipping inconsistent motion event",
                     connection->getInputChannelName());
 #endif
+            delete dispatchEntry;
             return; // skip the inconsistent event
         }
         break;
     }
     }
 
+    // Remember that we are waiting for this dispatch to complete.
+    if (dispatchEntry->hasForegroundTarget()) {
+        incrementPendingForegroundDispatchesLocked(eventEntry);
+    }
+
     // Enqueue the dispatch entry.
     connection->outboundQueue.enqueueAtTail(dispatchEntry);
 }
@@ -2462,14 +2477,17 @@
 
 void InputDispatcher::synthesizeCancelationEventsForConnectionLocked(
         const sp<Connection>& connection, const CancelationOptions& options) {
+    if (connection->status == Connection::STATUS_BROKEN) {
+        return;
+    }
+
     nsecs_t currentTime = now();
 
     mTempCancelationEvents.clear();
     connection->inputState.synthesizeCancelationEvents(currentTime,
             mTempCancelationEvents, options);
 
-    if (! mTempCancelationEvents.isEmpty()
-            && connection->status != Connection::STATUS_BROKEN) {
+    if (!mTempCancelationEvents.isEmpty()) {
 #if DEBUG_OUTBOUND_EVENT_DETAILS
         ALOGD("channel '%s' ~ Synthesized %d cancelation events to bring channel back in sync "
                 "with reality: %s, mode=%d.",
diff --git a/services/input/InputDispatcher.h b/services/input/InputDispatcher.h
index 8ae5a56..1478d67 100644
--- a/services/input/InputDispatcher.h
+++ b/services/input/InputDispatcher.h
@@ -1070,6 +1070,9 @@
     void prepareDispatchCycleLocked(nsecs_t currentTime, const sp<Connection>& connection,
             EventEntry* eventEntry, const InputTarget* inputTarget,
             bool resumeWithAppendedMotionSample);
+    void enqueueDispatchEntriesLocked(nsecs_t currentTime, const sp<Connection>& connection,
+            EventEntry* eventEntry, const InputTarget* inputTarget,
+            bool resumeWithAppendedMotionSample);
     void enqueueDispatchEntryLocked(const sp<Connection>& connection,
             EventEntry* eventEntry, const InputTarget* inputTarget,
             bool resumeWithAppendedMotionSample, int32_t dispatchMode);
diff --git a/services/java/com/android/server/BackupManagerService.java b/services/java/com/android/server/BackupManagerService.java
index 4ef8837..aebfd60 100644
--- a/services/java/com/android/server/BackupManagerService.java
+++ b/services/java/com/android/server/BackupManagerService.java
@@ -195,7 +195,7 @@
     boolean mProvisioned;
     boolean mAutoRestore;
     PowerManager.WakeLock mWakelock;
-    HandlerThread mHandlerThread = new HandlerThread("backup", Process.THREAD_PRIORITY_BACKGROUND);
+    HandlerThread mHandlerThread;
     BackupHandler mBackupHandler;
     PendingIntent mRunBackupIntent, mRunInitIntent;
     BroadcastReceiver mRunBackupReceiver, mRunInitReceiver;
@@ -235,6 +235,10 @@
     volatile long mLastBackupPass;
     volatile long mNextBackupPass;
 
+    // For debugging, we maintain a progress trace of operations during backup
+    static final boolean DEBUG_BACKUP_TRACE = true;
+    final List<String> mBackupTrace = new ArrayList<String>();
+
     // A similar synchronization mechanism around clearing apps' data for restore
     final Object mClearDataLock = new Object();
     volatile boolean mClearingData;
@@ -652,6 +656,23 @@
         }
     }
 
+    // ----- Debug-only backup operation trace -----
+    void addBackupTrace(String s) {
+        if (DEBUG_BACKUP_TRACE) {
+            synchronized (mBackupTrace) {
+                mBackupTrace.add(s);
+            }
+        }
+    }
+
+    void clearBackupTrace() {
+        if (DEBUG_BACKUP_TRACE) {
+            synchronized (mBackupTrace) {
+                mBackupTrace.clear();
+            }
+        }
+    }
+
     // ----- Main service implementation -----
 
     public BackupManagerService(Context context) {
@@ -1310,14 +1331,10 @@
             }
             if (added) {
                 synchronized (mBackupParticipants) {
-                    for (String pkgName : pkgList) {
-                        if (replacing) {
-                            // The package was just upgraded
-                            updatePackageParticipantsLocked(pkgName);
-                        } else {
-                            // The package was just added
-                            addPackageParticipantsLocked(pkgName);
-                        }
+                    if (replacing) {
+                        updatePackageParticipantsLocked(pkgList);
+                    } else {
+                        addPackageParticipantsLocked(pkgList);
                     }
                 }
             } else {
@@ -1325,9 +1342,7 @@
                     // The package is being updated.  We'll receive a PACKAGE_ADDED shortly.
                 } else {
                     synchronized (mBackupParticipants) {
-                        for (String pkgName : pkgList) {
-                            removePackageParticipantsLocked(pkgName);
-                        }
+                        removePackageParticipantsLocked(pkgList);
                     }
                 }
             }
@@ -1349,26 +1364,26 @@
         }
     };
 
-    // Add the backup agents in the given package to our set of known backup participants.
-    // If 'packageName' is null, adds all backup agents in the whole system.
-    void addPackageParticipantsLocked(String packageName) {
+    // Add the backup agents in the given packages to our set of known backup participants.
+    // If 'packageNames' is null, adds all backup agents in the whole system.
+    void addPackageParticipantsLocked(String[] packageNames) {
         // Look for apps that define the android:backupAgent attribute
-        if (DEBUG) Slog.v(TAG, "addPackageParticipantsLocked: " + packageName);
         List<PackageInfo> targetApps = allAgentPackages();
-        addPackageParticipantsLockedInner(packageName, targetApps);
+        if (packageNames != null) {
+            if (DEBUG) Slog.v(TAG, "addPackageParticipantsLocked: #" + packageNames.length);
+            for (String packageName : packageNames) {
+                addPackageParticipantsLockedInner(packageName, targetApps);
+            }
+        } else {
+            if (DEBUG) Slog.v(TAG, "addPackageParticipantsLocked: all");
+            addPackageParticipantsLockedInner(null, targetApps);
+        }
     }
 
     private void addPackageParticipantsLockedInner(String packageName,
             List<PackageInfo> targetPkgs) {
         if (MORE_DEBUG) {
-            Slog.v(TAG, "Adding " + targetPkgs.size() + " backup participants:");
-            for (PackageInfo p : targetPkgs) {
-                Slog.v(TAG, "    " + p + " agent=" + p.applicationInfo.backupAgentName
-                        + " uid=" + p.applicationInfo.uid
-                        + " killAfterRestore="
-                        + (((p.applicationInfo.flags & ApplicationInfo.FLAG_KILL_AFTER_RESTORE) != 0) ? "true" : "false")
-                        );
-            }
+            Slog.v(TAG, "Examining " + packageName + " for backup agent");
         }
 
         for (PackageInfo pkg : targetPkgs) {
@@ -1380,6 +1395,7 @@
                     mBackupParticipants.put(uid, set);
                 }
                 set.add(pkg.applicationInfo);
+                if (MORE_DEBUG) Slog.v(TAG, "Agent found; added");
 
                 // If we've never seen this app before, schedule a backup for it
                 if (!mEverStoredApps.contains(pkg.packageName)) {
@@ -1391,34 +1407,32 @@
         }
     }
 
-    // Remove the given package's entry from our known active set.  If
-    // 'packageName' is null, *all* participating apps will be removed.
-    void removePackageParticipantsLocked(String packageName) {
-        if (DEBUG) Slog.v(TAG, "removePackageParticipantsLocked: " + packageName);
-        List<String> allApps = new ArrayList<String>();
-        if (packageName != null) {
-            allApps.add(packageName);
-        } else {
-            // all apps with agents
-            List<PackageInfo> knownPackages = allAgentPackages();
-            for (PackageInfo pkg : knownPackages) {
-                allApps.add(pkg.packageName);
-            }
+    // Remove the given packages' entries from our known active set.
+    void removePackageParticipantsLocked(String[] packageNames) {
+        if (packageNames == null) {
+            Slog.w(TAG, "removePackageParticipants with null list");
+            return;
         }
-        removePackageParticipantsLockedInner(packageName, allApps);
+
+        if (DEBUG) Slog.v(TAG, "removePackageParticipantsLocked: #" + packageNames.length);
+        List<PackageInfo> knownPackages = allAgentPackages();
+        for (String pkg : packageNames) {
+            removePackageParticipantsLockedInner(pkg, knownPackages);
+        }
     }
 
     private void removePackageParticipantsLockedInner(String packageName,
-            List<String> allPackageNames) {
+            List<PackageInfo> allPackages) {
         if (MORE_DEBUG) {
             Slog.v(TAG, "removePackageParticipantsLockedInner (" + packageName
-                    + ") removing " + allPackageNames.size() + " entries");
-            for (String p : allPackageNames) {
-                Slog.v(TAG, "    - " + p);
+                    + ") removing from " + allPackages.size() + " entries");
+            for (PackageInfo p : allPackages) {
+                Slog.v(TAG, "    - " + p.packageName);
             }
         }
-        for (String pkg : allPackageNames) {
-            if (packageName == null || pkg.equals(packageName)) {
+        for (PackageInfo pkg : allPackages) {
+            if (packageName == null || pkg.packageName.equals(packageName)) {
+                /*
                 int uid = -1;
                 try {
                     PackageInfo info = mPackageManager.getPackageInfo(packageName, 0);
@@ -1427,22 +1441,28 @@
                     // we don't know this package name, so just skip it for now
                     continue;
                 }
+                */
+                final int uid = pkg.applicationInfo.uid;
+                if (MORE_DEBUG) Slog.i(TAG, "   found pkg " + packageName + " uid=" + uid);
 
                 HashSet<ApplicationInfo> set = mBackupParticipants.get(uid);
                 if (set != null) {
                     // Find the existing entry with the same package name, and remove it.
                     // We can't just remove(app) because the instances are different.
                     for (ApplicationInfo entry: set) {
+                        if (MORE_DEBUG) Slog.i(TAG, "      checking against " + entry.packageName);
                         if (entry.packageName.equals(pkg)) {
                             if (MORE_DEBUG) Slog.v(TAG, "  removing participant " + pkg);
                             set.remove(entry);
-                            removeEverBackedUp(pkg);
+                            removeEverBackedUp(pkg.packageName);
                             break;
                         }
                     }
                     if (set.size() == 0) {
                         mBackupParticipants.delete(uid);
                     }
+                } else {
+                    if (MORE_DEBUG) Slog.i(TAG, "   ... not found in uid mapping");
                 }
             }
         }
@@ -1477,21 +1497,20 @@
 
     // Reset the given package's known backup participants.  Unlike add/remove, the update
     // action cannot be passed a null package name.
-    void updatePackageParticipantsLocked(String packageName) {
-        if (packageName == null) {
-            Slog.e(TAG, "updatePackageParticipants called with null package name");
+    void updatePackageParticipantsLocked(String[] packageNames) {
+        if (packageNames == null) {
+            Slog.e(TAG, "updatePackageParticipants called with null package list");
             return;
         }
-        if (DEBUG) Slog.v(TAG, "updatePackageParticipantsLocked: " + packageName);
+        if (DEBUG) Slog.v(TAG, "updatePackageParticipantsLocked: #" + packageNames.length);
 
-        // brute force but small code size
-        List<PackageInfo> allApps = allAgentPackages();
-        List<String> allAppNames = new ArrayList<String>();
-        for (PackageInfo pkg : allApps) {
-            allAppNames.add(pkg.packageName);
+        if (packageNames.length > 0) {
+            List<PackageInfo> allApps = allAgentPackages();
+            for (String packageName : packageNames) {
+                removePackageParticipantsLockedInner(packageName, allApps);
+                addPackageParticipantsLockedInner(packageName, allApps);
+            }
         }
-        removePackageParticipantsLockedInner(packageName, allAppNames);
-        addPackageParticipantsLockedInner(packageName, allApps);
     }
 
     // Called from the backup task: record that the given app has been successfully
@@ -1614,6 +1633,7 @@
                             mAgentConnectLock.wait(5000);
                         } catch (InterruptedException e) {
                             // just bail
+                            if (DEBUG) Slog.w(TAG, "Interrupted: " + e);
                             return null;
                         }
                     }
@@ -1623,6 +1643,7 @@
                         Slog.w(TAG, "Timeout waiting for agent " + app);
                         return null;
                     }
+                    if (DEBUG) Slog.i(TAG, "got agent " + mConnectedAgent);
                     agent = mConnectedAgent;
                 }
             } catch (RemoteException e) {
@@ -1816,6 +1837,8 @@
 
             mCurrentState = BackupState.INITIAL;
             mFinished = false;
+
+            addBackupTrace("STATE => INITIAL");
         }
 
         // Main entry point: perform one chunk of work, updating the state as appropriate
@@ -1844,11 +1867,25 @@
         // We're starting a backup pass.  Initialize the transport and send
         // the PM metadata blob if we haven't already.
         void beginBackup() {
+            if (DEBUG_BACKUP_TRACE) {
+                clearBackupTrace();
+                StringBuilder b = new StringBuilder(256);
+                b.append("beginBackup: [");
+                for (BackupRequest req : mOriginalQueue) {
+                    b.append(' ');
+                    b.append(req.packageName);
+                }
+                b.append(" ]");
+                addBackupTrace(b.toString());
+            }
+
             mStatus = BackupConstants.TRANSPORT_OK;
 
             // Sanity check: if the queue is empty we have no work to do.
             if (mOriginalQueue.isEmpty()) {
                 Slog.w(TAG, "Backup begun with an empty queue - nothing to do.");
+                addBackupTrace("queue empty at begin");
+                executeNextState(BackupState.FINAL);
                 return;
             }
 
@@ -1861,13 +1898,17 @@
 
             File pmState = new File(mStateDir, PACKAGE_MANAGER_SENTINEL);
             try {
-                EventLog.writeEvent(EventLogTags.BACKUP_START, mTransport.transportDirName());
+                final String transportName = mTransport.transportDirName();
+                EventLog.writeEvent(EventLogTags.BACKUP_START, transportName);
 
                 // If we haven't stored package manager metadata yet, we must init the transport.
                 if (mStatus == BackupConstants.TRANSPORT_OK && pmState.length() <= 0) {
                     Slog.i(TAG, "Initializing (wiping) backup state and transport storage");
+                    addBackupTrace("initializing transport " + transportName);
                     resetBackupState(mStateDir);  // Just to make sure.
                     mStatus = mTransport.initializeDevice();
+
+                    addBackupTrace("transport.initializeDevice() == " + mStatus);
                     if (mStatus == BackupConstants.TRANSPORT_OK) {
                         EventLog.writeEvent(EventLogTags.BACKUP_INITIALIZE);
                     } else {
@@ -1886,6 +1927,7 @@
                             mPackageManager, allAgentPackages());
                     mStatus = invokeAgentForBackup(PACKAGE_MANAGER_SENTINEL,
                             IBackupAgent.Stub.asInterface(pmAgent.onBind()), mTransport);
+                    addBackupTrace("PMBA invoke: " + mStatus);
                 }
 
                 if (mStatus == BackupConstants.TRANSPORT_NOT_INITIALIZED) {
@@ -1896,11 +1938,13 @@
                 }
             } catch (Exception e) {
                 Slog.e(TAG, "Error in backup thread", e);
+                addBackupTrace("Exception in backup thread: " + e);
                 mStatus = BackupConstants.TRANSPORT_ERROR;
             } finally {
                 // If we've succeeded so far, invokeAgentForBackup() will have run the PM
                 // metadata and its completion/timeout callback will continue the state
                 // machine chain.  If it failed that won't happen; we handle that now.
+                addBackupTrace("exiting prelim: " + mStatus);
                 if (mStatus != BackupConstants.TRANSPORT_OK) {
                     // if things went wrong at this point, we need to
                     // restage everything and try again later.
@@ -1914,11 +1958,12 @@
         // if that was warranted.  Now we process the single next thing in the queue.
         void invokeNextAgent() {
             mStatus = BackupConstants.TRANSPORT_OK;
+            addBackupTrace("invoke q=" + mQueue.size());
 
             // Sanity check that we have work to do.  If not, skip to the end where
             // we reestablish the wakelock invariants etc.
             if (mQueue.isEmpty()) {
-                Slog.e(TAG, "Running queue but it's empty!");
+                if (DEBUG) Slog.i(TAG, "queue now empty");
                 executeNextState(BackupState.FINAL);
                 return;
             }
@@ -1928,6 +1973,7 @@
             mQueue.remove(0);
 
             Slog.d(TAG, "starting agent for backup of " + request);
+            addBackupTrace("launch agent for " + request.packageName);
 
             // Verify that the requested app exists; it might be something that
             // requested a backup but was then uninstalled.  The request was
@@ -1943,6 +1989,7 @@
                     mWakelock.setWorkSource(new WorkSource(mCurrentPackage.applicationInfo.uid));
                     agent = bindToAgentSynchronous(mCurrentPackage.applicationInfo,
                             IApplicationThread.BACKUP_MODE_INCREMENTAL);
+                    addBackupTrace("agent bound; a? = " + (agent != null));
                     if (agent != null) {
                         mStatus = invokeAgentForBackup(request.packageName, agent, mTransport);
                         // at this point we'll either get a completion callback from the
@@ -1956,14 +2003,17 @@
                     // Try for the next one.
                     Slog.d(TAG, "error in bind/backup", ex);
                     mStatus = BackupConstants.AGENT_ERROR;
+                            addBackupTrace("agent SE");
                 }
             } catch (NameNotFoundException e) {
                 Slog.d(TAG, "Package does not exist; skipping");
+                addBackupTrace("no such package");
+                mStatus = BackupConstants.AGENT_UNKNOWN;
             } finally {
                 mWakelock.setWorkSource(null);
 
                 // If there was an agent error, no timeout/completion handling will occur.
-                // That means we need to deal with the next state ourselves.
+                // That means we need to direct to the next state ourselves.
                 if (mStatus != BackupConstants.TRANSPORT_OK) {
                     BackupState nextState = BackupState.RUNNING_QUEUE;
 
@@ -1975,18 +2025,26 @@
                         dataChangedImpl(request.packageName);
                         mStatus = BackupConstants.TRANSPORT_OK;
                         if (mQueue.isEmpty()) nextState = BackupState.FINAL;
-                    } else if (mStatus != BackupConstants.TRANSPORT_OK) {
+                    } else if (mStatus == BackupConstants.AGENT_UNKNOWN) {
+                        // Failed lookup of the app, so we couldn't bring up an agent, but
+                        // we're otherwise fine.  Just drop it and go on to the next as usual.
+                        mStatus = BackupConstants.TRANSPORT_OK;
+                    } else {
                         // Transport-level failure means we reenqueue everything
                         revertAndEndBackup();
                         nextState = BackupState.FINAL;
                     }
 
                     executeNextState(nextState);
+                } else {
+                    addBackupTrace("expecting completion/timeout callback");
                 }
             }
         }
 
         void finalizeBackup() {
+            addBackupTrace("finishing");
+
             // Either backup was successful, in which case we of course do not need
             // this pass's journal any more; or it failed, in which case we just
             // re-enqueued all of these packages in the current active journal.
@@ -1999,6 +2057,7 @@
             // done a backup, we can now record what the current backup dataset token
             // is.
             if ((mCurrentToken == 0) && (mStatus == BackupConstants.TRANSPORT_OK)) {
+                addBackupTrace("success; recording token");
                 try {
                     mCurrentToken = mTransport.getCurrentRestoreSet();
                 } catch (RemoteException e) {} // can't happen
@@ -2014,11 +2073,13 @@
                     // Make sure we back up everything and perform the one-time init
                     clearMetadata();
                     if (DEBUG) Slog.d(TAG, "Server requires init; rerunning");
+                    addBackupTrace("init required; rerunning");
                     backupNow();
                 }
             }
 
             // Only once we're entirely finished do we release the wakelock
+            clearBackupTrace();
             Slog.i(TAG, "Backup pass finished.");
             mWakelock.release();
         }
@@ -2033,7 +2094,8 @@
         // handler in case it doesn't get back to us.
         int invokeAgentForBackup(String packageName, IBackupAgent agent,
                 IBackupTransport transport) {
-            if (DEBUG) Slog.d(TAG, "processOneBackup doBackup() on " + packageName);
+            if (DEBUG) Slog.d(TAG, "invokeAgentForBackup on " + packageName);
+            addBackupTrace("invoking " + packageName);
 
             mSavedStateName = new File(mStateDir, packageName);
             mBackupDataName = new File(mDataDir, packageName + ".data");
@@ -2073,10 +2135,13 @@
                         ParcelFileDescriptor.MODE_TRUNCATE);
 
                 // Initiate the target's backup pass
+                addBackupTrace("setting timeout");
                 prepareOperationTimeout(token, TIMEOUT_BACKUP_INTERVAL, this);
+                addBackupTrace("calling agent doBackup()");
                 agent.doBackup(mSavedState, mBackupData, mNewState, token, mBackupManagerBinder);
             } catch (Exception e) {
                 Slog.e(TAG, "Error invoking for backup on " + packageName);
+                addBackupTrace("exception: " + e);
                 EventLog.writeEvent(EventLogTags.BACKUP_AGENT_FAILURE, packageName,
                         e.toString());
                 agentErrorCleanup();
@@ -2087,6 +2152,7 @@
             // either be a callback from the agent, at which point we'll process its data
             // for transport, or a timeout.  Either way the next phase will happen in
             // response to the TimeoutHandler interface callbacks.
+            addBackupTrace("invoke success");
             return BackupConstants.TRANSPORT_OK;
         }
 
@@ -2098,6 +2164,7 @@
                     + mCurrentPackage.packageName);
             mBackupHandler.removeMessages(MSG_TIMEOUT);
             clearAgentState();
+            addBackupTrace("operation complete");
 
             ParcelFileDescriptor backupData = null;
             mStatus = BackupConstants.TRANSPORT_OK;
@@ -2107,6 +2174,7 @@
                     if (mStatus == BackupConstants.TRANSPORT_OK) {
                         backupData = ParcelFileDescriptor.open(mBackupDataName,
                                 ParcelFileDescriptor.MODE_READ_ONLY);
+                        addBackupTrace("sending data to transport");
                         mStatus = mTransport.performBackup(mCurrentPackage, backupData);
                     }
 
@@ -2115,11 +2183,15 @@
                     // hold off on finishBackup() until the end, which implies holding off on
                     // renaming *all* the output state files (see below) until that happens.
 
+                    addBackupTrace("data delivered: " + mStatus);
                     if (mStatus == BackupConstants.TRANSPORT_OK) {
+                        addBackupTrace("finishing op on transport");
                         mStatus = mTransport.finishBackup();
+                        addBackupTrace("finished: " + mStatus);
                     }
                 } else {
                     if (DEBUG) Slog.i(TAG, "no backup data written; not calling transport");
+                    addBackupTrace("no data to send");
                 }
 
                 // After successful transport, delete the now-stale data
@@ -2167,12 +2239,14 @@
             Slog.e(TAG, "Timeout backing up " + mCurrentPackage.packageName);
             EventLog.writeEvent(EventLogTags.BACKUP_AGENT_FAILURE, mCurrentPackage.packageName,
                     "timeout");
+            addBackupTrace("timeout of " + mCurrentPackage.packageName);
             agentErrorCleanup();
             dataChangedImpl(mCurrentPackage.packageName);
         }
 
         void revertAndEndBackup() {
             if (MORE_DEBUG) Slog.i(TAG, "Reverting backup queue - restaging everything");
+            addBackupTrace("transport error; reverting");
             for (BackupRequest request : mOriginalQueue) {
                 dataChangedImpl(request.packageName);
             }
@@ -2201,6 +2275,7 @@
 
             // If this was a pseudopackage there's no associated Activity Manager state
             if (mCurrentPackage.applicationInfo != null) {
+                addBackupTrace("unbinding " + mCurrentPackage.packageName);
                 try {  // unbind even on timeout, just in case
                     mActivityManager.unbindBackupAgent(mCurrentPackage.applicationInfo);
                 } catch (RemoteException e) {}
@@ -2208,6 +2283,7 @@
         }
 
         void restartBackupAlarm() {
+            addBackupTrace("setting backup trigger");
             synchronized (mQueueLock) {
                 try {
                     startBackupAlarmsLocked(mTransport.requestBackupTime());
@@ -2218,6 +2294,7 @@
         void executeNextState(BackupState nextState) {
             if (MORE_DEBUG) Slog.i(TAG, " => executing next step on "
                     + this + " nextState=" + nextState);
+            addBackupTrace("executeNextState => " + nextState);
             mCurrentState = nextState;
             Message msg = mBackupHandler.obtainMessage(MSG_BACKUP_RESTORE_STEP, this);
             mBackupHandler.sendMessage(msg);
@@ -4717,6 +4794,8 @@
                     // one already there, then overwrite it, but no harm done.
                     BackupRequest req = new BackupRequest(packageName);
                     if (mPendingBackups.put(app.packageName, req) == null) {
+                        if (DEBUG) Slog.d(TAG, "Now staging backup of " + packageName);
+
                         // Journal this request in case of crash.  The put()
                         // operation returned null when this package was not already
                         // in the set; we want to avoid touching the disk redundantly.
@@ -5738,6 +5817,17 @@
                 pw.println("    " + s);
             }
 
+            if (DEBUG_BACKUP_TRACE) {
+                synchronized (mBackupTrace) {
+                    if (!mBackupTrace.isEmpty()) {
+                        pw.println("Most recent backup trace:");
+                        for (String s : mBackupTrace) {
+                            pw.println("   " + s);
+                        }
+                    }
+                }
+            }
+
             int N = mBackupParticipants.size();
             pw.println("Participants:");
             for (int i=0; i<N; i++) {
diff --git a/services/java/com/android/server/am/ActivityManagerService.java b/services/java/com/android/server/am/ActivityManagerService.java
index bbb4917..db0a736 100644
--- a/services/java/com/android/server/am/ActivityManagerService.java
+++ b/services/java/com/android/server/am/ActivityManagerService.java
@@ -4045,6 +4045,7 @@
                 mHandler.sendMessageDelayed(nmsg, POWER_CHECK_DELAY);
                 // Tell anyone interested that we are done booting!
                 SystemProperties.set("sys.boot_completed", "1");
+                SystemProperties.set("dev.bootcomplete", "1");
                 broadcastIntentLocked(null, null,
                         new Intent(Intent.ACTION_BOOT_COMPLETED, null),
                         null, null, 0, null, null,
diff --git a/services/java/com/android/server/wm/WindowManagerService.java b/services/java/com/android/server/wm/WindowManagerService.java
index 75ace4f..6ff0100 100644
--- a/services/java/com/android/server/wm/WindowManagerService.java
+++ b/services/java/com/android/server/wm/WindowManagerService.java
@@ -7396,8 +7396,11 @@
         final int N = mWindows.size();
         int i;
 
-        if (DEBUG_LAYOUT) Slog.v(TAG, "performLayout: needed="
-                + mLayoutNeeded + " dw=" + dw + " dh=" + dh);
+        if (DEBUG_LAYOUT) {
+            Slog.v(TAG, "-------------------------------------");
+            Slog.v(TAG, "performLayout: needed="
+                    + mLayoutNeeded + " dw=" + dw + " dh=" + dh);
+        }
         
         mPolicy.beginLayoutLw(dw, dh, mRotation);
 
@@ -7414,19 +7417,20 @@
             // Don't do layout of a window if it is not visible, or
             // soon won't be visible, to avoid wasting time and funky
             // changes while a window is animating away.
-            final AppWindowToken atoken = win.mAppToken;
-            final boolean gone = win.mViewVisibility == View.GONE
-                    || !win.mRelayoutCalled
-                    || (atoken == null && win.mRootToken.hidden)
-                    || (atoken != null && atoken.hiddenRequested)
-                    || win.mAttachedHidden
-                    || win.mExiting || win.mDestroying;
+            final boolean gone = win.isGoneForLayoutLw();
 
             if (DEBUG_LAYOUT && !win.mLayoutAttached) {
-                Slog.v(TAG, "First pass " + win
+                Slog.v(TAG, "1ST PASS " + win
                         + ": gone=" + gone + " mHaveFrame=" + win.mHaveFrame
                         + " mLayoutAttached=" + win.mLayoutAttached);
-                if (gone) Slog.v(TAG, "  (mViewVisibility="
+                final AppWindowToken atoken = win.mAppToken;
+                if (gone) Slog.v(TAG, "  GONE: mViewVisibility="
+                        + win.mViewVisibility + " mRelayoutCalled="
+                        + win.mRelayoutCalled + " hidden="
+                        + win.mRootToken.hidden + " hiddenRequested="
+                        + (atoken != null && atoken.hiddenRequested)
+                        + " mAttachedHidden=" + win.mAttachedHidden);
+                else Slog.v(TAG, "  VIS: mViewVisibility="
                         + win.mViewVisibility + " mRelayoutCalled="
                         + win.mRelayoutCalled + " hidden="
                         + win.mRootToken.hidden + " hiddenRequested="
@@ -7448,7 +7452,7 @@
                     win.prelayout();
                     mPolicy.layoutWindowLw(win, win.mAttrs, null);
                     win.mLayoutSeq = seq;
-                    if (DEBUG_LAYOUT) Slog.v(TAG, "-> mFrame="
+                    if (DEBUG_LAYOUT) Slog.v(TAG, "  LAYOUT: mFrame="
                             + win.mFrame + " mContainingFrame="
                             + win.mContainingFrame + " mDisplayFrame="
                             + win.mDisplayFrame);
@@ -7466,7 +7470,7 @@
             WindowState win = mWindows.get(i);
 
             if (win.mLayoutAttached) {
-                if (DEBUG_LAYOUT) Slog.v(TAG, "Second pass " + win
+                if (DEBUG_LAYOUT) Slog.v(TAG, "2ND PASS " + win
                         + " mHaveFrame=" + win.mHaveFrame
                         + " mViewVisibility=" + win.mViewVisibility
                         + " mRelayoutCalled=" + win.mRelayoutCalled);
@@ -7484,7 +7488,7 @@
                     win.prelayout();
                     mPolicy.layoutWindowLw(win, win.mAttrs, win.mAttachedWindow);
                     win.mLayoutSeq = seq;
-                    if (DEBUG_LAYOUT) Slog.v(TAG, "-> mFrame="
+                    if (DEBUG_LAYOUT) Slog.v(TAG, "  LAYOUT: mFrame="
                             + win.mFrame + " mContainingFrame="
                             + win.mContainingFrame + " mDisplayFrame="
                             + win.mDisplayFrame);
diff --git a/services/java/com/android/server/wm/WindowState.java b/services/java/com/android/server/wm/WindowState.java
index 75bda41..794515b 100644
--- a/services/java/com/android/server/wm/WindowState.java
+++ b/services/java/com/android/server/wm/WindowState.java
@@ -1444,6 +1444,16 @@
                     || mAnimating);
     }
 
+    public boolean isGoneForLayoutLw() {
+        final AppWindowToken atoken = mAppToken;
+        return mViewVisibility == View.GONE
+                || !mRelayoutCalled
+                || (atoken == null && mRootToken.hidden)
+                || (atoken != null && (atoken.hiddenRequested || atoken.hidden))
+                || mAttachedHidden
+                || mExiting || mDestroying;
+    }
+
     /**
      * Returns true if the window has a surface that it has drawn a
      * complete UI in to.
diff --git a/services/surfaceflinger/EventThread.cpp b/services/surfaceflinger/EventThread.cpp
index 035836e..80ab519 100644
--- a/services/surfaceflinger/EventThread.cpp
+++ b/services/surfaceflinger/EventThread.cpp
@@ -102,7 +102,7 @@
 
     nsecs_t timestamp;
     DisplayEventReceiver::Event vsync;
-    KeyedVector< wp<DisplayEventConnection>, ConnectionInfo > displayEventConnections;
+    Vector< wp<DisplayEventConnection> > displayEventConnections;
 
     { // scope for the lock
         Mutex::Autolock _l(mLock);
@@ -153,6 +153,9 @@
                     }
                     info.count--;
                 }
+                if (reportVsync) {
+                    displayEventConnections.add(mDisplayEventConnections.keyAt(i));
+                }
             }
 
             if (reportVsync) {
@@ -164,15 +167,11 @@
         vsync.header.type = DisplayEventReceiver::DISPLAY_EVENT_VSYNC;
         vsync.header.timestamp = timestamp;
         vsync.vsync.count = mDeliveredEvents;
-
-        // make a copy of our connection list, so we can
-        // dispatch events without holding mLock
-        displayEventConnections = mDisplayEventConnections;
     }
 
     const size_t count = displayEventConnections.size();
     for (size_t i=0 ; i<count ; i++) {
-        sp<DisplayEventConnection> conn(displayEventConnections.keyAt(i).promote());
+        sp<DisplayEventConnection> conn(displayEventConnections[i].promote());
         // make sure the connection didn't die
         if (conn != NULL) {
             status_t err = conn->postEvent(vsync);
@@ -186,12 +185,12 @@
                 // handle any other error on the pipe as fatal. the only
                 // reasonable thing to do is to clean-up this connection.
                 // The most common error we'll get here is -EPIPE.
-                removeDisplayEventConnection(displayEventConnections.keyAt(i));
+                removeDisplayEventConnection(displayEventConnections[i]);
             }
         } else {
             // somehow the connection is dead, but we still have it in our list
             // just clean the list.
-            removeDisplayEventConnection(displayEventConnections.keyAt(i));
+            removeDisplayEventConnection(displayEventConnections[i]);
         }
     }
 
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index 42ae408..af47402 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -59,15 +59,9 @@
 #include "DisplayHardware/DisplayHardware.h"
 #include "DisplayHardware/HWComposer.h"
 
+#include <private/android_filesystem_config.h>
 #include <private/surfaceflinger/SharedBufferStack.h>
 
-/* ideally AID_GRAPHICS would be in a semi-public header
- * or there would be a way to map a user/group name to its id
- */
-#ifndef AID_GRAPHICS
-#define AID_GRAPHICS 1003
-#endif
-
 #define EGL_VERSION_HW_ANDROID  0x3143
 
 #define DISPLAY_COUNT       1
diff --git a/telephony/java/com/android/internal/telephony/DataConnectionTracker.java b/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
index dab72a9..664a091 100644
--- a/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
+++ b/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
@@ -1038,8 +1038,10 @@
                     didDisable = true;
                 }
             }
-            if (didDisable && enabledCount == 0) {
-                onCleanUpConnection(true, apnId, Phone.REASON_DATA_DISABLED);
+            if (didDisable) {
+                if (enabledCount == 0) {
+                    onCleanUpConnection(true, apnId, Phone.REASON_DATA_DISABLED);
+                }
 
                 // send the disconnect msg manually, since the normal route wont send
                 // it (it's not enabled)
diff --git a/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java b/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
index 6096cb0..c3adf7b 100644
--- a/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
+++ b/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
@@ -136,7 +136,8 @@
     private static final String INTENT_DATA_STALL_ALARM =
         "com.android.internal.telephony.gprs-data-stall";
 
-    static final Uri PREFERAPN_URI = Uri.parse("content://telephony/carriers/preferapn");
+    static final Uri PREFERAPN_NO_UPDATE_URI =
+                        Uri.parse("content://telephony/carriers/preferapn_no_update");
     static final String APN_ID = "apn_id";
     private boolean canSetPreferApn = false;
 
@@ -2357,26 +2358,30 @@
 
     private void setPreferredApn(int pos) {
         if (!canSetPreferApn) {
+            log("setPreferredApn: X !canSEtPreferApn");
             return;
         }
 
+        log("setPreferredApn: delete");
         ContentResolver resolver = mPhone.getContext().getContentResolver();
-        resolver.delete(PREFERAPN_URI, null, null);
+        resolver.delete(PREFERAPN_NO_UPDATE_URI, null, null);
 
         if (pos >= 0) {
+            log("setPreferredApn: insert");
             ContentValues values = new ContentValues();
             values.put(APN_ID, pos);
-            resolver.insert(PREFERAPN_URI, values);
+            resolver.insert(PREFERAPN_NO_UPDATE_URI, values);
         }
     }
 
     private ApnSetting getPreferredApn() {
         if (mAllApns.isEmpty()) {
+            log("getPreferredApn: X not found mAllApns.isEmpty");
             return null;
         }
 
         Cursor cursor = mPhone.getContext().getContentResolver().query(
-                PREFERAPN_URI, new String[] { "_id", "name", "apn" },
+                PREFERAPN_NO_UPDATE_URI, new String[] { "_id", "name", "apn" },
                 null, null, Telephony.Carriers.DEFAULT_SORT_ORDER);
 
         if (cursor != null) {
@@ -2391,6 +2396,7 @@
             pos = cursor.getInt(cursor.getColumnIndexOrThrow(Telephony.Carriers._ID));
             for(ApnSetting p:mAllApns) {
                 if (p.id == pos && p.canHandleType(mRequestedApnType)) {
+                    log("getPreferredApn: X found apnSetting" + p);
                     cursor.close();
                     return p;
                 }
@@ -2401,6 +2407,7 @@
             cursor.close();
         }
 
+        log("getPreferredApn: X not found");
         return null;
     }
 
diff --git a/tests/BiDiTests/res/values/strings.xml b/tests/BiDiTests/res/values/strings.xml
index b1f5e50e..1d4fc84 100644
--- a/tests/BiDiTests/res/values/strings.xml
+++ b/tests/BiDiTests/res/values/strings.xml
@@ -50,5 +50,6 @@
     <string name="rtl">"والحق أن تترك ونص"</string>
     <string name="composing">"\u0644\u0627"</string>
     <string name="url">www.amazon.co.uk/gp/aw/h.html/275-8912818-8203452</string>
+    <string name="pointer_location" msgid="6084434787496938001">"ตำแหน่งของตัวชี้"</string>
 </resources>
 
diff --git a/tests/BiDiTests/src/com/android/bidi/BiDiTestView.java b/tests/BiDiTests/src/com/android/bidi/BiDiTestView.java
index 0126dea..0b1974a 100644
--- a/tests/BiDiTests/src/com/android/bidi/BiDiTestView.java
+++ b/tests/BiDiTests/src/com/android/bidi/BiDiTestView.java
@@ -51,6 +51,7 @@
     private String MIXED_TEXT_1;
     private String HEBREW_TEXT;
     private String RTL_TEXT;
+    private String THAI_TEXT;
 
     private int currentTextSize;
 
@@ -82,6 +83,7 @@
         MIXED_TEXT_1 = context.getString(R.string.mixed_text_1);
         HEBREW_TEXT = context.getString(R.string.hebrew_text);
         RTL_TEXT = context.getString(R.string.rtl);
+        THAI_TEXT = context.getString(R.string.pointer_location);
     }
 
     public void setCurrentTextSize(int size) {
@@ -134,6 +136,10 @@
         // Test Hebrew
         deltaX = testString(canvas, RTL_TEXT, ORIGIN, ORIGIN + 14 * currentTextSize,
                 false, false,  Paint.DIRECTION_RTL, currentTextSize);
+
+        // Test Thai
+        deltaX = testString(canvas, THAI_TEXT, ORIGIN, ORIGIN + 16 * currentTextSize,
+                false, false,  Paint.DIRECTION_LTR, currentTextSize);
     }
 
     private int testString(Canvas canvas, String text, int x, int y,
diff --git a/tests/HwAccelerationTest/AndroidManifest.xml b/tests/HwAccelerationTest/AndroidManifest.xml
index 929b103..6f97ff0 100644
--- a/tests/HwAccelerationTest/AndroidManifest.xml
+++ b/tests/HwAccelerationTest/AndroidManifest.xml
@@ -466,6 +466,16 @@
         </activity>
 
         <activity
+                android:name="PosTextActivity"
+                android:label="_PosText"
+                android:theme="@android:style/Theme.NoTitleBar">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+
+        <activity
                 android:name="ListActivity"
                 android:label="__List">
             <intent-filter>
diff --git a/tests/HwAccelerationTest/res/values/strings.xml b/tests/HwAccelerationTest/res/values/strings.xml
new file mode 100644
index 0000000..69e58aa
--- /dev/null
+++ b/tests/HwAccelerationTest/res/values/strings.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2012 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+  
+          http://www.apache.org/licenses/LICENSE-2.0
+  
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+
+<resources>
+    <string name="complex_string">"ตำแหน่งของตัวชี้"</string>
+</resources>
diff --git a/tests/HwAccelerationTest/src/com/android/test/hwui/PosTextActivity.java b/tests/HwAccelerationTest/src/com/android/test/hwui/PosTextActivity.java
new file mode 100644
index 0000000..1c868d2
--- /dev/null
+++ b/tests/HwAccelerationTest/src/com/android/test/hwui/PosTextActivity.java
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2010 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.test.hwui;
+
+import android.app.Activity;
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.Paint;
+import android.os.Bundle;
+import android.view.View;
+
+@SuppressWarnings({"UnusedDeclaration"})
+public class PosTextActivity extends Activity {
+    @Override
+    protected void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+
+        setContentView(new CustomTextView(this));
+    }
+
+    static class CustomTextView extends View {
+        private final Paint mLargePaint;
+        private final String mText;
+        private final float[] mPos;
+
+        CustomTextView(Context c) {
+            super(c);
+
+            mText = c.getResources().getString(R.string.complex_string);
+            mPos = new float[mText.length() * 2];
+            for (int i = 0; i < mPos.length; i += 2) {
+                mPos[i] = i * 30.0f;
+                mPos[i + 1] = i * 10.0f;
+            }
+
+            mLargePaint = new Paint();
+            mLargePaint.setAntiAlias(true);
+            mLargePaint.setTextSize(36.0f);
+        }
+
+        @Override
+        protected void onDraw(Canvas canvas) {
+            super.onDraw(canvas);
+            canvas.drawRGB(255, 255, 255);
+            
+            canvas.save();
+
+            canvas.drawLine(100.0f, 0.0f, 100.0f, getHeight(), mLargePaint);
+            
+            canvas.translate(100.0f, 100.0f);
+            mLargePaint.setTextAlign(Paint.Align.LEFT);
+            canvas.drawPosText(mText, mPos, mLargePaint);
+
+            canvas.translate(0.0f, 50.0f);
+            mLargePaint.setTextAlign(Paint.Align.CENTER);
+            canvas.drawPosText(mText, mPos, mLargePaint);
+
+            canvas.translate(0.0f, 50.0f);
+            mLargePaint.setTextAlign(Paint.Align.RIGHT);
+            canvas.drawPosText(mText, mPos, mLargePaint);
+
+            canvas.restore();
+        }
+    }
+}
diff --git a/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/ComputePerf.java b/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/ComputePerf.java
index f7abe8b..5446f66 100644
--- a/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/ComputePerf.java
+++ b/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/ComputePerf.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011 The Android Open Source Project
+ * Copyright (C) 2011-2012 The Android Open Source Project
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -22,10 +22,10 @@
 import android.graphics.Bitmap;
 import android.renderscript.RenderScript;
 import android.renderscript.Allocation;
+import android.util.Log;
 import android.widget.ImageView;
 
 public class ComputePerf extends Activity {
-
     private LaunchTest mLT;
     private Mandelbrot mMandel;
     private RenderScript mRS;
@@ -35,14 +35,28 @@
         super.onCreate(savedInstanceState);
         setContentView(R.layout.main);
 
+        final int numTries = 100;
+
+        long timesXLW = 0;
+        long timesXYW = 0;
+
         mRS = RenderScript.create(this);
         mLT = new LaunchTest(mRS, getResources());
-        mLT.run();
-        mLT.run();
+        mLT.XLW();
+        mLT.XYW();
+        for (int i = 0; i < numTries; i++) {
+            timesXLW += mLT.XLW();
+            timesXYW += mLT.XYW();
+        }
+
+        timesXLW /= numTries;
+        timesXYW /= numTries;
+
+        // XLW and XYW running times should match pretty closely
+        Log.v("ComputePerf", "xlw launch test " + timesXLW + "ms");
+        Log.v("ComputePerf", "xyw launch test " + timesXYW + "ms");
 
         mMandel = new Mandelbrot(mRS, getResources());
         mMandel.run();
-
     }
-
 }
diff --git a/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/LaunchTest.java b/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/LaunchTest.java
index 0c29ce1..e2312ba 100644
--- a/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/LaunchTest.java
+++ b/tests/RenderScriptTests/ComputePerf/src/com/example/android/rs/computeperf/LaunchTest.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011 The Android Open Source Project
+ * Copyright (C) 2011-2012 The Android Open Source Project
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -19,7 +19,7 @@
 import android.content.res.Resources;
 import android.renderscript.*;
 
-public class LaunchTest implements Runnable {
+public class LaunchTest {
     private RenderScript mRS;
     private Allocation mAllocationX;
     private Allocation mAllocationXY;
@@ -40,18 +40,19 @@
         mScript_xlw.bind_buf(mAllocationXY);
     }
 
-    public void run() {
+    public long XLW() {
         long t = java.lang.System.currentTimeMillis();
         mScript_xlw.forEach_root(mAllocationX);
         mRS.finish();
         t = java.lang.System.currentTimeMillis() - t;
-        android.util.Log.v("ComputePerf", "xlw launch test  ms " + t);
+        return t;
+    }
 
-        t = java.lang.System.currentTimeMillis();
+    public long XYW() {
+        long t = java.lang.System.currentTimeMillis();
         mScript_xyw.forEach_root(mAllocationXY);
         mRS.finish();
         t = java.lang.System.currentTimeMillis() - t;
-        android.util.Log.v("ComputePerf", "xyw launch test  ms " + t);
+        return t;
     }
-
 }
diff --git a/tools/orientationplot/orientationplot.py b/tools/orientationplot/orientationplot.py
index 3a44cb2..f4e6b45 100755
--- a/tools/orientationplot/orientationplot.py
+++ b/tools/orientationplot/orientationplot.py
@@ -82,6 +82,7 @@
     self.raw_acceleration_x = self._make_timeseries()
     self.raw_acceleration_y = self._make_timeseries()
     self.raw_acceleration_z = self._make_timeseries()
+    self.raw_acceleration_magnitude = self._make_timeseries()
     self.raw_acceleration_axes = self._add_timeseries_axes(
         1, 'Raw Acceleration', 'm/s^2', [-20, 20],
         yticks=range(-15, 16, 5))
@@ -91,6 +92,8 @@
         self.raw_acceleration_axes, 'y', 'green')
     self.raw_acceleration_line_z = self._add_timeseries_line(
         self.raw_acceleration_axes, 'z', 'blue')
+    self.raw_acceleration_line_magnitude = self._add_timeseries_line(
+        self.raw_acceleration_axes, 'magnitude', 'orange', linewidth=2)
     self._add_timeseries_legend(self.raw_acceleration_axes)
 
     shared_axis = self.raw_acceleration_axes
@@ -98,7 +101,7 @@
     self.filtered_acceleration_x = self._make_timeseries()
     self.filtered_acceleration_y = self._make_timeseries()
     self.filtered_acceleration_z = self._make_timeseries()
-    self.magnitude = self._make_timeseries()
+    self.filtered_acceleration_magnitude = self._make_timeseries()
     self.filtered_acceleration_axes = self._add_timeseries_axes(
         2, 'Filtered Acceleration', 'm/s^2', [-20, 20],
         sharex=shared_axis,
@@ -109,7 +112,7 @@
         self.filtered_acceleration_axes, 'y', 'green')
     self.filtered_acceleration_line_z = self._add_timeseries_line(
         self.filtered_acceleration_axes, 'z', 'blue')
-    self.magnitude_line = self._add_timeseries_line(
+    self.filtered_acceleration_line_magnitude = self._add_timeseries_line(
         self.filtered_acceleration_axes, 'magnitude', 'orange', linewidth=2)
     self._add_timeseries_legend(self.filtered_acceleration_axes)
 
@@ -133,32 +136,46 @@
 
     self.current_rotation = self._make_timeseries()
     self.proposed_rotation = self._make_timeseries()
-    self.proposal_rotation = self._make_timeseries()
+    self.predicted_rotation = self._make_timeseries()
     self.orientation_axes = self._add_timeseries_axes(
-        5, 'Current / Proposed Orientation and Confidence', 'rotation', [-1, 4],
+        5, 'Current / Proposed Orientation', 'rotation', [-1, 4],
         sharex=shared_axis,
         yticks=range(0, 4))
     self.current_rotation_line = self._add_timeseries_line(
         self.orientation_axes, 'current', 'black', linewidth=2)
-    self.proposal_rotation_line = self._add_timeseries_line(
-        self.orientation_axes, 'proposal', 'purple', linewidth=3)
+    self.predicted_rotation_line = self._add_timeseries_line(
+        self.orientation_axes, 'predicted', 'purple', linewidth=3)
     self.proposed_rotation_line = self._add_timeseries_line(
         self.orientation_axes, 'proposed', 'green', linewidth=3)
     self._add_timeseries_legend(self.orientation_axes)
 
-    self.proposal_confidence = [[self._make_timeseries(), self._make_timeseries()]
-      for i in range(0, 4)]
-    self.proposal_confidence_polys = []
+    self.time_until_settled = self._make_timeseries()
+    self.time_until_flat_delay_expired = self._make_timeseries()
+    self.time_until_swing_delay_expired = self._make_timeseries()
+    self.stability_axes = self._add_timeseries_axes(
+        6, 'Proposal Stability', 'ms', [-10, 600],
+        sharex=shared_axis,
+        yticks=range(0, 600, 100))
+    self.time_until_settled_line = self._add_timeseries_line(
+        self.stability_axes, 'time until settled', 'black', linewidth=2)
+    self.time_until_flat_delay_expired_line = self._add_timeseries_line(
+        self.stability_axes, 'time until flat delay expired', 'green')
+    self.time_until_swing_delay_expired_line = self._add_timeseries_line(
+        self.stability_axes, 'time until swing delay expired', 'blue')
+    self._add_timeseries_legend(self.stability_axes)
 
     self.sample_latency = self._make_timeseries()
     self.sample_latency_axes = self._add_timeseries_axes(
-        6, 'Accelerometer Sampling Latency', 'ms', [-10, 500],
+        7, 'Accelerometer Sampling Latency', 'ms', [-10, 500],
         sharex=shared_axis,
         yticks=range(0, 500, 100))
     self.sample_latency_line = self._add_timeseries_line(
         self.sample_latency_axes, 'latency', 'black')
     self._add_timeseries_legend(self.sample_latency_axes)
 
+    self.fig.canvas.mpl_connect('button_press_event', self._on_click)
+    self.paused = False
+
     self.timer = self.fig.canvas.new_timer(interval=100)
     self.timer.add_callback(lambda: self.update())
     self.timer.start()
@@ -166,13 +183,22 @@
     self.timebase = None
     self._reset_parse_state()
 
+  # Handle a click event to pause or restart the timer.
+  def _on_click(self, ev):
+    if not self.paused:
+      self.paused = True
+      self.timer.stop()
+    else:
+      self.paused = False
+      self.timer.start()
+
   # Initialize a time series.
   def _make_timeseries(self):
     return [[], []]
 
   # Add a subplot to the figure for a time series.
   def _add_timeseries_axes(self, index, title, ylabel, ylim, yticks, sharex=None):
-    num_graphs = 6
+    num_graphs = 7
     height = 0.9 / num_graphs
     top = 0.95 - height * index
     axes = self.fig.add_axes([0.1, top, 0.8, height],
@@ -214,16 +240,19 @@
     self.parse_raw_acceleration_x = None
     self.parse_raw_acceleration_y = None
     self.parse_raw_acceleration_z = None
+    self.parse_raw_acceleration_magnitude = None
     self.parse_filtered_acceleration_x = None
     self.parse_filtered_acceleration_y = None
     self.parse_filtered_acceleration_z = None
-    self.parse_magnitude = None
+    self.parse_filtered_acceleration_magnitude = None
     self.parse_tilt_angle = None
     self.parse_orientation_angle = None
     self.parse_current_rotation = None
     self.parse_proposed_rotation = None
-    self.parse_proposal_rotation = None
-    self.parse_proposal_confidence = None
+    self.parse_predicted_rotation = None
+    self.parse_time_until_settled = None
+    self.parse_time_until_flat_delay_expired = None
+    self.parse_time_until_swing_delay_expired = None
     self.parse_sample_latency = None
 
   # Update samples.
@@ -252,14 +281,13 @@
         self.parse_raw_acceleration_x = self._get_following_number(line, 'x=')
         self.parse_raw_acceleration_y = self._get_following_number(line, 'y=')
         self.parse_raw_acceleration_z = self._get_following_number(line, 'z=')
+        self.parse_raw_acceleration_magnitude = self._get_following_number(line, 'magnitude=')
 
       if line.find('Filtered acceleration vector:') != -1:
         self.parse_filtered_acceleration_x = self._get_following_number(line, 'x=')
         self.parse_filtered_acceleration_y = self._get_following_number(line, 'y=')
         self.parse_filtered_acceleration_z = self._get_following_number(line, 'z=')
-
-      if line.find('magnitude=') != -1:
-        self.parse_magnitude = self._get_following_number(line, 'magnitude=')
+        self.parse_filtered_acceleration_magnitude = self._get_following_number(line, 'magnitude=')
 
       if line.find('tiltAngle=') != -1:
         self.parse_tilt_angle = self._get_following_number(line, 'tiltAngle=')
@@ -270,17 +298,20 @@
       if line.find('Result:') != -1:
         self.parse_current_rotation = self._get_following_number(line, 'currentRotation=')
         self.parse_proposed_rotation = self._get_following_number(line, 'proposedRotation=')
-        self.parse_proposal_rotation = self._get_following_number(line, 'proposalRotation=')
-        self.parse_proposal_confidence = self._get_following_number(line, 'proposalConfidence=')
+        self.parse_predicted_rotation = self._get_following_number(line, 'predictedRotation=')
         self.parse_sample_latency = self._get_following_number(line, 'timeDeltaMS=')
+        self.parse_time_until_settled = self._get_following_number(line, 'timeUntilSettledMS=')
+        self.parse_time_until_flat_delay_expired = self._get_following_number(line, 'timeUntilFlatDelayExpiredMS=')
+        self.parse_time_until_swing_delay_expired = self._get_following_number(line, 'timeUntilSwingDelayExpiredMS=')
 
         self._append(self.raw_acceleration_x, timeindex, self.parse_raw_acceleration_x)
         self._append(self.raw_acceleration_y, timeindex, self.parse_raw_acceleration_y)
         self._append(self.raw_acceleration_z, timeindex, self.parse_raw_acceleration_z)
+        self._append(self.raw_acceleration_magnitude, timeindex, self.parse_raw_acceleration_magnitude)
         self._append(self.filtered_acceleration_x, timeindex, self.parse_filtered_acceleration_x)
         self._append(self.filtered_acceleration_y, timeindex, self.parse_filtered_acceleration_y)
         self._append(self.filtered_acceleration_z, timeindex, self.parse_filtered_acceleration_z)
-        self._append(self.magnitude, timeindex, self.parse_magnitude)
+        self._append(self.filtered_acceleration_magnitude, timeindex, self.parse_filtered_acceleration_magnitude)
         self._append(self.tilt_angle, timeindex, self.parse_tilt_angle)
         self._append(self.orientation_angle, timeindex, self.parse_orientation_angle)
         self._append(self.current_rotation, timeindex, self.parse_current_rotation)
@@ -288,17 +319,13 @@
           self._append(self.proposed_rotation, timeindex, self.parse_proposed_rotation)
         else:
           self._append(self.proposed_rotation, timeindex, None)
-        if self.parse_proposal_rotation >= 0:
-          self._append(self.proposal_rotation, timeindex, self.parse_proposal_rotation)
+        if self.parse_predicted_rotation >= 0:
+          self._append(self.predicted_rotation, timeindex, self.parse_predicted_rotation)
         else:
-          self._append(self.proposal_rotation, timeindex, None)
-        for i in range(0, 4):
-          self._append(self.proposal_confidence[i][0], timeindex, i)
-          if i == self.parse_proposal_rotation:
-            self._append(self.proposal_confidence[i][1], timeindex,
-              i + self.parse_proposal_confidence)
-          else:
-            self._append(self.proposal_confidence[i][1], timeindex, i)
+          self._append(self.predicted_rotation, timeindex, None)
+        self._append(self.time_until_settled, timeindex, self.parse_time_until_settled)
+        self._append(self.time_until_flat_delay_expired, timeindex, self.parse_time_until_flat_delay_expired)
+        self._append(self.time_until_swing_delay_expired, timeindex, self.parse_time_until_swing_delay_expired)
         self._append(self.sample_latency, timeindex, self.parse_sample_latency)
         self._reset_parse_state()
 
@@ -309,45 +336,40 @@
       self._scroll(self.raw_acceleration_x, bottom)
       self._scroll(self.raw_acceleration_y, bottom)
       self._scroll(self.raw_acceleration_z, bottom)
+      self._scroll(self.raw_acceleration_magnitude, bottom)
       self._scroll(self.filtered_acceleration_x, bottom)
       self._scroll(self.filtered_acceleration_y, bottom)
       self._scroll(self.filtered_acceleration_z, bottom)
-      self._scroll(self.magnitude, bottom)
+      self._scroll(self.filtered_acceleration_magnitude, bottom)
       self._scroll(self.tilt_angle, bottom)
       self._scroll(self.orientation_angle, bottom)
       self._scroll(self.current_rotation, bottom)
       self._scroll(self.proposed_rotation, bottom)
-      self._scroll(self.proposal_rotation, bottom)
-      for i in range(0, 4):
-        self._scroll(self.proposal_confidence[i][0], bottom)
-        self._scroll(self.proposal_confidence[i][1], bottom)
+      self._scroll(self.predicted_rotation, bottom)
+      self._scroll(self.time_until_settled, bottom)
+      self._scroll(self.time_until_flat_delay_expired, bottom)
+      self._scroll(self.time_until_swing_delay_expired, bottom)
       self._scroll(self.sample_latency, bottom)
 
     # Redraw the plots.
     self.raw_acceleration_line_x.set_data(self.raw_acceleration_x)
     self.raw_acceleration_line_y.set_data(self.raw_acceleration_y)
     self.raw_acceleration_line_z.set_data(self.raw_acceleration_z)
+    self.raw_acceleration_line_magnitude.set_data(self.raw_acceleration_magnitude)
     self.filtered_acceleration_line_x.set_data(self.filtered_acceleration_x)
     self.filtered_acceleration_line_y.set_data(self.filtered_acceleration_y)
     self.filtered_acceleration_line_z.set_data(self.filtered_acceleration_z)
-    self.magnitude_line.set_data(self.magnitude)
+    self.filtered_acceleration_line_magnitude.set_data(self.filtered_acceleration_magnitude)
     self.tilt_angle_line.set_data(self.tilt_angle)
     self.orientation_angle_line.set_data(self.orientation_angle)
     self.current_rotation_line.set_data(self.current_rotation)
     self.proposed_rotation_line.set_data(self.proposed_rotation)
-    self.proposal_rotation_line.set_data(self.proposal_rotation)
+    self.predicted_rotation_line.set_data(self.predicted_rotation)
+    self.time_until_settled_line.set_data(self.time_until_settled)
+    self.time_until_flat_delay_expired_line.set_data(self.time_until_flat_delay_expired)
+    self.time_until_swing_delay_expired_line.set_data(self.time_until_swing_delay_expired)
     self.sample_latency_line.set_data(self.sample_latency)
 
-    for poly in self.proposal_confidence_polys:
-      poly.remove()
-    self.proposal_confidence_polys = []
-    for i in range(0, 4):
-      self.proposal_confidence_polys.append(self.orientation_axes.fill_between(
-        self.proposal_confidence[i][0][0],
-        self.proposal_confidence[i][0][1],
-        self.proposal_confidence[i][1][1],
-        facecolor='goldenrod', edgecolor='goldenrod'))
-
     self.fig.canvas.draw_idle()
 
   # Scroll a time series.
diff --git a/voip/jni/rtp/AudioGroup.cpp b/voip/jni/rtp/AudioGroup.cpp
index 4db5738..1139577 100644
--- a/voip/jni/rtp/AudioGroup.cpp
+++ b/voip/jni/rtp/AudioGroup.cpp
@@ -1008,7 +1008,7 @@
     delete stream;
     delete codec;
     close(socket);
-    env->SetIntField(thiz, gNative, NULL);
+    env->SetIntField(thiz, gNative, 0);
 }
 
 void remove(JNIEnv *env, jobject thiz, jint socket)
@@ -1017,7 +1017,7 @@
     if (group) {
         if (socket == -1 || !group->remove(socket)) {
             delete group;
-            env->SetIntField(thiz, gNative, NULL);
+            env->SetIntField(thiz, gNative, 0);
         }
     }
 }
diff --git a/wifi/java/android/net/wifi/SupplicantStateTracker.java b/wifi/java/android/net/wifi/SupplicantStateTracker.java
index cbd284c..104a02d 100644
--- a/wifi/java/android/net/wifi/SupplicantStateTracker.java
+++ b/wifi/java/android/net/wifi/SupplicantStateTracker.java
@@ -39,6 +39,7 @@
     private static final boolean DBG = false;
 
     private WifiStateMachine mWifiStateMachine;
+    private WifiConfigStore mWifiConfigStore;
     private int mAuthenticationFailuresCount = 0;
     /* Indicates authentication failure in supplicant broadcast.
      * TODO: enhance auth failure reporting to include notification
@@ -62,11 +63,12 @@
     private State mCompletedState = new CompletedState();
     private State mDormantState = new DormantState();
 
-    public SupplicantStateTracker(Context context, WifiStateMachine wsm, Handler target) {
-        super(TAG, target.getLooper());
+    public SupplicantStateTracker(Context c, WifiStateMachine wsm, WifiConfigStore wcs, Handler t) {
+        super(TAG, t.getLooper());
 
-        mContext = context;
+        mContext = c;
         mWifiStateMachine = wsm;
+        mWifiConfigStore = wcs;
         addState(mDefaultState);
             addState(mUninitializedState, mDefaultState);
             addState(mInactiveState, mDefaultState);
@@ -85,11 +87,11 @@
     private void handleNetworkConnectionFailure(int netId) {
         /* If other networks disabled during connection, enable them */
         if (mNetworksDisabledDuringConnect) {
-            WifiConfigStore.enableAllNetworks();
+            mWifiConfigStore.enableAllNetworks();
             mNetworksDisabledDuringConnect = false;
         }
         /* Disable failed network */
-        WifiConfigStore.disableNetwork(netId, WifiConfiguration.DISABLED_AUTH_FAILURE);
+        mWifiConfigStore.disableNetwork(netId, WifiConfiguration.DISABLED_AUTH_FAILURE);
     }
 
     private void transitionOnSupplicantStateChange(StateChangeResult stateChangeResult) {
@@ -285,7 +287,7 @@
              /* Reset authentication failure count */
              mAuthenticationFailuresCount = 0;
              if (mNetworksDisabledDuringConnect) {
-                 WifiConfigStore.enableAllNetworks();
+                 mWifiConfigStore.enableAllNetworks();
                  mNetworksDisabledDuringConnect = false;
              }
         }
diff --git a/wifi/java/android/net/wifi/WifiConfigStore.java b/wifi/java/android/net/wifi/WifiConfigStore.java
index cba0fba..5dffa60 100644
--- a/wifi/java/android/net/wifi/WifiConfigStore.java
+++ b/wifi/java/android/net/wifi/WifiConfigStore.java
@@ -103,12 +103,12 @@
  */
 class WifiConfigStore {
 
-    private static Context sContext;
+    private Context mContext;
     private static final String TAG = "WifiConfigStore";
     private static final boolean DBG = false;
 
     /* configured networks with network id as the key */
-    private static HashMap<Integer, WifiConfiguration> sConfiguredNetworks =
+    private HashMap<Integer, WifiConfiguration> mConfiguredNetworks =
             new HashMap<Integer, WifiConfiguration>();
 
     /* A network id is a unique identifier for a network configured in the
@@ -118,11 +118,11 @@
      * that is generated from SSID and security type of the network. A mapping
      * from the generated unique id to network id of the network is needed to
      * map supplicant config to IP configuration. */
-    private static HashMap<Integer, Integer> sNetworkIds =
+    private HashMap<Integer, Integer> mNetworkIds =
             new HashMap<Integer, Integer>();
 
     /* Tracks the highest priority of configured networks */
-    private static int sLastPriority = -1;
+    private int mLastPriority = -1;
 
     private static final String ipConfigFile = Environment.getDataDirectory() +
             "/misc/wifi/ipconfig.txt";
@@ -141,20 +141,19 @@
     private static final String EXCLUSION_LIST_KEY = "exclusionList";
     private static final String EOS = "eos";
 
-    private static HandlerThread sDiskWriteHandlerThread;
-    private static DiskWriteHandler sDiskWriteHandler;
-    private static Object sDiskWriteHandlerSync = new Object();
-    /* Tracks multiple writes on the same thread */
-    private static int sWriteSequence = 0;
-    private static final int WRITE = 1;
+    private WifiNative mWifiNative;
+
+    WifiConfigStore(Context c, WifiNative wn) {
+        mContext = c;
+        mWifiNative = wn;
+    }
 
     /**
-     * Initialize context, fetch the list of configured networks
+     * Fetch the list of configured networks
      * and enable all stored networks in supplicant.
      */
-    static void initialize(Context context) {
+    void initialize() {
         if (DBG) log("Loading config and enabling all networks");
-        sContext = context;
         loadConfiguredNetworks();
         enableAllNetworks();
     }
@@ -163,9 +162,9 @@
      * Fetch the list of currently configured networks
      * @return List of networks
      */
-    static List<WifiConfiguration> getConfiguredNetworks() {
+    List<WifiConfiguration> getConfiguredNetworks() {
         List<WifiConfiguration> networks = new ArrayList<WifiConfiguration>();
-        for(WifiConfiguration config : sConfiguredNetworks.values()) {
+        for(WifiConfiguration config : mConfiguredNetworks.values()) {
             networks.add(new WifiConfiguration(config));
         }
         return networks;
@@ -175,11 +174,11 @@
      * enable all networks and save config. This will be a no-op if the list
      * of configured networks indicates all networks as being enabled
      */
-    static void enableAllNetworks() {
+    void enableAllNetworks() {
         boolean networkEnabledStateChanged = false;
-        for(WifiConfiguration config : sConfiguredNetworks.values()) {
+        for(WifiConfiguration config : mConfiguredNetworks.values()) {
             if(config != null && config.status == Status.DISABLED) {
-                if(WifiNative.enableNetwork(config.networkId, false)) {
+                if(mWifiNative.enableNetwork(config.networkId, false)) {
                     networkEnabledStateChanged = true;
                     config.status = Status.ENABLED;
                 } else {
@@ -189,7 +188,7 @@
         }
 
         if (networkEnabledStateChanged) {
-            WifiNative.saveConfig();
+            mWifiNative.saveConfig();
             sendConfiguredNetworksChangedBroadcast();
         }
     }
@@ -206,7 +205,7 @@
      * @param config The configuration details in WifiConfiguration
      * @return the networkId now associated with the specified configuration
      */
-    static int selectNetwork(WifiConfiguration config) {
+    int selectNetwork(WifiConfiguration config) {
         if (config != null) {
             NetworkUpdateResult result = addOrUpdateNetworkNative(config);
             int netId = result.getNetworkId();
@@ -231,25 +230,25 @@
      *
      * @param netId network to select for connection
      */
-    static void selectNetwork(int netId) {
+    void selectNetwork(int netId) {
         // Reset the priority of each network at start or if it goes too high.
-        if (sLastPriority == -1 || sLastPriority > 1000000) {
-            for(WifiConfiguration config : sConfiguredNetworks.values()) {
+        if (mLastPriority == -1 || mLastPriority > 1000000) {
+            for(WifiConfiguration config : mConfiguredNetworks.values()) {
                 if (config.networkId != INVALID_NETWORK_ID) {
                     config.priority = 0;
                     addOrUpdateNetworkNative(config);
                 }
             }
-            sLastPriority = 0;
+            mLastPriority = 0;
         }
 
         // Set to the highest priority and save the configuration.
         WifiConfiguration config = new WifiConfiguration();
         config.networkId = netId;
-        config.priority = ++sLastPriority;
+        config.priority = ++mLastPriority;
 
         addOrUpdateNetworkNative(config);
-        WifiNative.saveConfig();
+        mWifiNative.saveConfig();
 
         /* Enable the given network while disabling all other networks */
         enableNetworkWithoutBroadcast(netId, true);
@@ -263,23 +262,23 @@
      *
      * @param config WifiConfiguration to be saved
      */
-    static NetworkUpdateResult saveNetwork(WifiConfiguration config) {
+    NetworkUpdateResult saveNetwork(WifiConfiguration config) {
         boolean newNetwork = (config.networkId == INVALID_NETWORK_ID);
         NetworkUpdateResult result = addOrUpdateNetworkNative(config);
         int netId = result.getNetworkId();
         /* enable a new network */
         if (newNetwork && netId != INVALID_NETWORK_ID) {
-            WifiNative.enableNetwork(netId, false);
-            sConfiguredNetworks.get(netId).status = Status.ENABLED;
+            mWifiNative.enableNetwork(netId, false);
+            mConfiguredNetworks.get(netId).status = Status.ENABLED;
         }
-        WifiNative.saveConfig();
+        mWifiNative.saveConfig();
         sendConfiguredNetworksChangedBroadcast();
         return result;
     }
 
-    static void updateStatus(int netId, DetailedState state) {
+    void updateStatus(int netId, DetailedState state) {
         if (netId != INVALID_NETWORK_ID) {
-            WifiConfiguration config = sConfiguredNetworks.get(netId);
+            WifiConfiguration config = mConfiguredNetworks.get(netId);
             if (config == null) return;
             switch (state) {
                 case CONNECTED:
@@ -300,13 +299,13 @@
      *
      * @param netId network to forget
      */
-    static void forgetNetwork(int netId) {
-        if (WifiNative.removeNetwork(netId)) {
-            WifiNative.saveConfig();
-            WifiConfiguration config = sConfiguredNetworks.get(netId);
+    void forgetNetwork(int netId) {
+        if (mWifiNative.removeNetwork(netId)) {
+            mWifiNative.saveConfig();
+            WifiConfiguration config = mConfiguredNetworks.get(netId);
             if (config != null) {
-                sConfiguredNetworks.remove(netId);
-                sNetworkIds.remove(configKey(config));
+                mConfiguredNetworks.remove(netId);
+                mNetworkIds.remove(configKey(config));
             }
             writeIpAndProxyConfigurations();
             sendConfiguredNetworksChangedBroadcast();
@@ -323,7 +322,7 @@
      *
      * @param config wifi configuration to add/update
      */
-    static int addOrUpdateNetwork(WifiConfiguration config) {
+    int addOrUpdateNetwork(WifiConfiguration config) {
         NetworkUpdateResult result = addOrUpdateNetworkNative(config);
         sendConfiguredNetworksChangedBroadcast();
         return result.getNetworkId();
@@ -337,13 +336,13 @@
      *
      * @param netId network to be removed
      */
-    static boolean removeNetwork(int netId) {
-        boolean ret = WifiNative.removeNetwork(netId);
+    boolean removeNetwork(int netId) {
+        boolean ret = mWifiNative.removeNetwork(netId);
         if (ret) {
-            WifiConfiguration config = sConfiguredNetworks.get(netId);
+            WifiConfiguration config = mConfiguredNetworks.get(netId);
             if (config != null) {
-                sConfiguredNetworks.remove(netId);
-                sNetworkIds.remove(configKey(config));
+                mConfiguredNetworks.remove(netId);
+                mNetworkIds.remove(configKey(config));
             }
         }
         sendConfiguredNetworksChangedBroadcast();
@@ -358,16 +357,16 @@
      *
      * @param netId network to be removed
      */
-    static boolean enableNetwork(int netId, boolean disableOthers) {
+    boolean enableNetwork(int netId, boolean disableOthers) {
         boolean ret = enableNetworkWithoutBroadcast(netId, disableOthers);
         sendConfiguredNetworksChangedBroadcast();
         return ret;
     }
 
-    static boolean enableNetworkWithoutBroadcast(int netId, boolean disableOthers) {
-        boolean ret = WifiNative.enableNetwork(netId, disableOthers);
+    boolean enableNetworkWithoutBroadcast(int netId, boolean disableOthers) {
+        boolean ret = mWifiNative.enableNetwork(netId, disableOthers);
 
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null) config.status = Status.ENABLED;
 
         if (disableOthers) {
@@ -380,7 +379,7 @@
      * Disable a network. Note that there is no saveConfig operation.
      * @param netId network to be disabled
      */
-    static boolean disableNetwork(int netId) {
+    boolean disableNetwork(int netId) {
         return disableNetwork(netId, WifiConfiguration.DISABLED_UNKNOWN_REASON);
     }
 
@@ -389,9 +388,9 @@
      * @param netId network to be disabled
      * @param reason reason code network was disabled
      */
-    static boolean disableNetwork(int netId, int reason) {
-        boolean ret = WifiNative.disableNetwork(netId);
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+    boolean disableNetwork(int netId, int reason) {
+        boolean ret = mWifiNative.disableNetwork(netId);
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         /* Only change the reason if the network was not previously disabled */
         if (config != null && config.status != Status.DISABLED) {
             config.status = Status.DISABLED;
@@ -404,17 +403,17 @@
     /**
      * Save the configured networks in supplicant to disk
      */
-    static boolean saveConfig() {
-        return WifiNative.saveConfig();
+    boolean saveConfig() {
+        return mWifiNative.saveConfig();
     }
 
     /**
      * Start WPS pin method configuration with pin obtained
      * from the access point
      */
-    static WpsResult startWpsWithPinFromAccessPoint(WpsInfo config) {
+    WpsResult startWpsWithPinFromAccessPoint(WpsInfo config) {
         WpsResult result = new WpsResult();
-        if (WifiNative.startWpsRegistrar(config.BSSID, config.pin)) {
+        if (mWifiNative.startWpsRegistrar(config.BSSID, config.pin)) {
             /* WPS leaves all networks disabled */
             markAllNetworksDisabled();
             result.status = WpsResult.Status.SUCCESS;
@@ -430,9 +429,9 @@
      * from the device
      * @return WpsResult indicating status and pin
      */
-    static WpsResult startWpsWithPinFromDevice(WpsInfo config) {
+    WpsResult startWpsWithPinFromDevice(WpsInfo config) {
         WpsResult result = new WpsResult();
-        result.pin = WifiNative.startWpsPinDisplay(config.BSSID);
+        result.pin = mWifiNative.startWpsPinDisplay(config.BSSID);
         /* WPS leaves all networks disabled */
         if (!TextUtils.isEmpty(result.pin)) {
             markAllNetworksDisabled();
@@ -447,9 +446,9 @@
     /**
      * Start WPS push button configuration
      */
-    static WpsResult startWpsPbc(WpsInfo config) {
+    WpsResult startWpsPbc(WpsInfo config) {
         WpsResult result = new WpsResult();
-        if (WifiNative.startWpsPbc(config.BSSID)) {
+        if (mWifiNative.startWpsPbc(config.BSSID)) {
             /* WPS leaves all networks disabled */
             markAllNetworksDisabled();
             result.status = WpsResult.Status.SUCCESS;
@@ -463,8 +462,8 @@
     /**
      * Fetch the link properties for a given network id
      */
-    static LinkProperties getLinkProperties(int netId) {
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+    LinkProperties getLinkProperties(int netId) {
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null) return new LinkProperties(config.linkProperties);
         return null;
     }
@@ -476,7 +475,7 @@
      *       that, we should remove handling DhcpInfo and move
      *       to using LinkProperties
      */
-    static DhcpInfoInternal getIpConfiguration(int netId) {
+    DhcpInfoInternal getIpConfiguration(int netId) {
         DhcpInfoInternal dhcpInfoInternal = new DhcpInfoInternal();
         LinkProperties linkProperties = getLinkProperties(netId);
 
@@ -502,10 +501,10 @@
     /**
      * set IP configuration for a given network id
      */
-    static void setIpConfiguration(int netId, DhcpInfoInternal dhcpInfo) {
+    void setIpConfiguration(int netId, DhcpInfoInternal dhcpInfo) {
         LinkProperties linkProperties = dhcpInfo.makeLinkProperties();
 
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null) {
             // add old proxy details
             if(config.linkProperties != null) {
@@ -518,8 +517,8 @@
     /**
      * clear IP configuration for a given network id
      */
-    static void clearIpConfiguration(int netId) {
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+    void clearIpConfiguration(int netId) {
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null && config.linkProperties != null) {
             // Clear everything except proxy
             ProxyProperties proxy = config.linkProperties.getHttpProxy();
@@ -532,7 +531,7 @@
     /**
      * Fetch the proxy properties for a given network id
      */
-    static ProxyProperties getProxyProperties(int netId) {
+    ProxyProperties getProxyProperties(int netId) {
         LinkProperties linkProperties = getLinkProperties(netId);
         if (linkProperties != null) {
             return new ProxyProperties(linkProperties.getHttpProxy());
@@ -543,26 +542,26 @@
     /**
      * Return if the specified network is using static IP
      */
-    static boolean isUsingStaticIp(int netId) {
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+    boolean isUsingStaticIp(int netId) {
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null && config.ipAssignment == IpAssignment.STATIC) {
             return true;
         }
         return false;
     }
 
-    private static void sendConfiguredNetworksChangedBroadcast() {
+    private void sendConfiguredNetworksChangedBroadcast() {
         Intent intent = new Intent(WifiManager.CONFIGURED_NETWORKS_CHANGED_ACTION);
         intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
-        sContext.sendBroadcast(intent);
+        mContext.sendBroadcast(intent);
     }
 
-    static void loadConfiguredNetworks() {
-        String listStr = WifiNative.listNetworks();
-        sLastPriority = 0;
+    void loadConfiguredNetworks() {
+        String listStr = mWifiNative.listNetworks();
+        mLastPriority = 0;
 
-        sConfiguredNetworks.clear();
-        sNetworkIds.clear();
+        mConfiguredNetworks.clear();
+        mNetworkIds.clear();
 
         if (listStr == null)
             return;
@@ -589,19 +588,19 @@
                 config.status = WifiConfiguration.Status.ENABLED;
             }
             readNetworkVariables(config);
-            if (config.priority > sLastPriority) {
-                sLastPriority = config.priority;
+            if (config.priority > mLastPriority) {
+                mLastPriority = config.priority;
             }
-            sConfiguredNetworks.put(config.networkId, config);
-            sNetworkIds.put(configKey(config), config.networkId);
+            mConfiguredNetworks.put(config.networkId, config);
+            mNetworkIds.put(configKey(config), config.networkId);
         }
 
         readIpAndProxyConfigurations();
         sendConfiguredNetworksChangedBroadcast();
     }
 
-    static void updateIpAndProxyFromWpsConfig(int netId, WpsInfo wpsConfig) {
-        WifiConfiguration config = sConfiguredNetworks.get(netId);
+    void updateIpAndProxyFromWpsConfig(int netId, WpsInfo wpsConfig) {
+        WifiConfiguration config = mConfiguredNetworks.get(netId);
         if (config != null) {
             config.ipAssignment = wpsConfig.ipAssignment;
             config.proxySettings = wpsConfig.proxySettings;
@@ -611,8 +610,8 @@
     }
 
     /* Mark all networks except specified netId as disabled */
-    private static void markAllNetworksDisabledExcept(int netId) {
-        for(WifiConfiguration config : sConfiguredNetworks.values()) {
+    private void markAllNetworksDisabledExcept(int netId) {
+        for(WifiConfiguration config : mConfiguredNetworks.values()) {
             if(config != null && config.networkId != netId) {
                 if (config.status != Status.DISABLED) {
                     config.status = Status.DISABLED;
@@ -622,43 +621,49 @@
         }
     }
 
-    private static void markAllNetworksDisabled() {
+    private void markAllNetworksDisabled() {
         markAllNetworksDisabledExcept(INVALID_NETWORK_ID);
     }
 
-    private static void writeIpAndProxyConfigurations() {
+    private void writeIpAndProxyConfigurations() {
 
         /* Make a copy */
         List<WifiConfiguration> networks = new ArrayList<WifiConfiguration>();
-        for(WifiConfiguration config : sConfiguredNetworks.values()) {
+        for(WifiConfiguration config : mConfiguredNetworks.values()) {
             networks.add(new WifiConfiguration(config));
         }
 
-        /* Do a delayed write to disk on a seperate handler thread */
-        synchronized (sDiskWriteHandlerSync) {
-            if (++sWriteSequence == 1) {
-                sDiskWriteHandlerThread = new HandlerThread("WifiConfigThread");
-                sDiskWriteHandlerThread.start();
-                sDiskWriteHandler = new DiskWriteHandler(sDiskWriteHandlerThread.getLooper());
-            }
-        }
-
-        sDiskWriteHandler.sendMessage(Message.obtain(sDiskWriteHandler, WRITE, networks));
+        DelayedDiskWrite.write(networks);
     }
 
-    private static class DiskWriteHandler extends Handler {
+    private static class DelayedDiskWrite {
 
-        DiskWriteHandler(android.os.Looper l) {
-            super(l);
-        }
+        private static HandlerThread sDiskWriteHandlerThread;
+        private static Handler sDiskWriteHandler;
+        /* Tracks multiple writes on the same thread */
+        private static int sWriteSequence = 0;
+        private static final String TAG = "DelayedDiskWrite";
 
-        public void handleMessage(Message msg) {
+        static void write (final List<WifiConfiguration> networks) {
 
-            if (msg.what != WRITE) {
-                throw new RuntimeException("Unsupported message in WifiConfigStore: " + msg);
+            /* Do a delayed write to disk on a seperate handler thread */
+            synchronized (DelayedDiskWrite.class) {
+                if (++sWriteSequence == 1) {
+                    sDiskWriteHandlerThread = new HandlerThread("WifiConfigThread");
+                    sDiskWriteHandlerThread.start();
+                    sDiskWriteHandler = new Handler(sDiskWriteHandlerThread.getLooper());
+                }
             }
 
-            List<WifiConfiguration> networks = (List<WifiConfiguration>) msg.obj;
+            sDiskWriteHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        onWriteCalled(networks);
+                    }
+                });
+        }
+
+        private static void onWriteCalled(List<WifiConfiguration> networks) {
 
             DataOutputStream out = null;
             try {
@@ -740,7 +745,7 @@
                                 /* Ignore */
                                 break;
                             default:
-                                loge("Ignore invalid proxy settings while writing");
+                                loge("Ignthisore invalid proxy settings while writing");
                                 break;
                         }
                         if (writeToFile) {
@@ -763,18 +768,22 @@
                 }
 
                 //Quit if no more writes sent
-                synchronized (sDiskWriteHandlerSync) {
+                synchronized (DelayedDiskWrite.class) {
                     if (--sWriteSequence == 0) {
-                        getLooper().quit();
+                        sDiskWriteHandler.getLooper().quit();
+                        sDiskWriteHandler = null;
                         sDiskWriteHandlerThread = null;
-                        sDiskWriteHandler= null;
                     }
                 }
             }
-       }
+        }
+
+        private static void loge(String s) {
+            Log.e(TAG, s);
+        }
     }
 
-    private static void readIpAndProxyConfigurations() {
+    private void readIpAndProxyConfigurations() {
 
         DataInputStream in = null;
         try {
@@ -847,8 +856,8 @@
                 } while (true);
 
                 if (id != -1) {
-                    WifiConfiguration config = sConfiguredNetworks.get(
-                            sNetworkIds.get(id));
+                    WifiConfiguration config = mConfiguredNetworks.get(
+                            mNetworkIds.get(id));
 
                     if (config == null) {
                         loge("configuration found for missing network, ignored");
@@ -901,7 +910,7 @@
         }
     }
 
-    private static NetworkUpdateResult addOrUpdateNetworkNative(WifiConfiguration config) {
+    private NetworkUpdateResult addOrUpdateNetworkNative(WifiConfiguration config) {
         /*
          * If the supplied networkId is INVALID_NETWORK_ID, we create a new empty
          * network configuration. Otherwise, the networkId should
@@ -911,12 +920,12 @@
         boolean newNetwork = false;
         // networkId of INVALID_NETWORK_ID means we want to create a new network
         if (netId == INVALID_NETWORK_ID) {
-            Integer savedNetId = sNetworkIds.get(configKey(config));
+            Integer savedNetId = mNetworkIds.get(configKey(config));
             if (savedNetId != null) {
                 netId = savedNetId;
             } else {
                 newNetwork = true;
-                netId = WifiNative.addNetwork();
+                netId = mWifiNative.addNetwork();
                 if (netId < 0) {
                     loge("Failed to add a network!");
                     return new NetworkUpdateResult(INVALID_NETWORK_ID);
@@ -929,7 +938,7 @@
         setVariables: {
 
             if (config.SSID != null &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.ssidVarName,
                         config.SSID)) {
@@ -938,7 +947,7 @@
             }
 
             if (config.BSSID != null &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.bssidVarName,
                         config.BSSID)) {
@@ -949,7 +958,7 @@
             String allowedKeyManagementString =
                 makeString(config.allowedKeyManagement, WifiConfiguration.KeyMgmt.strings);
             if (config.allowedKeyManagement.cardinality() != 0 &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.KeyMgmt.varName,
                         allowedKeyManagementString)) {
@@ -961,7 +970,7 @@
             String allowedProtocolsString =
                 makeString(config.allowedProtocols, WifiConfiguration.Protocol.strings);
             if (config.allowedProtocols.cardinality() != 0 &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.Protocol.varName,
                         allowedProtocolsString)) {
@@ -973,7 +982,7 @@
             String allowedAuthAlgorithmsString =
                 makeString(config.allowedAuthAlgorithms, WifiConfiguration.AuthAlgorithm.strings);
             if (config.allowedAuthAlgorithms.cardinality() != 0 &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.AuthAlgorithm.varName,
                         allowedAuthAlgorithmsString)) {
@@ -986,7 +995,7 @@
                     makeString(config.allowedPairwiseCiphers,
                     WifiConfiguration.PairwiseCipher.strings);
             if (config.allowedPairwiseCiphers.cardinality() != 0 &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.PairwiseCipher.varName,
                         allowedPairwiseCiphersString)) {
@@ -998,7 +1007,7 @@
             String allowedGroupCiphersString =
                 makeString(config.allowedGroupCiphers, WifiConfiguration.GroupCipher.strings);
             if (config.allowedGroupCiphers.cardinality() != 0 &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.GroupCipher.varName,
                         allowedGroupCiphersString)) {
@@ -1010,7 +1019,7 @@
             // Prevent client screw-up by passing in a WifiConfiguration we gave it
             // by preventing "*" as a key.
             if (config.preSharedKey != null && !config.preSharedKey.equals("*") &&
-                    !WifiNative.setNetworkVariable(
+                    !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.pskVarName,
                         config.preSharedKey)) {
@@ -1024,7 +1033,7 @@
                     // Prevent client screw-up by passing in a WifiConfiguration we gave it
                     // by preventing "*" as a key.
                     if (config.wepKeys[i] != null && !config.wepKeys[i].equals("*")) {
-                        if (!WifiNative.setNetworkVariable(
+                        if (!mWifiNative.setNetworkVariable(
                                     netId,
                                     WifiConfiguration.wepKeyVarNames[i],
                                     config.wepKeys[i])) {
@@ -1037,7 +1046,7 @@
             }
 
             if (hasSetKey) {
-                if (!WifiNative.setNetworkVariable(
+                if (!mWifiNative.setNetworkVariable(
                             netId,
                             WifiConfiguration.wepTxKeyIdxVarName,
                             Integer.toString(config.wepTxKeyIndex))) {
@@ -1046,7 +1055,7 @@
                 }
             }
 
-            if (!WifiNative.setNetworkVariable(
+            if (!mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.priorityVarName,
                         Integer.toString(config.priority))) {
@@ -1055,7 +1064,7 @@
                 break setVariables;
             }
 
-            if (config.hiddenSSID && !WifiNative.setNetworkVariable(
+            if (config.hiddenSSID && !mWifiNative.setNetworkVariable(
                         netId,
                         WifiConfiguration.hiddenSSIDVarName,
                         Integer.toString(config.hiddenSSID ? 1 : 0))) {
@@ -1072,7 +1081,7 @@
                     if (field != config.eap) {
                         value = (value.length() == 0) ? "NULL" : convertToQuotedString(value);
                     }
-                    if (!WifiNative.setNetworkVariable(
+                    if (!mWifiNative.setNetworkVariable(
                                 netId,
                                 varName,
                                 value)) {
@@ -1087,37 +1096,37 @@
 
         if (updateFailed) {
             if (newNetwork) {
-                WifiNative.removeNetwork(netId);
+                mWifiNative.removeNetwork(netId);
                 loge("Failed to set a network variable, removed network: " + netId);
             }
             return new NetworkUpdateResult(INVALID_NETWORK_ID);
         }
 
         /* An update of the network variables requires reading them
-         * back from the supplicant to update sConfiguredNetworks.
+         * back from the supplicant to update mConfiguredNetworks.
          * This is because some of the variables (SSID, wep keys &
          * passphrases) reflect different values when read back than
          * when written. For example, wep key is stored as * irrespective
          * of the value sent to the supplicant
          */
-        WifiConfiguration sConfig = sConfiguredNetworks.get(netId);
-        if (sConfig == null) {
-            sConfig = new WifiConfiguration();
-            sConfig.networkId = netId;
+        WifiConfiguration currentConfig = mConfiguredNetworks.get(netId);
+        if (currentConfig == null) {
+            currentConfig = new WifiConfiguration();
+            currentConfig.networkId = netId;
         }
 
-        readNetworkVariables(sConfig);
+        readNetworkVariables(currentConfig);
 
-        sConfiguredNetworks.put(netId, sConfig);
-        sNetworkIds.put(configKey(sConfig), netId);
+        mConfiguredNetworks.put(netId, currentConfig);
+        mNetworkIds.put(configKey(currentConfig), netId);
 
-        NetworkUpdateResult result = writeIpAndProxyConfigurationsOnChange(sConfig, config);
+        NetworkUpdateResult result = writeIpAndProxyConfigurationsOnChange(currentConfig, config);
         result.setNetworkId(netId);
         return result;
     }
 
     /* Compare current and new configuration and write to file on change */
-    private static NetworkUpdateResult writeIpAndProxyConfigurationsOnChange(
+    private NetworkUpdateResult writeIpAndProxyConfigurationsOnChange(
             WifiConfiguration currentConfig,
             WifiConfiguration newConfig) {
         boolean ipChanged = false;
@@ -1216,7 +1225,7 @@
         return new NetworkUpdateResult(ipChanged, proxyChanged);
     }
 
-    private static void addIpSettingsFromConfig(LinkProperties linkProperties,
+    private void addIpSettingsFromConfig(LinkProperties linkProperties,
             WifiConfiguration config) {
         for (LinkAddress linkAddr : config.linkProperties.getLinkAddresses()) {
             linkProperties.addLinkAddress(linkAddr);
@@ -1235,7 +1244,7 @@
      *
      * @param config the {@link WifiConfiguration} object to be filled in.
      */
-    private static void readNetworkVariables(WifiConfiguration config) {
+    private void readNetworkVariables(WifiConfiguration config) {
 
         int netId = config.networkId;
         if (netId < 0)
@@ -1248,21 +1257,21 @@
          */
         String value;
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.ssidVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.ssidVarName);
         if (!TextUtils.isEmpty(value)) {
             config.SSID = value;
         } else {
             config.SSID = null;
         }
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.bssidVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.bssidVarName);
         if (!TextUtils.isEmpty(value)) {
             config.BSSID = value;
         } else {
             config.BSSID = null;
         }
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.priorityVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.priorityVarName);
         config.priority = -1;
         if (!TextUtils.isEmpty(value)) {
             try {
@@ -1271,7 +1280,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.hiddenSSIDVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.hiddenSSIDVarName);
         config.hiddenSSID = false;
         if (!TextUtils.isEmpty(value)) {
             try {
@@ -1280,7 +1289,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.wepTxKeyIdxVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.wepTxKeyIdxVarName);
         config.wepTxKeyIndex = -1;
         if (!TextUtils.isEmpty(value)) {
             try {
@@ -1290,7 +1299,7 @@
         }
 
         for (int i = 0; i < 4; i++) {
-            value = WifiNative.getNetworkVariable(netId,
+            value = mWifiNative.getNetworkVariable(netId,
                     WifiConfiguration.wepKeyVarNames[i]);
             if (!TextUtils.isEmpty(value)) {
                 config.wepKeys[i] = value;
@@ -1299,14 +1308,14 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(netId, WifiConfiguration.pskVarName);
+        value = mWifiNative.getNetworkVariable(netId, WifiConfiguration.pskVarName);
         if (!TextUtils.isEmpty(value)) {
             config.preSharedKey = value;
         } else {
             config.preSharedKey = null;
         }
 
-        value = WifiNative.getNetworkVariable(config.networkId,
+        value = mWifiNative.getNetworkVariable(config.networkId,
                 WifiConfiguration.Protocol.varName);
         if (!TextUtils.isEmpty(value)) {
             String vals[] = value.split(" ");
@@ -1319,7 +1328,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(config.networkId,
+        value = mWifiNative.getNetworkVariable(config.networkId,
                 WifiConfiguration.KeyMgmt.varName);
         if (!TextUtils.isEmpty(value)) {
             String vals[] = value.split(" ");
@@ -1332,7 +1341,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(config.networkId,
+        value = mWifiNative.getNetworkVariable(config.networkId,
                 WifiConfiguration.AuthAlgorithm.varName);
         if (!TextUtils.isEmpty(value)) {
             String vals[] = value.split(" ");
@@ -1345,7 +1354,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(config.networkId,
+        value = mWifiNative.getNetworkVariable(config.networkId,
                 WifiConfiguration.PairwiseCipher.varName);
         if (!TextUtils.isEmpty(value)) {
             String vals[] = value.split(" ");
@@ -1358,7 +1367,7 @@
             }
         }
 
-        value = WifiNative.getNetworkVariable(config.networkId,
+        value = mWifiNative.getNetworkVariable(config.networkId,
                 WifiConfiguration.GroupCipher.varName);
         if (!TextUtils.isEmpty(value)) {
             String vals[] = value.split(" ");
@@ -1373,7 +1382,7 @@
 
         for (WifiConfiguration.EnterpriseField field :
                 config.enterpriseFields) {
-            value = WifiNative.getNetworkVariable(netId,
+            value = mWifiNative.getNetworkVariable(netId,
                     field.varName());
             if (!TextUtils.isEmpty(value)) {
                 if (field != config.eap) value = removeDoubleQuotes(value);
@@ -1382,16 +1391,16 @@
         }
     }
 
-    private static String removeDoubleQuotes(String string) {
+    private String removeDoubleQuotes(String string) {
         if (string.length() <= 2) return "";
         return string.substring(1, string.length() - 1);
     }
 
-    private static String convertToQuotedString(String string) {
+    private String convertToQuotedString(String string) {
         return "\"" + string + "\"";
     }
 
-    private static String makeString(BitSet set, String[] strings) {
+    private String makeString(BitSet set, String[] strings) {
         StringBuffer buf = new StringBuffer();
         int nextSetBit = -1;
 
@@ -1411,7 +1420,7 @@
         return buf.toString();
     }
 
-    private static int lookupString(String string, String[] strings) {
+    private int lookupString(String string, String[] strings) {
         int size = strings.length;
 
         string = string.replace('-', '_');
@@ -1446,10 +1455,10 @@
         return key.hashCode();
     }
 
-    static String dump() {
+    String dump() {
         StringBuffer sb = new StringBuffer();
         String LS = System.getProperty("line.separator");
-        sb.append("sLastPriority ").append(sLastPriority).append(LS);
+        sb.append("mLastPriority ").append(mLastPriority).append(LS);
         sb.append("Configured networks ").append(LS);
         for (WifiConfiguration conf : getConfiguredNetworks()) {
             sb.append(conf).append(LS);
@@ -1457,15 +1466,15 @@
         return sb.toString();
     }
 
-    public static String getConfigFile() {
+    public String getConfigFile() {
         return ipConfigFile;
     }
 
-    private static void loge(String s) {
+    private void loge(String s) {
         Log.e(TAG, s);
     }
 
-    private static void log(String s) {
+    private void log(String s) {
         Log.d(TAG, s);
     }
 }
diff --git a/wifi/java/android/net/wifi/WifiMonitor.java b/wifi/java/android/net/wifi/WifiMonitor.java
index 05b8fe1..bbb74d1 100644
--- a/wifi/java/android/net/wifi/WifiMonitor.java
+++ b/wifi/java/android/net/wifi/WifiMonitor.java
@@ -202,6 +202,7 @@
     private static final String AP_STA_DISCONNECTED_STR = "AP-STA-DISCONNECTED";
 
     private final StateMachine mStateMachine;
+    private final WifiNative mWifiNative;
 
     /* Supplicant events reported to a state machine */
     private static final int BASE = Protocol.BASE_WIFI_MONITOR;
@@ -266,8 +267,9 @@
      */
     private static final int MAX_RECV_ERRORS    = 10;
 
-    public WifiMonitor(StateMachine wifiStateMachine) {
+    public WifiMonitor(StateMachine wifiStateMachine, WifiNative wifiNative) {
         mStateMachine = wifiStateMachine;
+        mWifiNative = wifiNative;
     }
 
     public void startMonitoring() {
@@ -292,7 +294,7 @@
 
             //noinspection InfiniteLoopStatement
             for (;;) {
-                String eventStr = WifiNative.waitForEvent();
+                String eventStr = mWifiNative.waitForEvent();
 
                 // Skip logging the common but mostly uninteresting scan-results event
                 if (false && eventStr.indexOf(SCAN_RESULTS_STR) == -1) {
@@ -406,7 +408,7 @@
             int connectTries = 0;
 
             while (true) {
-                if (WifiNative.connectToSupplicant()) {
+                if (mWifiNative.connectToSupplicant()) {
                     return true;
                 }
                 if (connectTries++ < 5) {
diff --git a/wifi/java/android/net/wifi/WifiNative.java b/wifi/java/android/net/wifi/WifiNative.java
index f8eafde..48a785c 100644
--- a/wifi/java/android/net/wifi/WifiNative.java
+++ b/wifi/java/android/net/wifi/WifiNative.java
@@ -39,11 +39,13 @@
  */
 public class WifiNative {
 
+    private static final int DEFAULT_GROUP_OWNER_INTENT = 7;
+
     static final int BLUETOOTH_COEXISTENCE_MODE_ENABLED = 0;
     static final int BLUETOOTH_COEXISTENCE_MODE_DISABLED = 1;
     static final int BLUETOOTH_COEXISTENCE_MODE_SENSE = 2;
 
-    static String sDefaultInterface;
+    String mInterface = "";
 
     public native static boolean loadDriver();
 
@@ -59,60 +61,60 @@
        or when the supplicant is hung */
     public native static boolean killSupplicant();
 
-    public native static boolean connectToSupplicant(String iface);
+    private native boolean connectToSupplicant(String iface);
 
-    public native static void closeSupplicantConnection(String iface);
+    private native void closeSupplicantConnection(String iface);
 
     /**
      * Wait for the supplicant to send an event, returning the event string.
      * @return the event string sent by the supplicant.
      */
-    public native static String waitForEvent(String iface);
+    private native String waitForEvent(String iface);
 
-    private native static boolean doBooleanCommand(String iface, String command);
+    private native boolean doBooleanCommand(String iface, String command);
 
-    private native static int doIntCommand(String iface, String command);
+    private native int doIntCommand(String iface, String command);
 
-    private native static String doStringCommand(String iface, String command);
+    private native String doStringCommand(String iface, String command);
 
-    public static void setDefaultInterface(String iface) {
-        sDefaultInterface = iface;
+    public WifiNative(String iface) {
+        mInterface = iface;
     }
 
-    public static boolean connectToSupplicant() {
-        return connectToSupplicant(sDefaultInterface);
+    public boolean connectToSupplicant() {
+        return connectToSupplicant(mInterface);
     }
 
-    public static void closeSupplicantConnection() {
-        closeSupplicantConnection(sDefaultInterface);
+    public void closeSupplicantConnection() {
+        closeSupplicantConnection(mInterface);
     }
 
-    public static String waitForEvent() {
-        return waitForEvent(sDefaultInterface);
+    public String waitForEvent() {
+        return waitForEvent(mInterface);
     }
 
-    private static boolean doBooleanCommand(String command) {
-        return doBooleanCommand(sDefaultInterface, command);
+    private boolean doBooleanCommand(String command) {
+        return doBooleanCommand(mInterface, command);
     }
 
-    private static int doIntCommand(String command) {
-        return doIntCommand(sDefaultInterface, command);
+    private int doIntCommand(String command) {
+        return doIntCommand(mInterface, command);
     }
 
-    private static String doStringCommand(String command) {
-        return doStringCommand(sDefaultInterface, command);
+    private String doStringCommand(String command) {
+        return doStringCommand(mInterface, command);
     }
 
-    public static boolean ping() {
+    public boolean ping() {
         String pong = doStringCommand("PING");
         return (pong != null && pong.equals("PONG"));
     }
 
-    public static boolean scan() {
+    public boolean scan() {
        return doBooleanCommand("SCAN");
     }
 
-    public static boolean setScanMode(boolean setActive) {
+    public boolean setScanMode(boolean setActive) {
         if (setActive) {
             return doBooleanCommand("DRIVER SCAN-ACTIVE");
         } else {
@@ -126,33 +128,33 @@
      * for a graceful stop and a mild-sounding "stop" interface
      * to kill the process
      */
-    public static boolean stopSupplicant() {
+    public boolean stopSupplicant() {
         return doBooleanCommand("TERMINATE");
     }
 
-    public static String listNetworks() {
+    public String listNetworks() {
         return doStringCommand("LIST_NETWORKS");
     }
 
-    public static int addNetwork() {
+    public int addNetwork() {
         return doIntCommand("ADD_NETWORK");
     }
 
-    public static boolean setNetworkVariable(int netId, String name, String value) {
+    public boolean setNetworkVariable(int netId, String name, String value) {
         if (TextUtils.isEmpty(name) || TextUtils.isEmpty(value)) return false;
         return doBooleanCommand("SET_NETWORK " + netId + " " + name + " " + value);
     }
 
-    public static String getNetworkVariable(int netId, String name) {
+    public String getNetworkVariable(int netId, String name) {
         if (TextUtils.isEmpty(name)) return null;
         return doStringCommand("GET_NETWORK " + netId + " " + name);
     }
 
-    public static boolean removeNetwork(int netId) {
+    public boolean removeNetwork(int netId) {
         return doBooleanCommand("REMOVE_NETWORK " + netId);
     }
 
-    public static boolean enableNetwork(int netId, boolean disableOthers) {
+    public boolean enableNetwork(int netId, boolean disableOthers) {
         if (disableOthers) {
             return doBooleanCommand("SELECT_NETWORK " + netId);
         } else {
@@ -160,27 +162,27 @@
         }
     }
 
-    public static boolean disableNetwork(int netId) {
+    public boolean disableNetwork(int netId) {
         return doBooleanCommand("DISABLE_NETWORK " + netId);
     }
 
-    public static boolean reconnect() {
+    public boolean reconnect() {
         return doBooleanCommand("RECONNECT");
     }
 
-    public static boolean reassociate() {
+    public boolean reassociate() {
         return doBooleanCommand("REASSOCIATE");
     }
 
-    public static boolean disconnect() {
+    public boolean disconnect() {
         return doBooleanCommand("DISCONNECT");
     }
 
-    public static String status() {
+    public String status() {
         return doStringCommand("STATUS");
     }
 
-    public static String getMacAddress() {
+    public String getMacAddress() {
         //Macaddr = XX.XX.XX.XX.XX.XX
         String ret = doStringCommand("DRIVER MACADDR");
         if (!TextUtils.isEmpty(ret)) {
@@ -190,15 +192,15 @@
         return null;
     }
 
-    public static String scanResults() {
+    public String scanResults() {
         return doStringCommand("SCAN_RESULTS");
     }
 
-    public static boolean startDriver() {
+    public boolean startDriver() {
         return doBooleanCommand("DRIVER START");
     }
 
-    public static boolean stopDriver() {
+    public boolean stopDriver() {
         return doBooleanCommand("DRIVER STOP");
     }
 
@@ -227,7 +229,7 @@
      *
      * The  SETSUSPENDOPT driver command overrides the filtering rules
      */
-    public static boolean startFilteringMulticastV4Packets() {
+    public boolean startFilteringMulticastV4Packets() {
         return doBooleanCommand("DRIVER RXFILTER-STOP")
             && doBooleanCommand("DRIVER RXFILTER-REMOVE 2")
             && doBooleanCommand("DRIVER RXFILTER-START");
@@ -237,7 +239,7 @@
      * Stop filtering out Multicast V4 packets.
      * @return {@code true} if the operation succeeded, {@code false} otherwise
      */
-    public static boolean stopFilteringMulticastV4Packets() {
+    public boolean stopFilteringMulticastV4Packets() {
         return doBooleanCommand("DRIVER RXFILTER-STOP")
             && doBooleanCommand("DRIVER RXFILTER-ADD 2")
             && doBooleanCommand("DRIVER RXFILTER-START");
@@ -247,7 +249,7 @@
      * Start filtering out Multicast V6 packets
      * @return {@code true} if the operation succeeded, {@code false} otherwise
      */
-    public static boolean startFilteringMulticastV6Packets() {
+    public boolean startFilteringMulticastV6Packets() {
         return doBooleanCommand("DRIVER RXFILTER-STOP")
             && doBooleanCommand("DRIVER RXFILTER-REMOVE 3")
             && doBooleanCommand("DRIVER RXFILTER-START");
@@ -257,13 +259,13 @@
      * Stop filtering out Multicast V6 packets.
      * @return {@code true} if the operation succeeded, {@code false} otherwise
      */
-    public static boolean stopFilteringMulticastV6Packets() {
+    public boolean stopFilteringMulticastV6Packets() {
         return doBooleanCommand("DRIVER RXFILTER-STOP")
             && doBooleanCommand("DRIVER RXFILTER-ADD 3")
             && doBooleanCommand("DRIVER RXFILTER-START");
     }
 
-    public static int getPowerMode() {
+    public int getPowerMode() {
         String ret = doStringCommand("DRIVER GETPOWER");
         if (!TextUtils.isEmpty(ret)) {
             // reply comes back in the form "powermode = XX" where XX is the
@@ -278,11 +280,11 @@
         return -1;
     }
 
-    public static boolean setPowerMode(int mode) {
+    public boolean setPowerMode(int mode) {
         return doBooleanCommand("DRIVER POWERMODE " + mode);
     }
 
-    public static int getBand() {
+    public int getBand() {
        String ret = doStringCommand("DRIVER GETBAND");
         if (!TextUtils.isEmpty(ret)) {
             //reply is "BAND X" where X is the band
@@ -296,7 +298,7 @@
         return -1;
     }
 
-    public static boolean setBand(int band) {
+    public boolean setBand(int band) {
         return doBooleanCommand("DRIVER SETBAND " + band);
     }
 
@@ -308,7 +310,7 @@
      *            {@link #BLUETOOTH_COEXISTENCE_MODE_SENSE}.
      * @return Whether the mode was successfully set.
      */
-    public static boolean setBluetoothCoexistenceMode(int mode) {
+    public boolean setBluetoothCoexistenceMode(int mode) {
         return doBooleanCommand("DRIVER BTCOEXMODE " + mode);
     }
 
@@ -320,7 +322,7 @@
      * @param isSet whether to enable or disable this mode
      * @return {@code true} if the command succeeded, {@code false} otherwise.
      */
-    public static boolean setBluetoothCoexistenceScanMode(boolean setCoexScanMode) {
+    public boolean setBluetoothCoexistenceScanMode(boolean setCoexScanMode) {
         if (setCoexScanMode) {
             return doBooleanCommand("DRIVER BTCOEXSCAN-START");
         } else {
@@ -328,25 +330,25 @@
         }
     }
 
-    public static boolean saveConfig() {
+    public boolean saveConfig() {
         // Make sure we never write out a value for AP_SCAN other than 1
         return doBooleanCommand("AP_SCAN 1") && doBooleanCommand("SAVE_CONFIG");
     }
 
-    public static boolean setScanResultHandling(int mode) {
+    public boolean setScanResultHandling(int mode) {
         return doBooleanCommand("AP_SCAN " + mode);
     }
 
-    public static boolean addToBlacklist(String bssid) {
+    public boolean addToBlacklist(String bssid) {
         if (TextUtils.isEmpty(bssid)) return false;
         return doBooleanCommand("BLACKLIST " + bssid);
     }
 
-    public static boolean clearBlacklist() {
+    public boolean clearBlacklist() {
         return doBooleanCommand("BLACKLIST clear");
     }
 
-    public static boolean setSuspendOptimizations(boolean enabled) {
+    public boolean setSuspendOptimizations(boolean enabled) {
         if (enabled) {
             return doBooleanCommand("DRIVER SETSUSPENDOPT 0");
         } else {
@@ -354,11 +356,11 @@
         }
     }
 
-    public static boolean setCountryCode(String countryCode) {
+    public boolean setCountryCode(String countryCode) {
         return doBooleanCommand("DRIVER COUNTRY " + countryCode);
     }
 
-    public static void enableBackgroundScan(boolean enable) {
+    public void enableBackgroundScan(boolean enable) {
         //Note: BGSCAN-START and BGSCAN-STOP are documented in core/res/res/values/config.xml
         //and will need an update if the names are changed
         if (enable) {
@@ -368,7 +370,7 @@
         }
     }
 
-    public static void setScanInterval(int scanInterval) {
+    public void setScanInterval(int scanInterval) {
         doBooleanCommand("SCAN_INTERVAL " + scanInterval);
     }
 
@@ -378,81 +380,81 @@
      * NOISE=9999
      * FREQUENCY=0
      */
-    public static String signalPoll() {
+    public String signalPoll() {
         return doStringCommand("SIGNAL_POLL");
     }
 
-    public static boolean startWpsPbc() {
+    public boolean startWpsPbc() {
         return doBooleanCommand("WPS_PBC");
     }
 
-    public static boolean startWpsPbc(String bssid) {
+    public boolean startWpsPbc(String bssid) {
         return doBooleanCommand("WPS_PBC " + bssid);
     }
 
-    public static boolean startWpsPinKeypad(String pin) {
+    public boolean startWpsPinKeypad(String pin) {
         return doBooleanCommand("WPS_PIN any " + pin);
     }
 
-    public static String startWpsPinDisplay(String bssid) {
+    public String startWpsPinDisplay(String bssid) {
         return doStringCommand("WPS_PIN " + bssid);
     }
 
     /* Configures an access point connection */
-    public static boolean startWpsRegistrar(String bssid, String pin) {
+    public boolean startWpsRegistrar(String bssid, String pin) {
         return doBooleanCommand("WPS_REG " + bssid + " " + pin);
     }
 
-    public static boolean setPersistentReconnect(boolean enabled) {
+    public boolean setPersistentReconnect(boolean enabled) {
         int value = (enabled == true) ? 1 : 0;
         return doBooleanCommand("SET persistent_reconnect " + value);
     }
 
-    public static boolean setDeviceName(String name) {
+    public boolean setDeviceName(String name) {
         return doBooleanCommand("SET device_name " + name);
     }
 
-    public static boolean setDeviceType(String type) {
+    public boolean setDeviceType(String type) {
         return doBooleanCommand("SET device_type " + type);
     }
 
-    public static boolean setConfigMethods(String cfg) {
+    public boolean setConfigMethods(String cfg) {
         return doBooleanCommand("SET config_methods " + cfg);
     }
 
-    public static boolean setP2pSsidPostfix(String postfix) {
+    public boolean setP2pSsidPostfix(String postfix) {
         return doBooleanCommand("SET p2p_ssid_postfix " + postfix);
     }
 
-    public static boolean p2pFind() {
+    public boolean p2pFind() {
         return doBooleanCommand("P2P_FIND");
     }
 
-    public static boolean p2pFind(int timeout) {
+    public boolean p2pFind(int timeout) {
         if (timeout <= 0) {
             return p2pFind();
         }
         return doBooleanCommand("P2P_FIND " + timeout);
     }
 
-    public static boolean p2pListen() {
+    public boolean p2pListen() {
         return doBooleanCommand("P2P_LISTEN");
     }
 
-    public static boolean p2pListen(int timeout) {
+    public boolean p2pListen(int timeout) {
         if (timeout <= 0) {
             return p2pListen();
         }
         return doBooleanCommand("P2P_LISTEN " + timeout);
     }
 
-    public static boolean p2pFlush() {
+    public boolean p2pFlush() {
         return doBooleanCommand("P2P_FLUSH");
     }
 
     /* p2p_connect <peer device address> <pbc|pin|PIN#> [label|display|keypad]
         [persistent] [join|auth] [go_intent=<0..15>] [freq=<in MHz>] */
-    public static String p2pConnect(WifiP2pConfig config, boolean joinExistingGroup) {
+    public String p2pConnect(WifiP2pConfig config, boolean joinExistingGroup) {
         if (config == null) return null;
         List<String> args = new ArrayList<String>();
         WpsInfo wps = config.wps;
@@ -492,7 +494,7 @@
         //device battery state
         int groupOwnerIntent = config.groupOwnerIntent;
         if (groupOwnerIntent < 0 || groupOwnerIntent > 15) {
-            groupOwnerIntent = 7; //default value
+            groupOwnerIntent = DEFAULT_GROUP_OWNER_INTENT;
         }
         args.add("go_intent=" + groupOwnerIntent);
 
@@ -502,11 +504,11 @@
         return doStringCommand(command);
     }
 
-    public static boolean p2pCancelConnect() {
+    public boolean p2pCancelConnect() {
         return doBooleanCommand("P2P_CANCEL");
     }
 
-    public static boolean p2pProvisionDiscovery(WifiP2pConfig config) {
+    public boolean p2pProvisionDiscovery(WifiP2pConfig config) {
         if (config == null) return false;
 
         switch (config.wps.setup) {
@@ -524,21 +526,21 @@
         return false;
     }
 
-    public static boolean p2pGroupAdd() {
+    public boolean p2pGroupAdd() {
         return doBooleanCommand("P2P_GROUP_ADD");
     }
 
-    public static boolean p2pGroupRemove(String iface) {
+    public boolean p2pGroupRemove(String iface) {
         if (iface == null) return false;
         return doBooleanCommand("P2P_GROUP_REMOVE " + iface);
     }
 
-    public static boolean p2pReject(String deviceAddress) {
+    public boolean p2pReject(String deviceAddress) {
         return doBooleanCommand("P2P_REJECT " + deviceAddress);
     }
 
     /* Invite a peer to a group */
-    public static boolean p2pInvite(WifiP2pGroup group, String deviceAddress) {
+    public boolean p2pInvite(WifiP2pGroup group, String deviceAddress) {
         if (deviceAddress == null) return false;
 
         if (group == null) {
@@ -550,14 +552,14 @@
     }
 
     /* Reinvoke a persistent connection */
-    public static boolean p2pReinvoke(int netId, String deviceAddress) {
+    public boolean p2pReinvoke(int netId, String deviceAddress) {
         if (deviceAddress == null || netId < 0) return false;
 
         return doBooleanCommand("P2P_INVITE persistent=" + netId + " peer=" + deviceAddress);
     }
 
 
-    public static String p2pGetInterfaceAddress(String deviceAddress) {
+    public String p2pGetInterfaceAddress(String deviceAddress) {
         if (deviceAddress == null) return null;
 
         //  "p2p_peer deviceAddress" returns a multi-line result containing
@@ -577,7 +579,7 @@
         return null;
     }
 
-    public static String p2pGetDeviceAddress() {
+    public String p2pGetDeviceAddress() {
         String status = status();
         if (status == null) return "";
 
@@ -592,7 +594,7 @@
         return "";
     }
 
-    public static String p2pPeer(String deviceAddress) {
+    public String p2pPeer(String deviceAddress) {
         return doStringCommand("P2P_PEER " + deviceAddress);
     }
 }
diff --git a/wifi/java/android/net/wifi/WifiStateMachine.java b/wifi/java/android/net/wifi/WifiStateMachine.java
index 58e19cf..8c9e472 100644
--- a/wifi/java/android/net/wifi/WifiStateMachine.java
+++ b/wifi/java/android/net/wifi/WifiStateMachine.java
@@ -113,6 +113,8 @@
     private static final String SOFTAP_IFACE = "wl0.1";
 
     private WifiMonitor mWifiMonitor;
+    private WifiNative mWifiNative;
+    private WifiConfigStore mWifiConfigStore;
     private INetworkManagementService mNwService;
     private ConnectivityManager mCm;
 
@@ -554,11 +556,14 @@
         IBinder b = ServiceManager.getService(Context.NETWORKMANAGEMENT_SERVICE);
         mNwService = INetworkManagementService.Stub.asInterface(b);
 
-        mWifiMonitor = new WifiMonitor(this);
+        mWifiNative = new WifiNative(mInterfaceName);
+        mWifiConfigStore = new WifiConfigStore(context, mWifiNative);
+        mWifiMonitor = new WifiMonitor(this, mWifiNative);
         mDhcpInfoInternal = new DhcpInfoInternal();
         mWifiInfo = new WifiInfo();
-        mSupplicantStateTracker = new SupplicantStateTracker(context, this, getHandler());
-        mWpsStateMachine = new WpsStateMachine(context, this, getHandler());
+        mSupplicantStateTracker = new SupplicantStateTracker(context, this, mWifiConfigStore,
+                getHandler());
+        mWpsStateMachine = new WpsStateMachine(context, this, mWifiConfigStore, getHandler());
         mLinkProperties = new LinkProperties();
 
         WifiApConfigStore wifiApConfigStore = WifiApConfigStore.makeWifiApConfigStore(
@@ -572,9 +577,6 @@
         mLastNetworkId = WifiConfiguration.INVALID_NETWORK_ID;
         mLastSignalLevel = -1;
 
-        /* Set default interface for all primary socket communication */
-        WifiNative.setDefaultInterface(mInterfaceName);
-
         mAlarmManager = (AlarmManager)mContext.getSystemService(Context.ALARM_SERVICE);
         Intent scanIntent = new Intent(ACTION_START_SCAN, null);
         mScanIntent = PendingIntent.getBroadcast(mContext, SCAN_REQUEST, scanIntent, 0);
@@ -1044,7 +1046,7 @@
      * Returns the wifi configuration file
      */
     public String getConfigFile() {
-        return WifiConfigStore.getConfigFile();
+        return mWifiConfigStore.getConfigFile();
     }
 
     /**
@@ -1118,9 +1120,9 @@
         sb.append("mReconnectCount ").append(mReconnectCount).append(LS);
         sb.append("mIsScanMode ").append(mIsScanMode).append(LS);
         sb.append("Supplicant status").append(LS)
-                .append(WifiNative.status()).append(LS).append(LS);
+                .append(mWifiNative.status()).append(LS).append(LS);
 
-        sb.append(WifiConfigStore.dump());
+        sb.append(mWifiConfigStore.dump());
         return sb.toString();
     }
 
@@ -1413,7 +1415,7 @@
     }
 
     private String fetchSSID() {
-        String status = WifiNative.status();
+        String status = mWifiNative.status();
         if (status == null) {
             return null;
         }
@@ -1436,7 +1438,7 @@
         int newRssi = -1;
         int newLinkSpeed = -1;
 
-        String signalPoll = WifiNative.signalPoll();
+        String signalPoll = mWifiNative.signalPoll();
 
         if (signalPoll != null) {
             String[] lines = signalPoll.split("\n");
@@ -1486,28 +1488,28 @@
     }
 
     private void setHighPerfModeEnabledNative(boolean enable) {
-        if(!WifiNative.setSuspendOptimizations(!enable)) {
+        if(!mWifiNative.setSuspendOptimizations(!enable)) {
             loge("set suspend optimizations failed!");
         }
         if (enable) {
-            if (!WifiNative.setPowerMode(POWER_MODE_ACTIVE)) {
+            if (!mWifiNative.setPowerMode(POWER_MODE_ACTIVE)) {
                 loge("set power mode active failed!");
             }
         } else {
-            if (!WifiNative.setPowerMode(POWER_MODE_AUTO)) {
+            if (!mWifiNative.setPowerMode(POWER_MODE_AUTO)) {
                 loge("set power mode auto failed!");
             }
         }
     }
 
     private void configureLinkProperties() {
-        if (WifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
-            mLinkProperties = WifiConfigStore.getLinkProperties(mLastNetworkId);
+        if (mWifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
+            mLinkProperties = mWifiConfigStore.getLinkProperties(mLastNetworkId);
         } else {
             synchronized (mDhcpInfoInternal) {
                 mLinkProperties = mDhcpInfoInternal.makeLinkProperties();
             }
-            mLinkProperties.setHttpProxy(WifiConfigStore.getProxyProperties(mLastNetworkId));
+            mLinkProperties.setHttpProxy(mWifiConfigStore.getProxyProperties(mLastNetworkId));
         }
         mLinkProperties.setInterfaceName(mInterfaceName);
         if (DBG) {
@@ -1648,7 +1650,7 @@
         mWifiInfo.setLinkSpeed(-1);
 
         setNetworkDetailedState(DetailedState.DISCONNECTED);
-        WifiConfigStore.updateStatus(mLastNetworkId, DetailedState.DISCONNECTED);
+        mWifiConfigStore.updateStatus(mLastNetworkId, DetailedState.DISCONNECTED);
 
         /* send event to CM & network change broadcast */
         sendNetworkStateChangeBroadcast(mLastBssid);
@@ -1656,8 +1658,8 @@
         /* Clear network properties */
         mLinkProperties.clear();
         /* Clear IP settings if the network used DHCP */
-        if (!WifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
-            WifiConfigStore.clearIpConfiguration(mLastNetworkId);
+        if (!mWifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
+            mWifiConfigStore.clearIpConfiguration(mLastNetworkId);
         }
 
         mLastBssid= null;
@@ -1683,29 +1685,29 @@
              * coexistence would interrupt that connection.
              */
             // Disable the coexistence mode
-            WifiNative.setBluetoothCoexistenceMode(
-                    WifiNative.BLUETOOTH_COEXISTENCE_MODE_DISABLED);
+            mWifiNative.setBluetoothCoexistenceMode(
+                    mWifiNative.BLUETOOTH_COEXISTENCE_MODE_DISABLED);
         }
 
-        mPowerMode =  WifiNative.getPowerMode();
+        mPowerMode =  mWifiNative.getPowerMode();
         if (mPowerMode < 0) {
             // Handle the case where supplicant driver does not support
             // getPowerModeCommand.
             mPowerMode = WifiStateMachine.POWER_MODE_AUTO;
         }
         if (mPowerMode != WifiStateMachine.POWER_MODE_ACTIVE) {
-            WifiNative.setPowerMode(WifiStateMachine.POWER_MODE_ACTIVE);
+            mWifiNative.setPowerMode(WifiStateMachine.POWER_MODE_ACTIVE);
         }
     }
 
 
     void handlePostDhcpSetup() {
         /* restore power mode */
-        WifiNative.setPowerMode(mPowerMode);
+        mWifiNative.setPowerMode(mPowerMode);
 
         // Set the coexistence mode back to its default value
-        WifiNative.setBluetoothCoexistenceMode(
-                WifiNative.BLUETOOTH_COEXISTENCE_MODE_SENSE);
+        mWifiNative.setBluetoothCoexistenceMode(
+                mWifiNative.BLUETOOTH_COEXISTENCE_MODE_SENSE);
     }
 
     private void handleSuccessfulIpConfiguration(DhcpInfoInternal dhcpInfoInternal) {
@@ -1714,13 +1716,13 @@
         }
         mLastSignalLevel = -1; // force update of signal strength
         mReconnectCount = 0; //Reset IP failure tracking
-        WifiConfigStore.setIpConfiguration(mLastNetworkId, dhcpInfoInternal);
+        mWifiConfigStore.setIpConfiguration(mLastNetworkId, dhcpInfoInternal);
         InetAddress addr = NetworkUtils.numericToInetAddress(dhcpInfoInternal.ipAddress);
         mWifiInfo.setInetAddress(addr);
         if (getNetworkDetailedState() == DetailedState.CONNECTED) {
             //DHCP renewal in connected state
             LinkProperties linkProperties = dhcpInfoInternal.makeLinkProperties();
-            linkProperties.setHttpProxy(WifiConfigStore.getProxyProperties(mLastNetworkId));
+            linkProperties.setHttpProxy(mWifiConfigStore.getProxyProperties(mLastNetworkId));
             linkProperties.setInterfaceName(mInterfaceName);
             if (!linkProperties.equals(mLinkProperties)) {
                 if (DBG) {
@@ -1733,7 +1735,7 @@
         } else {
             configureLinkProperties();
             setNetworkDetailedState(DetailedState.CONNECTED);
-            WifiConfigStore.updateStatus(mLastNetworkId, DetailedState.CONNECTED);
+            mWifiConfigStore.updateStatus(mLastNetworkId, DetailedState.CONNECTED);
             sendNetworkStateChangeBroadcast(mLastBssid);
         }
     }
@@ -1749,7 +1751,7 @@
         if (++mReconnectCount > getMaxDhcpRetries()) {
             loge("Failed " +
                     mReconnectCount + " times, Disabling " + mLastNetworkId);
-            WifiConfigStore.disableNetwork(mLastNetworkId,
+            mWifiConfigStore.disableNetwork(mLastNetworkId,
                     WifiConfiguration.DISABLED_DHCP_FAILURE);
             mReconnectCount = 0;
         }
@@ -1757,8 +1759,8 @@
         /* DHCP times out after about 30 seconds, we do a
          * disconnect and an immediate reconnect to try again
          */
-        WifiNative.disconnect();
-        WifiNative.reconnect();
+        mWifiNative.disconnect();
+        mWifiNative.reconnect();
     }
 
     /* Current design is to not set the config on a running hostapd but instead
@@ -1826,7 +1828,7 @@
                     break;
                 case CMD_GET_CONFIGURED_NETWORKS:
                     mReplyChannel.replyToMessage(message, message.what,
-                            WifiConfigStore.getConfiguredNetworks());
+                            mWifiConfigStore.getConfiguredNetworks());
                     break;
                 case CMD_ENABLE_RSSI_POLL:
                     mEnableRssiPolling = (message.arg1 == 1);
@@ -1913,7 +1915,7 @@
             // 50021 wifi_state_changed (custom|1|5)
             EventLog.writeEvent(EVENTLOG_WIFI_STATE_CHANGED, getName());
 
-            if (WifiNative.isDriverLoaded()) {
+            if (mWifiNative.isDriverLoaded()) {
                 transitionTo(mDriverLoadedState);
             }
             else {
@@ -1966,7 +1968,7 @@
                             break;
                     }
 
-                    if(WifiNative.loadDriver()) {
+                    if(mWifiNative.loadDriver()) {
                         if (DBG) log("Driver load successful");
                         sendMessage(CMD_LOAD_DRIVER_SUCCESS);
                     } else {
@@ -2054,7 +2056,7 @@
                         loge("Unable to change interface settings: " + ie);
                     }
 
-                    if(WifiNative.startSupplicant()) {
+                    if(mWifiNative.startSupplicant()) {
                         if (DBG) log("Supplicant start successful");
                         mWifiMonitor.startMonitoring();
                         transitionTo(mSupplicantStartingState);
@@ -2086,7 +2088,7 @@
                 public void run() {
                     if (DBG) log(getName() + message.toString() + "\n");
                     mWakeLock.acquire();
-                    if(WifiNative.unloadDriver()) {
+                    if(mWifiNative.unloadDriver()) {
                         if (DBG) log("Driver unload successful");
                         sendMessage(CMD_UNLOAD_DRIVER_SUCCESS);
 
@@ -2217,9 +2219,9 @@
                     mLastNetworkId = WifiConfiguration.INVALID_NETWORK_ID;
                     mLastSignalLevel = -1;
 
-                    mWifiInfo.setMacAddress(WifiNative.getMacAddress());
+                    mWifiInfo.setMacAddress(mWifiNative.getMacAddress());
 
-                    WifiConfigStore.initialize(mContext);
+                    mWifiConfigStore.initialize();
 
                     sendSupplicantConnectionChangedBroadcast(true);
                     transitionTo(mDriverStartedState);
@@ -2227,7 +2229,7 @@
                 case WifiMonitor.SUP_DISCONNECTION_EVENT:
                     if (++mSupplicantRestartCount <= SUPPLICANT_RESTART_TRIES) {
                         loge("Failed to setup control channel, restart supplicant");
-                        WifiNative.killSupplicant();
+                        mWifiNative.killSupplicant();
                         transitionTo(mDriverLoadedState);
                         sendMessageDelayed(CMD_START_SUPPLICANT, SUPPLICANT_RESTART_INTERVAL_MSECS);
                     } else {
@@ -2276,7 +2278,7 @@
             long supplicantScanIntervalMs = Settings.Secure.getLong(mContext.getContentResolver(),
                     Settings.Secure.WIFI_SUPPLICANT_SCAN_INTERVAL_MS,
                     mDefaultSupplicantScanIntervalMs);
-            WifiNative.setScanInterval((int)supplicantScanIntervalMs / 1000);
+            mWifiNative.setScanInterval((int)supplicantScanIntervalMs / 1000);
         }
         @Override
         public boolean processMessage(Message message) {
@@ -2289,8 +2291,8 @@
                     break;
                 case WifiMonitor.SUP_DISCONNECTION_EVENT:  /* Supplicant connection lost */
                     loge("Connection lost, restart supplicant");
-                    WifiNative.killSupplicant();
-                    WifiNative.closeSupplicantConnection();
+                    mWifiNative.killSupplicant();
+                    mWifiNative.closeSupplicantConnection();
                     mNetworkInfo.setIsAvailable(false);
                     handleNetworkDisconnect();
                     sendSupplicantConnectionChangedBroadcast(false);
@@ -2301,46 +2303,46 @@
                     break;
                 case WifiMonitor.SCAN_RESULTS_EVENT:
                     eventLoggingEnabled = false;
-                    setScanResults(WifiNative.scanResults());
+                    setScanResults(mWifiNative.scanResults());
                     sendScanResultsAvailableBroadcast();
                     mScanResultIsPending = false;
                     break;
                 case CMD_PING_SUPPLICANT:
-                    boolean ok = WifiNative.ping();
+                    boolean ok = mWifiNative.ping();
                     mReplyChannel.replyToMessage(message, message.what, ok ? SUCCESS : FAILURE);
                     break;
                 case CMD_ADD_OR_UPDATE_NETWORK:
                     config = (WifiConfiguration) message.obj;
                     mReplyChannel.replyToMessage(message, CMD_ADD_OR_UPDATE_NETWORK,
-                            WifiConfigStore.addOrUpdateNetwork(config));
+                            mWifiConfigStore.addOrUpdateNetwork(config));
                     break;
                 case CMD_REMOVE_NETWORK:
-                    ok = WifiConfigStore.removeNetwork(message.arg1);
+                    ok = mWifiConfigStore.removeNetwork(message.arg1);
                     mReplyChannel.replyToMessage(message, message.what, ok ? SUCCESS : FAILURE);
                     break;
                 case CMD_ENABLE_NETWORK:
-                    ok = WifiConfigStore.enableNetwork(message.arg1, message.arg2 == 1);
+                    ok = mWifiConfigStore.enableNetwork(message.arg1, message.arg2 == 1);
                     mReplyChannel.replyToMessage(message, message.what, ok ? SUCCESS : FAILURE);
                     break;
                 case CMD_ENABLE_ALL_NETWORKS:
                     long time =  android.os.SystemClock.elapsedRealtime();
                     if (time - mLastEnableAllNetworksTime > MIN_INTERVAL_ENABLE_ALL_NETWORKS_MS) {
-                        WifiConfigStore.enableAllNetworks();
+                        mWifiConfigStore.enableAllNetworks();
                         mLastEnableAllNetworksTime = time;
                     }
                     break;
                 case CMD_DISABLE_NETWORK:
-                    ok = WifiConfigStore.disableNetwork(message.arg1, message.arg2);
+                    ok = mWifiConfigStore.disableNetwork(message.arg1, message.arg2);
                     mReplyChannel.replyToMessage(message, message.what, ok ? SUCCESS : FAILURE);
                     break;
                 case CMD_BLACKLIST_NETWORK:
-                    WifiNative.addToBlacklist((String)message.obj);
+                    mWifiNative.addToBlacklist((String)message.obj);
                     break;
                 case CMD_CLEAR_BLACKLIST:
-                    WifiNative.clearBlacklist();
+                    mWifiNative.clearBlacklist();
                     break;
                 case CMD_SAVE_CONFIG:
-                    ok = WifiConfigStore.saveConfig();
+                    ok = mWifiConfigStore.saveConfig();
                     mReplyChannel.replyToMessage(message, CMD_SAVE_CONFIG, ok ? SUCCESS : FAILURE);
 
                     // Inform the backup manager about a data change
@@ -2364,10 +2366,10 @@
                     break;
                 case CMD_SAVE_NETWORK:
                     config = (WifiConfiguration) message.obj;
-                    WifiConfigStore.saveNetwork(config);
+                    mWifiConfigStore.saveNetwork(config);
                     break;
                 case CMD_FORGET_NETWORK:
-                    WifiConfigStore.forgetNetwork(message.arg1);
+                    mWifiConfigStore.forgetNetwork(message.arg1);
                     break;
                 default:
                     return NOT_HANDLED;
@@ -2390,7 +2392,7 @@
             if (DBG) log(getName() + "\n");
             EventLog.writeEvent(EVENTLOG_WIFI_STATE_CHANGED, getName());
             if (DBG) log("stopping supplicant");
-            if (!WifiNative.stopSupplicant()) {
+            if (!mWifiNative.stopSupplicant()) {
                 loge("Failed to stop supplicant");
             }
 
@@ -2417,15 +2419,15 @@
                     /* Socket connection can be lost when we do a graceful shutdown
                      * or when the driver is hung. Ensure supplicant is stopped here.
                      */
-                    WifiNative.killSupplicant();
-                    WifiNative.closeSupplicantConnection();
+                    mWifiNative.killSupplicant();
+                    mWifiNative.closeSupplicantConnection();
                     transitionTo(mDriverLoadedState);
                     break;
                 case CMD_STOP_SUPPLICANT_FAILED:
                     if (message.arg1 == mSupplicantStopFailureToken) {
                         loge("Timed out on a supplicant stop, kill and proceed");
-                        WifiNative.killSupplicant();
-                        WifiNative.closeSupplicantConnection();
+                        mWifiNative.killSupplicant();
+                        mWifiNative.closeSupplicantConnection();
                         transitionTo(mDriverLoadedState);
                     }
                     break;
@@ -2516,7 +2518,7 @@
              * When this mode is on, some of the low-level scan parameters used by the
              * driver are changed to reduce interference with bluetooth
              */
-            WifiNative.setBluetoothCoexistenceScanMode(mBluetoothConnectionActive);
+            mWifiNative.setBluetoothCoexistenceScanMode(mBluetoothConnectionActive);
             /* set country code */
             setCountryCode();
             /* set frequency band of operation */
@@ -2525,26 +2527,26 @@
             setNetworkDetailedState(DetailedState.DISCONNECTED);
 
             /* Remove any filtering on Multicast v6 at start */
-            WifiNative.stopFilteringMulticastV6Packets();
+            mWifiNative.stopFilteringMulticastV6Packets();
 
             /* Reset Multicast v4 filtering state */
             if (mFilteringMulticastV4Packets.get()) {
-                WifiNative.startFilteringMulticastV4Packets();
+                mWifiNative.startFilteringMulticastV4Packets();
             } else {
-                WifiNative.stopFilteringMulticastV4Packets();
+                mWifiNative.stopFilteringMulticastV4Packets();
             }
 
             if (mIsScanMode) {
-                WifiNative.setScanResultHandling(SCAN_ONLY_MODE);
-                WifiNative.disconnect();
+                mWifiNative.setScanResultHandling(SCAN_ONLY_MODE);
+                mWifiNative.disconnect();
                 transitionTo(mScanModeState);
             } else {
-                WifiNative.setScanResultHandling(CONNECT_MODE);
-                WifiNative.reconnect();
+                mWifiNative.setScanResultHandling(CONNECT_MODE);
+                mWifiNative.reconnect();
                 // Status pulls in the current supplicant state and network connection state
                 // events over the monitor connection. This helps framework sync up with
                 // current supplicant state
-                WifiNative.status();
+                mWifiNative.status();
                 transitionTo(mDisconnectedState);
             }
         }
@@ -2555,17 +2557,17 @@
             switch(message.what) {
                 case CMD_SET_SCAN_TYPE:
                     mSetScanActive = (message.arg1 == SCAN_ACTIVE);
-                    WifiNative.setScanMode(mSetScanActive);
+                    mWifiNative.setScanMode(mSetScanActive);
                     break;
                 case CMD_START_SCAN:
                     eventLoggingEnabled = false;
                     boolean forceActive = (message.arg1 == SCAN_ACTIVE);
                     if (forceActive && !mSetScanActive) {
-                        WifiNative.setScanMode(forceActive);
+                        mWifiNative.setScanMode(forceActive);
                     }
-                    WifiNative.scan();
+                    mWifiNative.scan();
                     if (forceActive && !mSetScanActive) {
-                        WifiNative.setScanMode(mSetScanActive);
+                        mWifiNative.setScanMode(mSetScanActive);
                     }
                     mScanResultIsPending = true;
                     break;
@@ -2575,14 +2577,14 @@
                 case CMD_SET_COUNTRY_CODE:
                     String country = (String) message.obj;
                     if (DBG) log("set country code " + country);
-                    if (!WifiNative.setCountryCode(country.toUpperCase())) {
+                    if (!mWifiNative.setCountryCode(country.toUpperCase())) {
                         loge("Failed to set country code " + country);
                     }
                     break;
                 case CMD_SET_FREQUENCY_BAND:
                     int band =  message.arg1;
                     if (DBG) log("set frequency band " + band);
-                    if (WifiNative.setBand(band)) {
+                    if (mWifiNative.setBand(band)) {
                         mFrequencyBand.set(band);
                         //Fetch the latest scan results when frequency band is set
                         startScan(true);
@@ -2593,7 +2595,7 @@
                 case CMD_BLUETOOTH_ADAPTER_STATE_CHANGE:
                     mBluetoothConnectionActive = (message.arg1 !=
                             BluetoothAdapter.STATE_DISCONNECTED);
-                    WifiNative.setBluetoothCoexistenceScanMode(mBluetoothConnectionActive);
+                    mWifiNative.setBluetoothCoexistenceScanMode(mBluetoothConnectionActive);
                     break;
                 case CMD_STOP_DRIVER:
                     int mode = message.arg1;
@@ -2626,28 +2628,28 @@
                 case CMD_DELAYED_STOP_DRIVER:
                     if (message.arg1 != mDelayedStopCounter) break;
                     if (getCurrentState() != mDisconnectedState) {
-                        WifiNative.disconnect();
+                        mWifiNative.disconnect();
                         handleNetworkDisconnect();
                     }
                     mWakeLock.acquire();
-                    WifiNative.stopDriver();
+                    mWifiNative.stopDriver();
                     transitionTo(mDriverStoppingState);
                     mWakeLock.release();
                     break;
                 case CMD_START_PACKET_FILTERING:
                     if (message.arg1 == MULTICAST_V6) {
-                        WifiNative.startFilteringMulticastV6Packets();
+                        mWifiNative.startFilteringMulticastV6Packets();
                     } else if (message.arg1 == MULTICAST_V4) {
-                        WifiNative.startFilteringMulticastV4Packets();
+                        mWifiNative.startFilteringMulticastV4Packets();
                     } else {
                         loge("Illegal arugments to CMD_START_PACKET_FILTERING");
                     }
                     break;
                 case CMD_STOP_PACKET_FILTERING:
                     if (message.arg1 == MULTICAST_V6) {
-                        WifiNative.stopFilteringMulticastV6Packets();
+                        mWifiNative.stopFilteringMulticastV6Packets();
                     } else if (message.arg1 == MULTICAST_V4) {
-                        WifiNative.stopFilteringMulticastV4Packets();
+                        mWifiNative.stopFilteringMulticastV4Packets();
                     } else {
                         loge("Illegal arugments to CMD_STOP_PACKET_FILTERING");
                     }
@@ -2729,7 +2731,7 @@
                     break;
                 case CMD_START_DRIVER:
                     mWakeLock.acquire();
-                    WifiNative.startDriver();
+                    mWifiNative.startDriver();
                     mWakeLock.release();
                     transitionTo(mDriverStartingState);
                     break;
@@ -2756,8 +2758,8 @@
                         /* Ignore */
                         return HANDLED;
                     } else {
-                        WifiNative.setScanResultHandling(message.arg1);
-                        WifiNative.reconnect();
+                        mWifiNative.setScanResultHandling(message.arg1);
+                        mWifiNative.reconnect();
                         mIsScanMode = false;
                         transitionTo(mDisconnectedState);
                     }
@@ -2824,13 +2826,13 @@
                     break;
                     /* Do a redundant disconnect without transition */
                 case CMD_DISCONNECT:
-                    WifiNative.disconnect();
+                    mWifiNative.disconnect();
                     break;
                 case CMD_RECONNECT:
-                    WifiNative.reconnect();
+                    mWifiNative.reconnect();
                     break;
                 case CMD_REASSOCIATE:
-                    WifiNative.reassociate();
+                    mWifiNative.reassociate();
                     break;
                 case CMD_CONNECT_NETWORK:
                     int netId = message.arg1;
@@ -2844,15 +2846,15 @@
                      * a connection to the enabled network.
                      */
                     if (config != null) {
-                        netId = WifiConfigStore.selectNetwork(config);
+                        netId = mWifiConfigStore.selectNetwork(config);
                     } else {
-                        WifiConfigStore.selectNetwork(netId);
+                        mWifiConfigStore.selectNetwork(netId);
                     }
 
                     /* The state tracker handles enabling networks upon completion/failure */
                     mSupplicantStateTracker.sendMessage(CMD_CONNECT_NETWORK);
 
-                    WifiNative.reconnect();
+                    mWifiNative.reconnect();
                     /* Expect a disconnection from the old connection */
                     transitionTo(mDisconnectingState);
                     break;
@@ -2862,7 +2864,7 @@
                     break;
                 case WifiMonitor.SCAN_RESULTS_EVENT:
                     /* Set the scan setting back to "connect" mode */
-                    WifiNative.setScanResultHandling(CONNECT_MODE);
+                    mWifiNative.setScanResultHandling(CONNECT_MODE);
                     /* Handle scan results */
                     return NOT_HANDLED;
                 case WifiMonitor.NETWORK_CONNECTION_EVENT:
@@ -2907,14 +2909,14 @@
                 loge("Failed to enable IPv6: " + e);
             }
 
-            if (!WifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
+            if (!mWifiConfigStore.isUsingStaticIp(mLastNetworkId)) {
                 //start DHCP
                 mDhcpStateMachine = DhcpStateMachine.makeDhcpStateMachine(
                         mContext, WifiStateMachine.this, mInterfaceName);
                 mDhcpStateMachine.registerForPreDhcpNotification();
                 mDhcpStateMachine.sendMessage(DhcpStateMachine.CMD_START_DHCP);
             } else {
-                DhcpInfoInternal dhcpInfoInternal = WifiConfigStore.getIpConfiguration(
+                DhcpInfoInternal dhcpInfoInternal = mWifiConfigStore.getIpConfiguration(
                         mLastNetworkId);
                 InterfaceConfiguration ifcg = new InterfaceConfiguration();
                 ifcg.setLinkAddress(dhcpInfoInternal.makeLinkAddress());
@@ -2960,7 +2962,7 @@
                   transitionTo(mDisconnectingState);
                   break;
               case CMD_DISCONNECT:
-                  WifiNative.disconnect();
+                  mWifiNative.disconnect();
                   transitionTo(mDisconnectingState);
                   break;
                   /* Ignore connection to same network */
@@ -3027,7 +3029,7 @@
                   }
                   break;
                 case CMD_DISCONNECT:
-                    WifiNative.disconnect();
+                    mWifiNative.disconnect();
                     transitionTo(mDisconnectingState);
                     break;
                 case CMD_SET_SCAN_MODE:
@@ -3043,7 +3045,7 @@
                      * When scan results are received, the mode is switched
                      * back to CONNECT_MODE.
                      */
-                    WifiNative.setScanResultHandling(SCAN_ONLY_MODE);
+                    mWifiNative.setScanResultHandling(SCAN_ONLY_MODE);
                     /* Have the parent state handle the rest */
                     return NOT_HANDLED;
                     /* Ignore connection to same network */
@@ -3055,7 +3057,7 @@
                     return NOT_HANDLED;
                 case CMD_SAVE_NETWORK:
                     WifiConfiguration config = (WifiConfiguration) message.obj;
-                    NetworkUpdateResult result = WifiConfigStore.saveNetwork(config);
+                    NetworkUpdateResult result = mWifiConfigStore.saveNetwork(config);
                     if (mWifiInfo.getNetworkId() == result.getNetworkId()) {
                         if (result.hasIpChanged()) {
                             log("Reconfiguring IP on connection");
@@ -3111,7 +3113,7 @@
              * is in SCAN_ONLY_MODE. Restore CONNECT_MODE on exit
              */
             if (mScanResultIsPending) {
-                WifiNative.setScanResultHandling(CONNECT_MODE);
+                mWifiNative.setScanResultHandling(CONNECT_MODE);
             }
         }
     }
@@ -3192,7 +3194,7 @@
                  * cleared
                  */
                 if (!mScanResultIsPending) {
-                    WifiNative.enableBackgroundScan(true);
+                    mWifiNative.enableBackgroundScan(true);
                 }
             } else {
                 setScanAlarm(true);
@@ -3204,9 +3206,9 @@
             switch (message.what) {
                 case CMD_SET_SCAN_MODE:
                     if (message.arg1 == SCAN_ONLY_MODE) {
-                        WifiNative.setScanResultHandling(message.arg1);
+                        mWifiNative.setScanResultHandling(message.arg1);
                         //Supplicant disconnect to prevent further connects
-                        WifiNative.disconnect();
+                        mWifiNative.disconnect();
                         mIsScanMode = true;
                         transitionTo(mScanModeState);
                     }
@@ -3214,10 +3216,10 @@
                 case CMD_ENABLE_BACKGROUND_SCAN:
                     mEnableBackgroundScan = (message.arg1 == 1);
                     if (mEnableBackgroundScan) {
-                        WifiNative.enableBackgroundScan(true);
+                        mWifiNative.enableBackgroundScan(true);
                         setScanAlarm(false);
                     } else {
-                        WifiNative.enableBackgroundScan(false);
+                        mWifiNative.enableBackgroundScan(false);
                         setScanAlarm(true);
                     }
                     break;
@@ -3232,14 +3234,14 @@
                 case CMD_START_SCAN:
                     /* Disable background scan temporarily during a regular scan */
                     if (mEnableBackgroundScan) {
-                        WifiNative.enableBackgroundScan(false);
+                        mWifiNative.enableBackgroundScan(false);
                     }
                     /* Handled in parent state */
                     return NOT_HANDLED;
                 case WifiMonitor.SCAN_RESULTS_EVENT:
                     /* Re-enable background scan when a pending scan result is received */
                     if (mEnableBackgroundScan && mScanResultIsPending) {
-                        WifiNative.enableBackgroundScan(true);
+                        mWifiNative.enableBackgroundScan(true);
                     }
                     /* Handled in parent state */
                     return NOT_HANDLED;
@@ -3254,7 +3256,7 @@
         public void exit() {
             /* No need for a background scan upon exit from a disconnected state */
             if (mEnableBackgroundScan) {
-                WifiNative.enableBackgroundScan(false);
+                mWifiNative.enableBackgroundScan(false);
             }
             setScanAlarm(false);
         }
diff --git a/wifi/java/android/net/wifi/WpsStateMachine.java b/wifi/java/android/net/wifi/WpsStateMachine.java
index c14a8db..441a3b0 100644
--- a/wifi/java/android/net/wifi/WpsStateMachine.java
+++ b/wifi/java/android/net/wifi/WpsStateMachine.java
@@ -52,6 +52,7 @@
     private static final boolean DBG = false;
 
     private WifiStateMachine mWifiStateMachine;
+    private WifiConfigStore mWifiConfigStore;
 
     private WpsInfo mWpsInfo;
 
@@ -62,11 +63,12 @@
     private State mInactiveState = new InactiveState();
     private State mActiveState = new ActiveState();
 
-    public WpsStateMachine(Context context, WifiStateMachine wsm, Handler target) {
-        super(TAG, target.getLooper());
+    public WpsStateMachine(Context context, WifiStateMachine wsm, WifiConfigStore wcs, Handler t) {
+        super(TAG, t.getLooper());
 
         mContext = context;
         mWifiStateMachine = wsm;
+        mWifiConfigStore = wcs;
         addState(mDefaultState);
             addState(mInactiveState, mDefaultState);
             addState(mActiveState, mDefaultState);
@@ -97,13 +99,13 @@
                     WpsResult result;
                     switch (mWpsInfo.setup) {
                         case WpsInfo.PBC:
-                            result = WifiConfigStore.startWpsPbc(mWpsInfo);
+                            result = mWifiConfigStore.startWpsPbc(mWpsInfo);
                             break;
                         case WpsInfo.KEYPAD:
-                            result = WifiConfigStore.startWpsWithPinFromAccessPoint(mWpsInfo);
+                            result = mWifiConfigStore.startWpsWithPinFromAccessPoint(mWpsInfo);
                             break;
                         case WpsInfo.DISPLAY:
-                            result = WifiConfigStore.startWpsWithPinFromDevice(mWpsInfo);
+                            result = mWifiConfigStore.startWpsWithPinFromDevice(mWpsInfo);
                             break;
                         default:
                             result = new WpsResult(Status.FAILURE);
@@ -151,9 +153,9 @@
                              * and the configuration list needs to be reloaded from the supplicant.
                              */
                             Log.d(TAG, "WPS set up successful");
-                            WifiConfigStore.enableAllNetworks();
-                            WifiConfigStore.loadConfiguredNetworks();
-                            WifiConfigStore.updateIpAndProxyFromWpsConfig(
+                            mWifiConfigStore.enableAllNetworks();
+                            mWifiConfigStore.loadConfiguredNetworks();
+                            mWifiConfigStore.updateIpAndProxyFromWpsConfig(
                                     stateChangeResult.networkId, mWpsInfo);
                             mWifiStateMachine.sendMessage(WifiStateMachine.WPS_COMPLETED_EVENT);
                             transitionTo(mInactiveState);
@@ -161,7 +163,7 @@
                         case INACTIVE:
                             /* A failed WPS connection */
                             Log.d(TAG, "WPS set up failed, enabling other networks");
-                            WifiConfigStore.enableAllNetworks();
+                            mWifiConfigStore.enableAllNetworks();
                             mWifiStateMachine.sendMessage(WifiStateMachine.WPS_COMPLETED_EVENT);
                             transitionTo(mInactiveState);
                             break;
diff --git a/wifi/java/android/net/wifi/p2p/WifiP2pService.java b/wifi/java/android/net/wifi/p2p/WifiP2pService.java
index 1ad6336..69cbb5c 100644
--- a/wifi/java/android/net/wifi/p2p/WifiP2pService.java
+++ b/wifi/java/android/net/wifi/p2p/WifiP2pService.java
@@ -166,7 +166,8 @@
     public WifiP2pService(Context context) {
         mContext = context;
 
-        mInterface = SystemProperties.get("wifi.interface", "wlan0");
+        //STOPSHIP: fix this
+        mInterface = "p2p0";
         mNetworkInfo = new NetworkInfo(ConnectivityManager.TYPE_WIFI_P2P, 0, NETWORKTYPE, "");
 
         mP2pSupported = mContext.getPackageManager().hasSystemFeature(
@@ -278,7 +279,8 @@
         private GroupCreatedState mGroupCreatedState = new GroupCreatedState();
         private UserAuthorizingJoinState mUserAuthorizingJoinState = new UserAuthorizingJoinState();
 
-        private WifiMonitor mWifiMonitor = new WifiMonitor(this);
+        private WifiNative mWifiNative = new WifiNative(mInterface);
+        private WifiMonitor mWifiMonitor = new WifiMonitor(this, mWifiNative);
 
         private WifiP2pDeviceList mPeers = new WifiP2pDeviceList();
         private WifiP2pInfo mWifiP2pInfo = new WifiP2pInfo();
@@ -456,9 +458,9 @@
         public void enter() {
             if (DBG) logd(getName());
             logd("stopping supplicant");
-            if (!WifiNative.stopSupplicant()) {
+            if (!mWifiNative.stopSupplicant()) {
                 loge("Failed to stop supplicant, issue kill");
-                WifiNative.killSupplicant();
+                mWifiNative.killSupplicant();
             }
         }
 
@@ -468,7 +470,7 @@
             switch (message.what) {
                 case WifiMonitor.SUP_DISCONNECTION_EVENT:
                     logd("Supplicant connection lost");
-                    WifiNative.closeSupplicantConnection();
+                    mWifiNative.closeSupplicantConnection();
                     transitionTo(mP2pDisabledState);
                     break;
                 case WifiP2pManager.ENABLE_P2P:
@@ -594,7 +596,7 @@
                         if (DBG) Slog.w(TAG, "Unable to bring down wlan interface: " + e);
                     }
 
-                    if (WifiNative.startP2pSupplicant()) {
+                    if (mWifiNative.startP2pSupplicant()) {
                         mWifiMonitor.startMonitoring();
                         transitionTo(mP2pEnablingState);
                     } else {
@@ -630,7 +632,7 @@
                 case WifiMonitor.SUP_DISCONNECTION_EVENT:
                     if (++mP2pRestartCount <= P2P_RESTART_TRIES) {
                         loge("Failed to start p2p, retry");
-                        WifiNative.killSupplicant();
+                        mWifiNative.killSupplicant();
                         sendMessageDelayed(WifiP2pManager.ENABLE_P2P, P2P_RESTART_INTERVAL_MSECS);
                     } else {
                         loge("Failed " + mP2pRestartCount + " times to start p2p, quit ");
@@ -673,7 +675,7 @@
                     break;
                 case WifiP2pManager.DISCOVER_PEERS:
                     int timeout = message.arg1;
-                    if (WifiNative.p2pFind(timeout)) {
+                    if (mWifiNative.p2pFind(timeout)) {
                         replyToMessage(message, WifiP2pManager.DISCOVER_PEERS_SUCCEEDED);
                     } else {
                         replyToMessage(message, WifiP2pManager.DISCOVER_PEERS_FAILED,
@@ -692,8 +694,8 @@
                     break;
                case WifiMonitor.SUP_DISCONNECTION_EVENT:  /* Supplicant died */
                     loge("Connection lost, restart p2p");
-                    WifiNative.killSupplicant();
-                    WifiNative.closeSupplicantConnection();
+                    mWifiNative.killSupplicant();
+                    mWifiNative.closeSupplicantConnection();
                     if (mPeers.clear()) sendP2pPeersChangedBroadcast();
                     transitionTo(mP2pDisabledState);
                     sendMessageDelayed(WifiP2pManager.ENABLE_P2P, P2P_RESTART_INTERVAL_MSECS);
@@ -717,7 +719,7 @@
         public void enter() {
             if (DBG) logd(getName());
             //Start listening every time we get inactive
-            WifiNative.p2pListen();
+            mWifiNative.p2pListen();
         }
 
         @Override
@@ -727,13 +729,13 @@
                 case WifiP2pManager.CONNECT:
                     if (DBG) logd(getName() + " sending connect");
                     mSavedPeerConfig = (WifiP2pConfig) message.obj;
-                    String updatedPeerDetails = WifiNative.p2pPeer(mSavedPeerConfig.deviceAddress);
+                    String updatedPeerDetails = mWifiNative.p2pPeer(mSavedPeerConfig.deviceAddress);
                     mPeers.update(new WifiP2pDevice(updatedPeerDetails));
                     mPersistGroup = false;
                     int netId = configuredNetworkId(mSavedPeerConfig.deviceAddress);
                     if (netId >= 0) {
                         //TODO: if failure, remove config and do a regular p2pConnect()
-                        WifiNative.p2pReinvoke(netId, mSavedPeerConfig.deviceAddress);
+                        mWifiNative.p2pReinvoke(netId, mSavedPeerConfig.deviceAddress);
                     } else {
                         //If peer is a GO, we do not need to send provisional discovery,
                         //the supplicant takes care of it.
@@ -798,7 +800,7 @@
                     break;
                 case WifiP2pManager.CREATE_GROUP:
                     mPersistGroup = true;
-                    if (WifiNative.p2pGroupAdd()) {
+                    if (mWifiNative.p2pGroupAdd()) {
                         replyToMessage(message, WifiP2pManager.CREATE_GROUP_SUCCEEDED);
                     } else {
                         replyToMessage(message, WifiP2pManager.CREATE_GROUP_FAILED,
@@ -840,7 +842,7 @@
                             WifiP2pManager.BUSY);
                     break;
                 case WifiP2pManager.CANCEL_CONNECT:
-                    if (WifiNative.p2pCancelConnect()) {
+                    if (mWifiNative.p2pCancelConnect()) {
                         replyToMessage(message, WifiP2pManager.CANCEL_CONNECT_SUCCEEDED);
                     } else {
                         replyToMessage(message, WifiP2pManager.CANCEL_CONNECT_FAILED,
@@ -897,7 +899,7 @@
         @Override
         public void enter() {
             if (DBG) logd(getName());
-            WifiNative.p2pProvisionDiscovery(mSavedPeerConfig);
+            mWifiNative.p2pProvisionDiscovery(mSavedPeerConfig);
         }
 
         @Override
@@ -913,7 +915,7 @@
 
                     if (mSavedPeerConfig.wps.setup == WpsInfo.PBC) {
                         if (DBG) logd("Found a match " + mSavedPeerConfig);
-                        WifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
+                        mWifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
                         transitionTo(mGroupNegotiationState);
                     }
                     break;
@@ -926,7 +928,7 @@
                         if (DBG) logd("Found a match " + mSavedPeerConfig);
                         /* we already have the pin */
                         if (!TextUtils.isEmpty(mSavedPeerConfig.wps.pin)) {
-                            WifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
+                            mWifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
                             transitionTo(mGroupNegotiationState);
                         } else {
                             transitionTo(mUserAuthorizingInvitationState);
@@ -941,7 +943,7 @@
                     if (mSavedPeerConfig.wps.setup == WpsInfo.DISPLAY) {
                         if (DBG) logd("Found a match " + mSavedPeerConfig);
                         mSavedPeerConfig.wps.pin = provDisc.pin;
-                        WifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
+                        mWifiNative.p2pConnect(mSavedPeerConfig, FORM_GROUP);
                         notifyInvitationSent(provDisc.pin, device.deviceAddress);
                         transitionTo(mGroupNegotiationState);
                     }
@@ -1045,7 +1047,7 @@
                             if (DBG) logd("Removed client " + deviceAddress);
                             if (!mPersistGroup && mGroup.isClientListEmpty()) {
                                 Slog.d(TAG, "Client list empty, remove non-persistent p2p group");
-                                WifiNative.p2pGroupRemove(mGroup.getInterface());
+                                mWifiNative.p2pGroupRemove(mGroup.getInterface());
                             }
                         } else {
                             if (DBG) logd("Failed to remove client " + deviceAddress);
@@ -1067,12 +1069,12 @@
                         setWifiP2pInfoOnGroupFormation(dhcpInfo.serverAddress);
                         sendP2pConnectionChangedBroadcast();
                     } else {
-                        WifiNative.p2pGroupRemove(mGroup.getInterface());
+                        mWifiNative.p2pGroupRemove(mGroup.getInterface());
                     }
                     break;
                 case WifiP2pManager.REMOVE_GROUP:
                     if (DBG) loge(getName() + " remove group");
-                    if (WifiNative.p2pGroupRemove(mGroup.getInterface())) {
+                    if (mWifiNative.p2pGroupRemove(mGroup.getInterface())) {
                         replyToMessage(message, WifiP2pManager.REMOVE_GROUP_SUCCEEDED);
                     } else {
                         replyToMessage(message, WifiP2pManager.REMOVE_GROUP_FAILED,
@@ -1119,7 +1121,7 @@
                 case WifiP2pManager.CONNECT:
                     WifiP2pConfig config = (WifiP2pConfig) message.obj;
                     logd("Inviting device : " + config.deviceAddress);
-                    if (WifiNative.p2pInvite(mGroup, config.deviceAddress)) {
+                    if (mWifiNative.p2pInvite(mGroup, config.deviceAddress)) {
                         updateDeviceStatus(config.deviceAddress, WifiP2pDevice.INVITED);
                         sendP2pPeersChangedBroadcast();
                         replyToMessage(message, WifiP2pManager.CONNECT_SUCCEEDED);
@@ -1180,9 +1182,9 @@
                     break;
                 case PEER_CONNECTION_USER_ACCEPT:
                     if (mSavedPeerConfig.wps.setup == WpsInfo.PBC) {
-                        WifiNative.startWpsPbc();
+                        mWifiNative.startWpsPbc();
                     } else {
-                        WifiNative.startWpsPinKeypad(mSavedPeerConfig.wps.pin);
+                        mWifiNative.startWpsPinKeypad(mSavedPeerConfig.wps.pin);
                     }
                     mSavedPeerConfig = null;
                     transitionTo(mGroupCreatedState);
@@ -1422,7 +1424,7 @@
     }
 
     private void p2pConnectWithPinDisplay(WifiP2pConfig config, boolean join) {
-        String pin = WifiNative.p2pConnect(config, join);
+        String pin = mWifiNative.p2pConnect(config, join);
         try {
             Integer.parseInt(pin);
             notifyInvitationSent(pin, config.deviceAddress);
@@ -1432,16 +1434,16 @@
     }
 
     private void initializeP2pSettings() {
-        WifiNative.setPersistentReconnect(true);
-        WifiNative.setDeviceName(mThisDevice.deviceName);
+        mWifiNative.setPersistentReconnect(true);
+        mWifiNative.setDeviceName(mThisDevice.deviceName);
         //DIRECT-XY-DEVICENAME (XY is randomly generated)
-        WifiNative.setP2pSsidPostfix("-" + mThisDevice.deviceName);
-        WifiNative.setDeviceType(mThisDevice.primaryDeviceType);
+        mWifiNative.setP2pSsidPostfix("-" + mThisDevice.deviceName);
+        mWifiNative.setDeviceType(mThisDevice.primaryDeviceType);
         //The supplicant default is to support everything, but a bug necessitates
         //the framework to specify this explicitly
-        WifiNative.setConfigMethods("keypad display push_button");
+        mWifiNative.setConfigMethods("keypad display push_button");
 
-        mThisDevice.deviceAddress = WifiNative.p2pGetDeviceAddress();
+        mThisDevice.deviceAddress = mWifiNative.p2pGetDeviceAddress();
         updateThisDevice(WifiP2pDevice.AVAILABLE);
         if (DBG) Slog.d(TAG, "DeviceAddress: " + mThisDevice.deviceAddress);
     }