質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.47%
XML

XMLは仕様の1つで、マークアップ言語群を構築するために使われています。

HTML5

HTML5 (Hyper Text Markup Language、バージョン 5)は、マークアップ言語であるHTMLの第5版です。

iframe

HTMLのタグ<iframe>です。<iframe>は、ドキュメント内に""inline frame""を作るHTML要素で、同じページでセパレートしているドキュメントが表示されるようにします。

Three.js

Three.jsはWebGLをサポートしているJavaScriptの3D描画用ライブラリです。

Azure

Azureは、マイクロソフトのクラウド プラットフォームで、旧称は Windows Azureです。PaaSとIaaSを組み合わせることで、 コンピューティング・ストレージ・データ・ネットワーキング・アプリケーションなど多くの機能を持ちます。

Q&A

解決済

1回答

3710閲覧

Azureでエンコードした.mpdファイルを再生したい。

snooooopy_16

総合スコア15

XML

XMLは仕様の1つで、マークアップ言語群を構築するために使われています。

HTML5

HTML5 (Hyper Text Markup Language、バージョン 5)は、マークアップ言語であるHTMLの第5版です。

iframe

HTMLのタグ<iframe>です。<iframe>は、ドキュメント内に""inline frame""を作るHTML要素で、同じページでセパレートしているドキュメントが表示されるようにします。

Three.js

Three.jsはWebGLをサポートしているJavaScriptの3D描画用ライブラリです。

Azure

Azureは、マイクロソフトのクラウド プラットフォームで、旧称は Windows Azureです。PaaSとIaaSを組み合わせることで、 コンピューティング・ストレージ・データ・ネットワーキング・アプリケーションなど多くの機能を持ちます。

0グッド

0クリップ

投稿2017/01/30 10:50

編集2017/01/31 06:57

###前提・実現したいこと
Azureでエンコードした.mpdファイルをgoogle vr view for webで再生したい。

###発生している問題・エラーメッセージ
再生できる.mpdファイルと再生できない.mpdファイルがあり,Azureで.mp4⇒.mpdにエンコードした場合,再生できない。
![イメージ説明]
![追加
###該当のソースコード
動かない.mpdファイルの中身

<?xml version="1.0" encoding="utf-8"?> <MPD xmlns="urn:mpeg:dash:schema:mpd:2011" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" profiles="urn:mpeg:dash:profile:isoff-live:2011" type="static" mediaPresentationDuration="PT3M0.267S" minBufferTime="PT3S"><Period><AdaptationSet id="1" group="1" profiles="ccff" bitstreamSwitching="false" segmentAlignment="true" contentType="video" mimeType="video/mp4" codecs="avc1.64001F" maxWidth="1280" maxHeight="640" startWithSAP="1"><SegmentTemplate timescale="10000000" media="QualityLevels($Bandwidth$)/Fragments(video=$Time$,format=mpd-time-csf)" initialization="QualityLevels($Bandwidth$)/Fragments(video=i,format=mpd-time-csf)"><SegmentTimeline><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/><S d="20016666"/><S d="20016667"/><S d="20033333"/><S d="20016667" r="1"/></SegmentTimeline></SegmentTemplate><Representation id="1_V_video_1" bandwidth="3433827" width="1280" height="640"/><Representation id="1_V_video_2" bandwidth="2273278" width="960" height="480"/><Representation id="1_V_video_3" bandwidth="1515229" width="960" height="480"/><Representation id="1_V_video_4" bandwidth="1009339" codecs="avc1.640016" width="640" height="320"/><Representation id="1_V_video_5" bandwidth="655802" codecs="avc1.640016" width="640" height="320"/><Representation id="1_V_video_6" bandwidth="403922" codecs="avc1.64000D" width="320" height="160"/></AdaptationSet><AdaptationSet id="2" group="5" profiles="ccff" bitstreamSwitching="false" segmentAlignment="true" contentType="audio" mimeType="audio/mp4" codecs="mp4a.40.2"><SegmentTemplate timescale="10000000" media="QualityLevels($Bandwidth$)/Fragments(aac_UND_2_128=$Time$,format=mpd-time-csf)" initialization="QualityLevels($Bandwidth$)/Fragments(aac_UND_2_128=i,format=mpd-time-csf)"><SegmentTimeline><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="20053334"/><S d="20053333" r="1"/><S d="17920000"/></SegmentTimeline></SegmentTemplate><Representation id="5_A_aac_UND_2_128_1" bandwidth="128008" audioSamplingRate="48000"/></AdaptationSet></Period></MPD>

動く.mpdファイルの中身

<?xml version="1.0"?> <!-- MPD file Generated with GPAC version 0.5.2-DEV-rev971-g61bef99-master at 2016-08-31T22:43:16.278Z--> <MPD xmlns="urn:mpeg:dash:schema:mpd:2011" minBufferTime="PT1.500S" type="static" mediaPresentationDuration="PT0H0M40.101S" maxSegmentDuration="PT0H0M2.020S" profiles="urn:mpeg:dash:profile:isoff-on-demand:2011"> <ProgramInformation moreInformationURL="http://gpac.sourceforge.net"> <Title>test_vod_ricoh/dash/richoh1_0.mpd generated by GPAC</Title> </ProgramInformation> <Period duration="PT0H0M40.101S"> <AdaptationSet segmentAlignment="true" par="1:1" lang="und" subsegmentAlignment="true" subsegmentStartsWithSAP="1"> <Representation id="1" mimeType="audio/mp4" codecs="mp4a.40.2" audioSamplingRate="44100" startWithSAP="1" bandwidth="71452"> <AudioChannelConfiguration schemeIdUri="urn:mpeg:dash:23003:3:audio_channel_configuration:2011" value="2"/> <BaseURL>richoh1_0_1.mp4</BaseURL> <SegmentBase indexRangeExact="true" indexRange="855-1138"> <Initialization range="0-854"/> </SegmentBase> </Representation> </AdaptationSet> <AdaptationSet segmentAlignment="true" maxWidth="854" maxHeight="428" maxFrameRate="30" par="2:1" lang="und" subsegmentAlignment="true" subsegmentStartsWithSAP="1"> <Representation id="2" mimeType="video/mp4" codecs="avc1.64001f" width="854" height="428" frameRate="30" sar="428:427" startWithSAP="1" bandwidth="969630"> <BaseURL>richoh1_0_2.mp4</BaseURL> <SegmentBase indexRangeExact="true" indexRange="941-1224"> <Initialization range="0-940"/> </SegmentBase> </Representation> <Representation id="3" mimeType="video/mp4" codecs="avc1.64001e" width="640" height="322" frameRate="30" sar="161:160" startWithSAP="1" bandwidth="549938"> <BaseURL>richoh1_0_3.mp4</BaseURL> <SegmentBase indexRangeExact="true" indexRange="941-1224"> <Initialization range="0-940"/> </SegmentBase> </Representation> <Representation id="4" mimeType="video/mp4" codecs="avc1.64000d" width="426" height="214" frameRate="30" sar="214:213" startWithSAP="1" bandwidth="245251"> <BaseURL>richoh1_0_4.mp4</BaseURL> <SegmentBase indexRangeExact="true" indexRange="941-1224"> <Initialization range="0-940"/> </SegmentBase> </Representation> </AdaptationSet> </Period> </MPD>

html

<!DOCTYPE html> <html> <head> <title>VR View - video example</title> <meta name=viewport content="width=device-width, initial-scale=1"> <meta charset="utf-8" /> <link href="//fonts.googleapis.com/css?family=Lora|Open+Sans" rel="stylesheet" type="text/css"> <link href="../style.css" rel="stylesheet" type="text/css"> <style> </style> </head> <body> <h1>VR Test</h1> <!--<iframe frameborder="0" width="100%" scrolling="no" allowfullscreen src="vrview/index.html?video=/vrview/examples/video/congo_2048.mp4&is_stereo=true"></iframe>--> <iframe frameborder="0" width="100%" scrolling="no" allowfullscreen source src="vrview/index.html?video=http://testendpoint-testaccount.streaming.mediaservices.windows.net/fecebb23-46f6-490d-8b70-203e86b0df58/BigBuckBunny.ism/Manifest(format=mpd-time-csf)"></iframe> </body> </html>

###試したこと
ネットから拾ってきた以下の様な.mpdファイルは再生できることを確認済みです。
https://bitmovin-a.akamaihd.net/content/playhouse-vr/mpds/105560.mpd
###補足情報(言語/FW/ツール等のバージョンなど)
HTMLソースは「video=」以降を動画ソースを置き換えてテストしています。
今書いてある動画もAzureのサイトにあった.mpdファイルのサンプルなのですが,これも同様再生できません。

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

ベストアンサー

プレイヤー側では、拡張子で判定しているようです。
URLの最後に".mpd"をつけてみると再生できました。

html

1<iframe frameborder="0" width="100%" height="100%" scrolling="no" allowfullscreen src="vrview/index.html?video=//gtk2kritto.streaming.mediaservices.windows.net/8d801e4e-8c81-4276-926e-81284df8dd05/sintel.ism/manifest(format=mpd-time-csf).mpd"></iframe>

デモページ
(デモページで使用しているのは360°動画ではなく普通の動画をソースにしていますので見苦しいですが再生できることを確認できます)

あと、HLS(.m3u8)のほうは解決しました?

投稿2017/01/31 02:13

turbgraphics200

総合スコア4269

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

snooooopy_16

2017/01/31 05:37 編集

.mpdを付加してみたのですが,loadエラーが発生してしまい,再生することができませんでした。 発生している問題・エラーメッセージのところにエラー画面のキャプチャを添付いたしました。 HLSの方はまだ回避策を試せておりません。。
turbgraphics200

2017/01/31 05:41

.mdpファイルのURLを教えていただくことは可能ですか?
turbgraphics200

2017/01/31 05:54

testendpoint-testaccount.streaming.mediaservices.windows.net(BigBuckBunny)のほうは、エンドポイントが停止してませんか?meditatesttaito.streaming.mediaservices.windows.net(Sample1)のほうはmpdファイルにアクセスできました。
turbgraphics200

2017/01/31 06:03

あと、video=に設定するURLはhttpsなサイトだとhttp://~を設定するとMixed Contentになるため、https://~で設定するか//~(http: または https: 無しのURL)を設定してください。
snooooopy_16

2017/01/31 06:49 編集

httpの指定のところが間違っていたということでしょうか? ちなみにですが,test2.htmlの中身を見ることは可能ですか?(無知で申し訳ございません。) turbgraphics200さんに掲載して頂いた<iframe>タグの中身全てを置き換えてもロードエラーが発生します。何か環境の問題があるのでしょうか。(追加でキャプチャを張りました。)
snooooopy_16

2017/01/31 06:59

githubからクローンを落としてきてsample2.htmlをWindows Chromeブラウザで再生してみましたが,やはり再生できないようです。環境に問題あるのでしょうか。二枚目のエラー画面が今回のものですが,少しエラー文の中身が変わりました。
turbgraphics200

2017/01/31 07:02

デモページでは再生できました?
snooooopy_16

2017/01/31 07:05

デモページでは再生できました。
turbgraphics200

2017/01/31 07:08

たぶん、ローカルで直接開いているからだと思います。URLがfile:///となっていると思いますが、これだと動画にアクセスできません。
snooooopy_16

2017/02/01 11:34

解決しました! ありがとうございます!
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.47%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問