This tutorial describes how to enable/disable audio or video playback.
The purpose of this tutorial is to show you how to enable/disable audio or video playback separately in a video clip.
Required Background
The Video Client Overview introduces the video client utilities.
Introduction
You can enable/disable the audio and video separately when playing video clips. This means you can:
Note: By default, audio and video are enabled.
This functionality is made available through the CVideoPlayerUtility::SetAudioEnabledL() and CVideoPlayerUtility::SetVideoEnabledL() methods.
The following tasks are covered in this tutorial:
The high level steps to enable/disable audio or video playback are shown here:
Create a new video player utility object.
Open a video clip to play.
Enable/disable audio playback using the CVideoPlayerUtility::SetAudioEnabledL() method:
Enable/disable video playback using the CVideoPlayerUtility::SetVideoEnabledL() method:
Call the CVideoPlayerUtility::Prepare() method.
Control playback normally.
Example
//Create new video player utility object (iVideoPlayer) // Open the video clip iVideoPlayer->SetAudioEnabledL(EFalse); // disable audio playback iVideoVideoPlayer->SetVideoEnabledL(ETrue); // enable video playback // Audio has been disabled // Playback will be video only // Call Prepare() and then Play() to control playback normally