iOS – How to play a video with transparency?

Don’t know if anyone is still interested in this besides me, but I’m using GPUImage and the Chromakey filter to achieve this^^ https://github.com/BradLarson/GPUImage EDIT: example code of what I did (may be dated now): -(void)AnimationGo:(GPUImageView*)view { NSURL *url = [[NSBundle mainBundle] URLForResource:@”test” withExtension:@”mov”]; movieFile = [[GPUImageMovie alloc] initWithURL:url]; filter = [[GPUImageChromaKeyBlendFilter alloc] init]; [movieFile addTarget:filter]; … Read more

Avoiding blurriness at start & end of video (even after using setPreferredVideoStabilizationMode:AVCaptureVideoStabilizationModeAuto)?

Video is blurry by its nature. 24 or 30 frames per second video will always have some blur in the shot because that’s the way our eyes are tricked into believing the pictures are actually moving. The longer shutter speed allows the camera to give the impression of motion. Photos use a much shorter shutter … Read more

Youtube Video in WebView doesn’t load

Now it works, with a combination of some things: public class Videos extends Activity { private WebView mWebView; private String extra; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.videos_layout); extra = getIntent().getStringExtra(“VideosId”); mWebView = (WebView) findViewById(R.id.videos_webview); mWebView.getSettings().setJavaScriptEnabled(true); mWebView.getSettings().setPluginsEnabled(true); final Activity activity = this; mWebView.setWebChromeClient(new WebChromeClient() { public void onProgressChanged(WebView view, int progress) { // Activities … Read more

How to share NSData or phasset video using Facebook iOS SDK 4.0 FBSDKShareDialog

With the new Facebook SDK 4.0, videos must be passed as assets URL. You have to copy your local video path to Assets Library and use that generated URL to share on Facebook. Step 1: NSURL *videoURL=[NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResource:@”IMG_1007″ ofType:@”mp4″]]; [self saveToCameraRoll:videoURL]; Step 2: – (void)saveToCameraRoll:(NSURL *)srcURL { NSLog(@”srcURL: %@”, srcURL); ALAssetsLibrary *library = … Read more

create movie from [UIImage], Swift

I convert the objective-c code that posted by ā€™@Cameron Eā€˜ to Swift 3, and It’s working. the answer’s link:@Cameron E’s CEMovieMaker following is CXEImagesToVideo class: // // CXEImagesToVideo.swift // VideoAPPTest // // Created by Wulei on 16/12/14. // Copyright Ā© 2016 wulei. All rights reserved. // import Foundation import AVFoundation import UIKit typealias CXEMovieMakerCompletion = … Read more

Android MediaStore insertVideo

Here is an easy ‘single file based solution’: Whenever you add a file, let MediaStore Content Provider knows about it using sendBroadcast(new Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE, Uri.fromFile(imageAdded))); Main advantage: work with any mime type supported by MediaStore Whenever you delete a file, let MediaStore Content Provider knows about it using getContentResolver().delete(uri, null, null)