Ho provato a riprodurre un video .mp4 da un sito Web (con il tag HTML5 Video) con UIWebView. Il dispositivo e il simulatore di iPhone/iPad mostra solo una cornice nera con un pulsante di riproduzione barrato. Se ho appena chiamato questo sito Web nella versione Safari Mac, è possibile riprodurlo. Qual è il problema?UIWebview dos not playing mp4 Video
Non è un file locale. Il codice html è il seguente:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<link rel="stylesheet" type="text/css" href="../css/shared-culture.css" />
</head>
<body>
<section class="base">
<hgroup>
<h1>creative commons</h1>
<h2>a shared culture</h2>
</hgroup>
<p>To celebrate our 2008 fundraising campaign, Creative Commons has
released “A Shared Culture,” a short video by renowned filmmaker <a
href="http://en.wikipedia.org/wiki/Jesse_Dylan">Jesse Dylan</a>. Known for
helming a variety of films, music videos, and the Emmy Award-winning <a
href="http://my.barackobama.com/page/invite/yeswecanvideo">“Yes We Can”</a>
Barack Obama campaign video collaboration with rapper will.i.am, Dylan created
“A Shared Culture” to help spread the word about the Creative Commons mission. </p>
<!-- height="240" width="360" -->
<video id="video1" controls="controls">
<source src="../video/shared-culture.mp4" type="video/mp4"/>
<source src="../video/shared-culture.webm" type="video/webm"/>
<div class="errmsg">
<p>Your Reading System does not support (this) video.</p>
<pre><code>
<video id="video1" controls="controls">
<source src="../video/shared-culture.mp4" type="video/mp4"/>
<source src="../video/shared-culture.webm" type="video/webm"/>
</video>
</code></pre>
</div>
</video>
<p>In the video, some of the leading thinkers behind Creative Commons
describe how the organization is helping “save the world from failed sharing”
through free tools that enable creators to easily make their work available to
the public for legal sharing and remix. Dylan puts the Creative Commons system
into action by punctuating the interview footage with dozens of photos that have
been offered to the public for use under CC licenses. Similarly, he used two
CC-licensed instrumental pieces by Nine Inch Nails as the video’s soundtrack
music. These tracks, “17 Ghosts II” and “21 Ghosts III,” come from the Nine Inch
Nails album Ghosts I-IV, which was released earlier this year under a Creative
Commons BY-NC-SA license. (See <a
href="http://creativecommons.org/videos/a-shared-culture">attribution</a>.)
</p>
</section>
</body>
</html>
è quel video dal file locale, puoi pubblicare il tuo codice 'HTML'. – arthankamal
Se si desidera riprodurre il video solo in quel sito Web, controllare [VideoPlayerKit] (https://github.com/ign/VideoPlayerKit). –
Basta dare un'occhiata al sorgente della pagina su http://my.barackobama.com. . ./video/shared-culture.mp4', e dichiara il tag embed del film con l'attributo: 'type =" application/x-shockwave-flash "'. Per Apple HLS, hai bisogno di H.264/AVC in contenitori MPEG2.TS. Documentazione HLS qui: https://developer.apple.com/resources/http-streaming/ –