I'm not sure if this is the right place to ask this...sorry in advance if it is wrong.
Currently I have an app that can record audio with the mic and afterwards plays the file.
What I am wondering now is if it is possible to play the recorded file directly. So like a phone call, only that the file is always on one device and is recorded and played from the same device.
Is that possible? Maybe with streaming or something? Unfortunately I am a noob.
I would be very happy about an answer and thanks in advance
It is possible, to play the audio directly with a stream method. The data will be saved in background. To get basic knowledge I suggest to take a look at these examples, explained by the android-studio documentation. This is a taff project as a beginner. Start step by step. First try to record audio, then stream with mediaPlayer and saving it. And the final step is all together. Cheers.
Related
Ok, I have a video encrypted through AES, stored in the internal memory of an Android powered device. What i want is that the video should only be played through an android app.
It would be appreciated if that application would decrypt the video part by part, store it in a virtual memory, and then stream it.
My question:
Is it possible to decrypt it part by part and stream?
If Yes, what would be the basic process?
If No, (nothing is impossible to code)
To make it happen, do i need to design my own video player android app, or can i use some existing app to work inside my app?
This subject is already treated in many questions.
For instance, look at How to play an encrypted video file in Android
I am kind of stuck on my app design and wondering, if some of you experts, could point me in the right direction.
I am working an Android App that shows how to pronounce different English words.
When user clicks on a play button next to a word, corresponding audio file (prerecorded wav file) is played with Android media player. I have 2000 words and corresponding wav files (each file is between 1 to 2 seconds).
But the problem is, I can’t pack all 2000 audio files into APP, as it will make APP too big. I am wondering, what is the best way of having the audio files on the server somewhere, and when user clicks play button next to a word, my APP plays from server. Are there any other ways of doing this?
Do I need streaming server for this (it’s not live stream), if so would you please let me know some that host? Can I use Heroku?
Thanks for help
Srini
You do not need a streaming server for that. A simple web pages server will do the job. Just put all your files in (maybe via ftp) to the server in a directory that you now exactly. From there, you can use the MediaPlayer class of android to play those sounds in streaming with the appropriate link to the file.
Is there a simple way to record sound and stream it to a server in real time?
Thanks,
Leslie
No, there is no direct API that would do that..
What people usually do is read the media file as it is being saved, and upload it progressively to server.
See how some open-source projects do it:
http://code.google.com/p/sipdroid/
http://code.google.com/p/ipcamera-for-android/
http://code.google.com/p/camdroiduni/
I have just started studying Android and I am still lost.
I would just like to ask if playlist for video files is supported in Android 2.3.3 and above?
I just found out that there is MediaStore.Audio.Playlist but no MediaStore.Video.Playlist.
Any feedback would be greatly appreciated.
Thanks,
artsylar
Well yeah there is no such thing as MediaStore.Video.Playlist. And second thing is that if you want to play a list of video I strongly recommend you play them by folder (meaning you have a sort of listview that displays all of video in a folder you specified and play all of them, same as playlist). Why?
Because:
The point of using MediaStore is to have a convenient way to access ContentProvider which is sort of database that contains meta-data of copyright audio (tracks). If your audio is not licensed which means you are not buying the tracks from legal source, you wouldn't able to use MediaStore. So the same thing happens with videos
Use MX Player, it plays continuous videos also gives buttons to play next previous video in the list
I'd like my Android application to download an mp3 file from the internet and play it like a stream while downloading it. Is this even possible? How would I go about doing it?
Essentially I want the user to be able to listen to the file instantly, but have it keep downloading to the SD Card even if he stops listening, so the whole mp3 file will end up on the SD Card either way.
I don't believe android provides the functionality you're asking for. But there's one workaround I know of that might work.
http://code.google.com/p/android/issues/detail?id=739 is an open ticket with a lot of discussion that relates to what you're describing. In the 5th comment seeingwithsound says
However, as a workaround I next stream my synthesized data to temporary files much like you consider streaming your HTTP streams to files, for subsequent playback of these files via MediaPlayer. [...] It looks though like your problem might be served by more control over MediaPlayer's buffering, because you are essentially concatenating streams through some cache mechanism (buffer) ...
To be honest I haven't played with MediaPlayer too much, so I can't give you too many details on how to "control MediaPlayer's buffering". But assuming you can get that to work, I suggest that you download your .mp3 file to (a) temporary file(s) which you can then point MediaPlayer to.
Sorry this answer is so vague, but you're entering territory that few others have before attempted. Good luck.
For Android devices 2.3 and earlier, you need to remove the Content-Disposition response header altogether. This will cause the browser to invoke the audio player of the user's preference.
Try it here: http://declinefm.com/archives select an archive of your choice, and tap the download link.
For modern Android devices, you can dispense with the removal of the CD header.
I have a tutorial here that I wrote inspired on your post:
http://rudd-o.com/linux-and-free-software/how-to-properly-stream-audio-from-your-plone-varnish-site
Enjoy!
RTSP or HTTP? If HTTP you can try and remove the Content-Length header which on some mobile devices will allow for immediate invocation of the player. It sounds as though you're pumping the data through a local app. How are you playing the file now?