Type
open classType: BaseObj
| kotlin.Any | ||
| ↳ | android.renderscript.BaseObj | |
| ↳ | android.renderscript.Type | |
A Type describes the android.renderscript.Element and dimensions used for an or a parallel operation. Types are created through .
A Type always includes an android.renderscript.Element and an X dimension. A Type may be multidimensional, up to three dimensions. A nonzero value in the Y or Z dimensions indicates that the dimension is present. Note that a Type with only a given X dimension and a Type with the same X dimension but Y = 1 are not equivalent.
A Type also supports inclusion of level of detail (LOD) or cube map faces. LOD and cube map faces are booleans to indicate present or not present.
A Type also supports YUV format information to support an android.renderscript.Allocation in a YUV format. The YUV formats supported are android.graphics.ImageFormat#YV12, android.graphics.ImageFormat#NV21, and android.graphics.ImageFormat#YUV_420_888
Summary
| Nested classes | |
|---|---|
| open |
Builder class for Type. |
| Public methods | |
|---|---|
| open static Type! |
createX(rs: RenderScript!, e: Element!, dimX: Int)Utility function for creating basic 1D types. |
| open static Type! |
createXY(rs: RenderScript!, e: Element!, dimX: Int, dimY: Int)Utility function for creating basic 2D types. |
| open static Type! |
Utility function for creating basic 3D types. |
| open Int |
getCount()Return the total number of accessable cells in the Type. |
| open Element! |
Return the element associated with this Type. |
| open Int |
getX()Return the value of the X dimension. |
| open Int |
getY()Return the value of the Y dimension or 0 for a 1D allocation. |
| open Int |
getYuv()Get the YUV format |
| open Int |
getZ()Return the value of the Z dimension or 0 for a 1D or 2D allocation. |
| open Boolean |
hasFaces()Return if the Type is a cube map. |
| open Boolean |
Return if the Type has a mipmap chain. |
| Inherited functions | |
|---|---|
Public methods
createX
open static funcreateX(
rs: RenderScript!,
e: Element!,
dimX: Int
): Type!
Deprecated: Deprecated in Java.
Utility function for creating basic 1D types. The type is created without mipmaps enabled.
| Parameters | |
|---|---|
rs |
RenderScript!: The RenderScript context |
e |
Element!: The Element for the Type |
dimX |
Int: The X dimension, must be > 0 |
| Return | |
|---|---|
Type! |
Type |
createXY
open static funcreateXY(
rs: RenderScript!,
e: Element!,
dimX: Int,
dimY: Int
): Type!
Deprecated: Deprecated in Java.
Utility function for creating basic 2D types. The type is created without mipmaps or cubemaps.
| Parameters | |
|---|---|
rs |
RenderScript!: The RenderScript context |
e |
Element!: The Element for the Type |
dimX |
Int: The X dimension, must be > 0 |
dimY |
Int: The Y dimension, must be > 0 |
| Return | |
|---|---|
Type! |
Type |
createXYZ
open static funcreateXYZ(
rs: RenderScript!,
e: Element!,
dimX: Int,
dimY: Int,
dimZ: Int
): Type!
Deprecated: Deprecated in Java.
Utility function for creating basic 3D types. The type is created without mipmaps.
| Parameters | |
|---|---|
rs |
RenderScript!: The RenderScript context |
e |
Element!: The Element for the Type |
dimX |
Int: The X dimension, must be > 0 |
dimY |
Int: The Y dimension, must be > 0 |
dimZ |
Int: The Z dimension, must be > 0 |
| Return | |
|---|---|
Type! |
Type |
getCount
open fungetCount(): Int
Deprecated: Deprecated in Java.
Return the total number of accessable cells in the Type.
| Return | |
|---|---|
Int |
int |
getElement
open fungetElement(): Element!
Deprecated: Deprecated in Java.
Return the element associated with this Type.
| Return | |
|---|---|
Element! |
Element |
getX
open fungetX(): Int
Deprecated: Deprecated in Java.
Return the value of the X dimension.
| Return | |
|---|---|
Int |
int |
getY
open fungetY(): Int
Deprecated: Deprecated in Java.
Return the value of the Y dimension or 0 for a 1D allocation.
| Return | |
|---|---|
Int |
int |
getZ
open fungetZ(): Int
Deprecated: Deprecated in Java.
Return the value of the Z dimension or 0 for a 1D or 2D allocation.
| Return | |
|---|---|
Int |
int |
hasFaces
open funhasFaces(): Boolean
Deprecated: Deprecated in Java.
Return if the Type is a cube map.
| Return | |
|---|---|
Boolean |
boolean |
hasMipmaps
open funhasMipmaps(): Boolean
Deprecated: Deprecated in Java.
Return if the Type has a mipmap chain.
| Return | |
|---|---|
Boolean |
boolean |