Custom player DataSource without possible RTSP streaming?

Dear people,

everyone SUCCEEDS with Manager.createPlayer (source of data source)
with the data source customized with real audio STREAMING?
I mean without using the "rtsp: / / ' locator, just feed the player with your data buffer, which is more...

Example of the RIM is downloading the full file first is nothing new compared to the default behavior of the reader (read full datafile before playing; I understand that it could get in the J2ME standard, but then these methods makes no sense

When I try to read an audio stream (audio/amr) I see that the Player tries to put first the cached data (called read() length from 58000 until my current buffer size), the computer begins to play (the role he was able to buffer at the beginning) but ends by with code 5 error what Unspecified «» : an error has occurred which does not fit into another category. »

It looks like you are not conform to the contract of the SourceStream.read method. First of all, if currentPosition + len > stream.size (), and then you return stream.size () rather than the () - currentPosition bytes stream.size bytes. Second, if currentPosition + len<= stream.size(),="" you're="" returning="" the="" right="" bytes="" for="" the="" first="" time,="" but="" then="" you="" don't="" appear="" to="" be="" updating="" the="" currentposition="" variable="" --="" so,="" if="" the="" condition="" is="" still="" true="" on="" the="" next="" read,="" you're="" returning="" the="" same="" frames="" as="" last="" time="" causing="" the="" user="" to="" hear="" a="">

Here is how the read method should look like (minus the part blocking when no data is available and less-1 or EOFException when the SourceStream is closed or stopped)-I have tried compiling or running it though:

public int read(byte[] b, int off, int len) throws IOException {  if (len < 1) {    return 0;  }

  final int streamSize = stream.size();  final int currentPosition = (int) this.currentPosition;  final int bytesToReturn = Math.min(streamSize - currentPosition, len);  if (bytesToReturn < 1) {    // TODO: Need to block here on the stream until some bytes are available    return 0;  }

  System.arraycopy(stream.getByteArray(), currentPosition, b, off, bytesToReturn);  currentPosition += bytesToReturn;   return bytesToReturn;}

PS Examples of RIM (do not remember those who) have a shared stream in which a son written data and another thread reads the data from. This may be another (simpler) solution to your problem, your reading will be a one-liner: return sharedStream.read (b, off, len).

Tags: BlackBerry Developers

Similar Questions

  • How LinkSys WRT54G v7 supports RTSP streaming service?

    Hello

    I use the LinkSys WRT54G v7 and I can see the RTSP videos using VLC player to m.youtube.com. Strangely, I can't play videos if another AP as the DLINK is used instead of LinkSys.

    I analyzed packages and discovered that RTSP server (youtube) sends RTP packets to the ports of the client which are acquired to the RTSP SETUP procedures. Then the Server packets cannot reach the customer because the hole of the UDP is not perforated to the AP.

    But, when I use the LinkSys, RTP packets can cross the NAT.

    That is my question. LinkSys offers NAT traversal for RTSP streaming service? So, why can't find a list of features on this subject from the LinkSys product information? No explanation for this?

    Thank you in advance for your help!

    1. None of the NAT helpers in the Linksys firmware are documented anywhere.

    2. If possible, they added a helper for RTP.

    3. it could also be that VLC player in front of the port with UPnP.

  • Is it possible to stream DVD of ICloud instead of iTunes home sharing via my computer?

    I would like to be able to download my DVD somehow so I can play them all Apple TV (gen 4) instead of airplaying them or having to maintain the computer to share the home of my iTunes (latest version). As it is, if I want to watch a DVD, downloaded on my Apple TV I must select COMPUTERS and go into my library to select the movie and then keep my computer over time. I managed to download a DVD on my Icloud player hoping to be able to stream the DVD from there nothing doesn't. I do not understand why this is the case and am unable to find any resources that explain the case however, I'm rather new to all this and perhaps, I not looking in the right places. Second of all, why can't I just go to the MOVIES on Apple TV and find them there with the rest of my movies as opposed to strictly buy films he and others else where; they are all good movies? Put them in the category FILM (it is more a problem of Apple, I guess). Is it possible to stream my DVDs to iCloud instead of iTunes home sharing via my computer? Any information or guidance would be appreciated thank you for taking the time to answer my questions.

    When you look at the top row of the applications the homescreen are apps from iTunes Store.

    So the only films - purchased are one you purchesed from iTunes. It is the same for other applications in the same row.

    Focus on Plex to broadcast your own films as an alternative to the use of computers on the Apple TV.

  • Record audio RTSP stream

    OK im trying to automate a test audio on an IP video encoder. I can find the location of rtsp stream but im not sure were to start on the recovery of the stream. I have VLC playing the flow... I suppose I could run a vlc command line to record a second stream 5? then open the file for evaluation? What I want is direct stream copy in labview, so that I do not need 3rd party tools installed.

    Maybe a .net call for that would help me?

    Thanks in advance.

    -Corey


  • CD Player Help - without a disc in the reader msg trying to write a file in a new CD

    Original title: cd player help - without a disc in the reader msg

    CD player help - I have xp prof and get msg, no disc in drive for insert, when I try to save the file to a cd.  It is only on a new cd. I have a cd that I saved info in in the past and if I put this cd in the player it will open and I am able to write to her, but every time I try a new cd the msg comes that there is no cd in the drive. This has also happened when I put a dvd in the drive, it does not open it.  -confused and need easy to understand help. Thank you

    Thanks for the comments.  At least you things partially market.

    My guess is that it is your hardware which is a failure rather than a software problem.

    You can read these two articles Wikipedia: CD-R and CD-RW

  • When you use the media player, it is possible to take a song that's already torn in our library and announced another song or part of the same song at the end? kinda like a mix.

    When you use the media player, it is possible to take a song that's already torn in our library and announced another song or part of the same song at the end? kinda like a mix.

    Windows Media Player is not a Publisher.

    You can use Windows Movie Maker to split
    and combine audio files, but it works better
    If they are in the. WMA format.

    Also the free Audacity software may be worth a try:

    (FWIW... it's always a good idea to create a system)
    Restore point before installing software or updates)

    Audacity

    http://Audacity.sourceforge.NET/

    How to split a long recording into multiple files or CD tracks?
    http://Audacity.sourceforge.NET/Help/FAQ?s=files&i=split

    How to combine two files into one longer file?
    http://Audacity.sourceforge.NET/Help/FAQ?s=editing&i=join

    How to mix songs with Audacity
    http://www.ehow.com/how_5061510_mix-songs-audacity.html

  • Cannot play RTSP streams, or another video with MediaPlayer

    Hi, I started working with the Mediaplayer and have problems. My first test was to load a rtsp stream, but it does not work. I'm trying to open a video of playbook and it does not work. I've added to my blackberry - tablet.xml following actions

    access_shared

    access_internet

    PLAY_AUDIO

    And try out it on my (real device, no Simulator) playbook. It does not work. I always get the errornumber '10' which means that media can not open (RIM thank you for this useful error ). I have attached my code in this post. You can see what the problem with it?

    concerning

    
    http://ns.adobe.com/mxml/2009"
            xmlns:s="library://ns.adobe.com/flex/spark"
            xmlns:qm="qnx.media.*"
            creationComplete="init()">
    
        
            
            
        
    
        
            
        
    
        
            
            
        
    
        
    
    
    

    Response of RIM today.

    RTSP is not supported. The documentation does not in this aspect.

  • How can I update my credit card information to pay for the next tranche of creative cloud when it tells me that I have "Creative Cloud Free Membership" so without possibility to update a credit card - despite my payment for a slice of 1 year in January 20

    How can I update my credit card information to pay for the next tranche of creative cloud when the screen tells me that I have "Creative Cloud Free Membership" so without possibility to update a credit card - despite my payment for a slice of 1 year in January 2015?

    Hi kanikas100,

    Using my old Email to open a session allowed me to see my current subscription and I was able to update my credit card.   Thank you very much!

  • How to create the new Custom XML report without the use of the form builder

    Hello

    What are the steps to create the new Custom XML report without using the Report Builder?

    Thank you and best regards,
    Aerts

    Aerts,
    Can you clarify your question more away!

    -bifacts
    http://www.obinotes.com

  • Custom player skins?

    Hello, I'm working on creating a flash animation to be displayed on a Web page and I wonder if there are options out there to create a custom Player skin?

    I've never tried create a look, but I was wondering if Flash has given you all the options for this or if there's a different Adobe software that you would suggest?

    Thanks a lot for your help!

    Found my answer thanks!

  • Does player appears without inserting memory Satellite C650-129

    Hi all?

    I noticed that before I repair my HARD drive it has reserved 100 MB system & when I installed win 7.
    I checked in the device under Disk Manager 2 drivers one for my own drive HARD & second reader.

    I partitioned my HARD drive & deleted this 100 MB dedicated 4 systems & when I reinstalled Win 7 & install all the drivers for the drive are not in the computer, but when I insert a memory card there appears only.

    My question is; Does player appears all the time without inserting the memory into the computer & if this right how do I get 100 MB which reserved system & make my drive appears in the computer without inserting memory?

    I hope an answer bit for important thx

    Hello

    > My question is; Does player appears all the time without inserting the memory into the computer
    Card reader appears in my computer only if the memory (SD, SDHC card, multimedia card) card has been inserted.

    > How can I get 100 MB reserved for the system & make my drive appears in the computer without inserting memory?
    I assume you mean the partition if you deleted this partition, then you can get back the fact that the restoration of the system (System Recovery).

    I'm not sure if your drive HARD recovery option would still work if you have installed Windows 7 on the laptop. The system preinstalled by Toshiba usually contains a HARD drive recovery that allows to recover the laptop to factory settings.
    Press F8, choose fix my computer-> drive HARD recovery.
    This service as with Toshiba preinstalled image

    If you have changed the partitions on the HARD drive, then HARD drive recovery may not be available more. In this case, you will need to use the recovery disc.
    Did you create recovery disc at the beginning? Isn't it? Well, in this case you must order the disc here form:
    https://backupmedia.Toshiba.EU/landing.aspx

  • Qosmio G40 using as HD-DVD HDMI player on TV - possible?

    Is it possible to use G40 as HD-DVD player connecting via the HDMI interface on TV (individual Loewe)?
    Tried, but from HD-DVD player, error message, cannot use the interface.

    Hey mate, thanks for the beautiful ´bout tutorial linking the Qosmio on a LCD screen. It s really useful and a lot of people would appreciate it. :)

    Wish you a nice weekend and many greetings

  • Media Player 11 plays a video streaming to left side but can not display the overview

    I have Windows XP and have Windows Media Player 11 for quite awhile with no problems at all. Suddenly, my player goes immediately to the toolbar on the left tray low down. He reads the stream or the video, I can hear it but I can't optimize the image using the right click.  I deleted my 11 Windows and re-installed but nothing... Could you help out me? Thanks to you all

    Hi Evantha,

    I'm sorry to hear that you are facing this problem with the computer. I will do my best to get the problem solved. However, before I'll have to ask troubleshooting questions.

    1. When was the last time that the player was working fine?

    2. How did you remove Windows Media player?

    3. are you aware of any recent software or the hardware in the computer changes?

    You can go through the article and check if it helps. Here is another article with more information about the player.

    You can also go through this article and check if it helps. If the problem persists you can Uninstall and then reinstall the drive and check.

    Hope this helps and provide us more information if you need more assistance. We will be happy to help you.

  • No sound from Internet Explorer / Sound of ok media with USB speakers player and without.

    Please can someone help... I am running Vista Home premium on a Toshiba Satellite Pro A200 series. I ran diagnostics and any other thing, I see... I can get good sound play anything through Media Player... But no Internet Explorer sounds... makes no difference with or without USB speakers. Have upgraded to IE 8 to IE 7 - not make a difference.

    I just encountered this problem but luckily managed to solve it easily. I got guitar pro running playing sound normally and IE wasn't when you run simultaneously. I closed gp and IE worked as usual. I didn't know this before with these two programs, but I would say that if you have this problem try closing unnecessary programs and restart ie.

  • RTSP streaming

    Hi, I'm trying to stream videos a Nokia E71 since my WVC54GCA. It gets almost but expires on the server. Any help appreciated.

    I have the same problem.  I already have the latest firmware installed V100R24.  I'm trying to access the mobile video via RTSP on my BlackBerry Bold 9000, which is capable of RTSP (accesses RTSP on m.youtube.com).  I opened all the ports (554, 5000-5010 etc.).  Seems that the webcam is regestering the rtsp request (see the comments of my webcam connect 2008-12-29 19:02:25 RTSP: start of Streaming (video, UDP: 192.168.1.11:5002-> 32.149.239.244:6970, anonymous).)  I ran out of ideas to make it work.  Any suggestions?

Maybe you are looking for