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

How to rotate EPlayerView? #56

Closed
memishood opened this issue Sep 7, 2020 · 2 comments
Closed

How to rotate EPlayerView? #56

memishood opened this issue Sep 7, 2020 · 2 comments

Comments

@memishood
Copy link

I want to rotate the video but i couldn't find any method, I have tried rotate the parent layout but it wasn't successful

@memishood
Copy link
Author

I have solved the problem by adding the following codes to the Renderer Class;

@Override
public void onDrawFrame(final EFramebufferObject fbo) {
       ...
       Matrix.scaleM(MVPMatrix, 0, scale[0], scale[1], 1); // fix video stretch using scale
       Matrix.rotateM(MVPMatrix, 0, -angle, 0.f, 0.f, 1.f); // rotate the video
       ....
       previewFilter.draw(texName, MVPMatrix, STMatrix, aspectRatio);
}

@vikas-shrma
Copy link

@memishood can u help me
I ma creating app with Landscape mode and when i try to show vertical type video. Then it will stretch or not properly view

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

No branches or pull requests

2 participants