0
votes

I am using azure media service to generate encode,trim video. Now i want to generate video thumbnail with custom encoding preset. Here what i used to encode video and generate thumbnail:

{
"Version": "1.0",
  "Sources": [
    {
      "StartTime": "00:00:00",
      "Duration": "00:01:00"
    }
  ],
  "Codecs": [
    {
      "Type": "CopyVideo"
    },
    {
      "Type": "CopyAudio"
    },
    {
      "PngLayers": [
        {
          "Type": "PngLayer",
          "Width": 150,
          "Height": 150
        }
      ],
      "Start": "{Best}",
      "Type": "PngImage"
    }
  ],
  "Outputs": [
    {
      "FileName": "e3cb10a2-1580-49f7-ad29-99c44f5bc936_{Width}x{Height}_{VideoBitrate}.mp4",
      "Format": {
        "Type": "MP4Format"
      }
    },
    {
      "FileName": "{Basename}_{Index}{Extension}",
      "Format": {
        "Type": "PngFormat"
      }
    }
  ]
}

while i am trying to encode video and generate thumbnail, getting this error:

The preset results in multiple outputs with same name. Either use unique file names or use macros to disambiguate!

Above code is work perfect if i remove thumbnail configuration and doing just video encoding.

Can any one suggest is it possible to generate thumbnail with copyaudio and copyvideo codecs?

1
This likely indicates that your input Asset has multiple video tracks. Are you using a live archive as the input Asset?Anil Murching
@AnilMurching Yes, first i uploaded asset and then using that asset as input asset for encodingjpatel
Can you please share the Job ID, and the data center you used? If you are willing to share the input content, then send us a link (SAS URL perhaps) to [email protected]. ThanksAnil Murching
@AnilMurching i have one new issue video gets upload twice. after successfull first upload and encode video get upload again automatically. Any idea?jpatel
not sure what you mean by "video get upload again". The service does not upload videos to your account. Can you please clarify?Anil Murching

1 Answers

-1
votes

It's mandatory for Thumbnail generation to use the macro {Index} in the filename output. That shall solve the issue. Regards,