Code example for Animation

Methods: getTransformation

0
 
        Animation anim = component.mAnimation;
        if (anim != null) {
            long now = root.currentAnimationTimeMillis();
            Transformation temp = root.obtainTransformation();
            if (!anim.getTransformation(now, temp)) {
                component.mAnimation = null;
            } 
            invalidate(); 
            root.pushTransform();
            transform.compose(temp);
            root.freeTransformation(temp);
        } 
        component.render(root, gl);
        if (anim != null) root.popTransform();
        matrix.preTranslate(-xoffset, -yoffset);
    } 
 
    protected boolean onTouch(MotionEvent event) {
        if (mOnTouchListener != null) {
            return mOnTouchListener.onTouch(this, event);