Giter Club home page Giter Club logo

zowvideoplayer's Introduction

ZOWVideoPlayer

Usage

Drag ZOWVideoPlayer folder into your project, then link MobileCoreServices.framework, CoreMedia.framework and AVFoundation.framework in your project Build Phases.

Play Videos

Play video through a ZOWVideoPlayer

You can #import "ZOWVideoPlayer.h" and call

[self.videoPlayer playVideoWithURL:url];

to play a web video. In this way, you need to build video view yourself to sync the video behavior, for example, show loading indicator when video stucked. You can provide video view through a ZOWVideoPlayer.datasource, and receive event in ZOWVideoPlayer.delegate.

Play video through a established view(Recomended)

A ZOWVideoPlayerView is designed to handle the view issue besides the main video play process. You can subclass it to customize your own view behaviors.

You can play video through a ZOWVideoPlayerView subclass with

[self.videoView playVideoWithURL:url];

and the view itself will handle the video behaviors. Check the InstagramVideoView implementation example in the project to learn more about the subclassing.

Stop video play

If you want to stop a video, call [self.videoPlayer stopVideoPlay] or [self.videoView stopVideoPlay] to stop it. This will cancel the video buffering, remove the video layer and remove all the notifications. If you just want to pause the video, just call the pause method.

Features

Preload Buffer

if video play stuck when loading, the player will pause and prebuffer a few seconds to provide a merely smooth video play.

Cache

when a web video finishes play, the video will be auto cached. And when the next time you play the video through the same url, the cached video will be played. You can customize the video cached path through the videoCachedDirectory property.

End Action

provide end action to define the behavior of the video when video play reaching the end. You can reset the video status or replay it or just pause it at the end.

Background Resume

on default, the video play will auto pause when enter background, and auto resume when enter foreground. Set autoResumeFromBackground to NO to avoid auto resume.

zowvideoplayer's People

Contributors

stoncle avatar

Stargazers

Colin Walsh avatar Vatsal Kelawala avatar  avatar prodream avatar WL avatar Luka avatar Sergey Kazakov avatar Sebastian Barajas avatar AIZEN avatar Thomas Liu avatar Pawan Kumar Rai avatar Sachin Nautiyal avatar ADevTech avatar chris avatar  avatar Gerard McDonald avatar

Watchers

Sergey Kazakov avatar swiftAngel avatar  avatar

zowvideoplayer's Issues

Not working with UICollectionViewCell.

Hey,

I try to add InstagramVideoView to UICollectionViewCell.
But It's not working well. Just showing progress not play video.
Anyone can help me on this?

Thanks.

not working on UITableview

As the sample code directs, I followed all the steps to integrate the video player in UITableview but fortunately It didn't works. Can anyone please guide me to work it properly. Thanks

About changing the tab in tabbar

I am using the tab bar for making the Instagram-like app. But whenever I am changing the tabs I am unable to get the video player on the view will appear, its always returning me nil. Don't know why but for every other case it's working superb only for this case, have you included any observer for that, let me know if there is any.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.