Open topic with navigation

# Encode Video to MPEG Files

To encode video to one or more MPEG files on disk, follow these steps.

To encode video to a file

1. Create a new configuration to send to HPE Media Server with the `process` action, or open an existing configuration that you want to modify.

2. In the `[Encoding]` section, add a new encoding task by setting the `EncodingEngineN` parameter. You can give the task any name, for example:

       [Encoding]
       EncodingEngine0=MyEncodingTask

3. Below the `[Encoding]` section, create a configuration section for the engine by typing the task name inside square brackets. For example:

       [MyEncodingTask]

4. In the new section, set the following parameters:

   `Type` | The type of encoding engine to use. Set this parameter to `mpeg`.
   `VideoSize` | (Optional) The size of the encoded video, in pixels, width followed by height. If you want to use the same dimensions as the source, set this parameter to `copy`. To ensure HPE Media Server uses the same aspect ratio as the source video, set either the width or height and set the other dimension to zero.
   `OutputPath` | The path of the encoded output file(s). You can use macros to create output paths based on the information contained in the encoded records. Specify the path as an absolute path or relative to the HPE Media Server executable file.
   `UrlBase` | The base URL that will be used to access the encoded files. This is used when HPE Media Server generates proxy information. You can use macros to create the URL base from information contained in the encoded records.
   `Segment` | (Optional) Specifies whether to split the output file into segments.
   `SegmentDuration` | (Optional) The maximum duration of a segment, in seconds.

   For example:

       [MyEncodingTask]
       Type=mpeg
       VideoSize=0x720
       OutputPath=./mp4/%currentTime.year%/%currentTime.month%/%currentTime.day%/%currentTime.timestamp%_%segment.sequence%.mp4
       UrlBase=http://www.mysite.com/video/clips/mp4/%currentTime.year%/%currentTime.month%/%currentTime.day%/

   For more information about the configuration parameters and macros that you can use, refer to the HPE Media Server Reference.

5. Save and close the configuration file. HPE recommends that you save your configuration files in the location specified by the `ConfigDirectory` parameter.

© 2016 Hewlett Packard Enterprise Development LP | Send documentation feedback to HPE Close Send Documentation Feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a web mail client, and send this email to AutonomyTPFeedback@hpe.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_HP_HTML5_bannerTitle.htm