Permalink
Browse files

Initial commit of sample app code to GitHub

  • Loading branch information...
robgabbard-wowza committed May 20, 2016
1 parent cbdc19c commit 6753466567f78930189b936f8bd30c262347fe1f
Showing with 3,601 additions and 0 deletions.
  1. +30 −0 README.md
  2. BIN activities.png
  3. +2 −0 app/.gitignore
  4. +29 −0 app/build.gradle
  5. +17 −0 app/proguard-rules.pro
  6. +62 −0 app/src/main/AndroidManifest.xml
  7. +408 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/CameraActivity.java
  8. +313 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/GoCoderSDKActivityBase.java
  9. +82 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/MainActivity.java
  10. +102 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/config/ConfigPrefs.java
  11. +230 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/config/ConfigPrefsActivity.java
  12. +400 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/mp4/MP4BroadcastActivity.java
  13. +151 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/mp4/MP4CaptureActivity.java
  14. +107 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/ui/AutoFocusListener.java
  15. +99 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/ui/ControlButton.java
  16. +198 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/ui/StatusView.java
  17. +77 −0 app/src/main/java/com/wowza/gocoder/sdk/sampleapp/ui/TimerView.java
  18. BIN app/src/main/res/drawable-hdpi/ic_gear.png
  19. BIN app/src/main/res/drawable-hdpi/ic_mic.png
  20. BIN app/src/main/res/drawable-hdpi/ic_mic_off.png
  21. BIN app/src/main/res/drawable-hdpi/ic_mic_on.png
  22. BIN app/src/main/res/drawable-hdpi/ic_pause.png
  23. BIN app/src/main/res/drawable-hdpi/ic_photo.png
  24. BIN app/src/main/res/drawable-hdpi/ic_play.png
  25. BIN app/src/main/res/drawable-hdpi/ic_refresh.png
  26. BIN app/src/main/res/drawable-hdpi/ic_refresh_off.png
  27. BIN app/src/main/res/drawable-hdpi/ic_satellite.png
  28. BIN app/src/main/res/drawable-hdpi/ic_settings.png
  29. BIN app/src/main/res/drawable-hdpi/ic_start.png
  30. BIN app/src/main/res/drawable-hdpi/ic_stop.png
  31. BIN app/src/main/res/drawable-hdpi/ic_switch_camera.png
  32. BIN app/src/main/res/drawable-hdpi/ic_torch_off.png
  33. BIN app/src/main/res/drawable-hdpi/ic_torch_on.png
  34. BIN app/src/main/res/drawable-hdpi/ic_video_library.png
  35. BIN app/src/main/res/drawable-hdpi/ic_videocam.png
  36. BIN app/src/main/res/drawable-hdpi/ic_wowza.png
  37. BIN app/src/main/res/drawable-mdpi/ic_gear.png
  38. BIN app/src/main/res/drawable-mdpi/ic_mic.png
  39. BIN app/src/main/res/drawable-mdpi/ic_mic_off.png
  40. BIN app/src/main/res/drawable-mdpi/ic_mic_on.png
  41. BIN app/src/main/res/drawable-mdpi/ic_pause.png
  42. BIN app/src/main/res/drawable-mdpi/ic_photo.png
  43. BIN app/src/main/res/drawable-mdpi/ic_play.png
  44. BIN app/src/main/res/drawable-mdpi/ic_refresh.png
  45. BIN app/src/main/res/drawable-mdpi/ic_refresh_off.png
  46. BIN app/src/main/res/drawable-mdpi/ic_satellite.png
  47. BIN app/src/main/res/drawable-mdpi/ic_settings.png
  48. BIN app/src/main/res/drawable-mdpi/ic_start.png
  49. BIN app/src/main/res/drawable-mdpi/ic_stop.png
  50. BIN app/src/main/res/drawable-mdpi/ic_switch_camera.png
  51. BIN app/src/main/res/drawable-mdpi/ic_torch_off.png
  52. BIN app/src/main/res/drawable-mdpi/ic_torch_on.png
  53. BIN app/src/main/res/drawable-mdpi/ic_video_library.png
  54. BIN app/src/main/res/drawable-mdpi/ic_videocam.png
  55. BIN app/src/main/res/drawable-mdpi/ic_wowza.png
  56. BIN app/src/main/res/drawable-xhdpi/ic_gear.png
  57. BIN app/src/main/res/drawable-xhdpi/ic_mic.png
  58. BIN app/src/main/res/drawable-xhdpi/ic_mic_off.png
  59. BIN app/src/main/res/drawable-xhdpi/ic_mic_on.png
  60. BIN app/src/main/res/drawable-xhdpi/ic_pause.png
  61. BIN app/src/main/res/drawable-xhdpi/ic_photo.png
  62. BIN app/src/main/res/drawable-xhdpi/ic_play.png
  63. BIN app/src/main/res/drawable-xhdpi/ic_refresh.png
  64. BIN app/src/main/res/drawable-xhdpi/ic_refresh_off.png
  65. BIN app/src/main/res/drawable-xhdpi/ic_satellite.png
  66. BIN app/src/main/res/drawable-xhdpi/ic_settings.png
  67. BIN app/src/main/res/drawable-xhdpi/ic_start.png
  68. BIN app/src/main/res/drawable-xhdpi/ic_stop.png
  69. BIN app/src/main/res/drawable-xhdpi/ic_switch_camera.png
  70. BIN app/src/main/res/drawable-xhdpi/ic_torch_off.png
  71. BIN app/src/main/res/drawable-xhdpi/ic_torch_on.png
  72. BIN app/src/main/res/drawable-xhdpi/ic_video_library.png
  73. BIN app/src/main/res/drawable-xhdpi/ic_videocam.png
  74. BIN app/src/main/res/drawable-xhdpi/ic_wowza.png
  75. BIN app/src/main/res/drawable-xxhdpi/ic_gear.png
  76. BIN app/src/main/res/drawable-xxhdpi/ic_mic.png
  77. BIN app/src/main/res/drawable-xxhdpi/ic_mic_off.png
  78. BIN app/src/main/res/drawable-xxhdpi/ic_mic_on.png
  79. BIN app/src/main/res/drawable-xxhdpi/ic_pause.png
  80. BIN app/src/main/res/drawable-xxhdpi/ic_photo.png
  81. BIN app/src/main/res/drawable-xxhdpi/ic_play.png
  82. BIN app/src/main/res/drawable-xxhdpi/ic_refresh.png
  83. BIN app/src/main/res/drawable-xxhdpi/ic_refresh_off.png
  84. BIN app/src/main/res/drawable-xxhdpi/ic_satellite.png
  85. BIN app/src/main/res/drawable-xxhdpi/ic_settings.png
  86. BIN app/src/main/res/drawable-xxhdpi/ic_start.png
  87. BIN app/src/main/res/drawable-xxhdpi/ic_stop.png
  88. BIN app/src/main/res/drawable-xxhdpi/ic_switch_camera.png
  89. BIN app/src/main/res/drawable-xxhdpi/ic_torch_off.png
  90. BIN app/src/main/res/drawable-xxhdpi/ic_torch_on.png
  91. BIN app/src/main/res/drawable-xxhdpi/ic_video_library.png
  92. BIN app/src/main/res/drawable-xxhdpi/ic_videocam.png
  93. BIN app/src/main/res/drawable-xxhdpi/ic_wowza.png
  94. BIN app/src/main/res/drawable-xxxhdpi/ic_gear.png
  95. BIN app/src/main/res/drawable-xxxhdpi/ic_mic.png
  96. BIN app/src/main/res/drawable-xxxhdpi/ic_mic_off.png
  97. BIN app/src/main/res/drawable-xxxhdpi/ic_mic_on.png
  98. BIN app/src/main/res/drawable-xxxhdpi/ic_pause.png
  99. BIN app/src/main/res/drawable-xxxhdpi/ic_photo.png
  100. BIN app/src/main/res/drawable-xxxhdpi/ic_play.png
  101. BIN app/src/main/res/drawable-xxxhdpi/ic_refresh.png
  102. BIN app/src/main/res/drawable-xxxhdpi/ic_refresh_off.png
  103. BIN app/src/main/res/drawable-xxxhdpi/ic_satellite.png
  104. BIN app/src/main/res/drawable-xxxhdpi/ic_settings.png
  105. BIN app/src/main/res/drawable-xxxhdpi/ic_start.png
  106. BIN app/src/main/res/drawable-xxxhdpi/ic_stop.png
  107. BIN app/src/main/res/drawable-xxxhdpi/ic_switch_camera.png
  108. BIN app/src/main/res/drawable-xxxhdpi/ic_torch_off.png
  109. BIN app/src/main/res/drawable-xxxhdpi/ic_torch_on.png
  110. BIN app/src/main/res/drawable-xxxhdpi/ic_video_library.png
  111. BIN app/src/main/res/drawable-xxxhdpi/ic_videocam.png
  112. BIN app/src/main/res/drawable-xxxhdpi/ic_wowza.png
  113. +16 −0 app/src/main/res/drawable/rounded_corner.xml
  114. +142 −0 app/src/main/res/layout/activity_camera.xml
  115. +18 −0 app/src/main/res/layout/activity_main.xml
  116. +117 −0 app/src/main/res/layout/activity_mp4_broadcast.xml
  117. +129 −0 app/src/main/res/layout/activity_mp4_capture.xml
  118. +36 −0 app/src/main/res/layout/activity_surface_texture.xml
  119. +39 −0 app/src/main/res/layout/example_row.xml
  120. +32 −0 app/src/main/res/layout/status_view.xml
  121. BIN app/src/main/res/mipmap-hdpi/ic_launcher.png
  122. BIN app/src/main/res/mipmap-mdpi/ic_launcher.png
  123. BIN app/src/main/res/mipmap-xhdpi/ic_launcher.png
  124. BIN app/src/main/res/mipmap-xxhdpi/ic_launcher.png
  125. BIN app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  126. +41 −0 app/src/main/res/raw/per_pixel_fragment_shader.glsl
  127. +32 −0 app/src/main/res/raw/per_pixel_vertex_shader.glsl
  128. +6 −0 app/src/main/res/raw/point_fragment_shader.glsl
  129. +8 −0 app/src/main/res/raw/point_vertex_shader.glsl
  130. +5 −0 app/src/main/res/values-v21/styles.xml
  131. +6 −0 app/src/main/res/values-w820dp/dimens.xml
  132. +12 −0 app/src/main/res/values/attrs.xml
  133. +10 −0 app/src/main/res/values/colors.xml
  134. +5 −0 app/src/main/res/values/dimens.xml
  135. +110 −0 app/src/main/res/values/strings.xml
  136. +10 −0 app/src/main/res/values/styles.xml
  137. +41 −0 app/src/main/res/xml/audio_preferences.xml
  138. +20 −0 app/src/main/res/xml/capture_pref_headers.xml
  139. +10 −0 app/src/main/res/xml/connection_only_pref_headers.xml
  140. +45 −0 app/src/main/res/xml/connection_preferences.xml
  141. +15 −0 app/src/main/res/xml/video_and_connection.xml
  142. +76 −0 app/src/main/res/xml/video_preferences.xml
  143. +26 −0 build.gradle
  144. +18 −0 gradle.properties
  145. BIN gradle/wrapper/gradle-wrapper.jar
  146. +6 −0 gradle/wrapper/gradle-wrapper.properties
  147. +160 −0 gradlew
  148. +90 −0 gradlew.bat
  149. +12 −0 local.properties
  150. +1 −0 settings.gradle
View
@@ -0,0 +1,30 @@
# Wowza GoCoder SDK for Android Sample App
This repository contains an sample application that demonstrates the capabilities of the [Wowza GoCoder™ SDK for Android](https://www.wowza.com/products/gocoder).
## Development Requirements
- Android SDK 4.4.2 or later
- Android Studio 1.2.0 or later
## Sample App Activities
When you first run the sample app it displays a list of activities that demonstrate the features of the GoCoder SDK.
![Sample App Activities](activities.png)
|Title|Activity Class|Description|
|-|-|-|
|**Stream live video and audio**|`CameraActivity.java`|This activity demonstrates the primary camera, audio, and live streaming capabilities of the GoCoder SDK.|
|**Stream an MP4 file**|`MP4BroadcastActivity.java`|This activity demonstrates how to broadcast the frames from a local MP4 file using the WZBroadcast and WZBroadcastComponent (and related) classes/interfaces, which provide lower-level access to the various components involved in a Wowza broadcast.|
|**Capture an MP4 file**|`MP4CaptureActivity.java`|This activity saves the video from the camera to an MP4 file on the device's local storage as it is being streamed.|
## More resources
- [Wowza GoCoder Software Development Kit](https://www.wowza.com/products/gocoder/sdk)
- [Wowza GoCoder SDK Developer Documentation](https://www.wowza.com/resources/gocodersdk/docs/1.0/)
Wowza Media Systems™ provides developers with a platform to create streaming applications and solutions. See [Wowza Developer Tools](https://www.wowza.com/resources/developers) to learn more about our APIs and SDK.
## Contact
[Wowza Media Systems, LLC](https://www.wowza.com/contact)
## License
This code is distributed under the [BSD 3-Clause License](https://github.com/WowzaMediaSystems/gocoder-sdk-samples-ios/blob/master/LICENSE.txt).
View
Binary file not shown.
View
@@ -0,0 +1,2 @@
build
libs/com.wowza.gocoder.sdk.aar
View
@@ -0,0 +1,29 @@
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
applicationId 'com.wowza.gocoder.sdk.sampleapp'
minSdkVersion 19
targetSdkVersion 23
versionCode 3
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
productFlavors {
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.wowza.gocoder.sdk.android:com.wowza.gocoder.sdk:1.0@aar'
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:support-v4:23.1.1'
}
View
@@ -0,0 +1,17 @@
# Add project specific ProGuard rules here.
# By default, the flags in this file are appended to flags specified
# in /Users/rob/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 *;
#}
@@ -0,0 +1,62 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.wowza.gocoder.sdk.sampleapp">
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.FLASHLIGHT" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-feature android:name="android.hardware.camera.any" android:required="false" />
<uses-feature android:name="android.hardware.camera.autofocus" android:required="false" />
<uses-feature android:name="android.hardware.camera.flash" android:required="false" />
<uses-feature android:name="android.hardware.microphone" android:required="false" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name_short"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name=".MainActivity"
android:logo="@drawable/ic_wowza"
android:label="@string/app_name_short">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".CameraActivity"
android:configChanges="orientation|keyboardHidden|screenSize"
android:screenOrientation="fullSensor"
android:logo="@drawable/ic_wowza"
android:label="@string/camera_example_title">
</activity>
<activity android:name=".mp4.MP4BroadcastActivity"
android:label="@string/mp4_broadcast_title"/>
<activity android:name=".mp4.MP4CaptureActivity"
android:configChanges="orientation|keyboardHidden|screenSize"
android:screenOrientation="fullSensor"
android:label="@string/mp4_capture_title"/>
<activity android:name=".opengles.SurfaceTextureActivity"
android:configChanges="orientation|keyboardHidden|screenSize"
android:screenOrientation="landscape"
android:label="@string/surface_view_title"/>
<activity android:name=".config.ConfigPrefsActivity"
android:icon="@drawable/ic_gear"
android:label="@string/configuration_settings_title" />
</application>
</manifest>
Oops, something went wrong.

0 comments on commit 6753466

Please sign in to comment.