-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IDSK-2547 Re-writing AVPlayerExample #406
Open
piyushtank
wants to merge
9
commits into
master
Choose a base branch
from
task/ISDK-2547-Local-Audio-Mixing
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
2f5fd84
Removed AVPlayerExample
piyushtank b2bdd6b
Removed AVPlayerExample.xcodeproj
piyushtank 0e2f687
Added new AVPlayerExample
piyushtank 4b3f036
Fixed bridging header path
piyushtank cfb251f
AudioDevice mixes on local playout side only
piyushtank bf74ff3
Removed Viewer functionalities
piyushtank 81d1f7e
UI changes
piyushtank a077966
Using CameraSource APIs
piyushtank 9f1d961
Hide audio mixing switch
piyushtank File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
258 changes: 148 additions & 110 deletions
258
AVPlayerExample.xcodeproj/project.pbxproj
100644 → 100755
Large diffs are not rendered by default.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
AVPlayerExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata
100644 → 100755
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
8 changes: 8 additions & 0 deletions
8
AVPlayerExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>IDEDidComputeMac32BitWarning</key> | ||
<true/> | ||
</dict> | ||
</plist> |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
// | ||
// AppDelegate.swift | ||
// AVPlayerExample | ||
// | ||
// Copyright © 2018 Twilio Inc. All rights reserved. | ||
// | ||
|
||
import UIKit | ||
|
||
@UIApplicationMain | ||
class AppDelegate: UIResponder, UIApplicationDelegate { | ||
|
||
var window: UIWindow? | ||
|
||
|
||
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { | ||
print("didFinishLaunchingWithOptions:", launchOptions as Any) | ||
if let options = launchOptions, | ||
let videoUrl = options[UIApplication.LaunchOptionsKey.url] as? URL { | ||
let rootVC = window?.rootViewController as! ViewController | ||
rootVC.connect(contentUrl: videoUrl) | ||
} | ||
return true | ||
} | ||
|
||
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool { | ||
print("app:openURL:", url, " options:", options as Any) | ||
|
||
let rootVC = window?.rootViewController as! ViewController | ||
rootVC.connect(contentUrl: url) | ||
|
||
return true | ||
} | ||
|
||
func applicationWillResignActive(_ application: UIApplication) { | ||
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. | ||
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. | ||
} | ||
|
||
func applicationDidEnterBackground(_ application: UIApplication) { | ||
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. | ||
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. | ||
} | ||
|
||
func applicationWillEnterForeground(_ application: UIApplication) { | ||
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. | ||
} | ||
|
||
func applicationDidBecomeActive(_ application: UIApplication) { | ||
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. | ||
} | ||
|
||
func applicationWillTerminate(_ application: UIApplication) { | ||
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. | ||
} | ||
|
||
|
||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"info" : { | ||
"version" : 1, | ||
"author" : "xcode" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
// | ||
// AudioDevices-Bridging-Header.h | ||
// AVPlayerExample | ||
// | ||
// Copyright © 2018 Twilio Inc. All rights reserved. | ||
// | ||
|
||
#import "ExampleAVPlayerAudioDevice.h" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// | ||
// ExampleAVPlayerAudioDevice.h | ||
// AVPlayerExample | ||
// | ||
// Copyright © 2018 Twilio, Inc. All rights reserved. | ||
// | ||
|
||
#import <TwilioVideo/TwilioVideo.h> | ||
|
||
/* | ||
* ExampleAVPlayerAudioDevice uses a VoiceProcessingIO audio unit to play audio from an MTAudioProcessingTap | ||
* attached to an AVPlayerItem. The AVPlayer audio is mixed with Room audio provided by Twilio. | ||
* The microphone input, and MTAudioProcessingTap output are mixed into a single recorded stream. | ||
*/ | ||
@interface ExampleAVPlayerAudioDevice : NSObject <TVIAudioDevice> | ||
|
||
- (void)audioTapDidPrepare; | ||
|
||
- (void)startAudioTapAtTime:(CMTime)startTime; | ||
|
||
/* | ||
* Creates a processing tap bound to the device instance. | ||
* | ||
* @return An `MTAudioProcessingTap`, or NULL if there is an error. The caller assumes all ownership | ||
* of the tap, and should call CFRelease when they are finished with it. | ||
*/ | ||
- (nullable MTAudioProcessingTapRef)createProcessingTap; | ||
|
||
@end |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.