开发者

iPhone SDK: Custom video player controls

开发者 https://www.devze.com 2022-12-12 07:24 出处:网络
In my iPhone app I have designed a custom video player, currently it is v开发者_如何学编程ery basic with just a play pause and stop button,

In my iPhone app I have designed a custom video player, currently it is v开发者_如何学编程ery basic with just a play pause and stop button, but I would like the user to be able to scrub, (I think thats the right word) the video like you can do with apple's original media player. So for Instance I would like to be able to take a UISlider and have it control the current postiion of the videos playback if you get what I mean. Oh and incase your curious, the way I pause/play/stop the video is by using this simple piece of code [self.theMovie play]; [self.theMovie stop]; [self.theMovie pause]; The trouble is I don't know how to scrub the video. Any help appreciated.


I've asked the same question: customize quicktime iphone and here MPVideoPlayer add/remove buttons

It seams that you have to posibilities:

  1. You can add you view over the main window. An sample can be found here: MoviePlayer Sample
  2. You can iterate through views, found one you need and Add/Remove views. I don't know yet how must does Apple likes/dislikes this method.
0

精彩评论

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