Contents. Player Camera AudioIn, AudioOut Image & ImageUtil AudioRecorder VideoRecorder AudioDecoder/Encoder, VideoDecoder/Encoder

Similar documents
3.01C Multimedia Elements and Guidelines Explore multimedia systems, elements and presentations.

Prentice Hall. Learning Microsoft PowerPoint , (Weixel et al.) Arkansas Multimedia Applications I - Curriculum Content Frameworks

IMPECCA DFM-1512 USER S MANUAL

Mul$media Support in Android

Gecata by Movavi 5. Recording desktop. Recording with webcam Capture videos of the games you play. Record video of your full desktop.

Directory. Product overview. Connecting your media player. Specification. Interface. Explanation of the remote control. Connector Indication

DbsEditor v1.8 (Database Editor) QUICK REFERENCE

Mul$media Techniques in Android. Some of the informa$on in this sec$on is adapted from WiseAndroid.com

Overview 1. Foreword 2. Warnings

VC-HD8 Manual v2 July 2016

Tips for game development: Graphics, Audio, Sensor bada Developer Day in Seoul Dec 08, 2010

Completing the Multimedia Architecture

Streaming Media. Advanced Audio. Erik Noreke Standardization Consultant Chair, OpenSL ES. Copyright Khronos Group, Page 1

Professional Powerpoint Presentation II

ANDROID APPS DEVELOPMENT FOR MOBILE AND TABLET DEVICE (LEVEL II)

About sounds and Animate CC

EOS MOVIE Utility Ver. 1.5


Camera (2.0 mega pixels), support fourfold digital zoom, photographing, recording and video recording;

CS 528 Mobile and Ubiquitous Computing Lecture 4a: Playing Sound and Video Emmanuel Agu

VSPlayer User Manual V

JVA04 HDMI to USB Type-C Game Capture Station Manual Contents

ImTOO MPEG Encoder Help

Contents. Canvas and Graphical shapes Drawing Font and Text Bitmaps and Buffer Example Animation 3D-Graphics Hardware Support

MICRO 2+ USER MANUAL

Media Formats. Sound. Image. Video. WAV (uncompressed, PCM) MIDI. BMP XML dia MPEG

Viewing Live Video. Viewing Video through the Home Window Overview. Home Window Overview CHAPTER

Optimizing A/V Content For Mobile Delivery

Avigilon Control Center Player User Guide. Version 5.10

VSPlayer Software User Manual

VidOvation TV Digital Signage Overview

Elementary Computing CSC 100. M. Cheng, Computer Science

Revision 4.1.x /2.x.x [ ] Creating Media for Modulo Player & Kinetic

ADPF10XN Instruction Manual

Multimedia Technology

Advanced High Graphics

TotalRecorder On-line Help (Version 8.5)

UNDERSTANDING MUSIC & VIDEO FORMATS

Networking Applications

Main function 4.3 TFT Screen, Resolution 480*272

New Perspectives on PowerPoint Module 2: Adding Media and Special Effects

Before Operation. Basic Operation. Operating Instructions

Attentions. Overview function

TL240C Transparent Display User Manual

Taurus Series Multimedia Players XI'AN NOVASTAR TECH CO.,LTD. TB6 Specifications Document Version: Document Number: V1.4.0 NS

Digital single-lens non-reflex AF/AE camera

TL240C/TL321C Transparent Display User Manual

IO [io] MAYAH. IO [io] Audio Video Codec Systems

Recording Studio User Manual

Meeting Visuals UCF Toolkit User Guide

Viewer for Luma Fisheye IP Surveillance Camera. Software Manual

Technical Overview Axis M1031-W - Network Camera. Get yours direct at:

Camera & Imaging. Advanced Settings Capturing Still Images Recording Videos Oekaki Photo Library...

15 Video Screen. Manual v1.3

MULTIMEDIA AND CODING

Always there to help you. Register your product and get support at HMP5000. Question? Contact Philips.

PN ITEM UPC ARCHOS 70d Titanium 8GB - EU

EYEZONE B1080PAM. User Manual CONTENTS. Feb 24, 11

HyperMedia User Manual

Che2-L11 & Che2-L12 & Che2-L23 Smartphone V100R001. Product Description. Issue 01. Date HUAWEI TECHNOLOGIES CO., LTD.

Manual v2.1 July 2017

Image and video processing

M4-R4: INTRODUCTION TO MULTIMEDIA (JAN 2019) DURATION: 03 Hrs

Camera & Imaging. Capturing Image, Recording Video & Editing Camera Using Display as Viewfinder...7-9

User Guide for Leawo Prof. Media - How to Use Leawo Prof. Media

Camtasia Studio 5.0 PART I. The Basics

Copyright 2018 Xi'an NovaStar Tech Co., Ltd. All Rights Reserved. No part of this document may be copied, reproduced, extracted or transmitted in any

ESKIAV2 (SQA Unit Code - F9AL 04) Audio and Video Software

Camera. Mobile Camera Mobile Camera Precautions Camera Using Display as Viewfinder

Hi-Res 8 Wi-Fi Digital Picture Frame with MP3 player Table of Contents

MEDIA RELATED FILE TYPES

A+ Suite Software. User Manual

Audio issues in MIR evaluation

A Linux multimedia platform for SH-Mobile processors

Operator Manual. Version 2.813

1.0 Introduction Foreword Package Contents Warnings Computer Requirements Layout of the Player...

Windows Movie Maker. The Toolbar. The Toolbar

Microsoft Office: PowerPoint 2013

TotalRecorder On-line Help (Version 8.2)

Export Audio Mixdown

Quintic Software Tutorial 6. Quintic Editor

IP-8151P Vivotek - IP Cameras

Table of Contents 1.SAFETY INSTRUCTIONS BOXED CONTENTS PRODUCT REVIEW HARDWARE SPECIFICATIONS BASIC SETUP...

VAADRView Software/Debrief Station General Purpose Image Analysis and Enhancement

liquivid Video Improve v2.x Installation Instructions for Windows, macos, Adobe Lightroom Manual

Multimedia. File formats. Image file formats. CSE 190 M (Web Programming) Spring 2008 University of Washington

III INDEX. Product List 1. Overview 1. Projector Specification 2. Basic Functions: 2. MP4 key functions description: 3.

Multi Analog Video To HDMI UHD. 4Kx2K Scaler. With USB Media Player

CONTENTS. Part 1.GP-723 system requirements...2. Part 2.GP-723 driver installation...2. Part 3.Microsoft DirectX9 installation...7

Multimedia on the Web

Avigilon Control Center Web Client User Guide

Avigilon Control Center Player User Guide. Version 6.2

XEMIO-950 MP5 PLAYER / 4GB MEMORY / TOUCH SCREEN. For information and support,

2.1 Transcoding audio files

MP60 TABLE OF CONTENTS. HD Media Player

Ultimate Video Capture v1.8 User Manual

ACD Systems at the hub of digital imaging... 1

MP75. HD Media Player

Media Player. Media Player Downloading Music/Movies

Honor 3C (H30-U10) Mobile Phone V100R001. Product Description. Issue 01. Date HUAWEI TECHNOLOGIES CO., LTD.

Transcription:

Media

Contents Player Camera AudioIn, AudioOut Image & ImageUtil AudioRecorder VideoRecorder AudioDecoder/Encoder, VideoDecoder/Encoder 2

Introduction The Media namespace contains classes and interfaces that let developers e asily integrate audio, video, and image processing into their applications. Key features include: Encoding and decoding of images and videos. Playing audio and video from media files stored on a device or streaming over the network. Recording audio and video. Using the camera to display a live preview and capture a still image. Using codec to encode and decode the audio/video data. 3

1 Player

Player Class Overview Playback of media (Audio and Video) Player supports Playback of audio/video in local storage & stream from the server basic controls for audio/video content (play, pause, stop, & resume) time-based seeking, volume control, looping Getting the duration of audio/video content. Multiple audio stream playback. Playback of DRM content. Supported DRM are OMA (v1.0, v2.0, v2.1), WMDRM, PlayReadyDRM. Capturing the video frame during video playback. 5

Player Class APIs Important APIs OpenBuffer () OpenFile () OpenUrl () Play () Pause () Stop () Close () SeekTo () SetLooping () SetRenderingBuffer () GetCurrentMediaStreamInfoN () CaptureVideo () 6

Player Supported Formats and Protocols Local playback of Video H.264,H.263,MPEG4,VC-1 Video Streaming H.264, H.263, MPEG4 Local playback of Audio PCM, AMR-NB, AAC, AAC+, EAAC+, MIDI, MP3, WMA Audio streaming AMR-NB, AAC, AAC+, EAAC+ Protocols RTSP with live streaming HTTP with live streaming 7

Audio Mixing Multiple Audio Playback Multiple instance playback restriction Multiple compressed audio stream with different audio codec. Multiple uncompressed audio format (ex. WAV) The maximum instances of Player is dependent on system performance. The maximum count of Player instance is 10. 8

IPlayerEventListener Used to notify the status of media player during the media playback. Callbacks for the player events are OnPlayerOpened() : when the player is opened asynchronously OnPlayerBuffering(): when the streaming data is being buffered OnPlayerEndOfClip(): when playback reaches to the end of clip OnPlayerInterrupted(): when the device is taken by a task with a higher priority OnPlayerReleased() OnPlayerErrorOccurred(): when there is an error in playback OnPlayerSeekCompleted(): when the position of the audio/video content moves asynchronously 9

IPlayerVideoEventListener To get the decoded video frame OnVideoFrameDecoded() Notifies when the video frame is decoded asynchronously 10

2 Camera

Camera Class Overview Controls the Camera Device.. To capture still images. Supports real time preview. Allows processing of Preview data. Very important feature in Camera class. Requires CAMERA privilege Features Preview Format : RGB or YCbCr Camera Sensor controls Autofocus, Flash Brightness, Contrast Exposure, ISO Level, White Balance Zoom Preview Data Controls Preview format, preview frame rate, preview resolution 12

Camera Functions Prepare device PowerOn(), PowerOff() Getter /Setter methods for camera settings Get/Set {Brightness(), Contrast(), Effect(), Flash(), Quality(), WhiteBalance()} Get/Set {CaptureFormat(), CaptureResolution()} Get/Set {PreviewFormat(), PreviewFrameRate(), PreviewResolution()} Control Capture(), StartPreview(), StopPreview(), ZoomIn(), ZoomOut() 13

ICameraEventListener Camera Listener Functions OnCameraCaptured() called when a picture has been successfully captured OnCameraPreviewed() called at each frame of preview only when camera.startpreview(.., true) OnCameraAutoFocused() Called when Camera::SetAutoFocus() API is called and completed. OnCameraErrorOccurred Called when an error occurs in the Camera. 14

Previewing Scenario Preview Format List GetSupportedPreviewFormatListN() OverlayRegion Preview on the background buffer of an overlay region Steps Set the orientation of the form to landscape Create an overlay region Make the form as the current form Get background info of the overlay region Start preview on the background 15

Taking Picture Scenario Preparation Stage Creating & implementing the listener Construct Camera instance with ICameraEventListener Construct( listener, CAMERA_PRIMARY ) PowerOn camera PowerOn() Set camera options (optional) preview format, preview resolution, ISO level, brightness, effect, contrast, exposure, white balance Attach the backgroundbuffer of the OverlayRegion to camera to start preview StartPreview() 16

Taking Picture Scenario Taking picture & runtime control Take a picture camera.capture(); an event listener will be invoked Zoom camera.zoomin(), camera.zoomout() 17

Camera Example result TestPreviewing(void) { result r = E_SUCCESS; Camera* pprimarycamera = null; Osp::Ui::Controls::OverlayRegion * poverlayregion = null; Osp::Ui::Controls::Form* pcameraform = null; Osp::Graphics::BufferInfo bufferinfo; Osp::Graphics::Rectangle rect(0, 0, 320, 240); bool modified = false; bool suitable = false; // Initialize pcameraform pprimarycamera = new Camera(); plistener = new MyCameraListener; //Code snippet continued on the next slide.. 18

Camera Example // Construct camera with camera event listener and camera type r = pprimarycamera->construct(*plistener, CAMERA_PRIMARY); //17 r = pprimarycamera->poweron(); // camera is instructed to work suitable = OverlayRegion::EvaluateBounds( OVERLAY_REGION_EVALUATION_OPTION_LESS_THAN, rect, modified ); } poverlayregion = pcameraform->getoverlayregionn(rect, OVERLAY_REGION_TYPE_PRIMARY_CAMERA); r = poverlayregion->getbackgroundbufferinfo(bufferinfo); r = pprimarycamera->startpreview(&bufferinfo, true); return r; 19

3 AudioIn, AudioOut

AudioIn Class Overview Provides low level mechanism for audio recording Records PCM data from audio input device. If you want to record audio into a container file format, use AudioRecorder class. Dynamically we can get the information about the system (no of channels supported, Sample rate supported etc) Specification Input device type: microphone Number of channels: mono, stereo Sampling depth: 8 bit, 16 bit Sample rate: 8000 Hz ~ 48000 Hz 21

AudioIn Functions Prepare Device with number of channels, sample type, rate, and depth AddBuffer() Get information GetMin/MaxBufferSize() GetOptimized{ChannelType, SampleRate, SampleType}() GetState() Control Start(), Stop(), Reset(), Unprepare() 22

Typical AudioIn Scenario State transition Construct and prepare AudioIn Add buffer to AudioIn Start If there is interruption OnAudioInInterrupted() is called; stop AudioIn automatically OnAudioInReleased() is called; start AudioIn, again If the buffer is filled OnAudioInBufferFilled() is called; store data & rewind the buffer When the user stops recording, stop AudioIn and store data in the buffer unprepare AudioIn and delete it 23

IAudioInEventListener AudioIn captures audio data from the device in asynchronous mode, an d calls IAudioInEventListener methods to pass the captured audio data Provided callbacks are OnAudioInBufferIsFilled() when AudioIn fills the input buffer and indicates the application that buffer is filled and application may use it. OnAudioInInterrupted() when any high priority tasks acquire device ex: Call OnAudioInReleased() when the interrupted tasks releases the device which had acquired. 24

AudioIn: Multiple Buffering Adding more than one buffer Automatic switch When you start recording, the 1st buffer is used When the 1st is filled, OnAudioInBufferIsFilled() is invoked At the same time, the 2nd buffer starts being used When the 2nd is filled, the 1st buffer starts being used resulting in less latency. 25

AudioIn Example void AudioInExample::AudioInRecord(void) { // Constructs an AudioIn instance paudioininstance->construct(* pmyaudioinlistener); // Prepares an AudioIn instance paudioininstance->prepare(audio_input_device_mic,audio_type_pcm_u8, AUDIO_CHANNEL_TYPE_STEREO,8000); // Prepare buffers to store PCM data pbytebuffer1 = new ByteBuffer(); pbytebuffer1->construct(max_buffer_size); pbytebuffer2 = new ByteBuffer(); pbytebuffer2->construct(max_buffer_size); pbytebuffer3 = new ByteBuffer(); pbytebuffer3->construct(max_buffer_size); //Code snippet continued on the next slide.. 26

AudioIn Example // Adds buffers paudioininstance->addbuffer( pbytebuffer1); paudioininstance->addbuffer( pbytebuffer2); paudioininstance->addbuffer( pbytebuffer3); } // Start paudioininstance->start(); 27

AudioOut Class Overview Lower level audio playback class Play PCM (uncompressed) audio data in various sample types through Audio output device Can be either Mono or stereo Unsigned 8 bit or signed 16 bit Also supports multiple buffering. Usage is very similar to AudioIn except Raw Audio Buffer is for playback SetVolume is supported 28

AudioOut Functions Prepare Prepare(), Unprepare(), WriteBuffer() Volume control Get/SetVolume() Control Start(), Stop(), Reset() Get information GetMin/MaxBufferSize() GetOptimized{ChannelType,SampleRate,SampleType}() GetState() 29

IAudioOutEventListener Callbacks provided by IAudioOutEventListener OnAudioOutBufferEndReached() Called when all the content of the buffer has been played back OnAudioOutInterrupted() Called when the output device is occupied by another task with higher priority OnAudioOutReleased() Called when the interrupting task releases the device 30

AudioOut Example void AudioOutExample::AudioOutPlay() { // Construct the AudioOut instance with a listener paudiooutinstance->construct(* pmyaudiooutlistener); // AudioOut Preparation paudiooutinstance->prepare(audio_type_pcm_u8, AUDIO_CHANNEL_TYPE_STEREO,8000); // Write 3 buffers in queue of the device side ByteBuffer* pwritebuffer = null; pwritebuffer = static_cast<bytebuffer*>( pdataarray- >GetAt( playcount++)); paudiooutinstance->writebuffer(*pwritebuffer); //Code snippet continued on the next slide.. 31

AudioOut Example } pwritebuffer = static_cast<bytebuffer*>( pdataarray->getat( playcount++)); paudiooutinstance->writebuffer(*pwritebuffer); pwritebuffer = static_cast<bytebuffer*>( pdataarray- >GetAt( playcount++)); paudiooutinstance->writebuffer(*pwritebuffer); // Start playing until the end of the array paudiooutinstance->start(); 32

4 Image and ImageUtil

Image Class Overview IMAGE privilege is required. Media::Image class provides methods to encode, decode, and convert images. Supports decoding of JPEG, GIF, PNG, BMP, WBMP, TIFF Supports Encoding to JPEG, PNG, BMP Supports Image format conversion Supports JPEG compression. Optionally, the application can automatically scale images when decoding them. The application can compress JPEG images into smaller JPEG images with barely noticeable quality loss. Images can be handled from a file in storage or a buffer in memory. 34

Image Class APIs Important APIs CompressJpeg() CompressJpegN() ConvertN() DecodeN() DecodeToBufferN() DecodeUrl() EncodeToBufferN() EncodeToFile() 35

Example: Image Decoding #define SCREEN_WIDTH 320 #define SCREEN_HEIGHT 240 result TestDecoding(Form *pform) { result r = E_SUCCESS; String path("/media/images/sample.jpg"); // Create an Image instance. Image *pimage = new Image(); r = pimage->construct(); //Decode the image Bitmap *pbitmap = pimage->decoden(path, BITMAP_PIXEL_FORMAT_RGB565, SCREEN_WIDTH, SCREEN_HEIGHT); Osp::Graphics::Rectangle rect(0,0,screen_width,screen_height); Canvas *pcanvas = pform->getcanvasn(); //Get a Canvas instance r = pcanvas->drawbitmap(rect, *pbitmap); //Draw bitmap on the canvas r = pcanvas->show(); delete pimage; delete pcanvas; delete pbitmap; //Free the memory return r;} 36

ImageUtil Class Overview(since 2.0) ImageUtil class facilitates Image pixel format conversion Image scaling (such as resizing, rotating, and flipping) Important APIs ConvertPixelFormat() Flip() Resize() Rotate() 37

5 AudioRecorder

AudioRecorder Class Overview To Record the audio data from input device to a file Input source is automatically selected by current audio path(mic, Earphone) Provides Recording controls - Record, Pause, Stop, Mute Provides API to set Recording quality - Low / Medium / High Provides setting for maximum recording time and size Provides mute during recording Provides APIs for getting supported codecs and container formats Supported Recording formats - WAV, AMR, AAC 39

IAudioRecorderEventListener Response to control OnAudioRecorderStarted(): when the recording is started OnAudioRecorderPaused(): when the recording is paused OnAudioRecorderStopped(): when the recording is stopped OnAudioRecorderCanceled(): when the recording is cancelled OnAudioRecorderClosed(): when the recording is closed Other listener functions OnAudioRecorderEndReached(): when recording reaches the maximum size or time specified OnAudioRecorderErrorOccurred(): when there is an error occurred during Audio Recording 40

AudioRecorder Example result TestAudioRecording(void) { result r = E_SUCCESS; paudiorecorder = new AudioRecorder(); // Instantiate and register the AudioRecorder event listener plistener = new MyAudioRecorderListener; r = paudiorecorder->construct(*plistener); // Create/open the file handle for storing recorded data r = paudiorecorder->createaudiofile(path, true); // Start/resume recording r = paudiorecorder->record(); if(isfailed(r)) { delete paudiorecorder; delete plistener; } return r; } 41

6 VideoRecorder

VideoRecorder Class Overview Similar to Audio Recorder Except Construct with Camera Codec: encoding methods GetSupportedCodecListN(), SetCodec() Recording resolution: dimension of video GetSupportedRecordingResolutionListN(), SetRecordingResolution() Quality RECORDING_QUALITY_LOW, MEDIUM, HIGH Mode VIDEORECORDER_MODE_VIDEO_WITH_AUDIO, VIDEO_ONLY Format VIDEORECORDING_FORMAT_MP4, 3GP 43

IVideoRecorderEventListener VideoRecorder Listener functions OnVideoRecorderCanceled(): Video Recording canceled OnVideoRecorderClosed(): VideoRecorder closed OnVideoRecorderEndReached(): Recording reaches the end of the pre-defined file size or time OnVideoRecorderErrorOccurred(): Error occurred during recording OnVideoRecorderPaused(): Recording paused OnVideoRecorderStarted(): Recording started OnVideoRecorderStopped(): Recording stopped 44

VideoRecorder Example result VideoRecorderTestForm::OnInitializing(void) { result r = E_SUCCESS; Osp::Graphics::Rectangle rect(0, 0, 320, 240); bool modified=false; //Get Overlay proper overlay region dimension bool suitable = OverlayRegion::EvaluateBounds( OVERLAY_REGION_EVALUATION_OPTION_LESS_THAN, rect, modified); poverlayregion = GetOverlayRegionN(rect, OVERLAY_REGION_TYPE_PRIMARY_CAMERA); //Code snippet continued on the next slide.. 45

VideoRecorder Example } poverlayregion->getbackgroundbufferinfo( previewbufferinfo); pcamera = new Osp::Media::Camera(); r = pcamera->construct(*this); r = pcamera->poweron(); pvideorecorder = new Osp::Media::VideoRecorder(); r = pvideorecorder->construct(*this, * pcamera); r = pcamera->startpreview(& previewbufferinfo, false); pvideorecorder->createvideofile(filename, true); pvideorecorder->record(); return r; 46

7 AudioDecoder/Encoder, VideoDecoder/Encoder

AudioDecoder Class Overview Decodes compressed audio stream into raw audio data Supported audio decoding formats CODEC_MP3 CODEC_AAC CODEC_AMR_NB. Important APIs are Decode() Probe() IsPropertySupported () GetValue() GetSupportedPropertyListN() 48

AudioDecoder Example result DecodeMP3(void) { result r = E_SUCCESS; AudioDecoder dec; ByteBuffer srcbuf, dstbuf; File srcfile; int samplerate, value; AudioChannelType channeltype; AudioSampleType sampletype; //Code snippet continued on the next slide.. 49

AudioDecoder Example } r = dec.construct(codec_mp3); r = srcbuf.construct(src_buf_size); r = srcfile.construct(l"/home/test.mp3", "rb"); r = srcfile.read(srcbuf); srcbuf.flip(); //Flip the source Buffer position to zero r = dec.probe(srcbuf, sampletype, channeltype, samplerate); r = dstbuf.construct(dst_buf_size); r = dec.decode(srcbuf, dstbuf); //dstbuf will contain the decoded data return r; 50

AudioEncoder Class Overview Used to Encode raw audio data into compressed audio stream Supported audio encoding formats CODEC_AAC CODEC_AMR_NB Important API Encode() : Encodes the audio data from the source buffer and stores the encoded data into the destination buffer 51

VideoDecoder Class Overview used to decode compressed Video stream into raw video data Supported video encoding formats CODEC_H263, CODEC_MPEG4, CODEC_H264 Important API Decode() : Decodes the video data from the source buffer and stores the decoded data into the destination buffer Probe (): Probes whether the video data can be decoded. IsPropertySupported() GetValue() GetSupportedPropertyListN() 52

VideoEncoder Class Overview Used to encode raw Video stream into compressed video data Supported video encoding formats CODEC_H263, CODEC_MPEG4, CODEC_H264. Important API Encode() IsPropertySupported() SetValue() GetSupportedPropertyListN() 53

Summary Media namespace provides functionality to easy access a variety of media types including Image, audio and video Image files can be read and written via the Image class Player class can playback media contents Using Audio/Video Recorder, you can create content files AudioIn/Out are designed for low-level recording and playback a PCM audio. You can use them for sound processing and music applications Camera class provides camera-related functionalities including real-time preview and capturing Codec framework which supports Audio/Video Encoding/Decoding. 54

Practice Example Write a program which decodes image file or image buffer to a bitmap. Write a program which flips and rotate an image Write a program which converts from one image format to another image format. Write a program which plays an audio and video file using the player class. Write a program which plays multiple audio files simultaneously. Write a program which captures a frame of the video during video playbac k and display the same. 55

Practice Example Write a program which records audio with specified quality, time and size. Write a program which uses the VideoRecorder class for recording a video with different resolutions, size, time and codec formats. Write a program which records audio data using AudioIn and plays the sa me using the AudioOut class. Write a program which encodes pcm data to aac data using AudioEncoder class. Write a program which decodes mp3 data using AudioDecoder class. Write a program which encodes yuv data to mp4 data using VideoEncoder class. Write a program which decodes mp4 data using VideoDecoder class. 56