Search in sources :

Example 1 with ICameraAnimation

use of su.levenetc.android.textsurface.interfaces.ICameraAnimation in project TextSurface by elevenetc.

the class TextSurface method configAnimations.

private void configAnimations(ISurfaceAnimation animation) {
    if (animation instanceof ICameraAnimation) {
        ((ICameraAnimation) animation).setCamera(camera);
    } else if (animation instanceof ISet) {
        LinkedList<ISurfaceAnimation> animations = ((ISet) animation).getAnimations();
        for (ISurfaceAnimation a : animations) configAnimations(a);
    } else if (animation instanceof ITextSurfaceAnimation) {
        ITextSurfaceAnimation textAnimation = (ITextSurfaceAnimation) animation;
        Text text = textAnimation.getText();
        if (text != null && textsTree.add(text))
            textAnimation.setInitValues(text);
    }
}
Also used : ICameraAnimation(su.levenetc.android.textsurface.interfaces.ICameraAnimation) ISurfaceAnimation(su.levenetc.android.textsurface.interfaces.ISurfaceAnimation) ITextSurfaceAnimation(su.levenetc.android.textsurface.interfaces.ITextSurfaceAnimation) ISet(su.levenetc.android.textsurface.interfaces.ISet) LinkedList(java.util.LinkedList)

Aggregations

LinkedList (java.util.LinkedList)1 ICameraAnimation (su.levenetc.android.textsurface.interfaces.ICameraAnimation)1 ISet (su.levenetc.android.textsurface.interfaces.ISet)1 ISurfaceAnimation (su.levenetc.android.textsurface.interfaces.ISurfaceAnimation)1 ITextSurfaceAnimation (su.levenetc.android.textsurface.interfaces.ITextSurfaceAnimation)1