tencent cloud

All product documents
Media Processing Service
Filename Variable
Last updated: 2024-05-09 15:18:51
Filename Variable
Last updated: 2024-05-09 15:18:51
MPS supports rendering target paths of output files with the following variables:
Variable Name
Description
inputName
Input file name
inputFormat
Input file format
format
Output file format
definition
Parameter template ID
number
Output file number
Note:
This variable only takes effect on the output .ts files produced under the HLS format.

Sample 1

If your transcoding requirements are as follows:
The name of the input file is AnimalWorldE01.mp4.
Transcoding templates 100010, 100020, and 100030 are used.
The names of the output files are AnimalWorldE01_100010.mp4, AnimalWorldE01_100020.mp4, and AnimalWorldE01_100030.mp4, respectively.
Then, when using the ProcessMedia API to initiate transcoding: You should specify the InputInfo.CosInputInfo.OutputObjectPath parameter as {inputName}_{definition}.{format}.

Sample 2

If your transcoding requirements are as follows:
The name of the input file is AnimalWorldE01.mp4.
Transcoding template 100210 is used.
The name of the output .m3u8 file is AnimalWorldE01_from_mp4.m3u8.
The names of the output .ts files are AnimalWorldE01_from_mp4_0.ts, AnimalWorldE01_from_mp4_1.ts, AnimalWorldE01_from_mp4_2.ts, and so on.
Then, when using the ProcessMedia API to initiate transcoding:
You should specify the InputInfo.CosInputInfo.OutputObjectPath parameter as {inputName}_from_{inputFormat}.{format}.
You should specify the InputInfo.CosInputInfo.SegmentObjectName parameter as {inputName}_from_{inputFormat}_{number}.{format}.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

7x24 Phone Support
Hong Kong, China
+852 800 906 020 (Toll Free)
United States
+1 844 606 0804 (Toll Free)
United Kingdom
+44 808 196 4551 (Toll Free)
Canada
+1 888 605 7930 (Toll Free)
Australia
+61 1300 986 386 (Toll Free)
EdgeOne hotline
+852 300 80699
More local hotlines coming soon