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

VideoPlayerAndroid does not adhere to Viewport type #19

Closed
jameelur opened this issue Feb 5, 2016 · 2 comments
Closed

VideoPlayerAndroid does not adhere to Viewport type #19

jameelur opened this issue Feb 5, 2016 · 2 comments

Comments

@jameelur
Copy link

jameelur commented Feb 5, 2016

When using gdx-video on android I found that the VideoPlayerAndroid implementation doesn't adhere to the viewport (fill,fit etc) that it is instantiated with. It's a small viewport/camera problem.

@iMackshun
Copy link

In the VideoPlayerAndroid.java, I replaced these lines in order to make it fill the screen of whatever device it runs on.

//float x = -mp.getVideoWidth() / 2;
//float y = -mp.getVideoHeight() / 2;
//float width = mp.getVideoWidth();
//float height = mp.getVideoHeight();
float x = -(Gdx.graphics.getWidth()/2);
float y = -(Gdx.graphics.getHeight()/2);
float width = Gdx.graphics.getWidth();
float height = Gdx.graphics.getHeight();

@RBogie
Copy link
Member

RBogie commented Feb 8, 2016

This issue can be further discussed in the PR that has been opened to fix this issue ( #20 ).

@RBogie RBogie closed this as completed Feb 8, 2016
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

3 participants