android Programming Glossary: player
YouTube Video not playing in WebView - Android http://stackoverflow.com/questions/12708890/youtube-video-not-playing-in-webview-android public String getHTML String html iframe class youtube player style border 0 width 100 height 95 padding 0px margin 0px id.. border 0 width 100 height 95 padding 0px margin 0px id ytplayer type text html src http www.youtube.com embed J2fB5XWj6IE ..
Android: Override back button to act like home button http://stackoverflow.com/questions/2000102/android-override-back-button-to-act-like-home-button overrides the normal back behavior preventing the player activity from being destroyed and continues playing music even.. Activity simply controls this Service . I'm sure the Music player works in the same way so the example in the docs seems a bit..
Determining the current foreground application from a background task or service http://stackoverflow.com/questions/2166961/determining-the-current-foreground-application-from-a-background-task-or-service one app starts another. for example astro starting rock player when a move file was clicked. we dont have an activity then..
Streaming video from Android camera to server http://stackoverflow.com/questions/2550847/streaming-video-from-android-camera-to-server
Play audio file from the assets directory http://stackoverflow.com/questions/3289038/play-audio-file-from-the-assets-directory AssetFileDescriptor afd getAssets .openFd AudioFile.mp3 player new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare.. afd getAssets .openFd AudioFile.mp3 player new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare player.start.. new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare player.start The problem is that when I run this code..
Android: keeping a background service alive (preventing process death) http://stackoverflow.com/questions/3856767/android-keeping-a-background-service-alive-preventing-process-death would be disruptive to the user e.g. killing a music player service would stop music playing. You'll need to supply a Notification..
Android “Only the original thread that created a view hierarchy can touch its views.” http://stackoverflow.com/questions/5161951/android-only-the-original-thread-that-created-a-view-hierarchy-can-touch-its-vi can touch its views.&rdquo I've built a simple music player in Android. The view for each song contains a SeekBar implemented..
Problem to load flv video in webview http://stackoverflow.com/questions/6596243/problem-to-load-flv-video-in-webview style 'width 100 height 100 ' src 'http www.platipus.nl flvplayer download 1.0 FLVPlayer.swf fullscreen true video @VIDEO@' autoplay.. flash' pluginspage 'http www.macromedia.com go getflashplayer' String htmlPost body html @Override public void onCreate Bundle.. can confirm that the flash plugin does load and the movie player does intilaize with the swirly shape graphic. I can engage it..
Android MediaPlayer works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions http://stackoverflow.com/questions/8671479/android-mediaplayer-works-fine-in-custom-audio-streaming-application-up-to-andro throws the error. 3 The error is Unable to to create media player Other Solution tried I tried below alternate solution but nothing.. 4 markmail.org LogCat trace Unable to to create media player Error copying buffered conent. java.lang.NullPointerException.. Native Method android audio audio streaming android mediaplayer shoutcast share improve this question The StreamingMediaPlayer..
Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one http://stackoverflow.com/questions/8681550/android-2-2-mediaplayer-is-working-fine-with-one-shoutcast-url-but-not-with-the works with Android 2.2 or higher . Thanks android media player uri audio streaming shoutcast share improve this question.. the device to capture the stream and pass it to the audioplayer just like NPR does. audio aacp streaming is not supported directly..
android app with service only http://stackoverflow.com/questions/990217/android-app-with-service-only service shouldn't be stopped this was added mainly for mp3 player type services that have to keep running but can be used by any..
MediaPlayer error (1, -1004) aka MEDIA_ERROR_IO trying to stream music on Samsung S3 http://stackoverflow.com/questions/16672568/mediaplayer-error-1-1004-aka-media-error-io-trying-to-stream-music-on-samsun error 1 1004 aka MEDIA_ERROR_IO trying to stream music on Samsung.. on the S3 I've been able to figure out that the Media Player object goes into the Error state due to MEDIA_ERROR_UNKOWN great... this in onError with an OnErrorListener I reset the Media Player object and then call startPlaying which does the rest setting..
android: how do i use the progress bar? http://stackoverflow.com/questions/2967337/android-how-do-i-use-the-progress-bar to be a bar not a circle and how would i use it with MediaPlayer thanks android progress bar media player share improve this.. and this is an example with MediaPlayer package com.playerpgbar import android.app.Activity import android.media.MediaPlayer.. import android.app.Activity import android.media.MediaPlayer import android.os.Bundle import android.view.View import android.view.View.OnClickListener..
How do I pause Flash content in an Android WebView when my activity isn't visible? http://stackoverflow.com/questions/3431351/how-do-i-pause-flash-content-in-an-android-webview-when-my-activity-isnt-visibl The documentation for the mobile Flash player says Flash Player will also automatically pause SWF playback it is not in view..
How to embed a YouTube clip in a WebView on Android http://stackoverflow.com/questions/3458765/how-to-embed-a-youtube-clip-in-a-webview-on-android
WebView and HTML5 <video> http://stackoverflow.com/questions/3815090/webview-and-html5-video to get back to the web view. public void onCompletion MediaPlayer mp Log.d TAG Video completo a.setContentView R.layout.main WebView.. play inside the WebView frame instead of opening the Media Player window but this is for me a secondary issue. I hope it helps..
Extending Application to share variables globally http://stackoverflow.com/questions/4572338/extending-application-to-share-variables-globally public class GlobalVars extends Application ArrayList Player players new ArrayList Player ArrayList String playerNames new.. extends Application ArrayList Player players new ArrayList Player ArrayList String playerNames new ArrayList String public ArrayList.. String playerNames new ArrayList String public ArrayList Player getPlayers return players public ArrayList String getPlayerNames..
HTML5 <audio> tag on Android http://stackoverflow.com/questions/4895188/html5-audio-tag-on-android well . The only problem is that on some phones the Flash Player is not reinstalled and must be downloaded from Android Market.. that such a simple thing is a problem. Using the Flex Player is okey but the problem is that on some phones the Adobe Flash..
Screen blinking when using a webview with flash http://stackoverflow.com/questions/5095977/screen-blinking-when-using-a-webview-with-flash ANSWER ADDED LATER So the problem is that Adobe's Flash Player creates a SurfaceView inside the WebView and there is a delay..
Android MediaPlayer works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions http://stackoverflow.com/questions/8671479/android-mediaplayer-works-fine-in-custom-audio-streaming-application-up-to-andro MediaPlayer works fine in Custom audio Streaming application up to Android.. 2.1 but not in higher versions EDIT Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other.. local temporary storage. i am using the StreamingMediaPlayer class . Check this piece of code private MediaPlayer createMediaPlayer..
Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one http://stackoverflow.com/questions/8681550/android-2-2-mediaplayer-is-working-fine-with-one-shoutcast-url-but-not-with-the 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other.. android.media.AudioManager import android.media.MediaPlayer import android.net.Uri import android.os.Bundle import android.util.Log.. class SimpleMusicStream extends Activity implements MediaPlayer.OnCompletionListener MediaPlayer.OnPreparedListener MediaPlayer.OnErrorListener..
Media Player called in state 0, error (-38,0) http://stackoverflow.com/questions/9008770/media-player-called-in-state-0-error-38-0 Player called in state 0 error 38 0 I am currently trying to design.. I have the URL for the station and am setting up the Media Player like MediaPlayer mediaPlayer new MediaPlayer try mediaPlayer.setDataSource.. the station and am setting up the Media Player like MediaPlayer mediaPlayer new MediaPlayer try mediaPlayer.setDataSource URL..
YouTube Video not playing in WebView - Android http://stackoverflow.com/questions/12708890/youtube-video-not-playing-in-webview-android html getHTML wv.loadDataWithBaseURL html mimeType encoding public String getHTML String html iframe class youtube player style border 0 width 100 height 95 padding 0px margin 0px id ytplayer type text html src http www.youtube.com embed J2fB5XWj6IE.. String getHTML String html iframe class youtube player style border 0 width 100 height 95 padding 0px margin 0px id ytplayer type text html src http www.youtube.com embed J2fB5XWj6IE fs 0 frameborder 0 n iframe n return html android video youtube..
Android: Override back button to act like home button http://stackoverflow.com/questions/2000102/android-override-back-button-to-act-like-home-button music in the Music application and then presses BACK the application overrides the normal back behavior preventing the player activity from being destroyed and continues playing music even though its activity is no longer visible How do I replicate.. to perform something in the background and your visible Activity simply controls this Service . I'm sure the Music player works in the same way so the example in the docs seems a bit misleading. If that's the case then your Activity can finish..
Determining the current foreground application from a background task or service http://stackoverflow.com/questions/2166961/determining-the-current-foreground-application-from-a-background-task-or-service ComponentName activity activity can be null in cases where one app starts another. for example astro starting rock player when a move file was clicked. we dont have an activity then but the package exits as soon as back is hit. so we can ignore..
Streaming video from Android camera to server http://stackoverflow.com/questions/2550847/streaming-video-from-android-camera-to-server
Play audio file from the assets directory http://stackoverflow.com/questions/3289038/play-audio-file-from-the-assets-directory file from the assets directory I have the following code AssetFileDescriptor afd getAssets .openFd AudioFile.mp3 player new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare player.start The problem is that when I run this.. directory I have the following code AssetFileDescriptor afd getAssets .openFd AudioFile.mp3 player new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare player.start The problem is that when I run this code it starts playing.. afd getAssets .openFd AudioFile.mp3 player new MediaPlayer player.setDataSource afd.getFileDescriptor player.prepare player.start The problem is that when I run this code it starts playing all the audio files in the assets directory..
Android: keeping a background service alive (preventing process death) http://stackoverflow.com/questions/3856767/android-keeping-a-background-service-alive-preventing-process-death a concern. The is primarily intended for when killing the service would be disruptive to the user e.g. killing a music player service would stop music playing. You'll need to supply a Notification to the method which is displayed in the Notifications..
Android “Only the original thread that created a view hierarchy can touch its views.” http://stackoverflow.com/questions/5161951/android-only-the-original-thread-that-created-a-view-hierarchy-can-touch-its-vi &ldquo Only the original thread that created a view hierarchy can touch its views.&rdquo I've built a simple music player in Android. The view for each song contains a SeekBar implemented like this public class Song extends Activity implements..
Problem to load flv video in webview http://stackoverflow.com/questions/6596243/problem-to-load-flv-video-in-webview 0 pading 0 background color black ' String htmlCode embed style 'width 100 height 100 ' src 'http www.platipus.nl flvplayer download 1.0 FLVPlayer.swf fullscreen true video @VIDEO@' autoplay 'true' quality 'high' bgcolor '#000000' name 'VideoPlayer'.. ' ' allowFullScreen 'true' type 'application x shockwave flash' pluginspage 'http www.macromedia.com go getflashplayer' String htmlPost body html @Override public void onCreate Bundle savedInstanceState super.onCreate savedInstanceState setContentView.. You don't state clearly what your Android version however I can confirm that the flash plugin does load and the movie player does intilaize with the swirly shape graphic. I can engage it into fullscreen mode. I am also able to play online video..
Android MediaPlayer works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions http://stackoverflow.com/questions/8671479/android-mediaplayer-works-fine-in-custom-audio-streaming-application-up-to-andro 2 The mPlayer.setDataSource fis.getFD is the line which throws the error. 3 The error is Unable to to create media player Other Solution tried I tried below alternate solution but nothing worked so far. Android 2.2 MediaPlayer is working fine.. a lot of questions on this site but i found the answer no where. 4 markmail.org LogCat trace Unable to to create media player Error copying buffered conent. java.lang.NullPointerException com.ms.iradio.StreamingMediaPlayer.startMediaPlayer StreamingMediaPlayer.java.. ZygoteInit.java 597 dalvik.system.NativeStart.main Native Method android audio audio streaming android mediaplayer shoutcast share improve this question The StreamingMediaPlayer class is using a double buffering technique to get around..
Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one http://stackoverflow.com/questions/8681550/android-2-2-mediaplayer-is-working-fine-with-one-shoutcast-url-but-not-with-the current code works with Android 2.1 minor versions but not works with Android 2.2 or higher . Thanks android media player uri audio streaming shoutcast share improve this question Shoutcast mp3 streaming from Android 2.2 onwards is supported.. using a proxy on the stream end or a stream proxy class on the device to capture the stream and pass it to the audioplayer just like NPR does. audio aacp streaming is not supported directly . For this you can use ffmpeg opencore or faad2 library..
android app with service only http://stackoverflow.com/questions/990217/android-app-with-service-only in your service onCreate to tell Android that your service shouldn't be stopped this was added mainly for mp3 player type services that have to keep running but can be used by any service. Make sure you add the proper permissions for the..
MediaPlayer error (1, -1004) aka MEDIA_ERROR_IO trying to stream music on Samsung S3 http://stackoverflow.com/questions/16672568/mediaplayer-error-1-1004-aka-media-error-io-trying-to-stream-music-on-samsun error 1 1004 aka MEDIA_ERROR_IO trying to stream music on Samsung S3 Our application has to stream music from from an online.. that source . Why does it take over 2 minutes to start streaming on the S3 I've been able to figure out that the Media Player object goes into the Error state due to MEDIA_ERROR_UNKOWN great. Doesn't help me much. So upon handling this in onError.. great. Doesn't help me much. So upon handling this in onError with an OnErrorListener I reset the Media Player object and then call startPlaying which does the rest setting the data source etc. Members private ProgressBar playSeekBar..
android: how do i use the progress bar? http://stackoverflow.com/questions/2967337/android-how-do-i-use-the-progress-bar an actual bar. How do i change the style of the ProgressBar to be a bar not a circle and how would i use it with MediaPlayer thanks android progress bar media player share improve this question set style android attr progressBarStyleHorizontal.. ProgressBar android id @ id progressBar style android attr progressBarStyleHorizontal and this is an example with MediaPlayer package com.playerpgbar import android.app.Activity import android.media.MediaPlayer import android.os.Bundle import android.view.View.. and this is an example with MediaPlayer package com.playerpgbar import android.app.Activity import android.media.MediaPlayer import android.os.Bundle import android.view.View import android.view.View.OnClickListener import android.widget.Button..
How do I pause Flash content in an Android WebView when my activity isn't visible? http://stackoverflow.com/questions/3431351/how-do-i-pause-flash-content-in-an-android-webview-when-my-activity-isnt-visibl I should be trying in regard to Window or View management The documentation for the mobile Flash player says Flash Player will also automatically pause SWF playback it is not in view or the foreground application for example when a call is received..
How to embed a YouTube clip in a WebView on Android http://stackoverflow.com/questions/3458765/how-to-embed-a-youtube-clip-in-a-webview-on-android
WebView and HTML5 <video> http://stackoverflow.com/questions/3815090/webview-and-html5-video onCompletion and the onError events for the video in order to get back to the web view. public void onCompletion MediaPlayer mp Log.d TAG Video completo a.setContentView R.layout.main WebView wb WebView a.findViewById R.id.webview a.initWebView.. play button it does nothing. I would also like the video to play inside the WebView frame instead of opening the Media Player window but this is for me a secondary issue. I hope it helps somebody and I would also thank any comment or suggestion...
Extending Application to share variables globally http://stackoverflow.com/questions/4572338/extending-application-to-share-variables-globally How to declare global variables . Here's my application subclass public class GlobalVars extends Application ArrayList Player players new ArrayList Player ArrayList String playerNames new ArrayList String public ArrayList Player getPlayers return.. . Here's my application subclass public class GlobalVars extends Application ArrayList Player players new ArrayList Player ArrayList String playerNames new ArrayList String public ArrayList Player getPlayers return players public ArrayList String.. ArrayList Player players new ArrayList Player ArrayList String playerNames new ArrayList String public ArrayList Player getPlayers return players public ArrayList String getPlayerNames return playerNames public void setPlayers ArrayList Player..
HTML5 <audio> tag on Android http://stackoverflow.com/questions/4895188/html5-audio-tag-on-android the HTML web page Flex Javascript communication works pretty well . The only problem is that on some phones the Flash Player is not reinstalled and must be downloaded from Android Market first. Added even later Well the audio element is buggy even.. buggy even on Android 2.3 I do not know what are doing in Google that such a simple thing is a problem. Using the Flex Player is okey but the problem is that on some phones the Adobe Flash player cannot be installed from Android market because there..
Screen blinking when using a webview with flash http://stackoverflow.com/questions/5095977/screen-blinking-when-using-a-webview-with-flash webview flash player share improve this question THIS ANSWER ADDED LATER So the problem is that Adobe's Flash Player creates a SurfaceView inside the WebView and there is a delay between the SurfaceView appearing and the Flash engine bothering..
Android MediaPlayer works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions http://stackoverflow.com/questions/8671479/android-mediaplayer-works-fine-in-custom-audio-streaming-application-up-to-andro MediaPlayer works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions EDIT Android 2.2 MediaPlayer.. works fine in Custom audio Streaming application up to Android 2.1 but not in higher versions EDIT Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one I need to play audio files from external URLs shoutcast.. incrementally are played as soon as we get enough audio in phone local temporary storage. i am using the StreamingMediaPlayer class . Check this piece of code private MediaPlayer createMediaPlayer File mediaFile throws IOException MediaPlayer mPlayer..
Android 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one http://stackoverflow.com/questions/8681550/android-2-2-mediaplayer-is-working-fine-with-one-shoutcast-url-but-not-with-the 2.2 MediaPlayer is working fine with one SHOUTcast URL but not with the other one Please see the code i am using for streaming shoutcast.. SimpleMusicStream.java import android.app.Activity import android.media.AudioManager import android.media.MediaPlayer import android.net.Uri import android.os.Bundle import android.util.Log import android.view.View import android.widget.Button.. import android.view.View import android.widget.Button public class SimpleMusicStream extends Activity implements MediaPlayer.OnCompletionListener MediaPlayer.OnPreparedListener MediaPlayer.OnErrorListener MediaPlayer.OnBufferingUpdateListener private..
Media Player called in state 0, error (-38,0) http://stackoverflow.com/questions/9008770/media-player-called-in-state-0-error-38-0 Player called in state 0 error 38 0 I am currently trying to design a simple app that streams an internet radio station. I have.. design a simple app that streams an internet radio station. I have the URL for the station and am setting up the Media Player like MediaPlayer mediaPlayer new MediaPlayer try mediaPlayer.setDataSource URL catch IllegalArgumentException e e.printStackTrace.. that streams an internet radio station. I have the URL for the station and am setting up the Media Player like MediaPlayer mediaPlayer new MediaPlayer try mediaPlayer.setDataSource URL catch IllegalArgumentException e e.printStackTrace catch SecurityException..
|