开发者

How to change full screen mode during play video

开发者 https://www.devze.com 2023-01-26 16:04 出处:网络
Now I am make video player. and try to make video screen size change. I find MediaPlayer.OnVideoSizeChangedListener mSizeCha开发者_如何学CngedListener =

Now I am make video player. and try to make video screen size change.

I find

MediaPlayer.OnVideoSizeChangedListener mSizeCha开发者_如何学CngedListener =
    new MediaPlayer.OnVideoSizeChangedListener() {

but this is callback function. not direct call function.

How to change video screen size?


take a look at this demo on the android site, look at the method startVideoPlayback

http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Video.html


You can change the screen size by calling SetFixedSize() on your SurfaceHolder: http://developer.android.com/reference/android/view/SurfaceHolder.html

0

精彩评论

暂无评论...
验证码 换一张
取 消