Radio Streaming in Blackberry

穿精又带淫゛_ 提交于 2020-01-06 20:16:22

问题


I am a iphone/android developer, and now trying hands on Blackberry.

Need guidance in streaming radio url in blackberry.

need some resources , links to play radio streaming in blackberry.

Appreciate it.


回答1:


I think the link will help you,there is a sample zip file also http://supportforums.blackberry.com/t5/Java-Development/Streaming-media-Start-to-finish/ta-p/488255

And if you get a url you can directly give the url to Player object,Blackberry support almost all type of media files.

private void invokeMediaPlayer(String url){

        try {
            player = javax.microedition.media.Manager.createPlayer(url);
            player.realize();
            volume = (VolumeControl)player.getControl("VolumeControl");
            volume.setLevel(40);
            player.prefetch();
            player.start();
            player.addPlayerListener(this);    
           /* metaDataTrimmed = inner.getMetaData1();
            System.out.println(metaDataTrimmed);*/

        } catch (IOException e) {           
            e.printStackTrace();
        } catch (MediaException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    }


来源:https://stackoverflow.com/questions/5577795/radio-streaming-in-blackberry

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!