I have sqlite database within online radio url's and get it from bundle and try to play with media player classes. But i have had error codes which below.... Can you help me.....
Bundle bundle = getIntent().getExtras();
String getUrl = bundle.getString("UrlAdress");
Toast.makeText(getApplicationContext(), getUrl, Toast.LENGTH_LONG)
.show();
player = new MediaPlayer();
player.setAudioStreamType(AudioManager.STREAM_MUSIC);
player.setDataSource(getUrl);
player.prepareAsync();
player.setOnPreparedListener(new OnPreparedListener() {
@Override
public void onPrepared(MediaPlayer mp) {
// TODO Auto-generated method stub
player.start();
}
});
**09-05 08:31:53.094: W/EGL_genymotion(2503): eglSurfaceAttrib not implemented 09-05 08:31:53.118: W/ViewRootImpl(2503): Dropping event due to no window focus: KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_ALT_RIGHT, scanCode=100, metaState=META_ALT_ON|META_ALT_RIGHT_ON, flags=0x8, repeatCount=38480, eventTime=3580018, downTime=1536745, deviceId=1, source=0x301 } 09-05 08:31:53.122: W/ViewRootImpl(2503): Dropping event due to no window focus: KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_ALT_RIGHT, scanCode=100, metaState=META_ALT_ON|META_ALT_RIGHT_ON, flags=0x8, repeatCount=38481, eventTime=3580069, downTime=1536745, deviceId=1, source=0x301 } 09-05 08:31:53.126: W/ViewRootImpl(2503): Dropping event due to no window focus: KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_ALT_RIGHT, scanCode=100, metaState=META_ALT_ON|META_ALT_RIGHT_ON, flags=0x8, repeatCount=38482, eventTime=3580125, downTime=1536745, deviceId=1, source=0x301 } 09-05 08:31:56.266: E/MediaPlayer(2503): error (1, -2147483648) 09-05 08:31:56.266: E/MediaPlayer(2503): Error (1,-2147483648) 09-05 08:34:29.714: E/MediaPlayer(2503): error (1, -2147483648) 09-05 08:34:29.714: E/MediaPlayer(2503): Error (1,-2147483648) 09-05 08:41:25.334: D/dalvikvm(2503): GC_FOR_ALLOC freed 2260K, 12% free 18472K/20796K, paused 10ms, total 18ms 09-05 08:41:25.334: W/MediaPlayer-JNI(2503): MediaPlayer finalized without being released
**
0 comments:
Post a Comment