I want to stream a video from my Android application on Youtube but I want to stream a Stream not just give the Camera to the Youtube api and let it fo the job, I want create a stream by myself so that I can modify it first and add some effects on the video, then convert it to a stream, then stream it.
I am ok with the first part, the stream is ready, modified, filtered, effects are added. How to stream that stream to Youtube from Android?
Related
I want to develop a app which can get current playing audio stream type. and add special audio effect on it according to the stream type,is there any way to get the playing audio stream type? Thanks
I want to distinguish the content type of data incoming from a HLS stream using Google's ExoPlayer.
Specifically, I want to distinguish between Video and Audio-only content.
Thanks!
Accoridng to the Exoplayer documentation the player does not currently support detecting the media format at all:
ExoPlayer does not (yet) automatically detect the format of the media being played. An application needs to know the format of the media it wishes to play in order to construct an ExoPlayer capable of playing it. Removing this limitation is tracked by Issue #438.
The issue link mentioned above is: https://github.com/google/ExoPlayer/issues/438
You could look at the raw stream yourself if you can access it (it is not encrypted) and figure out from there if it is audio or video but this will need a reasonable amount of work: HLS is a 'streaming protocol' that streams MPEG-2 transport streams, chunked into segments. Each of these MPEG-2 transport streams can contain audio and video.
The MPEG standards (MPEG 1 and MPEG 2) use stream ids to identify each individual audio or video stream in the transport stream. Audio streams are numbered 110X XXXX and video streams 1110XXXX - hence you can check all the individual streams in an MPEG2 transport stream and see if whether it is audio only, video only or a mix.
I am developing a Android video player that can play RTSP Stream. I use ffmpeg in jni part to get and decode RTSP Stream. For now, the player can play and then pause video stream. The next step is to create a buffer for the player so that when user pauses video, the player can still load video stream in the next several seconds.
Is there any good documentation on how to create a buffer for video streaming in proper way?
My plan is to create a array of packets. When the array is full, the player calls
av_read_pause();
to stop buffering. When the array has spaces, the player will call
av_read_play();
to continue buffering. There is a read_thread for getting packets from the buffer and the decode the packets. The read_thread will stop (resume), when user pauses (resume) video.
Can this plan work?
I would like to stream microphone.
And use http server on android so that
user just go http://xxxx.xxx.xx.xxx/xxx.wav can listen to what I say?
How can I do so?
I would try to develop a small HTTP server which serves an FLV stream.
You can take ipcamera-for-android as an example. This app serves a FLV video stream however you could reuse the server and the FLV encoder part.
As FLV supports PCM streams you can simply copy the buffer of the microphone to your stream.
Another variant
You can encode the microphone stream using the built-in MediaRecorder.AudioEncoder.AAC. Afterwards you can simply serve the AAC as a stream to your client.
I am completely new to displaying streaming either audio or video content using media player.
Somehow using post available here, i am able to display RTSP content(.3gp video) in my MediaPlayer implementation.
How to identify streaming content is audio only stream or audio/video stream using MediaPlayer class or streaming link?
I could be wrong here, but I believe there is only a MediaPLayer.OnInfoListner API available in Java to get information about the content stream being played. Not sure of how helpful that API actually is though. You might also want to try stream scrapers(is what I believe they are called) to get stream data and see if there is both audio and video channel to make a determination.