android-visualizer icon indicating copy to clipboard operation
android-visualizer copied to clipboard

Link mediaplayer in background service?

Open vankhoadesign opened this issue 11 years ago • 5 comments

I has app, I want to use visualizer, But mediaplayer in service, I can't link it with visualize on activity? Please help me. THanks pro.

vankhoadesign avatar Jun 29 '14 08:06 vankhoadesign

Sorry. I don't know. But your project is very good

------------------ 原始邮件 ------------------ 发件人: "Khoa Nguyen";[email protected]; 发送时间: 2014年6月29日(星期天) 下午4:43 收件人: "felixpalmer/android-visualizer"[email protected];

主题: [android-visualizer] Link mediaplayer in background service? (#10)

I has app, I want to use visualizer, But mediaplayer in service, I can't link it with visualize on activity? Please help me. THanks pro.

— Reply to this email directly or view it on GitHub.

longtaoge avatar Jun 29 '14 15:06 longtaoge

Try to pass the reference of the VisualizerView at the service and execute the ".link()" there, it worked nice for me.

impex93 avatar Jan 19 '15 12:01 impex93

Can you please describe how we can pass the VisualizerView reference to the service? I tried sending it as parcelable and serilizable in a bundle from the activity to the service. But unfortunately VisualizerView cannot be cast to either of them.

opnchaudhary avatar Dec 04 '15 08:12 opnchaudhary

I know that this is a bit dirty bit you could write a method that return the instance of the VisualizerView and then call it from the service, let me know!

Il giorno 04 dic 2015, alle ore 09:20, Paras Nath Chaudhary [email protected] ha scritto:

Can you please describe how we can pass the VisualizerView reference to the service? I tried sending it as parcelable and serilizable in a bundle from the activity to the service. But unfortunately VisualizerView cannot be cast to either of them.

— Reply to this email directly or view it on GitHub.

impex93 avatar Jan 15 '16 22:01 impex93

I had the same issue, I discovered that when I'm referring to VisualizerView in service initialization, every think works as it supposed to. Sorry but I'm just beginning my journey with Android. Maybe this is not the best solution, and I'm pretty sure that there is a better one but it works for me. I'm writing allow application with music player as a service. This solution works perfectly for my.

Misiorator21 avatar Jan 16 '16 22:01 Misiorator21