Code example for SurfaceTexture

Methods: updateTexImage

0
        mSurfaceTextureLock.lock();
            if (mSurfaceTexture != null)
            { 
                // Only request an update if currently playing 
                if (mCurrentState == MEDIA_STATE.PLAYING)
                    mSurfaceTexture.updateTexImage();
 
                result = mTextureID;
            } 
        mSurfaceTextureLock.unlock();
 
        return result;
    } 
 
    /** Moves the movie to the requested seek position */ 
    public boolean seekTo(int position)
    { 
        if (!isPlayableOnTexture()) 
        { 
            // DebugLog.LOGD("Cannot seek-to on this video since it is not on texture"); 
            return false;