# Video transcoding

This topic describes typical messaging application call data flow sequences involving video transcoding. The video transcoder is available separately from NMS.

vmsamp demonstrates the following functions:

- Play and record video and audio natively (no transcoding) using the video format selected during H.245 negotiation with the 3G mobile terminal.

- Real-time video transcoding during playing of the messages whose video format does not match the one selected during H.245 negotiation with the calling terminal.

The following illustration shows the media flow in a video mail system when H.263 baseline is the negotiated format in the 3G-324M connection:

All MPEG-4 video content played to the terminal must go through the video transcoder so that it can be rendered by the terminal. H.263 messages can be passed from the Video Messaging Server Interface to the 3G-324M Interface directly.

The application is responsible for configuring the server's RTP endpoint correctly so it sends RTP packets from the Video Messaging Server Interface either:

- Through the video transcoder platform, which then relays the packets to the 3G-324M Interface, or

- Directly to the 3G-324M Interface (internally on the CG board).

For recording, H.263 video is passed directly from the 3G-324M Interface to the Video Messaging Server Interface over RTP for 3GP storage.

## Switching between video pass-through and video transcoding

In the call-connected state, the application reconfigures the destination IP and port addresses of the server video endpoint to match the desired destination platform of either the 3G-324M Interface (gateway) or video transcoding.

The application also requires an I-frame to be generated by the video transcoder whenever it switches the server to play though the transcoder:

## Setting up and tearing down a call

The following call flow describes the application logic for setting up and tearing down an H.324M video call that involves video transcoding.

Note: The video transcoding channel can be created and started at any point after the video codec is selected on the 3G-324M Interface.