KudanAR - Android
ARAlphaVideoTextureMaterial Class Reference
+ Inheritance diagram for ARAlphaVideoTextureMaterial:
+ Collaboration diagram for ARAlphaVideoTextureMaterial:

Public Member Functions

 ARAlphaVideoTextureMaterial ()
 
 ARAlphaVideoTextureMaterial (ARTextureOES texture)
 
void setTexture (ARTextureOES newTexture)
 
ARTextureOES getTexture ()
 
boolean prepareRendererWithNode (ARNode node)
 
void setUVTransform (float[]uvTransform)
 
- Public Member Functions inherited from ARMaterial
boolean getTransparent ()
 
void setTransparent (boolean transparent)
 
boolean getDepthOnly ()
 
void setDepthOnly (boolean depthOnly)
 
void setDepthWrite (boolean depthWrite)
 
boolean getDepthWrite ()
 
void setDepthTest (boolean depthTest)
 
boolean getDepthTest ()
 
boolean prepareRendererWithNode (ARNode node)
 
void setName (String name)
 
String getName ()
 

Detailed Description

A material used to render alpha videos as an ARVideoTexture. Alpha Videos are videos specially created using the Kudan AR Toolkit. They are a series of images that are in two halves, with the left half containing the colour frames of the image on a white background and the right half containing an alpha mask. When these frames are encoded using the Kudan AR Toolkit, the resulting video is a .mp4 file playing the frames at the specified frame rate. When rendered using the framework, the two halves are combined together and the resulting video with transparency is displayed on its associated node.

Constructor & Destructor Documentation

Initialises an empty ARAlphaVideoTextureMaterial to be loaded with values later.

Initialises an ARAlphaVideoTextureMaterial with an ARTextureOES.

Parameters
textureThe texture to load into the material.

Member Function Documentation

ARTextureOES getTexture ( )
inline

Returns the ARTextureOES currently loaded into this material, or null if empty.

Returns
The ARTextureOES used by the ARAlphaVideoTextureMaterial
boolean prepareRendererWithNode ( ARNode  node)
inline

Prepares the renderer for drawing a node. Binds the ARAlphaVideoTextureShader for rendering and sets the UV transform and texture parameters.

Parameters
node
Returns
true
void setTexture ( ARTextureOES  newTexture)
inline

Sets the texture applied to the ARAlphaVideoTextureMaterial.

Parameters
newTextureThe ARTextureOES to apply to the material.
void setUVTransform ( float[]  uvTransform)
inline

Updates ARAlphaVideo materials UV transform. Used to transform from 2d coodinates to texture coordinates.

Parameters
uvTransformArray of floats containing the UV transform matrix.

The documentation for this class was generated from the following file: