Azure媒体服务v3-生成字幕的预设:Azure Media Indexer 2预览

时间:2018-10-30 20:04:36

标签: caption azure-media-services

是否存在用于生成字幕的 Preset (预设),例如v2中的v2 Azure Media Indexer 2 Preview 媒体处理器?

假设的例子:

operator () const

2 个答案:

答案 0 :(得分:0)

通过检查“转到参考”中的代码注释来找到解决方案。

var transform = await _client.Transforms.GetAsync(ResourceGroup, AccountName, TranscribeTransformName);

if (transform == null)
{
    var output = new[]
    {
        new TransformOutput(new VideoAnalyzerPreset("en-US", InsightsType.AudioInsightsOnly))
    };

    transform = await _client.Transforms.CreateOrUpdateAsync(ResourceGroup, AccountName, TranscribeTransformName, output);
}


/// <summary>
/// Initializes a new instance of the VideoAnalyzerPreset class.
/// </summary>
/// <param name="audioLanguage">The language for the audio payload in
/// the input using the BCP-47 format of 'language tag-region' (e.g:
/// 'en-US'). The list of supported languages are, 'en-US', 'en-GB',
/// 'es-ES', 'es-MX', 'fr-FR', 'it-IT', 'ja-JP', 'pt-BR', 'zh-CN',
/// 'de-DE', 'ar-EG', 'ru-RU', 'hi-IN'. If not specified, automatic
/// language detection would be employed. This feature currently
/// supports English, Chinese, French, German, Italian, Japanese,
/// Spanish, Russian, and Portuguese. The automatic detection works
/// best with audio recordings with clearly discernable speech. If
/// automatic detection fails to find the language, transcription would
/// fallback to English.</param>
/// <param name="insightsToExtract">The type of insights to be
/// extracted. If not set then based on the content the type will
/// selected.  If the content is audi only then only audio insights are
/// extraced and if it is video only. Possible values include:
/// 'AudioInsightsOnly', 'VideoInsightsOnly', 'AllInsights'</param>
public VideoAnalyzerPreset(string audioLanguage = null, InsightsType? insightsToExtract = null);

答案 1 :(得分:0)

字幕也适用于以“ AdaptiveStreaming”编码的视频吗?