Finish plumbing for double RS elements.

Change-Id: Ic708dcaeda4966bb2121ecb6834f56cfa68ad58e
This commit is contained in:
Stephen Hines
2010-09-30 15:19:22 -07:00
parent 5972e52e15
commit 02f4170519
3 changed files with 10 additions and 2 deletions

View File

@@ -39,7 +39,7 @@ public class Element extends BaseObj {
public enum DataType {
//FLOAT_16 (1, 2),
FLOAT_32 (2, 4),
//FLOAT_64 (3, 8),
FLOAT_64 (3, 8),
SIGNED_8 (4, 1),
SIGNED_16 (5, 2),
SIGNED_32 (6, 4),
@@ -149,6 +149,13 @@ public class Element extends BaseObj {
return rs.mElement_F32;
}
public static Element F64(RenderScript rs) {
if(rs.mElement_F64 == null) {
rs.mElement_F64 = createUser(rs, DataType.FLOAT_64);
}
return rs.mElement_F64;
}
public static Element ELEMENT(RenderScript rs) {
if(rs.mElement_ELEMENT == null) {
rs.mElement_ELEMENT = createUser(rs, DataType.RS_ELEMENT);