private void setVideoSurface(Surface surface) throws IOException {
            if(mDecoders != null && mDecoders.getVideoDecoder() != null) {
                if(mVideoFrameInfo != null) {
                    // Dismiss queued video frame
                    // After updating the surface, which re-initializes the codec,
                    // the frame buffer will not be valid any more and trying to decode
                    // it would result in an error; so we throw it away.
                    mDecoders.getVideoDecoder().dismissFrame(mVideoFrameInfo);
                    mVideoFrameInfo = null;
                }

                mDecoders.getVideoDecoder().updateSurface(surface);
            }
        }
Removes a cue added by {@link #addCue(int, Object)} from the playback timeline.

@param cue the cue to remove
@return true if removal was successful, false if the cue wasn't cued on the timeline,
i.e. it has already been removed before
MediaPlayer/src/main/java/net/protyposis/android/mediaplayer/MediaPlayer.java