videojs in WeChat doesn't work for rtmp - rtmp

I want to play rtmp in WeChat and it can play on my PC browser, but in WeChat browser on Android, it returns:
"No compatible source was found for this video"
But on iPhone it just shows an infinite loading screen.
<script>
videojs.options.flash.swf = "video-js/video-js.swf";
</script>
<video id="example_video_1" class="video-js vjs-default-skin" controls preload="none" width="640" height="264"
poster="http://www.pageresource.com/wallpapers/wallpaper/bleach-ichigo-mugetsu-here-size-original_215405.jpg"
data-setup="{}">
<source src="rtmp://hsn.mpl.miisolutions.net/hsn-live01/mp4:420p500kB31" type='rtmp/mp4'>
<!--source src="rtmp://219.232.161.204/livestream/mtzysunq" type='rtmp/mp4' / -->
<!--<track kind="captions" src="demo.captions.vtt" srclang="en" label="English"></track>--><!-- Tracks need an ending tag thanks to IE9 -->
<!--<track kind="subtitles" src="demo.captions.vtt" srclang="en" label="English"></track>--><!-- Tracks need an ending tag thanks to IE9 -->
</video>

No browser supports rtmp without flash. videojs uses a flash fallback for rtmp (video-js.swf). Mobile devices do not support flash, hence no flash fall back, hence no video. You need to use a format other than rtmp. Like mp4, hls or dash.

Related

HTML5 video tag in vue.js

I have the strangest problem in a vue-setup.
This markup works perfectly for one page - on all devices and all tested browsers:
<video
width="960px"
height="540px"
controls autoplay muted loop preload="auto"
playsinline
>
<source src="#/assets/video/studio_sor_v1.mp4" type="video/mp4">
Your browser does not support the video tag.
</video>
But this markup works only on desktop and Android for mobile. Both Chrome and Safari fails to play it on iOS mobiles:
<video
width="960px"
height="540px"
controls autoplay muted loop preload="auto"
playsinline
>
<source src="#/assets/video/studio_nord_high_sml.mp4" type="video/mp4">
Your browser does not support the video tag.
</video>
Different video's, but encoded with the same encoder, same settings, same file size etc.
Some dude tried to upload the non-playing file to his site (some Vix site) - and it works there. Vue.js or server (netlify) problem?
Makes no sense to me. Any ideas?
I'm betting this is a codec issue. what is the codec of the non-playing video?
First is probably h264 (nearly universal support)
Im guessing the second is VP8 or VP9 in an mp4 container. iOS mobiles (no matter the browser) do not support these codecs.
You can check this with FFprobe Here's API for ffprobe: https://www.streamclarity.com/probe?url={videoURL}

Not able to play aac audio files on IE11

I have a page with this html :
<audio controls="controls">
<source src="http://techslides.com/demos/samples/sample.aac" type="audio/aac" />
</audio>
It works on Firefox and Edge but it doesn't on IE11. My windows version is up to date and I saw it should be supported. I tried to change my settings to be sure ActiveX is enabled and it is.
I also tried with :
<audio controls="controls" src="http://techslides.com/demos/samples/sample.aac">
It doesn't works too.
What can I do?
I tested the sample code with IE 11 browser and I am able to produce the issue.
I try to check the documentation and found this information.
Beginning with Windows Internet Explorer 9, any audio or video content
needs the correct mime type set on the server, or the files won't
play. Internet Explorer 9 supports MP3 audio, and MP4 audio and video.
WebM audio and video files can be supported by installing the WebM
components from The WebM project. The following table shows the
required settings for your web server to host these files correctly.
Microsoft Edge updates introduced WAV support.
Reference:
audio element | audio object
you can see that .AAC format is not in the list but sites like MDN and CANIUSE shows that it is supported.
I also tried with audio type mp4 which also did not worked.
<audio controls="controls">
<source src="http://techslides.com/demos/samples/sample.aac" type="audio/mp4" />
</audio>
It also can be possible that it is some kind of bug with IE browser or issue is related with H.264 format.
As a work around, I suggest you to use mp3 file format which is working fine with IE 11.
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<audio controls="controls">
<source src="https://www.soundhelix.com/examples/mp3/SoundHelix-Song-1.mp3" type="audio/mpeg3" />
</audio>
</body>
</html>

HTML5 Audio Won't Load Using Safari for Mavericks

Here is the code I am using for the audio:
<audio controls preload="none" class="voice-audio">
<source class="voice-audio-source" src="<path to content>")" type="audio/mpeg" />
<p>Your browser does not support HTML5 audio.</p>
</audio>
The audio will not load at all on Safari for Mavericks. Has anyone successfully done this?
Using jPlayer in the hopes of resolving.

How to play MKV file in browser?

I have a video file in MKV format, i want to play that file in the browser without converting, how can i play this file format in browser?
<video width="320" height="240" controls>
<source src="movie.mkv" type="video/mkv">
Your browser does not support the video tag.
</video>
i want this file to be played in full screen mode always. My browser is chrome.
It will refuse to play Matroska if the type attribute is set to video/x-matroska. Try removing the type attribute completely.
After some experimentation with this issue, I've found the best solution is to set the mime type to video/webm.
I think Chrome doesn't play .mkv videos.
By the way, 'type' is mime-type, and mkv's mime type is video/x-matroska.
Try:
source src="movie.mkv" type="video/x-matroska"
If this works, maybe the sound will be muted, so you can try type="video/mp4".
I added the IIS Mime Type as (.mkv - video/webm) over the IIS option and it worked fine.
If you want to use video with path .mkv
<!-- mkv -->
<video width="320" height="240" controls src="assets/animation.mkv"></video>
<!-- mp4 -->
<video width="320" height="240" controls>
<source src="assets/animation.mp4" type="video/mp4" />
</video>
if you do not understand, click on link
Play Code

html5 mp4 video player

I am trying to play mp4 video using html5 video tag. But in FF 3.6 its just showing a black window with cross sign. Its playing in Chrome.
I can play that video in windows media player (i.e. the required codec are installed)
How can i play that video in FF too?
<video id="video1" width="200" height="200" controls="true">
<source src="video1.mp4" type='video/mp4; codecs="avc1.64001E, mp4a.40.2"' />
Your browser does not support mp4 videos
</video>
firefox does not support most MPEG4 natively due to licencing. you can save your video in a few different types and use canPlayType(type) method.
more here:
http://wiki.whatwg.org/wiki/Video_type_parameters
http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#dom-navigator-canplaytype
For Firefox, you'll have to encode the video as Theora and save as an .ogv file.
http://diveintohtml5.info/video.html#what-works