meetecho / janus-gateway

Janus WebRTC Server
https://janus.conf.meetecho.com
GNU General Public License v3.0
8.15k stars 2.47k forks source link

Video is a green rectangle (H.264), iOS, Ionic 2 #579

Closed bushev closed 8 years ago

bushev commented 8 years ago

I'm trying to get work Ionic 2 application on iOS. Stream comes from Raspberry pi (gStreamer + Janus WebRTC gateway)

Application is a streaming application with the following logic:

  1. Create connection to RPi using Janus WebRTC gateway
  2. Obtain stream and create video tag with src: URL.createObjectURL(stream)

I'm getting WebRTC support by the following plugin: https://github.com/eface2face/cordova-plugin-iosrtc

Streaming works great in FireFox browser by ionic serve --platform=ios command.

Streaming is NOT works inside iOS emulator and on a real device. I just got a green rectangle instead of stream, like on the picture above:

7935075e-4d25-11e6-88ac-88124d9d2881

gStreamer command:

raspivid --verbose --nopreview --width 640 --height 480 --framerate 15 --bitrate 1000000 --profile main --timeout 0 -o - | 
gst-launch-1.0 -v fdsrc ! h264parse ! rtph264pay config-interval=1 pt=96 ! udpsink host=127.0.0.1 port=8004

Janus config:

[gst-rpwc]
type = rtp
id = 1
description = RPWC H264 test streaming
audio = no
video = yes
videoport = 8004
videopt = 96
videortpmap = H264/90000
videofmtp = profile-level-id=4D401F\;packetization-mode=1

I have googled a similar problem (http://stackoverflow.com/questions/21120717/h-264-video-wont-play-on-ios).

They say iOS safari support Main profile with AVC level 3.1. I'm tried this proposal but it doesn't help me too..

I'm also tried the following "pairs" (profile-level-id + profile) without success:

"42e028 + baseline"  
"640028 + hight"

No any errors in console. Traffic for the app is also OK (~100kbps). But I see green square instead of image..

lminiero commented 8 years ago

Not a bug, since other endpoints play the stream fine, so doesn't belong here. Please post on meetecho-janus instead.

sezerkorkmaz commented 7 years ago

any news?

krishnaclouds commented 6 years ago

Really any update on this?