yixia / Vitamio-iOS

Vitamio for iOS
http://www.vitamio.org/en/
451 stars 176 forks source link

No audio after a few seconds if do not pause when bufferingStart and play when bufferingEnd #5

Open vminc opened 10 years ago

vminc commented 10 years ago

Related to #3 I reopened since the problem isn't solved by using VMDecodingSchemeQuickTime as mentioned in #3.

Here's the stream I used to test: rtmp://113.161.212.25/live/atv1

The issue is if I don't pause the player in bufferingStart, and start the player in bufferingEnd, the audio will be gone after a while.

(void)mediaPlayer:(VMediaPlayer *)player bufferingStart:(id)arg { [player pause]; }

(void)mediaPlayer:(VMediaPlayer *)player bufferingEnd:(id)arg { [player start]; }

If I choose to pause, start the player like above, then the video is not played as smooth as compared to Vitamio for Android. It stops very often for buffering. The buffer size I used is 200 000.

ghost commented 8 years ago

Same issue, i am facing in android device. Please help. Below is my code: try{ Log.v("APP","app launched in"); /* Start audio streaming */ try { vmPlayer.setDataSource("rtsp://219.65.90.226:1935/app1/myStream"); vmPlayer.prepare(); } catch (IllegalArgumentException e1) { e1.printStackTrace(); } catch (SecurityException e1) { e1.printStackTrace(); } catch (IllegalStateException e1) { e1.printStackTrace(); } catch (IOException e1) { e1.printStackTrace(); } vmPlayer.setBufferSize(1000); vmPlayer.start();

        }catch(Exception e){
            e.printStackTrace();
            result = "fail";
        }