Skip to content
This repository has been archived by the owner on Jul 20, 2021. It is now read-only.

Player lags when swiping up/down to change volume #60

Open
UGhari opened this issue May 30, 2018 · 0 comments
Open

Player lags when swiping up/down to change volume #60

UGhari opened this issue May 30, 2018 · 0 comments

Comments

@UGhari
Copy link

UGhari commented May 30, 2018

    • Better Video Player version: 1.2.alpha1
    • Device OS version: 8.0
    • Device Manufacturer: Samsung
    • Device Name: Galaxy S7

I enable swipe gestures on the player as follows:

        player = findViewById(R.id.player);
        player.setCallback(this);
        player.enableSwipeGestures(getWindow());
        player.setLoadingStyle(2);
        player.getToolbar().inflateMenu(R.menu.player);
        player.getToolbar().setOnMenuItemClickListener((item) -> {
           ...
        }
            return false;
        });

Heres the XML for the player:

<com.halilibo.bettervideoplayer.BetterVideoPlayer xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/player" android:layout_width="match_parent" android:layout_height="match_parent" app:bvp_autoPlay="true" />

Problem:

When swiping up/down to change volume (the video is still playing) the frame rate on the video drops significantly to roughly 10fps. As soon as you stop swiping/ release finger it goes back to normal smooth fps.

Any idea why this is happening? If so could you tell me why please? if its a fix in the code and you dont have time to implement it if you give me a high level overview as to why its happening and where in the code then ill be more than happy to help fix it with Pull Request

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant