Skip to content

Commit 44860ef

Browse files
authored
Merge pull request #108 from AgoraIO/dev/android
Dev/android
2 parents 69e0300 + 40dc65e commit 44860ef

31 files changed

Lines changed: 2796 additions & 17 deletions

Android/APIExample/app/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ dependencies {
5252

5353
implementation 'io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:1.2.0'
5454
implementation 'com.yanzhenjie:permission:2.0.3'
55+
implementation 'de.javagl:obj:0.2.1'
56+
implementation 'com.google.ar:core:1.0.0'
5557

5658
implementation project(path: ':lib-stream-encrypt')
5759
implementation project(path: ':lib-push-externalvideo')

Android/APIExample/app/src/main/AndroidManifest.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@
4343
android:label="@string/app_name"
4444
android:screenOrientation="portrait" />
4545

46+
<!-- This tag indicates that this application requires ARCore. This results in the Google Play
47+
Store downloading and installing ARCore along with the application. -->
48+
<meta-data android:name="com.google.ar.core" android:value="required" />
49+
4650
</application>
4751

4852
</manifest>

Android/APIExample/app/src/main/java/io/agora/api/example/ExampleActivity.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212

1313
import io.agora.api.component.Constant;
1414
import io.agora.api.example.common.model.ExampleBean;
15+
import io.agora.api.example.examples.advanced.ARCore;
1516
import io.agora.api.example.examples.advanced.AdjustVolume;
1617
import io.agora.api.example.examples.advanced.ChannelEncryption;
1718
import io.agora.api.example.examples.advanced.CustomRemoteVideoRender;
@@ -154,6 +155,9 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
154155
case R.id.action_mainFragment_to_live_streaming:
155156
fragment = new LiveStreaming();
156157
break;
158+
case R.id.action_mainFragment_arcore:
159+
fragment = new ARCore();
160+
break;
157161
default:
158162
fragment = new JoinChannelAudio();
159163
break;
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
package io.agora.api.example.common.model;
2+
3+
import java.nio.ByteBuffer;
4+
5+
/**
6+
* Created by wyylling@gmail.com on 03/01/2018.
7+
*/
8+
9+
public class Peer {
10+
public int uid;
11+
public ByteBuffer data;
12+
public int width;
13+
public int height;
14+
public int rotation;
15+
public long ts;
16+
}

0 commit comments

Comments
 (0)