2009-05-19 21 views
4

私は近い将来に書き込む必要のあるiPhoneアプリケーション用のビデオストリーミングを研究しています。アプリケーションは、ストリームビデオ以外のものはたくさんありますが、ビデオアスペクトは私が経験していない部分です。埋め込みビデオ付きiPhoneアプリケーションを作成する

ストリーミングビデオアプリの作成に関する優れた記事は誰でも知っていますか?

Googleは、私が求めていることをしないことすべてを持っているリンクで私を溢れさせるようだ。

おかげで、

メートル

+0

をしたり、専門知識を持っているとしたい場合は、あまりにも動作します開始する方法についていくつかのガイダンスを、提供する:MPMoviePlayerControllerのためのAppleのドキュメントには、これを行うことができる方法を説明します! – michael

+0

http://stackoverflow.com/questions/778574/live-video-streaming-how-to-play-it-on-iphone – voyager

答えて

1

Appleは、私はドキュメントをNtheirのメディアフレームワークの良いドキュメントを提供しています。

MPMoviePlayerControllerを検索します。次のサンプルコードは、URLからムービーを再生します。 (免責事項、このコードはAppleから削除されました)。

-(void)playMovieAtURL:(NSURL*)theURL 

{ 
    MPMoviePlayerController* theMovie=[[MPMoviePlayerController alloc] initWithContentURL:theURL]; 
    theMovie.scalingMode=MPMovieScalingModeAspectFill; 
    theMovie.userCanShowTransportControls=NO; 

    // Register for the playback finished notification. 

    [[NSNotificationCenter defaultCenter] addObserver:self 
              selector:@selector(myMovieFinishedCallback:) 
               name:MPMoviePlayerPlaybackDidFinishNotification 
               object:theMovie]; 

    // Movie playback is asynchronous, so this method returns immediately. 
    [theMovie play]; 
} 

// When the movie is done,release the controller. 
-(void)myMovieFinishedCallback:(NSNotification*)aNotification 
{ 
    MPMoviePlayerController* theMovie=[aNotification object]; 
    [[NSNotificationCenter defaultCenter] removeObserver:self 
                name:MPMoviePlayerPlaybackDidFinishNotification 
                object:theMovie]; 

    // Release the movie instance created in playMovieAtURL 
    [theMovie release]; 
} 
+0

ありがとうございました。私はムービープレイヤーの使用についていくらか認識していましたが、さらに統合されたムービーを再生するためのライブラリがあるかどうか疑問に思っていました。つまり、自分のアプリのUIを表示している間に小さなフレームムービーを再生します。 – michael

+0

VLCを見てください。オープンソースで、(Jailbroken)iPhoneに移植されています –

0

私もこの問題を検討しています。私はiPadアプリにビデオを埋め込みたいと思っています。これは、AP通信のiPadアプリケーションがビデオをどのように扱うかのようなものです。

OS 3.2以降では、このタイプの埋め込みビデオを作成できます。

http://developer.apple.com/iphone/library/documentation/MediaPlayer/Reference/MPMoviePlayerController_Class/MPMoviePlayerController/MPMoviePlayerController.html