Android: How to create video player?

后端 未结 2 459
南方客
南方客 2020-12-13 16:59

I am creating a video recorder and would like to create video player to preview the recorded videos. Modifying the code from this page I have created a MediaPreview class th

相关标签:
2条回答
  • 2020-12-13 17:22

    Off the cuff, I think you need some more logic in some of your callback methods, like surfaceCreated().

    0 讨论(0)
  • 2020-12-13 17:41

    You need to attach the surface to the played after the surface is created.

    call

     mp.setDisplay(mPreview.getHolder());
    

    from inside

    public void surfaceCreated(SurfaceHolder holder)
    
    0 讨论(0)
提交回复
热议问题