Difference between revisions of "VLCKit"

From VideoLAN Wiki
Jump to navigation Jump to search
(categorise)
Line 1: Line 1:
 +
This page provides a brief overview on the [[LibVLC]] Objective-C binding.
 +
 
=== Build the framework ===  
 
=== Build the framework ===  
  
Line 6: Line 8:
 
* build the project
 
* build the project
  
this should automatically build vlc itself.
+
This should automatically build VLC itself.
  
 
== Basic usage in your application ==
 
== Basic usage in your application ==
Line 24: Line 26:
 
You should be able to find sample code in:
 
You should be able to find sample code in:
 
* <code> Examples </code>: This is the folder that contains the VLC.framework basics usage.
 
* <code> Examples </code>: This is the folder that contains the VLC.framework basics usage.
 +
* <code> ./vlc/projects/macosx/vlc_app </code>: This is the VLC application that uses the framework intensivly, this is much more advanced.
  
* <code> ./vlc/projects/macosx/vlc_app </code>: This is the VLC application that uses the framework intensivly, this is much more advanced.
+
[[Category:LibVLC]]
 +
[[Category:Mac OS X]]

Revision as of 14:21, 14 August 2013

This page provides a brief overview on the LibVLC Objective-C binding.

Build the framework

  • Clone git.videolan.org/vlc-bindings/VLCKit.git
  • open .VLCKit.xcodeproj
  • make sure the VLCKit target is selected
  • build the project

This should automatically build VLC itself.

Basic usage in your application

The code should speak by itself

  // Set up a videoView by hand. You can also do that in the nib file
   videoView = [[VLCVideoView alloc] initWithFrame:[[window contentView] bounds]];
   [[window contentView] addSubview:videoView];
   [videoView setAutoresizingMask: NSViewHeightSizable|NSViewWidthSizable];
  
   // Init the player object
   player = [[VLCMediaPlayer alloc] initWithVideoView:videoView];
 
   [player setMedia:[VLCMedia mediaWithPath:@"/to/my/movie"]];
   [player play];

Sample code

You should be able to find sample code in:

  • Examples : This is the folder that contains the VLC.framework basics usage.
  • ./vlc/projects/macosx/vlc_app : This is the VLC application that uses the framework intensivly, this is much more advanced.