Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 41
Registered: ‎07-22-2009
My Device: 9850 Torch 2
My Carrier: Sprint

Unable to play any videos after I record a video from my application using the Player API ...

[ Edited ]

I have an application whereby part of the functionality is to record a short (about 15 seconds) video using the Player object from the javax.microedition.media package.  The problem is after I have recorded my video if I try to use any other application on the handset that is designed to view the file I receive a "Cannot play media while third party video recording is active" error message.

 

At this point I'm NOT recording anything.  In fact, my application isn't even running at that point.  I have to pull the battery for it to allow me to play any videos again.  Once I do pull and replace the battery all videos ... mine included ... play normally.  It's almost like the Player object isn't getting cleaned up properly or something.

 

My screen's close() method has the following code, which I have verified is getting called and there are no exceptions being thrown:

 

 

if (videoPlayer != null)

{

      videoPlayer.stop();

      videoPlayer.deallocate();

      videoPlayer.close();

}

videoPlayer = null;

 

From what I have seen in the documentation, including the sample application "VideoRecordingDemo" this should all work just fine, but like I said above the only way I can get any video to play (and I think this is effecting sound files too .... so, I guess you could say "any media") to play is by pulling/replacing the battery on the handset.

 

By the way, the handset is a Torch 2 with Sprint (pretty sure that's not the issue).

 

Any ideas or suggestions would be greatly appreicated.

 

Thank you.

 

 

Just a quick edit .......... if I go into the Camera application on the handset (after unsuccessfully attempting to play any videos) this fixes the problem .... would love to know what RIM is doing in the Camera application that allows the video to work again without having to pull the battery.

New Contributor
Posts: 3
Registered: ‎11-19-2012
My Device: Blackberry 9380
My Carrier: Airtel

Re: Unable to play any videos after I record a video from my application using the Player API ...

Hi,

I was wondering if anyone has a solution to this problem. I am having the same problem. This is happening when I am trying to close video player after 10s and saving and closing the recording screen. I was not able to find a solution even after working on the same issue for 2 weeks. Any help would be appreciated.

 

Thanks,

 

Lanka

Highlighted
Developer
Posts: 41
Registered: ‎07-22-2009
My Device: 9850 Torch 2
My Carrier: Sprint

Re: Unable to play any videos after I record a video from my application using the Player API ...

I never did hear from anyone, nor did I solve it myself.  Frankly, I ended up having to use the built-in video recording application instead.  Though, I appreciate how RIM's video applet is more sophisticated and "polished" than what I had the budget to produce the issue is you do not have complete control over it the way you would if it were your code executing .... such as limiting the the recording either by memory consumed or recording time.

 

Things like this are party what has allowed RIM to slip so drastically in the marketplace .... I don't mean the fact that there might be a bug, but that you cannot get help on it.  Android, iOS, and even Windows are platforms whereby answers are readily available.

 

Sorry to hear you stumbled across this same issue ...