Skip to content
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

ExoPlayer2 support #55

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Application/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ dependencies {

compile project(':TVUIComponent')
compile project(':UAMP')
compile project(':AMZNMediaPlayerComponent')
compile project(':ExoPlayer2MediaPlayerComponent')
compile project(':PassThroughAdsComponent')
compile project(':PassThroughLoginComponent')
compile project(':LoggerAnalyticsComponent')
Expand Down
1 change: 1 addition & 0 deletions Application/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,4 @@ applicationName = FireAppBuilder
# mediaPlayerType = externalExoPlayer
# compileUrl = com.brightcove.player:exoplayer:5.0.3
# mavenUrl = http://repo.brightcove.com/releases
mavenUrl = https://maven.google.com/
4 changes: 2 additions & 2 deletions Application/settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ include ':app',
':ModuleInterface',
/* Implementations */
':PassThroughAdsComponent',
':AMZNMediaPlayerComponent',
':ExoPlayer2MediaPlayerComponent',
':PassThroughLoginComponent',
':LoggerAnalyticsComponent'

Expand All @@ -57,7 +57,7 @@ project(':AnalyticsInterface').projectDir = new File(rootProject.projectDir, '..
project(':PurchaseInterface').projectDir = new File(rootProject.projectDir, '../PurchaseInterface')

/* Implementations */
project(':AMZNMediaPlayerComponent').projectDir = new File(rootProject.projectDir, '../AMZNMediaPlayerComponent')
project(':ExoPlayer2MediaPlayerComponent').projectDir = new File(rootProject.projectDir, '../ExoPlayer2MediaPlayerComponent')
project(':PassThroughAdsComponent').projectDir = new File(rootProject.projectDir, '../PassThroughAdsComponent')
project(':PassThroughLoginComponent').projectDir = new File(rootProject.projectDir, '../PassThroughLoginComponent')
project(':LoggerAnalyticsComponent').projectDir = new File(rootProject.projectDir, '../LoggerAnalyticsComponent')
Expand Down
69 changes: 69 additions & 0 deletions ExoPlayer2MediaPlayerComponent/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/**
* Copyright 2015-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0/
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/

apply plugin: 'com.android.library'

android {
compileSdkVersion 23
buildToolsVersion "24.0.3"

defaultConfig {
minSdkVersion 21
targetSdkVersion 23
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true

}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
testCoverageEnabled true
}
}
packagingOptions {
pickFirst 'META-INF/LICENSE'
}
//compileOptions {
// sourceCompatibility JavaVersion.VERSION_1_8
// targetCompatibility JavaVersion.VERSION_1_8
//}
}

apply plugin: 'jacoco'
jacoco {
version "0.7.1.201405082137"
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:support-v4:23.1.1'
compile 'com.amazon.android:exoplayer:2.7.1'
compile project(':ModuleInterface')
compile project(':UAMP')

// Set this dependency to use JUnit 4 rules
androidTestCompile 'com.android.support.test:rules:0.4.1'
androidTestCompile('junit:junit:4.12')

androidTestCompile('com.android.support.test:runner:0.4.1') {
exclude module: 'support-annotations'
}
}
17 changes: 17 additions & 0 deletions ExoPlayer2MediaPlayerComponent/proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Add project specific ProGuard rules here.
# By default, the flags in this file are appended to flags specified
# in /Users/urgcelil/Library/Android/sdk/tools/proguard/proguard-android.txt
# You can edit the include path and order by changing the proguardFiles
# directive in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html

# Add any project specific keep options here:

# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}
29 changes: 29 additions & 0 deletions ExoPlayer2MediaPlayerComponent/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<!--
Copyright 2015-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
A copy of the License is located at

http://aws.amazon.com/apache2.0/

or in the "license" file accompanying this file. This file is distributed
on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
express or implied. See the License for the specific language governing
permissions and limitations under the License.
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.amazon.mediaplayer.module">

<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>

<application
android:allowBackup="true">
<meta-data android:name="AMZNAP@CustomExoplayer"
android:value="UAMP@com.amazon.mediaplayer.module.ExoPlayer2MediaPlayerImplCreator"/>
</application>

</manifest>
Loading