Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buffering lenght #31

Closed
dproni opened this issue Nov 16, 2015 · 4 comments
Closed

Buffering lenght #31

dproni opened this issue Nov 16, 2015 · 4 comments
Milestone

Comments

@dproni
Copy link

dproni commented Nov 16, 2015

Hi guys, thank you for nice plugin for nice player. Could you please explain how could I set buffering size or rtmp stream.

Thank you

@gfronza
Copy link
Collaborator

gfronza commented Dec 2, 2015

Hi @kurdd. Last week we pushed a new version of the plugin. Now you can set the bufferTime on the options:

var player = new Clappr.Player({
    source: "rtmp://source_here",
    parentId: "#player-wrapper",
    plugins: {'playback': [RTMP]},
    rtmpConfig: {
        swfPath: 'dist/assets/RTMP.swf',
        scaling:'stretch',
        playbackType: 'live',
        bufferTime: 1,
        startLevel: 0
    },
});

@BastienClement
Copy link

The default value is chosen if bufferTime evaluates to false (because of the || operator).
As a result, it is not possible to set bufferTime to 0, disabling buffering entirely.

https://github.com/clappr/clappr-rtmp-plugin/blob/master/src/main.js#L34

I believe === undefined would be a better check here.

This is required in the case the application focuses on no-delay streaming. Even a buffering of 0.1 secs will accumulate latency in the long run if re-buffering is required. A buffering of 0 will always be as live as possible.

@gfronza
Copy link
Collaborator

gfronza commented Dec 5, 2015

@galedric I used the || operator on purpose there, because my experience with bufferTime 0 is that it brings a lot of side effects. But I agree that this should be the programmers' responsibility, so will change this behaviour. Thanks for pointing that out.

@gfronza
Copy link
Collaborator

gfronza commented Dec 12, 2015

@galedric #35 will fix it.

@gfronza gfronza added the bug label Dec 14, 2015
@gfronza gfronza added this to the 0.0.8 milestone Dec 14, 2015
@gfronza gfronza closed this as completed Dec 15, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants