codeName one : full duplex conversation - codenameone

I have a camera with a microphone and a speaker.
I want to make a full duplex audio communication between the browser of a terminal device and this camera.
Is it possible with CodeName One?
If so, can I have a tutorial?

We don't have a tutorial for this. If you want to use a browser within the app to do this you can use the BrowserComponent notice that this won't behave the same on the simulator and the device.

Related

Video streaming including application overlay components

I want to make a react-native app having the capability of video streaming from a mobile app to a connected browser user. On top of that, I want to overlay some application components so connected users can see video streaming as well as some of the application UI.
For an example take a reference of the below-given image. Here, video streaming is running in the car showroom and there are a few app components shown as an overlay of the video like an app menu and a car image.
I want to achive same functionality and using VideoSDK platform for video streaming service.
So far I have created react-native app and able to stream video through camera to the connected browser user.
Next, I want to add my app menu on top of the video as per the image and therefore i am thinking screenshare with combination of video sharing is way to go.
The above image is the actual implementation using video SDK in the browser but as you can see screen share window is opening in a totally different context which is not the expected implementation.
Can someone suggest how can I achieve the functionality of video streaming having the capability of app overlay components?
I have reviewed your requirement and I am glad to inform you that we do have application with same requirements, for further discussion and demos can we connect over mail i.e. karan10010#gmail.com

How to play audio in iOS in background?

My goal is to make iOS play audio in a background.
When the audio is received by iPhone, it's not played unless I open the app in the foreground.
Basically, the iPhone is "waiting" when I click to open the app, and then it plays the audio.
Following Developer Guide, I added ios.background_modes=music to my .properties file.
However, nothing changed in behaviour.
I receive audio in real time via websocket class (onMessage(byte[] message) method).
What approach would you suggest in order to resolve this issue and make iOS play audio in a background?
This is the syntax for adding via the GUI not editing the properties file directly. You need to add the property with a codename1.arg. prefix.
Specifically: codename1.arg.ios.background_modes=music

hardware back button on Android is stopping the app

I making mp3 player with ionic. I use "cordova.plugins.backgroundMode.enable()" for play music in background if close the app.
But when press hardware back button on Android is "stopping and closing" the app instead of just "closing and go back".
You have to use something called Android Services.
From the docs:
"A Service is an application component representing either an application's desire to perform a longer-running operation while not interacting with the user or to supply functionality for other applications to use."
Here's the excellent official guide to using services to get you started: http://developer.android.com/guide/components/services.html
Here's a good tutorial on building an audio player: http://www.androidhive.info/2012/03/android-building-audio-player-tutorial/
Here's a video tutorial for building a streaming music player: http://www.youtube.com/watch?v=LKL-efbiIAM

Stream live video to Android and iPhone smartphones

I am developing a live video streaming solution for a client with the following requirements:
- Stream live video to high-end Android and iPhone devices, from a mobile-optimized web app (NOT native apps)
- The video should not be full screen but partial screen, so that other HTML content can be displayed below the video
So my question is, what is the video format/technology that allows live video streaming in both devices? I've heard about HLS but I am not sure it plays in both devices.
And also, is there a way to prevent the video from going full screen? I've come across this in SO http://broken-links.com/tests/video/, but it's for on demand video. Could it also apply for live video streaming?
Thanks in advance
You should set allowsInlineMediaPlayback attribute of your UIWebView instance to YES for iOS.
From Apple's UIWebView reference page:
allowsInlineMediaPlayback
A Boolean value that determines whether HTML5 videos play inline or
use the native full-screen controller.
#property(nonatomic) BOOL allowsInlineMediaPlayback Discussion The
default value on iPhone is NO.
In order for video to play inline, not only does this property need to
be set on the view, but the video element in the HTML document must
also include the webkit-playsinline attribute.
For Android, AFAIK default behaviour of Android's WebView is not triggering media player with fullscreen. You should be able to use WebView as is.
You can get information about supported video formats with those links:
iOS Media Layer Supported Video Formats
Android Supported Video Formats
There are two major industry standards, I guess it won't be a problem if I understand your concerns correctly.
Hope that helps.

How to play .3gp videos in mobile using RTMP (FMS) and HTTP?

I am not able to play video on mobile device which is .3gp container and H.263 / AMR_NB encoded. I just want to play my website videos in mobile device also just like youtube.com. I want to use RTMP and HTTP both. My requirement is as follows-
Which codec and container will be best?
Should I use FLV to play video on mobile device?
RTSP required or can be use RTMP?
Is NetStream and NetConnection methods different from Flash Player in Flash Lite Player?
How to play 3gp video using RTMP stream ie. ns.play(“mp4:mobilevideo.3gp”, 0, -1, true) is it ok or any thing else required?
For mobile browser and computer browser, can I use single player or I have to make different player for computer browser and mobile browser?
It would be better if I can do it with single player for both mobile and computer browser.
Sample code required for testing. If you can.
I got below article in which they mention that we can play video 3gp container in mobile also. Please find the article.
Articles URL-
http://www.hsharma.com/tech/articles/flash-lite-30-video-formats-and-video-volume/
http://www.adobe.com/devnet/logged_in/dmotamedi_fms3.html
Thanks
Sunil Kumar
We've established that it's possible to play mp4 within a 3gp wrapper, but only if the file has an mp4 extension, and for Flash 9 onwards.
See http://www.adobe.com/eeurope/products/hdvideo/faq/
Hi I am not able to play video on mobile device which is .3gp container and H.263 /AMR_NB encoded. I just want to play my website videos in mobile device also just like youtube.com. I want to use RTMP and HTTP both. My requirement is as follows-
Which codec and container will be best?
Should I use FLV to play video on mobile device?
RTSP required or can be use RTMP?
.flv is not supported on all devices that support FL 3.0. Please refer to the following threads in the nokia discussion forum:http://discussion.forum.nokia.com/forum/showthread.php?p=731458#post731458 regarding transcoding in 3gp to be used in the rtsp server.
You can use http for flv.
Is NetStream and NetConnection methods different from Flash Player in Flash Lite Player?
I have no clue about this.
How to play 3gp video using RTMP stream ie. ns.play(“mp4:mobilevideo.3gp”, 0, -1, true) is it ok or any thing else required?
For the rtsp, you need to setup the darwin streaming server, which is pretty simple to install and then place your 3gp/mp4 files there. There is no need for a netstream object for this. You can simply use the 'play' method with the instance of the video object:
.play(<3gp_Or_mp4__file>);
For mobile browser and computer browser, can I use single player or I have to make different player for computer browser and mobile browser? It would be better if I can do it with single player for both mobile and computer browser.
No clue.
I would recommend you to look at the 3gp players official website at http://www.3gp-player.com .
You can read and get some information about playing 3gp video files on both Desktop/Laptop computers, and cellphones/mobile devices.
Most of the tools offered there are free, and so is the information about all the 3gp player / converters.
Hope this helps you.

Resources